Advertisement Jump to content
Sign in to follow this  
DigiMan Shart

CAL3D Breaks New

This topic is 3656 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Currently I'm using the CAL3D library to do animations in my game, but I've run into a problem as of late. In my cModel class that's a wrapper around the CAL3D stuff the code break when I call new in the ctor, and was wondering if someone could help me spot my error. Thanks.

typedef CalCoreModel Model;
typedef CalModel ModelInstance;

class cModel
		cModel(std::string name, int ID);
		std::string GetFilename(void){return fileName;}
		int modelID;
		int textureCount;
		std::string fileName;
		Model* calModel;
		ModelInstance* calModelInstance;

cModel::cModel(std::string name, int ID)
	fileName = name; 
	modelID = ID; 
	calModel = new CalCoreModel(fileName);//Breaks here
	calModelInstance = NULL;

//Function that calls constructor code
bool LoadAllModels(void)
	//My temporary model
	cModel temp("assets\\Models\\cally\\", 0);
	std::string tempStr = temp.GetFilename();

	return true;

Share this post

Link to post
Share on other sites
I can't step into the cal model struct because I'm using it's .lib and .dll files, but it says the heap seems to be exploding. Outside of that it's hard for me to tell what's really going on.

Share this post

Link to post
Share on other sites
Original post by Antheus
Does this work?
		Model calModel;


cModel::cModel(std::string name, int ID)

Unfortunately, I'm using the newest version of the CAL3D library and in that version they said they felt the create functions were redundant of the constructor, so they got rid of the create functions in favor of using the constructor only.

Share this post

Link to post
Share on other sites
Sign in to follow this  

  • Advertisement

Important Information

By using, you agree to our community Guidelines, Terms of Use, and Privacy Policy. is your game development community. Create an account for your GameDev Portfolio and participate in the largest developer community in the games industry.

Sign me up!