From 5658c6ea1a5caf1b408366cebf785f79d650ff53 Mon Sep 17 00:00:00 2001 From: Mikko Rasa Date: Mon, 3 Aug 2009 12:25:44 +0000 Subject: [PATCH] Properly handle the case where an object doesn't have a main texture but its technique does --- source/object.cpp | 2 ++ source/technique.h | 1 + 2 files changed, 3 insertions(+) diff --git a/source/object.cpp b/source/object.cpp index b53a3f08..2026e3d5 100644 --- a/source/object.cpp +++ b/source/object.cpp @@ -132,6 +132,8 @@ Object::Loader::Loader(Object &o, Collection &c): void Object::Loader::finish() { + if(obj.technique && !obj.main_texture) + obj.main_texture=obj.technique->get_main_texture(); for(unsigned i=0; i