Problem Problems with exporting textures in Anim8or.

JonnyBGoode

Sky Marshal
Addon Developer
Joined
Oct 24, 2009
Messages
686
Reaction score
34
Points
28
Location
Bakersfield, CA
I'm working on an addon, an addition to Martin's Antelope Valley pack. Martin forgot to add the iconic Lockheed Site 10 building!

Here's a reference image to start with:

58630905.jpg


So. I'm building the mesh in Anim8or, with Urwumpe's msh export plugin. And it's just about done. With one minor problem.

15134570_10208317031225538_3069618407405298923_n.jpg


No textures when I export it!

15134725_10208324189724496_3151447352976623031_n.jpg


I'm sure I must be doing something wrong (either that or this doesn't work on Windows 10?), but I'll be buggered as to what.

So, let me recap my steps, and maybe someone will be adept enough to figure out what I'm doing wrong.

First, I created two 512x512, pixel 24 bit bitmap textures. Called them lockheed.bmp and blueline.bmp.

In Anim8or, double clicked on New material.

step1.jpg


Click on the button next to Diffuse.

step2.jpg


Select the texture that I want to use, and click OK.

step3.jpg


Slide the color slider to the top, and click OK.

step4.jpg


Now select Object/Point Edit, and Face Select, and click on the face I want...

step5.jpg


Then select the Texture UV tool and resize and position as required.

step6.jpg


Then export my mesh to the sim. Except... the materials don't get added to the mesh when I export it.

Can anyone spot where I'm going astray here? Much thanks!
 
Last edited:

DaveS

Addon Developer
Addon Developer
Donator
Beta Tester
Joined
Feb 4, 2008
Messages
9,434
Reaction score
689
Points
203
Does each element of the mesh use one or two materials? Each element can only have one material assigned to it.

The export script uses the material used the most (example, a cube, 6 sides where material01 is used 4 sides and material02 is used on 2 sides. This will cause the script to apply only material01 to all sides of the cube).

The solution is to only have one material/object and never apply them on a face-by-face basis.
 

JonnyBGoode

Sky Marshal
Addon Developer
Joined
Oct 24, 2009
Messages
686
Reaction score
34
Points
28
Location
Bakersfield, CA
Anyone know where I can find a copy of Vinka's script? I don't recall having difficult with that so much...
 

paddy

Addon Developer
Addon Developer
Joined
Jul 14, 2012
Messages
80
Reaction score
0
Points
0
daft question but you have converted the texture to a DDS file?
 

DaveS

Addon Developer
Addon Developer
Donator
Beta Tester
Joined
Feb 4, 2008
Messages
9,434
Reaction score
689
Points
203
Anyone know where I can find a copy of Vinka's script? I don't recall having difficult with that so much...
Have you tried something else besides Anim8or? It's rather simplistic and doesn't quite lend itself to advanced 3D modelling. Orbiter compatible options right now are:

  • GMAX (free slightly less capable sibling of 3DSMAX)
  • Blender (free)
  • AC3D (Commercial advanced 3D modeling at par with GMAX)

I personally use both GMAX and AC3D. I started with Anim8or back in 2002 abandoning it in favor for GMAX in 2006. First tried out AC3D in 2008 and bought shortly after that.
 

JonnyBGoode

Sky Marshal
Addon Developer
Joined
Oct 24, 2009
Messages
686
Reaction score
34
Points
28
Location
Bakersfield, CA
Ok, so something Dave said gave me an idea. I textured the entire blocks I was doing a side panel in, and it worked! Except... it crashed more than half the time. Couldn't figure out why, until I realized Martin was using a high res texture and a lot of other buildings, so I reduced my texture res from 512x512 to 256x256, which made it a lot more stable.

15170865_10208335845495883_3801500774006935747_n.jpg
 

gattispilot

Addon Developer
Addon Developer
Joined
Oct 17, 2007
Messages
8,707
Reaction score
2,683
Points
203
Location
Dallas, TX
Great. So will the doors open up? If you need help with that email me
 

jacquesmomo

Addon Developer
Addon Developer
Joined
Jun 14, 2008
Messages
613
Reaction score
453
Points
78
Location
FRANCE
Website
francophone.dansteph.com
the materials don't get added to the mesh when I export it.

Can anyone spot where I'm going astray here? Much thanks!
Yes : the UV's textures are ok when you export to a msh file, but you have to edit the msh file and add like that :
Code:
 (...)
  552  547  555
 552  555  564
 564  565  552
MATERIALS 1
Blanc_
MATERIAL Blanc_
 1  1  1  1
 1  1  1  1
 1  1  1  1  0
 .18  .18  .18  1
[COLOR=red][B]TEXTURES 3
[/B]my_texture1.dds [/COLOR]
[COLOR=red]my_texture2.dds[/COLOR]
[COLOR=red]my_object\my_texture.dds[/COLOR]
... and you have in adition to add the n# of the texture to the right group(s)
like this (at the begining of the group(s)

Code:
 (...)
 LABEL <name of your group> optional
MATERIAL 1
[COLOR=red][B]TEXTURE 1
[/B][/COLOR]GEOM 566 486 ;Group 0 Kourou\Kourou_Bat-01.dds Blanc_
 18.041  4.00003E-05  31.195  .707107  0 -.707107  .61104  .54983
 (...)
In this case, this groupe has the texture n#1
(if TEXTURE 0 => no texture)

With MeshWizard, it is easy to do that...

You know what ? I use anim8or to make meshes, then export to OBJ, then I use UVMapper to apply textures, then import again in anim8or and finaly export to msh.
Then I add the line with the textures, then I use MeshWizard to affect the texture....
 
Last edited:

4throck

Enthusiast !
Joined
Jun 19, 2008
Messages
3,502
Reaction score
1,008
Points
153
Location
Lisbon
Website
orbiterspaceport.blogspot.com
...

  • GMAX (free slightly less capable sibling of 3DSMAX)
  • Blender (free)
  • AC3D (Commercial advanced 3D modeling at par with GMAX)
...

Another good option for buildings is Sketchup, but harder to import/export from it and limited for other uses.

I'd recommend Blender. Takes a little time to get the interface, but it's really powerful with good import/export scripts. Also lots of support and up to date versions.


Regarding the open doors, it's a good idea if you model the interior ;-)
For simplicity of having it as a base object, I'd keep the doors open.
 

Trekkie

Starfleet Head of Ship Design
Addon Developer
Donator
Joined
Feb 6, 2016
Messages
350
Reaction score
89
Points
43
Location
Starfleet Ship Design Bureau
Another good option for buildings is Sketchup, but harder to import/export from it and limited for other uses.

I'd recommend Blender. Takes a little time to get the interface, but it's really powerful with good import/export scripts. Also lots of support and up to date versions.


Regarding the open doors, it's a good idea if you model the interior ;-)
For simplicity of having it as a base object, I'd keep the doors open.

i never got anything i tried importing out of sketchup to work, only like parts of the models appeared... blender is really good though
 

JonnyBGoode

Sky Marshal
Addon Developer
Joined
Oct 24, 2009
Messages
686
Reaction score
34
Points
28
Location
Bakersfield, CA
I'm considering making it a ship, and having the doors openable. But I've got no idea what the interior looks like (other than one old pic from the L-1011 days), so it may just stay untextured inside if I do.

And if I decide to make the doors open, then yes, gattispilot, I'll need some assistance with the animation.
 

martins

Orbiter Founder
Orbiter Founder
Joined
Mar 31, 2008
Messages
2,448
Reaction score
462
Points
83
Website
orbit.medphys.ucl.ac.uk
Nice work! If you want me to include it in the next update of the Antelope Valley scenery pack (whenever that materialises) I would prefer it as simple as possible, i.e. static mesh, not as a vessel, no animations, lowest possible polygon count, smallest possible textures.

If you want to provide it as a separate addon, then of course feel free to make it as elaborate as you like.
 

JonnyBGoode

Sky Marshal
Addon Developer
Joined
Oct 24, 2009
Messages
686
Reaction score
34
Points
28
Location
Bakersfield, CA
Thanks for the praise, Martin!

I'm working on optimizing it as a static mesh right now. It's currently basically a bunch of long blocks with a large block on top. Seems to be a bit rough on the processor though. I'm seeing if I make the doors actual doors with a lot of empty inside, rather than long blocks that go all the way through, if that will make a difference, more stable.

I might release it both ways. Send it to you to add in as a static mesh, and put it out as a movable addon for those that want to open the doors. (I need the animation practice, lol.)

---------- Post added at 07:57 PM ---------- Previous post was at 05:56 PM ----------

Minor issue; it tends to crash the sim a lot. Not quite sure why. Anyone care to take a look at it and see if they might be able to pinpoint the cause?

It is possible my install has gone over the edge. I'm going to try a fresh install and see if that changes anything.

---------- Post added at 09:11 PM ---------- Previous post was at 07:57 PM ----------

Progress report: I created a new instance of Orbiter to test, with just the AV pack and my mesh in it. Still crashed.

I removed the textures from the mesh. No crash. It's the textures that are causing most of the problem.

I'm using a web-based conversion tool to create the dds textures, and apparently it's not up to the task. I can't get the nvidia conversion plugin to run on my system. Anyone else know of a dds conversion tool I could use (that doesn't cost an arm and a leg)? I'm soooo close to having this work!

Martin: I can send you the no-texture version if you like, and update you later when I get my texture issue worked out. Here's the building w/o the texture, it still looks pretty legit.

lockheedplain.jpg


---------- Post added at 11:24 PM ---------- Previous post was at 09:11 PM ----------

I found this program: http://www.easy2convert.com/bmp2dds/

I can't tell if it added mipmaps, but it did convert textures that didn't crash the sim. It also wasn't consistent (white came out a bit grey, had to change some of the white materials to match the textures) but hey, it worked!

Final view:

hangarstaticfinal.jpg


Here's a picture looking north from the 14 Freeway, at approximately the site of the Aerospace Valley Monument, a distance of five miles, showing how this building has dominated the valley skyline (such as it is) for decades.

vistapoint.jpg


---------- Post added 11-28-16 at 12:25 AM ---------- Previous post was 11-27-16 at 11:24 PM ----------

Edit: I spoke too soon. Still testing. Stand by...

---------- Post added at 12:44 AM ---------- Previous post was at 12:25 AM ----------

Hmmm. Must be a glitch that worked into my primary folder. Test folder with just the mesh works fine, but my "big" folder with all the addons I've tested so far, glitches. I'm willing to drop it on a couple of people to beta test, I think...
 
Last edited:

4throck

Enthusiast !
Joined
Jun 19, 2008
Messages
3,502
Reaction score
1,008
Points
153
Location
Lisbon
Website
orbiterspaceport.blogspot.com
...lowest possible polygon count, smallest possible textures....

Even with a low end computer the impact of having an interior wall with minimal details (more 30 or 40 polygons?) and 2048x2048 textures is close to zero.
Of course it all adds up but still... if we have high resolution terrain + textures why not some medium resolution buildings?


Another thing:
For a better integration, the buildings should have the roofs textured with the ground texture (or at least take those colors into account).

---------- Post added at 09:35 ---------- Previous post was at 09:22 ----------

Seems to be a bit rough on the processor though

....
Minor issue; it tends to crash the sim a lot. Not quite sure why.
...
I removed the textures from the mesh. No crash.
...
It also wasn't consistent (white came out a bit grey, had to change some of the white materials to match the textures)

Some things you can try:

If your mesh is acting funny, then you have a geometry problem. It's impossible for such a simple geometry to act heavy.
Check your model for duplicate geometry, for example. Do you have unneeded subdivisions ? All that will cause trouble on export.

Also it makes texturing harder. Probably it crashes on textures because the geometry is not right.

Material properties will certainly need to be tweaked after export.
To get better results texture the entire model. Solid white wall should be textures with a solid white part of your texture, and so forth. Remember, one texture per material on Orbiter.



Anyway, looking good, keep at it and you will find a workflow that works for you! :cheers:
 

Notebook

Addon Developer
Addon Developer
News Reporter
Donator
Joined
Nov 20, 2007
Messages
11,816
Reaction score
641
Points
188
I'm using a web-based conversion tool to create the dds textures, and apparently it's not up to the task. I can't get the nvidia conversion plugin to run on my system. Anyone else know of a dds conversion tool I could use (that doesn't cost an arm and a leg)? I'm soooo close to having this work!

Have you tried this:
http://www.mwgfx.co.uk/

"DXTBmp" converts between most formats, and lets you open the alpha channel in your paint program.
I mostly use it for converting from .jpg to .bmp then .dds(various flavours) for surface tiles.
That's on hold till I get a grip on Orbiter 2016 format, could be a while...

N.
 

gattispilot

Addon Developer
Addon Developer
Joined
Oct 17, 2007
Messages
8,707
Reaction score
2,683
Points
203
Location
Dallas, TX
Have you tried this:
http://www.mwgfx.co.uk/

"DXTBmp" converts between most formats, and lets you open the alpha channel in your paint program.
I mostly use it for converting from .jpg to .bmp then .dds(various flavours) for surface tiles.
That's on hold till I get a grip on Orbiter 2016 format, could be a while...

N.
This is what I use to convert bmp to dds textures
 

JonnyBGoode

Sky Marshal
Addon Developer
Joined
Oct 24, 2009
Messages
686
Reaction score
34
Points
28
Location
Bakersfield, CA
I'm working on the outbuildings surrounding the main hangar on site 10. PM me if you'd like a beta test copy.

Also... I just realized, when I put out the winnebago, I had one main mesh with a different texture on each side. Why is it now only one texture per mesh? Was that because I was using Vinka's tool? (Also still can't find Vinka's msh tool...)
 

4throck

Enthusiast !
Joined
Jun 19, 2008
Messages
3,502
Reaction score
1,008
Points
153
Location
Lisbon
Website
orbiterspaceport.blogspot.com
Orbiter meshes only support one texture per material, and one material per face.
Unless there's some trick I'm unaware.

Still, for a simple export/import to/from Orbiter, stick to that limitation. Your life will be easier :)
 
Top