• Create Account

# Exporting .X files from Maya 7.0

23 replies to this topic

### #1zer0wolf  Members   -  Reputation: 1018

Like
0Likes
Like

Posted 27 March 2006 - 12:26 PM

Not sure how many of you have been faced with the challenge of figuring this out, but I recently have, and I figured that somebody out there might appreciate this tutorial in the relatively near future - Installing the .x exporter for Maya 7.0 - After making sure that both Maya 7.0 and the Microsoft DirectX SDK (February 2006) are installed, the following needs to be done to be able to export .x files from Maya if the SDK does not automatically install the needed files for you (which happened to me and also apparently happened with the computers at school as well): 1) Copy from C:\Program Files\Microsoft DirectX SDK (February 2006)\Utilities\Bin\x86\dxcc.dll to C:\Program Files\x86\dxcc.dll /* The following three files can be found in the zip file found at http://www.quest3d.com/download/Maya_7.0_X_Exporter.zip instead of searching around through the SDK if you prefer */ 2) Copy from C:\Program Files\Microsoft DirectX SDK (February 2006)\Utilities\Bin\PlugIns\Maya\Binary7\Plug-ins\D3DMaya7ExportX.mll to C:\Program Files\Alias\Maya7.0\bin\plug-ins\D3DMaya7ExportX.mll 3) Copy DirectX.mel, DXMUnitTests.mel, and AEDirectXShaderTemplate.mel from C:\Program Files\Microsoft DirectX SDK (February 2006)\Utilities\Bin\PlugIns\Maya\Binary7\Scripts to C:\Documents and Settings\username\My Documents\maya\7.0\scripts 4) Copy DirectX.xpm and render_DirectXShader.xpm from C:\Program Files\Microsoft DirectX SDK (February 2006)\Utilities\Bin\PlugIns\Maya\Binary7\Icons to C:\Documents and Settings\username\My Documents\maya\7.0\prefs\icons /* If for some reason the directory structure on your system is setup differently than mine (like at school), then you can use the commands "internalVar -usd" to see where to put the MEL files and "internalVar -ubd" to see where to put the XPM file. */ 5) Last but not least, you need to load the D3DMaya7ExportX plug-in for Maya by going to Window -> Settings/Preferences -> Plug-in Manager and selecting the box labeled "loaded" to load it then and "autoload" so that it will automatically load whenever Maya starts up. Hopefully this works for everyone. It was a bitch to figure this all out, because Microsoft wasn't exactly kind enough to spell this out. As I learn more about the process of dealing with the DirectX Shaders in Maya and properly rigging and animating for exporting to the X format in Maya, I'll add that info here.
laziness is the foundation of efficiency | www.AdrianWalker.info | Adventures in Game Production | @zer0wolf - Twitter

### #2Professor420  Members   -  Reputation: 496

Like
0Likes
Like

Posted 27 March 2006 - 03:53 PM

The x86 folder is the tricky one because its not really mentioned anywhere, had to look online to figure that out.
BTW, as I've said in another thread, the Maya .x exporter BLOWS. Don't expect to be able to use it for skinned objects, it is extremely lacking in features and options. Its pretty much limited to static meshes, I've found. I've heard it has something to do with its OpenGL foundation, while you are exporting to a DirectX format. But good luck if this is your only option. Otherwise I suggest exporting from 3ds Max or Right Hemisphere's Deep Exploration.

### #3zer0wolf  Members   -  Reputation: 1018

Like
0Likes
Like

Posted 31 March 2006 - 03:32 AM

Okay, I've been messing with for like two days and I still can't get textures to work. I've (obviously) gotten the exporter installed and I can export geometry just fine, but I'm doing something wrong with where I'm putting the textures/what kinds of textures I'm using/parameters. I'm not sure. I export to a .x file and when I load it up in the DirectX Viewer, the object is there, but there is no texture. I downloaded the Deep Exploration trial and I get the same error, so it has to be a user error. How do you properly texturing for export, export the texture reference, and where does the texture go?
laziness is the foundation of efficiency | www.AdrianWalker.info | Adventures in Game Production | @zer0wolf - Twitter

### #4Professor420  Members   -  Reputation: 496

Like
0Likes
Like

Posted 31 March 2006 - 05:08 AM

While I'm somewhat of a .x novice, I don't think you can 'embed' the textures into the .x format. When you export the texture, you are just making a copy of the texture into the same folder as the .x file goes. So in Deep Exploration, you still have to link the material to use the proper textures. In .x viewer, not so sure, but it probably works in a similar way, try configuring the material from Deep Exploration and exporting from there and see if it links correctly. Sorry if this sounds confusing, exporting always is, unfortuately.

### #5 Anonymous Poster_Anonymous Poster_*   Guests   -  Reputation:

0Likes

Posted 10 April 2006 - 07:38 AM

And if I've installed dxsdk to d:\program files? dxcc.dll not found if I place it in c:\program files\x86. Tried to place it in d:\program files\x86 - same result.

### #6 Anonymous Poster_Anonymous Poster_*   Guests   -  Reputation:

0Likes

Posted 10 April 2006 - 08:04 AM

I've installed maya to d:\program files too. Sorry for spamming.

### #7zer0wolf  Members   -  Reputation: 1018

Like
0Likes
Like

Posted 10 April 2006 - 10:40 AM

When exporting a model from Maya with textures, make sure that under Make Relative Paths, set to True. Have the .x file and the texture in either the same directory or make sure that it just plain maintains a relative path, like having the texture already in a sub folder called "texures" and making sure it doesn't go anywhere in relation to the .x file.

Quote:
 Anonymous PosterAnd if I've installed dxsdk to d:\program files?

Dunno. I would recommend that you just install it to its default location, because it works just fine from there.
laziness is the foundation of efficiency | www.AdrianWalker.info | Adventures in Game Production | @zer0wolf - Twitter

### #8dm5  Members   -  Reputation: 122

Like
0Likes
Like

Posted 11 April 2006 - 10:26 AM

Quote:
 Dunno. I would recommend that you just install it to its default location, because it works just fine from there.

Yeah, I had to reinstall maya, after that it started to work.
BTW I haven't had any problems with textures yet, even without relative paths.

### #9dm5  Members   -  Reputation: 122

Like
0Likes
Like

Posted 12 April 2006 - 06:37 AM

I've experienced problems with textures too. I found out that if you change texture path in maya the old path can be used when exporting (which results in missing texture in directx viewer). The cure for this is to reload the scene in maya. After that everything seems to export correctly both with absolute or relative texture paths.

### #10zer0wolf  Members   -  Reputation: 1018

Like
0Likes
Like

Posted 17 April 2006 - 12:25 PM

Just a few more notes of interest for people -

I read this in the DX docs and then promptly forgot - hard binding does not work! You have to use soft binding. I had so many damn problems by forgetting this that it isn't even funny.

Don't load the DX plug-in after you've been working on the model. It'll try to rebuild and possibly crash. Load up the DX plug-in from the start. This isn't a big deal if you simply set it to load up at the start, but if you're on a school computer with Maya that does the whole clean wipe thing, make sure you remember to load it as soon as you start up Maya.

DX doesn't support IK handles. This isn't really all that big of a deal though because of how animations are handled in the .X files, though. For people writing .X loaders, the fact that IK handles are stripped on export could be useful to know.

That being said, I've finally got working animations of textured models working out of Maya in DirectX. It has been a fun ride. ;) Now onto the fun part of getting some solid looking animations - the artistic side of things.
laziness is the foundation of efficiency | www.AdrianWalker.info | Adventures in Game Production | @zer0wolf - Twitter

### #11Victor17  Members   -  Reputation: 122

Like
0Likes
Like

Posted 24 April 2006 - 09:13 PM

It seems this plug-in is extremely unstable. My Maya crashed several times because of it.

Did Microsoft add any improvement to their plug-in in DX SDK April 2006?

### #12zer0wolf  Members   -  Reputation: 1018

Like
0Likes
Like

Posted 04 May 2006 - 11:19 AM

I figured that I should revisit this thread after talking to some classmates of mine who were trying to use this thread to get the Maya DirectX exporter working. I made a .zip file of all of the files you need and a batch file to put them where they need to go. You can find that here. Make sure to read the readme file and make the necessary edits to the batch file. Also, I'm creating a web page that will contain the information I've found in a better arranged format. It can be found at tools.anomicworld.net.

Something I neglected to specify is that step 5 in the directions in the first post is within the Maya menu set.

Quote:
 It seems this plug-in is extremely unstable. My Maya crashed several times because of it.

Quote:
 Did Microsoft add any improvement to their plug-in in DX SDK April 2006?

Nope, I've taken a gander at it and it is exactly the same.

[Edited by - zer0wolf on June 17, 2006 9:19:42 AM]
laziness is the foundation of efficiency | www.AdrianWalker.info | Adventures in Game Production | @zer0wolf - Twitter

### #13Victor17  Members   -  Reputation: 122

Like
0Likes
Like

Posted 09 May 2006 - 10:15 PM

It's very kind of you, thank you very much!

1. Remember to revise directories in the batch file, they r critical. For an example, many ppl's "My Documents" or Maya is not located in C:
2. Pay attention to where dxcc.dll is put, coz it's location is a little tricky...in my case, my Maya is installed in D:\Maya7, so I have to put dxcc.dll into D:\x86\ instead of C:\Program Files\x86
3. As mentioned before, this plug-in is unstable, make sure u load it right the moment before u export your work.

### #14spooky_paul  Members   -  Reputation: 126

Like
0Likes
Like

Posted 11 May 2006 - 06:34 PM

hy, ive downloaded the plugin from http://www.quest3d.com/download/ and im getting this error every time i try 2 load it "Error: The operation completed successfully.". then ive installed the plugin with the bat file suplied on this site, but the error remains...
pls can u tell me how can i fix this, how can i get the plugin 2 work?
thank you

### #15zer0wolf  Members   -  Reputation: 1018

Like
0Likes
Like

Posted 12 May 2006 - 12:18 AM

Did you install Maya to the default directory? Did you follow the instructions in the readme file included with the batch file on what you need to change in the batch file to make it work? Are you using a legal copy of Maya. Have you tried installing the file and then loading up Maya (as opposed to while Maya is running)?
laziness is the foundation of efficiency | www.AdrianWalker.info | Adventures in Game Production | @zer0wolf - Twitter

### #16Professor420  Members   -  Reputation: 496

Like
0Likes
Like

Posted 12 May 2006 - 04:26 AM

BTW, the DirectX exporter plugin really f'ed up my Maya really bad. I had it autoloading, and it was causing constant Fatal Errors, and serious batch rendering problems/crashes. I finally had the bright idea to unload the plugin unless I needed it (hopefully never), but just a note to anyone that has it installed and sees that D3D window when they batch render, and wonder why they have to restart their comp every time they exit Maya because their comp becomes a slug.

### #17spooky_paul  Members   -  Reputation: 126

Like
0Likes
Like

Posted 14 May 2006 - 07:40 AM

yes i am using a legal copy of maya!...
the plugin seems 2 work now.

### #18Salsa  GDNet+   -  Reputation: 1146

Like
0Likes
Like

Posted 14 May 2006 - 01:35 PM

/Applies glue

### #19 Anonymous Poster_Anonymous Poster_*   Guests   -  Reputation:

0Likes

Posted 14 May 2006 - 03:02 PM

Thank you very much ZeroWolf for your instrution. With your instruction, now I can export my object to .X now ^^. But can I ask few more questions....I'm really new with Maya so I don't know that soft binding and hard binding are the same one with rigid and smooth ? because binding help tool in Maya I can only find rigid and smooth so I don't have any conclusion to prove that these are the same things...and I have heard that IK is using for moving bones if have to aviod it...which tool should I use to handle it instade? and last one is that can I use ExportX tool to export the exsist Objects(the one that I have already finished it up before finding exportX tool)I have tested the polygon with no moving and it still work...but how about moving thing(because the exportX tool make my Maya 3 times slower than before...it is great if you don't have to turn it on immediatly when you doing your job)... thanks a lot for listening to all of my questions ^^.

### #20 Anonymous Poster_Anonymous Poster_*   Guests   -  Reputation:

0Likes

Posted 14 May 2006 - 04:35 PM

Thank you for all your support and it worked for me.

PARTNERS