예제 #1
0
void ofxSkeleton::setup(string atlasPath, string jsonPath){
    
	Bone_setYDown(true);
    
	atlas = Atlas_readAtlasFile(atlasPath.c_str());
    
	SkeletonJson * json = SkeletonJson_create(atlas);
	skeletonData = SkeletonJson_readSkeletonDataFile(json, jsonPath.c_str());
	SkeletonJson_dispose(json);
    
	skeleton = Skeleton_create(skeletonData);
	skeleton->flipX = false;
	skeleton->flipY = false;
	Skeleton_setToSetupPose(skeleton);
    
	stateData = AnimationStateData_create(skeletonData);
    
	state = AnimationState_create(stateData);
}
예제 #2
0
void CCSkeleton::setToSetupPose () {
	Skeleton_setToSetupPose(skeleton);
}