Jump to content

Crashing during blender export


linkus
 Share

Recommended Posts

Hey everyone, I'm encountering a problem with the blender exporter. It's crashing 100% of the time while exporting (although almost always finishes exporting the whole scene with its materials). I'm using the latest 4.4.1 blender exporter and 2.76b blender on a mac. I'm attaching my export log if it's any help. Is there a way to get the blender log, if it would be more helpful?

 

Really looking forward to the help as this problem has been driving me crazy (always having to reopen the blender file when I want to continue working after the export).

 

	Exporter version: 4.4.1, Blender version: 2.76 (sub 0)
========= Conversion from Blender to Babylon.js =========
	Scene settings used:
		selected layers only:  false
		flat shading entire scene:  false
		inline textures:  false
		texture directory:  /**REMOVED**/
	Python World class constructor completed
	processing begun of mesh:  Glass_Dark
		processing begun of baked material:  Glass_Dark
			Cycles baking texture, type: DIFFUSE_COLOR, mapped using: BakingUV
		num positions      :  51
		num normals        :  51
		num uvs            :  102
		num uvs2           :  0
		num colors         :  0
		num indices        :  60
	processing begun of mesh:  Lamp_Mesh_4
		processing begun of baked material:  Lamp_Mesh_4
			Cycles baking texture, type: DIFFUSE_COLOR, mapped using: BakingUV
		num positions      :  371
		num normals        :  371
		num uvs            :  742
		num uvs2           :  0
		num colors         :  0
		num indices        :  684
	processing begun of mesh:  Door_Room2
		processing begun of Standard material:  Door_Room2_Material
		num positions      :  20
		num normals        :  20
		num uvs            :  0
		num uvs2           :  0
		num colors         :  0
		num indices        :  108
	processing begun of mesh:  Roof
		processing begun of baked material:  Roof
			Cycles baking texture, type: DIFFUSE_COLOR, mapped using: UVMap
		num positions      :  4
		num normals        :  4
		num uvs            :  8
		num uvs2           :  0
		num colors         :  0
		num indices        :  6
	processing begun of camera (FreeCamera):  Camera
	processing begun of mesh:  Walls
		processing begun of baked material:  Walls
			Cycles baking texture, type: DIFFUSE_COLOR, mapped using: UVMap
		num positions      :  952
		num normals        :  952
		num uvs            :  1904
		num uvs2           :  0
		num colors         :  0
		num indices        :  1644
	processing begun of mesh:  Floor
		processing begun of baked material:  Floor
			Cycles baking texture, type: DIFFUSE_COLOR, mapped using: UVMap
		num positions      :  4
		num normals        :  4
		num uvs            :  8
		num uvs2           :  0
		num colors         :  0
		num indices        :  6
	processing begun of mesh:  Door_Bathroom
		processing begun of baked material:  Door_Bathroom
			Cycles baking texture, type: DIFFUSE_COLOR, mapped using: UVMap
		num positions      :  79
		num normals        :  79
		num uvs            :  158
		num uvs2           :  0
		num colors         :  0
		num indices        :  102
	processing begun of mesh:  Door_Outside
		processing begun of Standard material:  Door_Outside_Material
		num positions      :  18
		num normals        :  18
		num uvs            :  0
		num uvs2           :  0
		num colors         :  0
		num indices        :  102
	processing begun of mesh:  Window_Big
		processing begun of baked material:  Window_Big
			Cycles baking texture, type: DIFFUSE_COLOR, mapped using: UVMap
		num positions      :  73
		num normals        :  73
		num uvs            :  146
		num uvs2           :  0
		num colors         :  0
		num indices        :  96
	processing begun of mesh:  Window_Small
		processing begun of baked material:  Window_Small
			Cycles baking texture, type: DIFFUSE_COLOR, mapped using: UVMap
		num positions      :  71
		num normals        :  71
		num uvs            :  142
		num uvs2           :  0
		num colors         :  0
		num indices        :  96
	processing begun of mesh:  Door_Room1
		processing begun of Standard material:  Door_Room1_Material
		num positions      :  18
		num normals        :  18
		num uvs            :  0
		num uvs2           :  0
		num colors         :  0
		num indices        :  102
	processing begun of mesh:  Window_Medium
		processing begun of Standard material:  Window_Medium_Material
		num positions      :  16
		num normals        :  16
		num uvs            :  0
		num uvs2           :  0
		num colors         :  0
		num indices        :  96
	processing begun of mesh:  Small_Window
		processing begun of baked material:  Small_Window
			Cycles baking texture, type: DIFFUSE_COLOR, mapped using: BakingUV
		num positions      :  147
		num normals        :  147
		num uvs            :  294
		num uvs2           :  0
		num colors         :  0
		num indices        :  204
	processing begun of mesh:  Big_Window
		processing begun of baked material:  Big_Window
			Cycles baking texture, type: DIFFUSE_COLOR, mapped using: BakingUV
		num positions      :  355
		num normals        :  355
		num uvs            :  710
		num uvs2           :  0
		num colors         :  0
		num indices        :  480
	processing begun of mesh:  Medium_Window
		processing begun of baked material:  Medium_Window
			Cycles baking texture, type: DIFFUSE_COLOR, mapped using: BakingUV
		num positions      :  149
		num normals        :  149
		num uvs            :  298
		num uvs2           :  0
		num colors         :  0
		num indices        :  204
	processing begun of mesh:  Lamp_Mesh_3
		processing begun of baked material:  Lamp_Mesh_3
			Cycles baking texture, type: DIFFUSE_COLOR, mapped using: UVMap
		num positions      :  581
		num normals        :  581
		num uvs            :  1162
		num uvs2           :  0
		num colors         :  0
		num indices        :  684
	processing begun of mesh:  Glass_Window
		processing begun of baked material:  Glass_Window
			Cycles baking texture, type: DIFFUSE_COLOR, mapped using: BakingUV
		num positions      :  124
		num normals        :  124
		num uvs            :  248
		num uvs2           :  0
		num colors         :  0
		num indices        :  144
	WARNING: The following lamp not visible in scene thus ignored: Spot_Hall
	WARNING: The following lamp not visible in scene thus ignored: Area
	WARNING: The following lamp not visible in scene thus ignored: Lamp
	WARNING: The following lamp not visible in scene thus ignored: Spot_Bathroom
========= Writing of scene file started =========
========= Writing of scene file completed =========
========= end of processing =========
elapsed time:  0 min, 55.0042 secs

 

Link to comment
Share on other sites

Just looking at what you provided,

texture directory:  /**REMOVED**/

looks weird.  Did you ever set this?  I also see a lot of baking / cycles use.  Baking in Blender is further out on the curve.  You might do a combination of providing UV's for all textures and switching to Blender render over Cycles where you can.

When Baking, if there was no UV, the exporter makes one with the name BakingUV, then deletes it.  Making your own UV means less work at export time.

You should also know that because a material was custom baked during export, it cannot be used across meshes.  If you are using the same cycles material in multiple meshes, baking outside the exporter process & saving to a file, might yield smaller results.

Finally, trying some spot exports with stuff deleted could yield more info on the cause. If no crash happened, then it could be the problem.

Link to comment
Share on other sites

14 hours ago, JCPalmer said:

Just looking at what you provided,


texture directory:  /**REMOVED**/

looks weird.  Did you ever set this?

Yes, I removed the directory from the log file myself.

what would be the correct workflow if I bake textures using cycles and want to export with the blender renderer? I mean, if I do as I did with the baking in cycles and then just switch to blender renderer and assign the textures, will it ignore everything that has to do with the cycles nodes and, in turn, pose less problems than exporting in cycles mode?

Link to comment
Share on other sites

I started trying to hide objects from my scene and got this error below: 

========= An error was encountered =========
  File "/Users/linkus/Library/Application Support/Blender/2.76/scripts/addons/io_export_babylon.py", line 329, in execute
    mesh = Mesh(object, scene, nextStartFace, forcedParent, nameID, self)
  File "/Users/linkus/Library/Application Support/Blender/2.76/scripts/addons/io_export_babylon.py", line 784, in __init__
    bakedMat = BakedMaterial(exporter, object, recipe)
  File "/Users/linkus/Library/Application Support/Blender/2.76/scripts/addons/io_export_babylon.py", line 2100, in __init__
    bpy.ops.object.mode_set(mode='EDIT')
  File "/Applications/blender.app/Contents/MacOS/../Resources/2.76/scripts/modules/bpy/ops.py", line 189, in __call__
    ret = op_call(self.idname_py(), None, kw)
ERROR:  Operator bpy.ops.object.mode_set.poll() failed, context is incorrect

It also crashed blender. What does that mean?

Link to comment
Share on other sites

If there is a direct Blender render equivalent, you should definitely use it over cycles.  If you want to do baking yourself, then save outside of export, you can then also use the Blender render (many videos which demo baking to texture).  The Cycles exporter support is nice during dev cutting out steps, but doing lots of it in export once the material is how you want it slows things down & prohibits sharing.

I believe any materials not assigned to a mesh do not get exported, so think you can keep the material using force.  If you ever wanted to change it, you still have it.

Just saw your error, do not know, how you are "hiding" mesh, but in order to bake you must switch to edit mode.  Probably not allowed to do that.  Will look if there is a fix next week.  Another way to hide from export is to move mesh to another level, then pick "selected layers only" on the scene level exporter options.

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...