Blender exporter

Just wondering how people were getting on with the blender exporter as until/if I get classics 3 and "if" cmp works to commit content can't try it in a scenery.

As regards exporting to the im file exports OK with 1 or 2 textures on a test cube.

Just tried it on a static seaplane, one texture, I made a few years ago but came up with an error notice no material assigned to object cylinder 004 and to object cylinder 002 even though I had joined all the parts when I made it and all just one mesh.

Then tried it on one of my canal narrowboats made a few years ago with one texture and the blend file exported OK to the i.m. file OK with no error notice.

As I am unable to see what happens when the im file is in trainz perhaps others could detail what they have put into trainz from Blender, number of textures on object, any alpha textures on windows, etc, or any problems, etc.

Would be useful anyway for others who may read this thread.

Barry
 
Last edited:
Trying the exporter on rhuddlan castle which is one of the series of North Wales castles I have made.
I kept this version fairly simple just the towers and walls based on plans with one texture. Parts made seperate textured then joined.
I took the textures off then put it back on with F6 key etc.
set to image and load etc.
It worked for the narrowboat but doesn't seem to work this time

Blender comes up with error notice.
"file<string> line 1393 in module
ditto...........line 386 in CollectData
ditto...........line 1142 ib GetMesh Data
Name error: global name "amt" is not defined.

So not sure what the name error refers to.

Will try another of my castles and see what happens.

Barry
 
Tried Conway and Caernarvon castle and same error notice so looks like I am doing something wrong, or the textures buttons F6 tab needs to be set for each component before joining?
Objects were made before I tried Blender exporter.

Carnaervon castle as vrml2

Barry
caernc.jpg
 
Last edited:
Hi Barry,

for each material used by the objects you want to export either no texture or an image texture must be assigned.

For a material you can assign up to 10 textures in Blender, up to three textures are supported by Trainz(afaik); it would be hard to implement that using the image property of a Blender face(which can hold only one image name) like the VRML exporter does.

Ciao
Uschi
 
Hi Uschi

I think it's just the case of finding what I need to click on as I don't do anything when exporting vrml2 except put the texture on with the UV window or UV Calculation (U with mouse over mesh window).

Same I think applies to obj. although can't test that yet until next version of sailsimulator comes out, but seems to make the obj file OK with no errors.

Thanks

Barry

P.S. Had another try as only one texture on this castle.
Set the materials to 1 as showed 4. Set F6 tab to material and loaded texture. Textured before I started trying the exporter, so UV window shows the texture on castle and Alt plus Z just puts it back on.
Only result I get is to lock up Blender.
Will try again and will remove texture and put texture on again last with UV window.

Same again and Blender locks up and restart it. ( Vista).
 
Last edited:
Success.

I made the material name in the material column the same as the texture name.
Not quite sure why you need a material colour when it is not seen and hidden by a texture.

Set the F6 to image etc, loaded texture and the texture was already put on previously using the UV window.
So apparently using U and mouse over mesh window or just the UV window both seem to work OK

Possibly because its quite a big object I clicked Blender off too quick which caused it to lock up.

Took about half a minute to minute before the (im) box came up to click.

Next I need to try it on another of my castles to see if I get the same result then write it up for myself so I can remember.

Finally get trainz classics 3 , and see if I can get cmp to eventually work to commit content.

Thanks

Barry
 
Last edited:
Nothing more I can do now untiil I get Classics 3 and see if CMP works to commit content (Nothing to do with downloading as use ftp anyway). If not, as previous, pointless then me looking further into the exporter.

Still not sure about multiple textures or rather do single textures on seperate objectS, which are then joined which then have one material colour as one object work OK, as they seem to, as explained below.

Caernarvon castle worked OK, one texture and managed to get Conway Castle to work, which I think had 4 seperate objects joined with 4 sepearate textures: castle brick, floor, rock, windows/doors.

However not quite sure how I did that.

Tried 4 different boxes with 4 seperate textures, joined them and one material colour default grey then.
That made the im file just using the F6 settings. set to Image, and put the the names of the 4 textures in the boxes and loaded texture for each.

Did not set up seperate links and pipeline, links and materials, etc (that the part I don't understand)
Whether the im file shows them right in trainz unable to check that as explained.

Unfortunately there doesn't seem much feedback of actual content made with Blender and exported as im on this thread. Perhaps it's on another thread? I don't know.

Stll curious to know if obj file animation will export just one file for animation as exports one texture file for each poition making 100 or 250 files etc. Also apparently unusable in next version of sailsim for animation as key times missing or similar the way I tried exporting obj, although works fine in Blender?

That about ties up my input on the im. file.

Thanks

Barry
 
Last edited:
Hi Ahsan that's history now.

Will wait until I get classics 3 and will go through the usual procedure with cmp. once again for the last time.
I detailed it all in threads a while ago.

For scenery and content making the system and procedures have to be user friendly and stable to be worthwhile spending more time on them which was to use trainz as a world editor for c1800 as regards my own content and scenery making in line with using the sailing simulator in a similar way. Also this way I can use the same blend files for both simulators.

Alternatively could also use gmax again, drag dxf file fromm blender into gmax window then add attachment points with gmax.
Managed to get the textures back on with a few mouse clicks at least for single texture last time.

This time I have updated the nvidia drivers. I am on dial up, and I don't need it to connect to the download station as I always used ftp anyway for my requirements, and to get back my own content on DS and the small amount of content from others.

I tried all the usual cures with cmp as it locked up on commiting content after a little while which in turns makes Surveyor useless as its all integrated, but now disposed of clasics 1&2 so will see what 3 brings.

Locking up means classics driver and surveyor and then required restarting, not sure control/alt/del or just classics 1/2.
I think it varied at the time.

At least the route should be interesting in driver if nothing else for classics 3.

Will have a look at the thread but think I read it all previously.

Thanks

Barry

P.S Saved linked thread for reference.
 
Last edited:
Hello Barry

Time to cure your CMP:wave:

1. Whats is your PC Spec?
2. What Version of Windows have you got?
3. Have you got MS Net Installed?
4. What version of Trainz are you running 06 or TC?
5. Have you ran TrainzDiag to see if it passes all Tests?
6. Do you run Trainz in OpenGL or DirectX?
7. Whats settings are you using to run Trainz?
8. Have you installed the latest Graphics card drivers?
9. Any other software running in the background when you use CMP?

Regards

Ahsan:)
 
Last edited:
Hello Ahsan

no cmp, no trainz, no lottery win;)
Has to wait until I get classics 3 now.

But Vista, nvidia, 8600gts, classics only, latest drivers installed for card.
Quite a bit runs in the background with Vista but no intention of altering or stopping anything.

Just removed SP1 to Vista as twice windows vista didn't boot up and had to use sytem restore to start it.

With nvidia no idea how to change to open gl now with the current nvidia panel. Changed in trainz?
Net 2 and 3 I think are now on the computer.

If possible I don't want to connect to the Internet with CMP and if I remember correctly there is a setting to not connect when starting up.
Only want it as a content manager not as a download manager to put content into surveyor with commit function.
CMP and dial up I think would be unsuitable and much easier by ftp for my interests.
No idea if that can be done with the way it works.

Anyway thanks for the interest.

Barry
 
Hello Ahsan

no cmp, no trainz, no lottery win;)
Has to wait until I get classics 3 now.

Just removed SP1 to Vista as twice windows vista didn't boot up and had to use sytem restore to start it.

With nvidia no idea how to change to open gl now with the current nvidia panel. Changed in trainz?
Net 2 and 3 I think are now on the computer.

Barry

Hello

Ok Barry if you insist wait till your TC3 comes, I hope CMP works for you then.;)

I've never had problems with CMP in Microsoft Vista SP1 and Microsoft XP.:D

I've got Windows Vista Ultimate with SP1 installed with no problems.:cool:

In Trainz if you select options from the main menu and then select the display settings tab then their you have the option of running Trainz in OpenGL Mode or DirectX Mode.:wave:

Regards

Ahsan:)
 
Last edited:
Hi Ahsan to explain a little more I got trainz 2004 and trainz classics a few months ago but 2004 no longer suitable siimply because of invisible track not visible when driving in driver map.
Bit like trains and you can't see where they are going but in my case, sailing ships, canal barges and horse drawn transport and canal narrow boats.

Classics I think has visible, invisible track in driver map.

So on to classics 1/2 these were interesting enough in driver mode but too exasperated wth cmp after many hours so disposed of them.

Classics 3 has an interesting route so will use it for that.
If I can get cmp to work when I receive it well and good, and will try the blender exporter with it as all my files are all there as blend files and perhaps will try vulcans (Ian's) working locks, etc and include them in early canal networks c1800.

If not no matter, as just waiting for next version of the Stentec sailsimulator or maybe trainz 2009 as well, if it has integrated dem data and interestiing functions for non train routes plus a friendly cmp (for everbody;) ).

Using broadband and using dial-up I think may make our cases different as regards ease of connecting with cmp to the internet.
However I ONLY want cmp to commit content not for downloading content, and I don't know how that works out for people, as most of the posts seem to be about downloading yet CMP is essential to make routes and to add content now.

My SP1 for Vista is automatic download from MS as had Vista for almost a year.

Barry
 
Last edited:
Getting back to the exporter any feedback of blender content made and exported using the trainz exporter...especially using a few textures (photographic, etc) on an object rather than material colours, etc.
I exported Conway castle to the im file so will see what classics 3 brings as regards testing it.

Barry
 
Last edited:
. . . .

In Trainz if you select options from the main menu and then select the display settings tab then their you have the option of running Trainz in OpenGL Mode or DirectX Mode.:wave:

Ahsan:)

What is the difference between these modes and is it specific to Vista?

Thanks,
 
What is the difference between these modes and is it specific to Vista?

Thanks,

There are two main graphics standards DirectX is a Microsoft one that is specific to Windows and optimised for games the other is OpenGL which is a more "standards" based one.

ATI made money by incorporating DirectX in silicon to get good performance at a reasonable price.

It takes about two years for a feature to make its way into the OpenGL standard however you are allowed to have extensions to the standard. So basically nVidia's business model to to use propriety extensions to the OpenGL standard then assist companies such as Auran to get the best performance out of their games by using the features on their cards. Hence the nVidia logo on Auran's web site.

So in general if you have an AT or rather AMD video card then DirectX is probably better if you have an nVidia card then OpenGL is probably better.

Cheerio John
-- /* Style Definitions */ p.MsoNormal, li.MsoNormal, div.MsoNormal {mso-style-parent:""; margin:0cm; margin-bottom:.0001pt; mso-pagination:widow-orphan; font-size:12.0pt; font-family:"Times New Roman"; mso-fareast-font-family:"Times New Roman";} @page Section1 {size:612.0pt 792.0pt; margin:72.0pt 90.0pt 72.0pt 90.0pt; mso-header-margin:36.0pt; mso-footer-margin:36.0pt; mso-paper-source:0;} div.Section1 {page:Section1;}[FONT=&quot][/FONT]
 
So how is the exporter working out with proper 3D content with a few photographic textures, etc for static items, etc, for a start, then attachment points, animation, etc.

If I get CMP to work with clasics 3, I intend to use just Blender and the exporter, so would be interesting to read how others are getting on.
Is anybody using it as no mention so far?

Pointless me trying to use gmax again, as I need the blend file for trainz and the sailing simulator eventually, as have been using Blender for about 5 years or so now I think and no no longer any interest in making the same content twice having to use gmax.

Barry
 
Last edited:
Ahsan I have looked at that, but it would still be interesting to read on this thread what has been made and exported into trainz using it, then others could also read about it.

But cmp... willing I can soon find out myself what works and what doesn't as have been making content using Blender for about 5 years for the sail simulator as vrml2, and also soon obj. and some I put into trainz exported as dxf. and exported through gmax. Also have used the same blend files in Virtual sailor as direct.x which exports well with texture.

Just re-reading it and does not sound encouraging as regards future versions and changes in file format, etc.
Whether Auran will ever program trainz to read other file formats i think is doubtful so don't know what to make of things.
However I can always just use driver mode.



Barry
 
Last edited:
The Blender exporter support all materials the 3dsMax exporter does. Animations and attachement points are also supported. What's currently not possible is the creation of PM files; as they are marked as obsolete I'm not sure if I should invest in this, the only problem is that pantographs must be in PM format up to TRS2006, I don't know if this is still valid with TC.

You can take a look at the examples in the download section at sourceforge, all examples can be imported into Trainz. I have used them as test cases, so don't expect to much artistic expression ;).

Regards Torsten
 
Back
Top