From 9169cac38c86e584d552d5bb4ecc1956bda409e8 Mon Sep 17 00:00:00 2001 From: Jack Andersen Date: Tue, 9 Aug 2016 09:16:31 -1000 Subject: [PATCH] Blender crash fix for recent blender-git builds --- DataSpec/DNACommon/ANCS.hpp | 2 +- DataSpec/DNACommon/CMDL.cpp | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/DataSpec/DNACommon/ANCS.hpp b/DataSpec/DNACommon/ANCS.hpp index 8c85f6b2b..573d8c132 100644 --- a/DataSpec/DNACommon/ANCS.hpp +++ b/DataSpec/DNACommon/ANCS.hpp @@ -101,7 +101,7 @@ bool ReadANCSToBlender(hecl::BlenderConnection& conn, "\n" "# Clear Scene\n" "for ob in bpy.data.objects:\n" - " if ob.type != 'LAMP':\n" + " if ob.type != 'LAMP' and ob.type != 'CAMERA':\n" " bpy.context.scene.objects.unlink(ob)\n" " bpy.data.objects.remove(ob)\n" "\n" diff --git a/DataSpec/DNACommon/CMDL.cpp b/DataSpec/DNACommon/CMDL.cpp index e65301e9f..a81e862e8 100644 --- a/DataSpec/DNACommon/CMDL.cpp +++ b/DataSpec/DNACommon/CMDL.cpp @@ -428,7 +428,7 @@ void InitGeomBlenderContext(hecl::BlenderConnection::PyOutStream& os, "\n" "# Clear Scene\n" "for ob in bpy.data.objects:\n" - " if ob.type != 'LAMP':\n" + " if ob.type != 'LAMP' and ob.type != 'CAMERA':\n" " bpy.context.scene.objects.unlink(ob)\n" " bpy.data.objects.remove(ob)\n" "\n"