diff options
author | Antony Riakiotakis <kalast@gmail.com> | 2014-09-23 22:40:27 +0400 |
---|---|---|
committer | Antony Riakiotakis <kalast@gmail.com> | 2014-09-23 22:40:27 +0400 |
commit | eb464eed57e695594c1e8c6738c27a6b7846d657 (patch) | |
tree | ae2d28c9332a55c098f00e45d26061a2af8b176a /source/gameengine/BlenderRoutines | |
parent | 2e7c8f730c2b78ddd64140229d49615db84900c6 (diff) |
Fix game engine not supporting material view.v2.72-rc1
Force textured view in that case. Also correct a few uses of the GLSL
flag in the viewport. Should only be relevant for textured viewport.
Diffstat (limited to 'source/gameengine/BlenderRoutines')
-rw-r--r-- | source/gameengine/BlenderRoutines/BL_KetsjiEmbedStart.cpp | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/source/gameengine/BlenderRoutines/BL_KetsjiEmbedStart.cpp b/source/gameengine/BlenderRoutines/BL_KetsjiEmbedStart.cpp index 298b16af43b..c652532895f 100644 --- a/source/gameengine/BlenderRoutines/BL_KetsjiEmbedStart.cpp +++ b/source/gameengine/BlenderRoutines/BL_KetsjiEmbedStart.cpp @@ -67,6 +67,7 @@ extern "C" { + #include "DNA_object_types.h" #include "DNA_view3d_types.h" #include "DNA_screen_types.h" #include "DNA_userdef_types.h" @@ -282,6 +283,10 @@ extern "C" void StartKetsjiShell(struct bContext *C, struct ARegion *ar, rcti *c bool mouse_state = startscene->gm.flag & GAME_SHOW_MOUSE; bool restrictAnimFPS = startscene->gm.flag & GAME_RESTRICT_ANIM_UPDATES; + short drawtype = v3d->drawtype; + + /* we do not support material mode in game engine, force change to texture mode */ + if (drawtype == OB_MATERIAL) drawtype = OB_TEXTURE; if (animation_record) usefixed= false; /* override since you don't want to run full-speed for sim recording */ // create the canvas and rasterizer @@ -370,7 +375,7 @@ extern "C" void StartKetsjiShell(struct bContext *C, struct ARegion *ar, rcti *c camzoom = 2.0; } - rasterizer->SetDrawingMode(v3d->drawtype); + rasterizer->SetDrawingMode(drawtype); ketsjiengine->SetCameraZoom(camzoom); // if we got an exitcode 3 (KX_EXIT_REQUEST_START_OTHER_GAME) load a different file |