Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'source/blender/gpu/intern/gpu_material.c')
-rw-r--r--source/blender/gpu/intern/gpu_material.c8
1 files changed, 5 insertions, 3 deletions
diff --git a/source/blender/gpu/intern/gpu_material.c b/source/blender/gpu/intern/gpu_material.c
index e936f35574d..50e65b5ddbb 100644
--- a/source/blender/gpu/intern/gpu_material.c
+++ b/source/blender/gpu/intern/gpu_material.c
@@ -1049,7 +1049,7 @@ static void do_material_tex(GPUShadeInput *shi)
GPU_link(mat, "mtex_negate_texnormal", tnor, &tnor);
if(mtex->normapspace == MTEX_NSPACE_TANGENT)
- {
+ {
if(iFirstTimeNMap!=0)
{
// use unnormalized normal (this is how we bake it - closer to gamedev)
@@ -1065,7 +1065,7 @@ static void do_material_tex(GPUShadeInput *shi)
}
else
newnor = tnor;
-
+
norfac = MIN2(fabsf(mtex->norfac), 1.0f);
if(norfac == 1.0f && !GPU_link_changed(stencil)) {
@@ -1104,7 +1104,7 @@ static void do_material_tex(GPUShadeInput *shi)
iBumpSpacePrev = 0;
init_done = 1;
}
-
+
// find current bump space
if( mtex->texflag & MTEX_BUMP_OBJECTSPACE )
iBumpSpace = 1;
@@ -1427,11 +1427,13 @@ void GPU_materials_free(void)
Object *ob;
Material *ma;
extern Material defmaterial;
+ extern Material matcap_ma;
for(ma=G.main->mat.first; ma; ma=ma->id.next)
GPU_material_free(ma);
GPU_material_free(&defmaterial);
+ GPU_material_free(&matcap_ma);
for(ob=G.main->object.first; ob; ob=ob->id.next)
GPU_lamp_free(ob);