Import Maya ASCII into the game

I am currently working on creating an import-based pipeline for my indie game using Maya ASCII.ma as the source format and my own format for physics and graphics as output. I will store things like Maya range attributes for swivel, for example. Other types of parameters that need a lot of settings are given in separate source files (possibly .ini for things like mass, spring constants, the strength of physical engines, etc.).

Thus, the input is one .ma and one .ini, and the output is, among other things, one .physics and several .mesh files (one .mesh file for each geometry / material).

I'm also probably going to use Python 3.1 to reformat the data, and I already found some LGPL 2.1 code that reads the main Mayan ASCII. I will probably also use Python to run the platform during development. The game is developed in C ++.

Is there anything in all of this that you would advise? A brief description of things that may be ruined:

  • Import-based pipeline (non-export-based)?
  • Maya (not 3DS)?
  • Maya ASCII.ma (not.mb)?
  • .ini (not .xml)?
  • Does the motion separation match the Maya and "freak-tweak" attributes in .ini (not everything in Maya)?
  • Python 3.1 for creating data (not native C ++)?

Edit: if you have a better suggestion on how to implement the physicist / graphics import / export tool chain, I would appreciate input.

+3
3

, . , , , , . :

  • Maya.ma( , v.2010) mel. Mel - Turing-complete, , , , "".
  • .
  • , , , . , ( ), " " (, ).
  • .ma ; . "" script .ma, , Maya. , . ,
    • " ",
    • " this-and-that from here to there"
    • " 252 xyz " ( ).
  • ; rt .
  • , node, , . ( ),
  • , , . . , , , , . . ( "polyCube" ) ( ", , " ).
  • " ". , , , ( ), ().
  • Node (. Maya xform doc ):

vrt = getattr("rpt")
rt = mat4.translation(vrt)
...
m = t * rt * rpi * r * ar * rp * st * spi * sh * s * sp
  • , , , , . ( " " ). . . , , ; , .
  • cgkit Maya. Matthias Baas!
  • - , , . "" , .
+4

, , , Python (, , ), YAML JSON ini XML.

XML , .

JSON YAML : Python, , float, ints... : python.

, , , - , 3.1, 2.x - .

+1

, OBJ COLLADA, .ma Maya, .

.ma/.mb - , , Autodesk . 100%, MEL.

Maya, , , MEL Maya, MEL node.

Note. Maya can be run in headless mode, where it loads a scene, executes a MEL script, and exists without loading a GUI. Thus, there are no problems with its use in automated assembly systems.

+1
source

Source: https://habr.com/ru/post/1713100/


All Articles