Bl
Bl
Bl
Bl
Bl
You are here:   Home »  Products »  PolyTrans|CAD+DCC  
Bl

Home > Supported File Formats > Maya to OpenGL C Code


How to convert Maya (.ma,.mb) to OpenGL C Code (.cpp)?


PolyTrans|CAD+DCC performs mathematically precise CAD, DCC/Animation, GIS and BIM 3D file conversions into all key downstream 3D packages and file formats. Okino software is used and trusted throughout the world by many tens of thousands of 3D professionals in mission & production critical environments, backed by respectable personal support directly from our core development team.

     

Maya

Maya is a well known and respected DCC/Animation system which had originally been developed by Alias Research in Canada then purchased by Autodesk in 2006 after Alias went bankrupt.

As is very little understood, no program on this planet can read or write Maya ".ma" (ASCII) or ".mb" (binary) files because the full geometry modifier stack of the Maya software, and its various plugin modules, are needed in order to properly evaluate the file before it can be rendered. This is what forced Okino to write its well known PolyTrans-for-Maya system, which allows for all Okino 3D converters to run within Maya itself. For example, if you want to convert to/from CINEMA 4D (.c4d files) then you would do so entirely inside of Maya.

Due to multi-decades history, Maya users are notorious for using the OBJ file format to convert files to/from other software packages just as 3ds Max users wrongly use the 1985-era .3ds file format. OBJ is an "okay" file format but there are much better or more preferred methods to convert the data.

     

OpenGL C Code

OpenGL is a cross-platform application programming interface (API) for rendering 2D and 3D vector graphics. The API is typically used to interact with a graphics processing unit (GPU), to achieve hardware-accelerated rendering.

Okino's OpenGL export converter writes out the scene database as a C code program in the Open GL scene description language. The resulting program can then be compiled and used to draw the 3D database directly using OpenGL. The database is output as a series of polygons with vertex positions, normals, colors and texture coordinates. In addition, the surface definitions (materials) associated with each polygon is used to set up the OpenGL shading parameters. Please note that each object is output as a separate C code function in the resulting file.