Jump to content
MedicalByte

Blender V3O Import/Export Scripts

Recommended Posts

I have been working on Blender V3O Import/Export scripts for the past few weeks and have achieved what I believe is a suitable state for beta release of the scripts.

Thanks goes to THVFD for his patience while I bugged him with all my Zmodeler2 questions.

 

Requires Blender v2.7

 

These scripts are licensed under the GNU GPL v2.0 license (http://www.gnu.org/licenses/gpl-2.0.txt).

 

Any use of these scripts and resulting actions is at the sole-risk of the user! I have done my best to ensure the scripts work as intended, but it's a good idea to keep back-up copies of models, textures, and any other data before use of these scripts.

 

Updates will be edited into this post.

 

Current Features and Supported Functions:

Import/Export Mesh Vertices/Faces

Import/Export Materials

Import/Export UV Mapping

Code comments! (not the best, but I'll try to keep it somewhat documented for those who'd like to help improve it or understand what I've learned about the v3o format so far)

 

Planned Features:

Optional rotation on export

 

Known Bugs:

B001 - Can't export unless the model is uv unwrapped. - Fixed

B002 - Can't export an imported .v3o model when a texture image fails to load. A texture image can fail to load when it doesn't exist in the imported .v3o file directory.

 

 

Updates

20150225233000

  • Fixed Bug #001
  • Added a ton of comments and removed some uneeded code

 

If y'all have any issues with the script or find any bugs, let me know here. If you are able to send me (via PM) any models/textures/.blend/.v3o files you are having issues with, I can hopefully recreate the specific bug on my end to work on a fix a little faster.

 

If you have any feature requests, by all means ask! I can't guarantee anything but you never know till you try.

 

Installation:

1. Extract the "io_mesh_v3o.zip" file.

 You should have a directory called "io_mesh_v3o" with four files inside. The file names are "__init__.py", "export_v3o.py", "import_v3o.py", and "License.txt".

2. Open the "%USERPROFILE%\AppData\Roaming\Blender Foundation\Blender\2.73\" directory in Windows Explorer.

3. If it doesn't already exsist, you need to create a folder named "scripts". Inside of the scripts folder, create another folder called "addons".

4. Move the "io_mesh_v3o" folder into the "addons" directory. The four files referenced above should now be in the "%USERPROFILE%\AppData\Roaming\Blender Foundation\Blender\2.73\scripts\addons\io_mesh_v3o" folder.

5. Start Blender up, and goto "File->User Preferences".

Spoiler

image.png

6. In the User Preferences window, goto the "Add-ons" section and search for "v3o".

Spoiler

image.png

7. Enable the v3o add-on by checking the box on the far right. You can save the setting by clicking "Save User Settings".

Spoiler

That's it! The Import/Export options should now be available in the Blender File menu.

b2_io_mesh_v3o.zip

b2_io_mesh_v3o.zip

  • Upvote 4
Link to comment
Share on other sites

I'm using this script to export a model I've made and I'm having a couple of issues. When I initially modeled the vehicle I followed the dimensions of the blueprint and the model ended up being much larger than real world version. I scaled down the model but no matter what I try, the v3o file keeps the original size of the model, not the scaled down version. 

 

The second thing is that when I export a model, the v3o version of the model contains 50-75% more polys than the blender model. To my inexperienced eye most of the new faces are not needed, it simply turns all the faces into triangles.

 

The blender model I try to export

AcxBSHP.png

 

The v3o file when I import it back in Blender:

1DfSEA1.png

Link to comment
Share on other sites

Correct me someone if I'm wrong, but it appears that blender uses squares and v3o files don't like those, making them into triangles. I don't know if there's a way with converting it to solve this, other than either making it with triangles originally, or post conversing editting. Usually when you convert something you have to spend time editing it to rectify issues with it. 

 

In as far as the scaling, it may be worthwhile to just scale it all in Zmod, instead of blender if it keeps resetting to normal. It looks like there's an error while saving if it won't save the scaled dimensions. 

Link to comment
Share on other sites

Correct me someone if I'm wrong, but it appears that blender uses squares and v3o files don't like those, making them into triangles. I don't know if there's a way with converting it to solve this, other than either making it with triangles originally, or post conversing editting. Usually when you convert something you have to spend time editing it to rectify issues with it. 

 

In as far as the scaling, it may be worthwhile to just scale it all in Zmod, instead of blender if it keeps resetting to normal. It looks like there's an error while saving if it won't save the scaled dimensions. 

 

Thanks for the reply!

 

If I notice any lag while using the model in-game I'll try and optimize it a bit more. I'm not really keen on purchasing a license for ZModeler, especially since I'll only use it to convert the file. I'll ask a friend to convert the files with ZMod and see if that fixes the size issue, but I don't like bothering someone else every time I make a change to the model. I was really happy to find this script and was hoping it would take ZMod out of the equation...

Link to comment
Share on other sites

Thanks for the reply!

If I notice any lag while using the model in-game I'll try and optimize it a bit more. I'm not really keen on purchasing a license for ZModeler, especially since I'll only use it to convert the file. I'll ask a friend to convert the files with ZMod and see if that fixes the size issue, but I don't like bothering someone else every time I make a change to the model. I was really happy to find this script and was hoping it would take ZMod out of the equation...

You can use the triangulate modifyer to change it all to trriangles i model in blender and dont have any issues out of them you can pm me if you need anymore help

Sent from my iPhone using Tapatalk

Link to comment
Share on other sites

You can use the triangulate modifyer to change it all to trriangles i model in blender and dont have any issues out of them you can pm me if you need anymore help

Sent from my iPhone using Tapatalk

 

Thanks for the tip! It will be useful in the future to keep an eye on the poly count. I don't have any other questions right now but I will keep your offer in mind.

Link to comment
Share on other sites

Thanks for the tip! It will be useful in the future to keep an eye on the poly count. I don't have any other questions right now but I will keep your offer in mind.

If you look at the top it says faces,tris, etc

If you look at the number next to tris it will tell you how many triangles there are

Sent from my iPhone using Tapatalk

Link to comment
Share on other sites

For some reason it wont let me import models? it comes up with an error????

The models are giving you the error bc of 1 of 2 things

1. Make sure the model is unlocked(to do this open the .v3o in a word program such as notepad++)

2. The model is missing a texture

Sent from my iPhone using Tapatalk

Link to comment
Share on other sites

The models are giving you the error bc of 1 of 2 things

1. Make sure the model is unlocked(to do this open the .v3o in a word program such as notepad++)

2. The model is missing a texture

Sent from my iPhone using Tapatalk

i made a vehicle but im having trouble texturing the rest of the body for it

Link to comment
Share on other sites

PM me your issues with it and i shall help you fix it

Sent from my iPhone using Tapatalk

do you want me to pm you the whole thing because it is the first fire engine made it through blender and i really appreciate the help on this.

Pierce_PUC_engine.pngThis is the the problem im having with it i had made a Pierce PUC Engine thats needs to be fixed up a bit 

Link to comment
Share on other sites

do you want me to pm you the whole thing because it is the first fire engine made it through blender and i really appreciate the help on this.

Pierce_PUC_engine.pngThis is the the problem im having with it i had made a Pierce PUC Engine thats needs to be fixed up a bit

Yes pm me the whole thing

Sent from my iPhone using Tapatalk

Link to comment
Share on other sites

My apologies for missing all the activity here. Thanks TH for helping people out!

BogdanM, in regards to the scaling issue, there is a way to get the scaling to "stick". I didn't implement the auto-reset of the scaling vars in the scripts, but there is a way to do it. If you are still having the issue let me know and I can take a look when I get a spare moment.

On the triangles vs quads issue, Newfoundking is correct, the v3o format is based on triangles, so the export script will convert all quads to triangles so it plays nicely in Emergency 4.

Link to comment
Share on other sites

On ‎2‎/‎20‎/‎2016 at 2:01 PM, MedicalByte said:

My apologies for missing all the activity here. Thanks TH for helping people out!

BogdanM, in regards to the scaling issue, there is a way to get the scaling to "stick". I didn't implement the auto-reset of the scaling vars in the scripts, but there is a way to do it. If you are still having the issue let me know and I can take a look when I get a spare moment.

On the triangles vs quads issue, Newfoundking is correct, the v3o format is based on triangles, so the export script will convert all quads to triangles so it plays nicely in Emergency 4.

excuse me, but I think the download is broken, I just got into modeling and decided to use blender, when I click the download link it said that the website cannot display the page and it may be due to a programming error, I f you could fix this or re-upload that'd be great. Thanks.

Link to comment
Share on other sites

Fixed download link?

 

On 3/16/2016 at 5:35 PM, dinwitty said:

I have blender 2.71 and its not working, the import v3o shows up, I try to import a model but does not work.

 

played around again, the cube was hiding it, however the model is all "scrunched", all parts centered.

if you are importing multiple files you need to move the model around to an open position before importing the next file. And many models are locked and that causes the error message to pop up.

Link to comment
Share on other sites

On ‎3‎/‎19‎/‎2016 at 8:16 PM, Connor Brumleve said:

Fixed download link?

 

if you are importing multiple files you need to move the model around to an open position before importing the next file. And many models are locked and that causes the error message to pop up.

The download link isn't fixed (yet) at least for me, is it working for you?

  • Upvote 2
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.



×
×
  • Create New...