![]() |
|
Addon Development Developers post news, updates, & discussions here about your projects in development. |
![]() |
|
Thread Tools |
![]() |
#76 |
Aspiring rocket scientist
![]() ![]() ![]() |
![]() Quote:
Quote:
I'll give it a shot when I get home this evening and get back to you. Thanks again. |
![]() |
![]() |
![]() |
#77 |
Defender of Truth
![]() ![]() |
![]() Quote:
|
![]() |
![]() |
![]() |
#79 |
Orbinaut
|
![]()
Where do I put this addon for Blender version 2.57? If there are different versions of this then post them all.
![]() ![]() I meant were do the files (io_orbiter_msh.py and pax_global_header) go in the blender files. I have a plugins file but it has no .py files in it I can go in here C:\Program Files\Blender Foundation\Blender\2.57\python\lib or here C:\Program Files\Blender Foundation\Blender\blender-2.57-windows32\2.57\plugins or here C:\Program Files\Blender Foundation\Blender\blender-2.57-windows32\2.57\python\lib Last edited by XSSA; 08-09-2011 at 10:37 PM. |
![]() |
![]() |
![]() |
#80 |
Aspiring rocket scientist
![]() ![]() ![]() |
![]() Quote:
Click on "Install Plugin" and select the file. From here on there should you should be able to edit Orbiter *.MSHs using Blender's Import/Export function. |
![]() |
![]() |
![]() |
#81 |
Orbinaut
|
![]()
Hello vlad32768,
first of all many thx for endowing us with your Blender 2.5 export addon, really appreciate your efforts! ![]() Note number 7 in your python script Code:
# 7. Some meshes (XR5 for example) have groups with missing UVs in some vertices. Usually this issue is fixed automatically, # but in some cases script could crash with "List index out of range" error. Please report if it happens! I verified my troubles with the most simple setup - by UV unwrapping the cube that is shown when Blender starts. As soon as I add a UV map, exporting the mesh will throw the following error message: Code:
line 627 in export_msh uvs=me.uv_textures[0].data[n].uv_raw[(2*i):(2*i+2)] IndexError: byp_prop_collection[index]: index 0 out of range, size 0 I'm currently using Blender 2.68.1 r38019, 64bit version on Windows7, and your latest export script from http://gitorious.org/blender-orbiter...tarball/master It should be easy to reproduce the issue by - starting Blender - going to edit mode, Unwrap the cube - try to export the mesh ==> error thrown Is there something wrong on my end, or some incompatibility between my Version of Blender and your script? Any idea how I could support debugging this issue? Regards, Ludl PS: btw, do you know this Blender 2.49->Orbiter.msh export script?: http://sourceforge.net/projects/blorbiter/ That script is nicely written, with plenty of comments, and has some nice features you might want to include in your export module as well, e.g. automatically generating *.dds files by writing and converting a *.bmp directly from python. Neat ;-) |
![]() |
![]() |
![]() |
#82 |
Orbinaut
|
![]()
Started to debug my problems, installed Winpdb to have a closer look what's going on - many things to learn about internal blender data structures ...
What I realized today is that the simple test case I described in my previous post is indeed throwing an error - but actually an other one than what I get when trying to export my own model. Looks like the export script dislikes being in "Edit Mode" (instead of "Object Mode") when trying to export the UV unwrapped blender cube. Means: - starting Blender - going to "Edit Mode", Unwrap the cube - remain in "Edit Mode" and try to export the mesh ==> will throw an error while on the other hand: - starting Blender - going to "Edit Mode", Unwrap the cube - switch back to "Object Mode" and try to export the mesh ==> no error! As soon as I have learned more about Blender's API, I might better understand what's going wrong here. Meanwhile I just can recommend that whoever stumbles across above error should check if he's trying to export while being in "Edit Mode". Me, for now, will try to look more into the details of the error thrown when trying to export my own model - which happens around line 679 Code:
if has_uv: file.write(" {} {}".format(v[2][0],1-v[2][1])) |
![]() |
![]() |
![]() |
#83 |
Orbinaut
|
![]()
Ludl, thanks for your posts! Sorry for late answer, I was on vacation.
Quote:
Also, I wanted to learn something about Python and Blender 2.5 API; that's why I wrote the addon. About .dds converting. AFAIK Blorbiter uses an external utility to convert textures to .dds. I write my addon on a Linux workstation, and I don't know any cross-platform utility that can convert files to .dds. So this feature is not implemented, but it's easy to add it. Quote:
When I have time I'll test the script with the latest Blender revision (already 2.59 ![]() |
![]() |
![]() |
Thanked by: |
![]() |
#84 |
Orbinaut
|
![]()
Hello Vlad, thx for your reply, hope you had nice vacations ... ^^
![]() Meanwhile I found out what was the problem when trying to export my model. As one could have expected, there were some issues in the model. There existed several orphaned vertices, some of them easily removed by Blenders "Remove Double" function (forget to do that after spin-duplicating), but after that done, still several hard-to-find vertices remained. Finally I found out that one can find and get them easily selected by commanding Code:
bpy.ops.mesh.select_by_number_vertices(type='OTHER') Looking into the details of your script, I understand that the orphaned vertices are added to the vertex list, but as they are not enlisted in any face, your script fails when trying to add an UV index vector to them. Maybe one could just skip such orphaned vertices? For sure one could improve the error message, I assume ;-) Regarding *.dds export: you are correct, blorbiter script utilizes "DxTex.exe", a Windows executable. If I should come across a linux *.dds converter I'll let you know ^^ (though chances should be small, especially if targeting for an all-platform solution). Thx again for your export script! Ludl PS: Blender2.59 - I need to upgrade ^^ |
![]() |
![]() |
![]() |
#85 |
Orbinaut
|
![]()
Some changes:
-- Another fix due to API change. Addon now works with Blender 2.59. -- Fixed that bug with exporting in Edit mode. --Added "Delete orphan vertices" feature that helps to avoid "List index out of range" error when there are such vertices in selected meshes. Thanks Ludl for bug investigation! Last edited by vlad32768; 08-24-2011 at 07:52 PM. |
![]() |
![]() |
Thanked by: |
![]() |
#86 |
Orbinaut
|
![]()
Hi Vlad,
many thanks for continuing your work on exporting mesh files from Blender. I've tested your latest version with Blender 2.59 on two of my old models (with orphaned vertices in), and your new option to remove those works like a charm! ![]() Best regards, Ludl |
![]() |
![]() |
![]() |
#87 |
Orbinaut
|
![]()
Blender 2.63 is released! The long-anticipated Bmesh is finally here!
I updated the script, it should work with blender 2.63 and later. Now you can use NGons in your models. Download and enjoy! I tested the script with a very little model with some NGons. Try it with your advanced models and report bugs. Last edited by vlad32768; 05-01-2012 at 10:26 PM. |
![]() |
![]() |
Thanked by: |
![]() |
#88 |
Addon Developer
![]() ![]() |
![]()
How did I miss that thread ?
![]() Now that's a really good reason to use Blender instead of Anim8tor... Excellent work there ! ![]() |
![]() |
![]() |
![]() |
#89 |
Aspiring rocket scientist
![]() ![]() ![]() |
![]()
Havn't found any issues yet.
Thanks again Vlad. Congrats on a job well done. |
![]() |
![]() |
![]() |
#90 |
Defender of Truth
![]() ![]() |
![]() Quote:
|
![]() |
![]() |
Thanked by: |
![]() |
|
Thread Tools | |
|
|
Quick Links | Need Help? |