Blender Git Loki

Git Commits -> Revision 9d567dd

Revision 9d567dd by Bastien Montagne (master)
May 17, 2013, 07:10 (GMT)
This commit addresses the somewhat weak handling of stackless textures in Blender with default (BI) renderer. To do so, it's defining an "other" texture context, and when in this one, it switches to using the "new shading" texture handling already known with Cycles engine.

So now, in the new "other" tex context, you can (depending on active data) have direct access to modifiers', force's or brushes' textures...

I also refactored a bit how texture contexts are handled (once again, we had some quite similar code in both space_buttons and RNA sources). This should also solve some harmless glitches like "no texture context selected in UI" sometimes when you remove data related to current texture (see e.g. after removing the material from default cube, in startup scene).

This usage of two different systems for textures, and the handling of switches between them, has been a bit tricky to get working right, but it is OK now I think. I also had to add a bool flag to buttons space, SB_TEX_USER_LIMITED (use_limited_texture_context in RNA), which indicates "new shading" texture code whether it has to ignore materials, lamps etc. (BI) or not (Cycles).

Btw, pinned textures from modifiers/force/etc. were also broken (showing nothing), now it should work too.

Thanks to Brecht for reviewing.

Commit Details:

Full Hash: 9d567dd3662e5d79c98c64829f3d039e75697395
SVN Revision: 56870
Parent Commit: 308d014
Lines Changed: +322, -166

1 Added Path:

/source/blender/editors/include/ED_buttons.h (+39, -0) (View)

9 Modified Paths:

/intern/cycles/blender/addon/ui.py (+4, -2) (Diff)
/release/scripts/startup/bl_ui/properties_texture.py (+34, -7) (Diff)
/source/blender/editors/space_buttons/buttons_context.c (+19, -56) (Diff)
/source/blender/editors/space_buttons/buttons_header.c (+30, -19) (Diff)
/source/blender/editors/space_buttons/buttons_intern.h (+1, -0) (Diff)
/source/blender/editors/space_buttons/buttons_texture.c (+146, -32) (Diff)
/source/blender/makesdna/DNA_space_types.h (+12, -8) (Diff)
/source/blender/makesrna/intern/rna_space.c (+31, -42) (Diff)
/source/blenderplayer/bad_level_call_stubs/stubs.c (+6, -0) (Diff)
Tehnyt: Miika HämäläinenViimeksi päivitetty: 07.11.2014 14:18MiikaH:n Sivut a.k.a. MiikaHweb | 2003-2021