Blender > .3dp import/export script.

Stop by here for help with RRT3 Editor problems and tips.
Just Crazy Jim

Re: Blender > .3dp import/export script. Unread post

Gumboots wrote:Hey hang on a doggone minute. I haz another idea. This one might even be useful. :mrgreen:

Since the .3dp import process drops information for normals, it follows that if you took one of the flat-shaded .3dp's and imported that into Blender, then exported it straight away using the smooth-shaded script, it should fix the problem.

Note that I said "should". Might be worth trying.
Well, I tried several formats, POV-Ray, Lightwave, AutoCAD/AutoDesk, etc., none of them worked any better. (a few of which stripped the UVmap off the mesh !hairpull! )

I then tried you latest idea, importing and exporting a flat-shaded 3DP with the smooth-shading script. Still flat-shaded, but at least the UVmap didn't go on vacation *!*!*!
User avatar
Gumboots
CEO
Posts: 1203
Joined: Mon Aug 13, 2012 4:32 am
Location: Australia

Re: Blender > .3dp import/export script. Unread post

Is the new Mogul smooth-shaded in your RT3 installation?
Gumbootz Lokomotivfabrik und Bierkeller

LMR Samson 0-4-0 - Pennsy H3 Consolidation - Custom double tank cars set
Just Crazy Jim

Re: Blender > .3dp import/export script. Unread post

Gumboots wrote:Is the new Mogul smooth-shaded in your RT3 installation?
Smooth shaded. So I am at a loss.
User avatar
Gumboots
CEO
Posts: 1203
Joined: Mon Aug 13, 2012 4:32 am
Location: Australia

Re: Blender > .3dp import/export script. Unread post

Ok, which version of Blender are you using? Every so often the nutters in charge change the syntax for various bits. I know the script works with 2.74 to 2.76, but can't vouch for it on other versions.
Gumbootz Lokomotivfabrik und Bierkeller

LMR Samson 0-4-0 - Pennsy H3 Consolidation - Custom double tank cars set
Just Crazy Jim

Re: Blender > .3dp import/export script. Unread post

I'm using 2.74 for RT3 stuff but I wouldn't even try to guess which subversion. There's a date and time on the splash screen: 2015-03-31 13:39

I will try another version and see where it goes.
User avatar
Gumboots
CEO
Posts: 1203
Joined: Mon Aug 13, 2012 4:32 am
Location: Australia

Re: Blender > .3dp import/export script. Unread post

That version should be fine. Beats me what is causing this problem. I used the same script that you've tried, and I get smooth shading.
Gumbootz Lokomotivfabrik und Bierkeller

LMR Samson 0-4-0 - Pennsy H3 Consolidation - Custom double tank cars set
Just Crazy Jim

Re: Blender > .3dp import/export script. Unread post

Since posting last night, I've tried the 32bit and 64bit versions of Blender 2.74, 2.75, 2.75a, 2.76, 2.76a, and 2.76b.

I've checked my Python install for issues, none detected. Python 2 is 2.7.12 (vers. 2.7.13 came out of beta on 17 Decemeber). Python 3 is 3.5.0, until 2 days ago, the latest stable release for Windows (vers. 3.6.0 came out of beta 2 days ago).

I tried a number of antique model formats that do not carry any embedded shading or UV information. Upon exporting the otherwise unproblematic file to 3DP, I still get flat-shading in RT3 format.

This simply proved that on my system all model formats work/appear as expected in Blender. I've tried the script in the archive and the version you shared last night. I've gone through the script line by line and all is as it should be.

If I import a random PopTop 3DP, in Blender, it is always flat-shaded even if the same model is smooth-shaded in RT3. When I import any of the models I have made, in Blender, they always appear smooth-shaded until they pass through the 3DP export, then they appear flat-shaded in Blender (just like a random PopTop 3DP), but are also flat-shaded in-game, unlike your Mogul.

So, having parsed this thing out, we can safely say:

• It's not a problem with Blender (you used Blender to debork the Mogul)
• It's not a problem with Python (you used Python via Blender to debork the Mogul)
• It's not a problem with the script (you used the script to debork the Mogul)
• It's not a problem with Milkshape 3D (proven by using roughly a dozen formats without shading or UVmapping data)
• It's not a problem with AutoCAD/AutoDesk (proven by using roughly a dozen formats without shading or UVmapping data)
• It's not a problem with RT3 (the game engine is simply rendering what it reads from the file)

Ergo, it has to be one of three things:

• An ID-10-T error, a.k.a. EBCAK, since this process is pretty soundly idiot-proof, not highly likely
• A system issue.
• A discrete issue with the model itself. I cannot think what that would be, but I am including it as a possibility.

That's where my idea well runs dry.

I'm attaching a RAR file with my model and game files for the problem child for you to look over when you have the time. It's not a mission critical matter and in a fairly crude state, just enough to test in Blender and in-game, and nothing more. The most I'm hoping for is that you can see something that helps fix the overarching issue on my end.
User avatar
Gumboots
CEO
Posts: 1203
Joined: Mon Aug 13, 2012 4:32 am
Location: Australia

Re: Blender > .3dp import/export script. Unread post

I'll happily take a look. This is intriguing, and if you've hit this problem it's a safe bet somebody else will too, sooner or later.

The .3dp's importing as flat-shaded to Blender is normal. Flat-shaded is Blender's default mode in the absence of any other information. Since Blender doesn't import any .3dp information re shading, the imported files default to flat. I just set them to smooth after importing, unless it's a face I particularly want flat.
Gumbootz Lokomotivfabrik und Bierkeller

LMR Samson 0-4-0 - Pennsy H3 Consolidation - Custom double tank cars set
User avatar
Gumboots
CEO
Posts: 1203
Joined: Mon Aug 13, 2012 4:32 am
Location: Australia

Re: Blender > .3dp import/export script. Unread post

Your PK4 is fine in my game. Smooth as silk.
Shot.jpg
Which is weird. The model appears to be fine, since it smooth-shades on my box. The Mogul is fine on your box and on mine. Beats me why you're getting flat-shading on the Martian beastie on your box.
Gumbootz Lokomotivfabrik und Bierkeller

LMR Samson 0-4-0 - Pennsy H3 Consolidation - Custom double tank cars set
Just Crazy Jim

Re: Blender > .3dp import/export script. Unread post

Ok, this just breaks my head. I just tested the same PK4 before posting it and it was flat-shaded. I just looked again and it was smooth-shaded. All that had changed was I rebooted the computer in the time in between. It makes no sense that a reboot would change shading properties. !hairpull!
Post Reply