Jump to content

Blender exporter woo's


will233
 Share

Recommended Posts

I tried to UV map the default scene cube, and apply a texture. I added a texture to the default material of the cube(I think) by following this tut http://blogs.msdn.com/b/eternalcoding/archive/2013/06/28/babylon-js-how-to-load-a-babylon-file-produced-with-blender.aspx. When i export I get this log:

 

    Babylon.js Exporter version: 1.7.0, Blender version: 2.72 (sub 0)
========= Conversion from Blender to Babylon.js =========
    Python World class constructor completed
    processing begun of material:  cube.Material
    Diffuse texture found
Error encountered processing image file:  C:\Users\me\Documents\blends\ground.png, Error:  'C:\\Users\\me\\Documents\\blends\\ground.png' and 'C:\\Users\\me\\Documents\\blends\\ground.png' are the same file
    WARNING image texture type not recognized:  <bpy_struct, MaterialTextureSlot("Tex")>, ignored.
    processing begun of mesh:  Cube
        num positions      :  30
        num normals        :  30
        num uvs            :  60
        num uvs2           :  0
        num colors         :  0
        num indices        :  36
    processing begun of camera (FreeCamera):  Camera
    processing begun of light (POINT):  Lamp
========= Writing of scene file started =========
========= Writing of scene file completed =========
========= end of processing =========

 

Thank you for any help.
 

Link to comment
Share on other sites

Is the blender exporter currently broken? I tried this with different versions of blender. I tried it in Ubuntu. I tried it with downloaded blends. I always get same error. Is it possible to get an older version of the exporter?

Link to comment
Share on other sites

Looking at this now.  If I do anything on weekends, it is solely my own stuff.  For search purposes, GIT (and every other source code management system) always allows you to get previous versions.  Assuming you are using the Github interface, display the history file in question.  Select your version, click on raw.  Select everything, Crtl-A, and put on clipboard.  Paste it into a local file & save.

 

Hold off on that for a while.  Another thing for searchers is:  the exporter tries to copy the image file so a version will also reside in the same directory as the created .babylon.  Blender, I think, can also encapsulate a texture file inside of a .blend, so this gets an external version back in that case.

 

I am glad you posted your log file.  From it I see you have uvs.  The real problem line is the one after the error you highlighted.  The copy fail is understandable, since you are creating the .babylon in the same dir as the texture.

 

stay tuned.

Link to comment
Share on other sites

@will233 -  Good news.  Think you can go forward assuming it is working.  Thanks for bring attention to this.

 

@Deltakosh - The image type not recognized warning was put in by m0ppers, never communicated with him, in https://github.com/BabylonJS/Babylon.js/commit/a7e8e39e965dcca597d321d7057eaeee4686af09

 

Before, there was no warning there.  It is because only at the end are things elif'd that this warning shows erroneously for diffuse textures.  Can a given texture in a single iteration of this loop be multiple types?  If so, should probably just delete this warning, unless we want to add a boolean, useFound, and only show warning if !useFound.

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.

Loading...
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...