diff options
author | Brecht Van Lommel <brechtvanlommel@pandora.be> | 2009-07-24 01:50:40 +0400 |
---|---|---|
committer | Brecht Van Lommel <brechtvanlommel@pandora.be> | 2009-07-24 01:50:40 +0400 |
commit | 366a64959c5950c2fd29f3b1fe74adbd9f420988 (patch) | |
tree | a3ca649622cea57340b639e69b6195072ec936c5 /source/blender/editors/space_buttons/buttons_context.c | |
parent | 1ee8038e41f2daf3aaac40e58d7cdc416d2af35d (diff) |
2.5: Render/Game Engine
An engine to use for output can now be selected an influences what
shows in the buttons window, only showing relevant data. The idea
behind this is to make it more clear what is supported where, make
the system more pluggable for external render/game engines, and save
space hiding stuff that is not relevant anyway.
* Top header now has an engine menu, to choose between the blender
render engine, game engine, and other future external engines.
* If the game engine is enabled, the buttons window should show
only properties that work in the game engine, and similarly for
the render engine.
* Moved panels from the logic space and game tabs to the physics,
scene and world tabs instead, and removed the game tab.
* Materials and textures tabs should eventually become game
specific too, to better show what is supported.
Diffstat (limited to 'source/blender/editors/space_buttons/buttons_context.c')
-rw-r--r-- | source/blender/editors/space_buttons/buttons_context.c | 30 |
1 files changed, 1 insertions, 29 deletions
diff --git a/source/blender/editors/space_buttons/buttons_context.c b/source/blender/editors/space_buttons/buttons_context.c index 9048565b01f..1ebab105086 100644 --- a/source/blender/editors/space_buttons/buttons_context.c +++ b/source/blender/editors/space_buttons/buttons_context.c @@ -360,32 +360,7 @@ static int buttons_context_path_texture(ButsContextPath *path) return 0; } -static int buttons_context_path_game(ButsContextPath *path) -{ - /* XXX temporary context. Using material slot instead of ob->game_data */ - Object *ob; - PointerRNA *ptr= &path->ptr[path->len-1]; - Material *ma; - - /* if we already have a (pinned) material, we're done */ - if(RNA_struct_is_a(ptr->type, &RNA_Material)) { - return 1; - } - /* if we have an object, use the object material slot */ - else if(buttons_context_path_object(path)) { - ob= path->ptr[path->len-1].data; - if(ob && ob->type && (ob->type<OB_LAMP)) { - ma= give_current_material(ob, ob->actcol); - RNA_id_pointer_create(&ma->id, &path->ptr[path->len]); - path->len++; - return 1; - } - } - - /* no path to a material possible */ - return 0; -} static int buttons_context_path(const bContext *C, ButsContextPath *path, int mainb, int worldtex) { SpaceButs *sbuts= (SpaceButs*)CTX_wm_space_data(C); @@ -430,9 +405,6 @@ static int buttons_context_path(const bContext *C, ButsContextPath *path, int ma case BCONTEXT_DATA: found= buttons_context_path_data(path, -1); break; - case BCONTEXT_GAME: - found= buttons_context_path_game(path); - break; case BCONTEXT_PARTICLE: found= buttons_context_path_particle(path); break; @@ -526,7 +498,7 @@ int buttons_context(const bContext *C, const char *member, bContextDataResult *r if(CTX_data_dir(member)) { static const char *dir[] = { "world", "object", "mesh", "armature", "lattice", "curve", - "meta_ball", "lamp", "camera", "material", "material_slot", "game", + "meta_ball", "lamp", "camera", "material", "material_slot", "texture", "texture_slot", "bone", "edit_bone", "particle_system", "cloth", "soft_body", "fluid", "collision", NULL}; |