Click here to Skip to main content
15,893,190 members
Articles / Multimedia / DirectX

Loading and Rendering Milkshape 3D Models with Animation and Skinning

Rate me:
Please Sign up or sign in to vote.
4.81/5 (13 votes)
18 May 2011CPOL5 min read 88.8K   4.6K   31  
This article shows how to load Milkshape ms3d binary files, animate and display them with OpenGL
/*
------------------------------------------------------------------------------------------
Author:
Boroş Tiberiu
Administrator Sistem                                                    Tel.: +40745310081
Institutul de Cercetări pentru Inteligenţă Artificială,
Academia Română
Calea 13 Septembrie, Nr. 13, CASA ACADEMIEI, Bucuresti 050711, ROMANIA
Tel.: +40-(0)213188103
Fax: +40-(0)213188142
E-mail: office@racai.ro
Web: http://www.racai.ro
------------------------------------------------------------------------------------------
*/
package Grizle.Models.Structures;

public class MilkshapeJoint {
    public byte flags;
    public String name="";
    public String parentName="";
    public float pos[]=new float[3];
    public float rot[]=new float[3];
    public MilkshapeKeyFrame rotationKeys[];
    public MilkshapeKeyFrame positionKeys[];
    public MilkshapeTangent tangents[];
    public String comment="";
    public float color[]=new float[3];
    public int parentIndex;
    public float matLocalSkeleton[][]=new float[3][4];
    public float matGlobalSkeleton[][]=new float[3][4];
    public float matLocal[][]=new float[3][4];
    public float matGlobal[][]=new float[3][4];
}

By viewing downloads associated with this article you agree to the Terms of Service and the article's licence.

If a file you wish to view isn't highlighted, and is a text file (not binary), please let us know and we'll add colourisation support for it.

License

This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)


Written By
Research Institute For Artificial Intelligence, Ro
Romania Romania
This member has not yet provided a Biography. Assume it's interesting and varied, and probably something to do with programming.

Comments and Discussions