Project Blender 2.63 + to Orbiter import/export addon

vlad32768

Member
Joined
Oct 11, 2010
Messages
78
Reaction score
0
Points
6
To anyone using this, does this work yet?
Which version of Blender do I have to use?
Is this the only / most recent Blender exporter available?

I think this is the only one Orbiter mesh plugin for modern Blender.

I haven't updated the plugin for a long time,but it should work with the latest Blender versions. Blender API is stable, and Blender developers usually don't change it.
 

RANSES

New member
Joined
Feb 3, 2016
Messages
2
Reaction score
0
Points
0
CFD .msh and Blender

Hello everybody, my name is Riccardo, an aerospace engineer working and studying on CFD (computational fluid dynamics) simulations and this is my first post on this forum (or better, the second one after the presentation post). I'm writing on an "old" thread, hoping not violating the terms, because this conversation seems really suitable for my question which is rather interesting and challenging, still regarding .msh files and their portability in blender. More specifically, the matter is the possibility of using this add-on also for importing .msh files coming from ANSYS Fluent software. Ther blender version I'm using is the 2.76 one. Do you think that would be possible?
 

vlad32768

Member
Joined
Oct 11, 2010
Messages
78
Reaction score
0
Points
6
Hello everybody, my name is Riccardo, an aerospace engineer working and studying on CFD (computational fluid dynamics) simulations and this is my first post on this forum (or better, the second one after the presentation post). I'm writing on an "old" thread, hoping not violating the terms, because this conversation seems really suitable for my question which is rather interesting and challenging, still regarding .msh files and their portability in blender. More specifically, the matter is the possibility of using this add-on also for importing .msh files coming from ANSYS Fluent software. Ther blender version I'm using is the 2.76 one. Do you think that would be possible?

Hi Riccardo,

Orbiter .msh files are just simple models for a computer game, representing only 2d surfaces made of triangles, and Fluent .msh is usually a 3d finite element mesh for CFD calculations. That's a different and more complex data.
My plugin can't do anything with Fluent .msh.
BTW what do you want to do with Blender and 3d FEM meshes?
 

Loopos

Procrastination Master
Joined
Sep 17, 2016
Messages
38
Reaction score
9
Points
8
3.Place io_orbiter_msh.py into Blender's addons directory
Can you pls teach me where the folder is located??
 

francisdrake

Addon Developer
Addon Developer
Joined
Mar 23, 2008
Messages
1,086
Reaction score
903
Points
128
Website
francisdrakex.deviantart.com
I played around with Blender recently. The io_orbiter_msh works with version 2.79.

Unfortunately not with the upcoming version 2.80! When trying to activate it, an error message is presented: "This script has not been updated to version 2.80. Ignoring."
This seem related to how the scripts are registered in Blender 2.80.

I don't know if Vlad is still around and could update his script, please?
The new Blender version 2.80 is a major improvement on the (somewhat cluttered) interface of Blender, much more friendly to use.
 

fred18

Addon Developer
Addon Developer
Donator
Joined
Feb 2, 2012
Messages
1,667
Reaction score
104
Points
78
I played around with Blender recently. The io_orbiter_msh works with version 2.79.

Unfortunately not with the upcoming version 2.80! When trying to activate it, an error message is presented: "This script has not been updated to version 2.80. Ignoring."
This seem related to how the scripts are registered in Blender 2.80.

I don't know if Vlad is still around and could update his script, please?
The new Blender version 2.80 is a major improvement on the (somewhat cluttered) interface of Blender, much more friendly to use.

I have the very same point here. I just started to finally get familiar with blender in this days and the new 2.80 is really a super step forward compared to the the 2.79. I tried to update the plugin myself but I don't know anything about python, so I tried with just the export part (personally I don't care much about importing, but just to get my models into orbiter). I got it to install, but no luck with showing up in the options and everything so I am still using 2.79 to export.

if vlad or anybody is up to the task it would be really a nice to have :thumbup:
 

Marijn

Active member
Joined
Mar 5, 2008
Messages
755
Reaction score
166
Points
43
Location
Amsterdam
I've been doing some research on this recently. To me, it seems that the glTF format is being pushed as a new 'standard'.

Therefore, I think we need a glTF-to-Orbiter converter. Export to glTF is supported by Blender2.80 without plug-ins.
 

llarian

Well-known member
Joined
Apr 1, 2009
Messages
578
Reaction score
159
Points
58
Location
Ottawa
Remember that Blender 2.8 is only a beta release at this point (Blender has a strange numbering system. There are enough changes in this version to make it 3.0 in any other application.). The API is being worked on but is not yet complete. Personally, I would wait for the general release of 2.8. That being said, I've been looking at what it takes to upgrade our addon since jayanam released his blender tutorials on the matter. Nothing concrete yet and I don't have Vlad's permission at this time.

edit: Oops. Make the Python API.

2nd edit: Link removed,
 
Last edited:

francisdrake

Addon Developer
Addon Developer
Joined
Mar 23, 2008
Messages
1,086
Reaction score
903
Points
128
Website
francisdrakex.deviantart.com
Thanks for trying! Sorry it does not work.

Changing the blender info verison in the script:
"blender": (2, 80, 0),
is unfortunately not enough.

Error message:
Attribute error: Module 'bpy.utils' has no attribute 'register_module'

When comparing it with other import/export scripts it looks like the registering process requires classes to be defined, which have register / unregister methods included.
The old method probably allowed this to done with simple functions.

So the challenge would be to structure the register / unregister in classes as it is done for the other import and export scripts.
 

fred18

Addon Developer
Addon Developer
Donator
Joined
Feb 2, 2012
Messages
1,667
Reaction score
104
Points
78

nope, it doesn't work. did you just update the version? because it is not enough. previously I went on and also updated the class registration, it installed fine but it didn't show up in my export menu.

I am wondering also if there is any compatibility issue between blender files versions. I think there is not actually... so one option could be to model and test render in 2.8 and then just export through 2.79.
 

francisdrake

Addon Developer
Addon Developer
Joined
Mar 23, 2008
Messages
1,086
Reaction score
903
Points
128
Website
francisdrakex.deviantart.com
I did install both versions, 2.79 and 2.8.
Once a model is modified in 2.8, it reports an error when trying to open in 2.79.
"File written by a newer Blender binary (280.0). Expect loss of data."

My test file loaded then as empty, no geometrical information.
And - if the "Load UI" option is checked - also all menu bars are removed.
 

Blake

Addon Developer
Addon Developer
Joined
Mar 9, 2009
Messages
235
Reaction score
123
Points
58
Location
Lehi, Utah
FYI, Blender script changes are documented here:


https://wiki.blender.org/wiki/Reference/Release_Notes/2.80/Python_API/Addons


How classes are registered and named is also changing. Scripts and blend files are not backward compatible.


As has been noted, this is Beta software and any changes made to scripts may or may not work in the next release. I'd stick with Blender 2.79 for serious Orbiter development until things are locked down a bit tighter with 2.80.


BTW, I do like the direction Blender is taking. It should soften the learning curve for many coming from other applications.
 

Traveller

Donator
Donator
Joined
Apr 25, 2012
Messages
27
Reaction score
0
Points
1
There will be some rewrite needed. Tessfaces was removed from the Mesh API, for example.
 

llarian

Well-known member
Joined
Apr 1, 2009
Messages
578
Reaction score
159
Points
58
Location
Ottawa
Thanks for the feedback ... and my apologies, guys. It was a late Saturday night thing while I was tinkering with a new Raspberry Pi, so I made the quick minimum change and then pulled a Microsoft and let the community do the testing. I abase myself.

I need it working too so I will continue working on the rest of it ... and then test it first. It would be better if Vlad came back to play as the original author always knows his software best. Please feel free to add in your own efforts, too.

I haven't tried it yet, but I think there is still the option of saving a Blender model as .obj and then using the obj to msh converter.
 

llarian

Well-known member
Joined
Apr 1, 2009
Messages
578
Reaction score
159
Points
58
Location
Ottawa
While I've been researching the required changes to Vlad's Blender i/o addon, I noticed that Blender 2.8 can output 3ds flies. Has anyone tried this yet and then passed the output through the max to msh converter successfully?
 

4throck

Enthusiast !
Joined
Jun 19, 2008
Messages
3,502
Reaction score
1,008
Points
153
Location
Lisbon
Website
orbiterspaceport.blogspot.com
Yes, we need a new plugin, specially one with support for more advanced materials (D3D9).
The current one only outputs GSGL/Blender Render materials, not Cycles.

I have a lot of things going on right now, but eventually I might be able to help with some testing. PM if needed :hmm:
 

vlad32768

Member
Joined
Oct 11, 2010
Messages
78
Reaction score
0
Points
6
I played around with Blender recently. The io_orbiter_msh works with version 2.79.

Unfortunately not with the upcoming version 2.80! When trying to activate it, an error message is presented: "This script has not been updated to version 2.80. Ignoring."
This seem related to how the scripts are registered in Blender 2.80.

I don't know if Vlad is still around and could update his script, please?
The new Blender version 2.80 is a major improvement on the (somewhat cluttered) interface of Blender, much more friendly to use.

It looks like Python API has changed in Blender 2.8.
Also the Blender render is replaced with Eevee, the script should export Eevee materials into a .msh file.
BTW, I didn't launch Orbiter for some years. Are there any improvements in Orbiter rendering engine that require some additional material data?
I will investigate the changes if I have free time.
 

vlad32768

Member
Joined
Oct 11, 2010
Messages
78
Reaction score
0
Points
6
WIP

Unfortunately, I haven't enough free time to update the module for 2.8.
But the work is slooowly getting done. Now I can import mesh geometry and UV data into Blender 2.8.
However, the old Blender renderer has gone in 2.8, so I have to learn how to work with new EEVEE node-based materials, and 2.8 PyAPI documentation isn't good yet.

AFAIK there are new advanced rendering plugins like d3d9Client.
Do they use cool material features like normal mapping, specular mapping etc? Maybe the plugin should handle features like that?
 
Top