Maya > Blitz3D probsCommunity Forums/Developer Stations/Maya > Blitz3D probs
| I'm trying to get my Maya objects in Blitz, and exporting the meshes work fine. Unfortunately I can't get my smoothing information across, and therefore all straight edges look horribly soft and fuzzy. I've tried the following methods:|
- Convert directly to .X from Maya
- Convert to .OBJ from Maya (including smoothing groups). Import into Milkshape. Export to .B3D.
- Convert to .OBJ from Maya (including smoothing groups). Import into Milkshape. Export to .3DS.
While importing the stuff into Milkshape works fine, all smoothing information is lost after exporting. Is there anybody who knows how to solve these problems, because now my objects don't look very nice :-(
See it for yourself:
| I was under the impression that if the .x file contains normals, Blitz3D won't overwrite them so am suprised Maya->.x doesn't work. As for Milkshape, you may want to try UltimateUnwrap as an alternative as it seems to have best reputation for .b3d conversions. |
| Actually, loss of smoothing information is one of the main reasons I am working on a b3d exporter for Maya. I convert via Ultimate Unwrap and I don't know of any way to preserve smoothing information. You can separate hard-edged regions in Ultimate Unwrap and exporting to b3d from Ultimate Unwrap preserves smoothing information perfectly, but I don't know how to get from Maya to Ultimate Unwrap with smoothing intact.|
It is entirely possible however that I just haven't tried the right thing (possibly something pretty obvious) to get the smoothing into Ultimate Unwrap and, as I said, Ultimate Unwrap does export smoothing information perfectly. In fact, I'll try a couple things I just thought of right now and report here if they work.
| jhocking: ever tried to use Maya's built in OBJ exporter with smoothing ticked? OBJ preserves smoothing information. |
| I'm pretty absent-minded but I'm not THAT bad. Heh.|
Yeah, I've tried exporting to obj and importing to Ultimate Unwrap, and I've made sure smoothing was checked. Doesn't work; Ultimate Unwrap seems to ignore the smoothing information when importing obj models. This may be something Brad can change though; he's usually pretty good about addressing user suggestions.
| It should be possible, because Milkshape imports OBJ with smoothing without any problems. It's the exporting where it all goes wrong. So basically we need Milkshape import and Ultimate Unwrap export ... |
| If the .x files are importing with smoothing correct in these apps a standalone .x -> .b3d conversion utility would be the ticket. |
I would imagine a blitz3d app such as Quill3D would do the conversion with style?
| Maybe Gile[s] could be a solution? I'm running the demo right now, and it seems I can import .OBJ without any problems (and smoothing intact). I'm not sure if it exports okay though, as saving/exporting is disabled in the demo. The lightmapping looks pretty wicked by the way... |
| skidracer: do you use Ultimate Unwrap? And if so, can I send you the (.obj) model so you can see if it works? I'm a bit afraid to splash out on a registered copy without knowing if it actually works. |
| Good call on gile[s]. I'll test that right now but it should work fine. For your needs at least; that doesn't help me any since I need animated models and gile[s] doesn't support animation. Going from Maya to Ultimate Unwrap via .x is currently the best (only?) way to get animated models from Maya to b3d file format.|
ADDITION: Darn it, gile[s] doesn't seem to work either. It takes smoothing information into account when lightmapping, but if you strip off the lightmapping and set the object off of fullbright it turns out the normals are all smoothed out.
| I'm also trying to solve this with sa guy on Blitzcoder.com, and he's having the same problems. So far the best solution seems to be exporting to .X or .OBJ from Maya and do the smoothing in Unwrap before exporting to .B3D.|
Is that Maya exporter of yours a long way off? It would be absolutely Godsend. I'm not enough of a .MEL man to code it myself unfortunately...
| Well it was supposed to be done by now but you know, sidetracked on other projects and that gets put on the backburner. I really don't want to get your hopes up about my exporter because it is rather low priority for me right now. Existing tools CAN do everything I need, it's just more complicated than it needs to be. |
| Do you reckon investing in Unwrap would be a smart move for me? So far Maya does everything I want, although I'm looking into Gile[s] for those lovely lightmaps... |
| I recommend Ultimate Unwrap to anyone doing art for videogames, especially using Blitz3D, regardless of their modeling tool. Even if you have no need for the texture mapping tools (which are really good) it's file conversion abilities are excellent. It can open AND save to several animated file formats, including Milkshape .ms3d, .x, and .b3d|
But remember, this isn't going to fix your smoothing problem. You can set the smoothing in Ultimate Unwrap and that will export perfectly, but it isn't obvious how to do so, so you'll probably be right back here asking that :)
| I think I'll be buying it then ... I find Maya's UV editor horrible to work with anyway.|
EDIT: a bit of a shame though, that's it's so hard to export something from one of the most powerful and leading 3D applications around. Especially considering the fact that converting between Maya and Shockwave 3D is an absolute doddle compared to this.
| After a little fiddling around, It seems the Maya .X export to Ultimate Unwrap3D works with smoothing information intact! Wouldn't exporting to .B3D from Unwrap solve this problem then? |
| Are you sure Ultimate Unwrap imports .x models with smoothing intact? When I try it doesn't. Note that it may seem like the smoothing groups are intact if the smoothing boundaries also happen to coincide with seams in the texture mapping. DirectX models will import with the geometry broken (and thus hard edged) on texture boundaries, something which can be repaired easily with Weld Model.|
If you're getting the look you want then sure, exporting to b3d will work.
| Yes you're right ... the model I'm using has only been mapped properly for about 40%, and you can see the seems exactly where I put them. So far the best option has been autosmoothing the object on 35, although that still blurs corners you want to be sharp a tad TOO much.|
When I use 'weld model' I get this horrible cottonball look again :-(
| Actually I just discovered something pretty cool. It turns out smoothing IS being preserved when you export .x from Maya and import into Ultimate Unwrap, but the mesh is ALSO breaking along texture seams. So in Maya just eliminate all texture seams (eg. map the entire model with a single planar map,) export to Ultimate Unwrap, and do the texture mapping there. This way it'll carry over the smoothing information but without any additional edges from texture seams. |
| You, Sir, are a genius. Importing it into UUnwrap now works perfect. So basically if you map it in UUnwrap, and export it to Blitz it'll appear exactly as it does in Unwrap? (Still got that creditcard in my wallet, you've probably noticed ;) )|
EDIT: If I'm not mistaken, it's possible to export UV maps from Maya. Wouldn't that make it possible to do all your modelling/texturing in Maya, export the UV map, make a planar map, export it to UUnwrap and then import the UV map again?
| Hey whatever, it's not like I'm getting kick-backs for every customer I refer. At least in terms of the mesh (the material features supported by each is slightly different) what you see in Ultimate Unwrap is what you see in Blitz.|
As for exporting the UV maps separately, I rather doubt that'll work because Maya and Ultimate Unwrap probably aren't using a consistent file format for storing the UV information. But it's worth a shot I suppose.
| I have to simplify my models I'm afraid, it seems Ultimate Unwrap is even a bigger horror to use than Maya's UV tools. |
| Aw, I like texture mapping in Ultimate Unwrap. Don't give up so quickly because if you can get used to the tools in Ultimate Unwrap you'll no longer have any smoothing problems going from Maya to Blitz3D. |
| jhocking: This may be entirely off topic, but could you send me the OBJ file you tested with gile[s]?|
Then I'll take a look, the email is: giles@...
| Fredborg: are you considering fixing this issue on short notice? Otherwise I'll postpone getting Unwrap and wait for gile[s] to support this instead as I like the additional features of gile[s] much better and are actually very useful to me. |
| The thing is that it should work already, but as I have very limited access to OBJ files, there may be a problem or two that needs ironing out :)|
edit: nap0leon, you can also send your file to me, and I can give it a go.
| I can provide you with all the OBJ files you ever wished for... I can also send you the object I used in the first post of this thread, the spaceship thing. BTW: There's a small bug in Gile[s] because it doesn't render the inside plane of the engine-exhaust even though the normal is facing the right way (Milkshape, Maya, Unwrap and Blitz do display it). |
| Please send me the file. Then I will see how it works :) |
| Fredborg: your profile doesn't display an email adress, but here is the object: |
Don't worry about lightmaps and the like messing up, because I haven't got a proper UV map in place (still working on it!)
| Ok, it seems I'm not loading the vertex normals :) I'll see if I can get it to work, and I'll get back to you! |
| Now that we're talking about gile[s], do you plan to support multiple imports in the future? Like: I load my landscape mesh, then import some trees and place them and afterwards import a house I had lying about in some other folder? Maybe I'm missing it (only played around with it for a few minutes), but now it seems you have to load an entire world at once, add lights and create a map. And start all the way over again when you want to change/add something. |
| You can use 'Merge' to add new models to your scene. |
| Cool. You may now hit me with the Newbie-Hammer ;) |
| It sounds like you guys have already figured this out but I just realized gile[s] does not preserve smoothing information/vertex normals when importing obj models. Napoleon, I got misled by an earlier post of yours which suggested that gile[s] can import obj with smoothing information. It imports b3d perfectly but that rather defeats the purpose here.|
Also, I won't bother sending my model as you already got his. Mine was just a simple cylinder with separate smoothing groups between the sides and ends anyway.
| Fredborg, would you be interested in spinning off a lightweight .x->b3D converter? If not I am interested in doing a decl for dx8util to parse .x using the IDirectXFile interface so Blitz3D has stronger support in this area. |
| Doesn't something like that already exist? I haven't tried it but I keep hearing about Stickman's .x converter. |
| jhocking: I thought that gile[s] was doing it correctly at first, but I found out later with different lighting an dobjects it didn't really work as well as I first thought. Probably the first lighting map I got was a 'lucky shot'.|
You may also hit me with the newbie hammer :-) But at least my dumb questions got something rolling here...
| skidracer: I'm actually using Blitz3D's native .x file loader, and then simply grab the info about materials and textures using the GetSurfaceBrush etc. commands. So I would be very interested in a loader that gave better access to all the data in the file.|
I think it wouldn't be too hard to do a custom .x importer, but if you can do some magic with a userlib that would be awesome!
jhocking & napole0n: I'm messing with the vertex normals right now, it should not be a major problem to get it to work.
| Fredborg: if you get it to work, you'll have yourself a new customer. Converting and prelighting in one easy to use package is just what I need.|
And thanks to all of you for making my first entry into the Blitz community such a pleasant one.
| Fredborg: I'm on to it, Ive been meaning to publish an example of using an IUnknown interface from Blitz so I'll get bizzy. |
| I think I got it working...Here is a screen from gile[s], with vertex lighting and no shadows:|
You can download the b3d file here. There is no lightmapping or vertex lighting baked into it, so it should look just the same as in maya.
BTW: Funky ship, but you might want to cut down on the polygon count if you are gonna use it for realtime graphics.
| You prince you. So how soon will there be a new version of gile[s], with the improved obj loader, to download?|
Oh, and I concur about the polygon count. Unless that's the only thing which is going to be on screen, in which case it'll probably be fine. 14,000 each is high if there are going to be several ships on screen but perfectly doable if you'll only have the one.
So how soon will there be a new version of gile[s], with the improved obj loader, to download?You can download the new version now!
| Fredborg: you're a real hero. Expect my order shortly!|
And about the polygon count: actually I was just experimenting a bit with modelling, exporting and importing to get a feel for Blitz3D and it's capabilities (only got it registered since yesterday), so it's by no means final. I haven't got any performance issues so far in Blitz3D with this object and a few others, and I'm planning to use this ship as 'main' character and simpler models as enemies for a practice R-Type-meets-Xyanide kind of game which will probably never get finished ;-)
Thanks for all the help guys!
-Edit- Just loaded it into Blitz3D and it all seems okay. Except that there seems to be a transparant face in the back of the engine exhausts, but maybe I've got a normal wrong. Although Milkshape, Maya and Unwrap did show it.
-Edit 2- The transparant faces occur in cylinder-caps in one piece (so basically a plane with 16 vertex points). Gile[s] seems to ignore them, rather than triangulate them like other packages do.
| At least by default (in all three cases you can turn backface culling on) Milkshape, Maya, and Ultimate Unwrap don't do backface culling. So polygons facing the wrong way will still be visible. |
| jhocking: it was a problem with the amount of vertices; gile[s] only supports tri's or quads. Easy enough to work around (clean up polygons or just split them if necessary) |
| Ah, that's important to know. |
| Maya + Gile[s] + Photoshop + Blitz =|
Obviously I'm not done yet texturing and I have to adjust the lightmap, but it's a 100 times better than yesterday!
| Yeppers, that's one for the gallery. What would be a really cool shot for the gallery would be that model (in a more dynamic pose) and scene with a particle system exhaust trail. There is the "craftflare" demo which comes with Blitz3D you could drop your model and scenery into, or if you really can't figure it out send me the model and other media and I'll do it. |
| Yeah, I'll make a nice still out of it. But not until I'm finished texturing and lighting it... |
| If one of you can send me a simple model (ie. a cylinder), with non-triangulated polygons, I will add support for that in the obj loader. |
| I just sent a cylinder to the gile[s] support adress.|
It can also be downloaded here:
| Ok, thanks! Got it fixed, so it should work in the next update. No date on that yet, though. |
Reduced the amount of polygons to little over 2000 and you can actually fly the ship now, and shoot too :-)
| Hey, I thought I would update this old topic. I have been in contact with the maker of UU3D, and told him of this problem.|
I don't know if anyone tried actually contacting him 3 years ago with this, but he has 'fixed' it over the last few days.
I say 'fix' as it is more of a work around, basically un-welding hard edges, but it gives the same end result. Here are two shots, with smoothing visually intact:
I haven't tried it on an animated model yet, but it all should be OK.
I say 'fix' as it is more of a work around, basically un-welding hard edges, but it gives the same end result.
Not sure why you think that functionality is new in the last few days, because that has been an option for the last few years (probably before this thread was started.) Perhaps the interface for doing it has changed so it seems new? Like, you weren't selecting edges directly, but rather welding/unwelding polygons.
The issue wasn't that this couldn't be done within UU, but that there wasn't a way to define smoothing groups within Maya. This is addressed in the latest version of UU because there is now an exporter for Maya.
| hey jhocking did you ever finish the exporter you were talking about? |
| No, I got models and texture coordinates before I gave up. Would be nice to have a way to export from Maya on a Mac, but using UU works great. |
| too bad, i'm trying to do this on a budget of free|
i got maya for school but theres no .x exporter.
| No, jhocking. The maker of UU3D has added a tick box in the maya exporter plug-in, that automatically unwelds hard edges directly, and automatically when the object is exported from Maya.|
I told him about the problem some time last week and he has been working on it. Yesterday he send me a new exporter plugin that had it in. That is how I think its new in the last few days.
| Oh I see what you mean, that's new. Very cool! |
| Mayamannn101 I thought the DirectX SDK had a .x exporter for Maya included in it. I can remember using it a while back. |
| its for 6.0 and 6.5 only i think i couldn't get it to show up in the plugins window.|
i've got 8.5 unlim