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')
-rw-r--r--source/blender/gpu/intern/gpu_buffers.c10
-rw-r--r--source/blender/gpu/intern/gpu_codegen.c6
-rw-r--r--source/blender/gpu/intern/gpu_draw.c14
-rw-r--r--source/blender/gpu/intern/gpu_extensions.c10
-rw-r--r--source/blender/gpu/intern/gpu_material.c2
5 files changed, 21 insertions, 21 deletions
diff --git a/source/blender/gpu/intern/gpu_buffers.c b/source/blender/gpu/intern/gpu_buffers.c
index f2be686d2d4..3c9648c33a5 100644
--- a/source/blender/gpu/intern/gpu_buffers.c
+++ b/source/blender/gpu/intern/gpu_buffers.c
@@ -1535,7 +1535,7 @@ GPUBuffer *GPU_buffer_setup( DerivedMesh *dm, GPUDrawObject *object, int size, G
return buffer;
}
-void GPU_buffer_copy_vertex( DerivedMesh *dm, float *varray, int *index, int *redir, void *user )
+void GPU_buffer_copy_vertex(DerivedMesh *dm, float *varray, int *index, int *redir, void *UNUSED(user))
{
int start;
int i, j, numfaces;
@@ -1584,7 +1584,7 @@ GPUBuffer *GPU_buffer_vertex( DerivedMesh *dm )
return GPU_buffer_setup( dm, dm->drawObject, sizeof(float)*3*(dm->drawObject->nelements+dm->drawObject->nlooseverts), GL_ARRAY_BUFFER_ARB, 0, GPU_buffer_copy_vertex);
}
-void GPU_buffer_copy_normal( DerivedMesh *dm, float *varray, int *index, int *redir, void *user )
+void GPU_buffer_copy_normal(DerivedMesh *dm, float *varray, int *index, int *redir, void *UNUSED(user))
{
int i, numfaces;
int start;
@@ -1648,7 +1648,7 @@ GPUBuffer *GPU_buffer_normal( DerivedMesh *dm )
return GPU_buffer_setup( dm, dm->drawObject, sizeof(float)*3*dm->drawObject->nelements, GL_ARRAY_BUFFER_ARB, 0, GPU_buffer_copy_normal);
}
-void GPU_buffer_copy_uv( DerivedMesh *dm, float *varray, int *index, int *redir, void *user )
+void GPU_buffer_copy_uv(DerivedMesh *dm, float *varray, int *index, int *redir, void *UNUSED(user))
{
int start;
int i, numfaces;
@@ -1790,7 +1790,7 @@ GPUBuffer *GPU_buffer_color( DerivedMesh *dm )
return result;
}
-void GPU_buffer_copy_edge( DerivedMesh *dm, float *varray, int *index, int *redir, void *user )
+void GPU_buffer_copy_edge(DerivedMesh *dm, float *varray, int *UNUSED(index), int *UNUSED(redir), void *UNUSED(user))
{
int i;
@@ -1818,7 +1818,7 @@ GPUBuffer *GPU_buffer_edge( DerivedMesh *dm )
return GPU_buffer_setup( dm, dm->drawObject, sizeof(int)*2*dm->drawObject->nedges, GL_ELEMENT_ARRAY_BUFFER_ARB, 0, GPU_buffer_copy_edge);
}
-void GPU_buffer_copy_uvedge( DerivedMesh *dm, float *varray, int *index, int *redir, void *user )
+void GPU_buffer_copy_uvedge(DerivedMesh *dm, float *varray, int *UNUSED(index), int *UNUSED(redir), void *UNUSED(user))
{
MTFace *tf = DM_get_face_data_layer(dm, CD_MTFACE);
int i, j=0;
diff --git a/source/blender/gpu/intern/gpu_codegen.c b/source/blender/gpu/intern/gpu_codegen.c
index d596f573682..34cf62462a7 100644
--- a/source/blender/gpu/intern/gpu_codegen.c
+++ b/source/blender/gpu/intern/gpu_codegen.c
@@ -686,7 +686,7 @@ static void codegen_call_functions(DynStr *ds, ListBase *nodes, GPUOutput *final
BLI_dynstr_append(ds, ";\n");
}
-static char *code_generate_fragment(ListBase *nodes, GPUOutput *output, const char *name)
+static char *code_generate_fragment(ListBase *nodes, GPUOutput *output, const char *UNUSED(name))
{
DynStr *ds = BLI_dynstr_new();
char *code;
@@ -916,7 +916,7 @@ GPUNode *GPU_node_begin(char *name)
return node;
}
-void GPU_node_end(GPUNode *node)
+void GPU_node_end(GPUNode *UNUSED(node))
{
/* empty */
}
@@ -1036,7 +1036,7 @@ static void gpu_node_input_socket(GPUNode *node, GPUNodeStack *sock)
}
}
-void GPU_node_output(GPUNode *node, int type, char *name, GPUNodeLink **link)
+void GPU_node_output(GPUNode *node, int type, char *UNUSED(name), GPUNodeLink **link)
{
GPUOutput *output = MEM_callocN(sizeof(GPUOutput), "GPUOutput");
diff --git a/source/blender/gpu/intern/gpu_draw.c b/source/blender/gpu/intern/gpu_draw.c
index e8701793e5d..a93d8cbbb8e 100644
--- a/source/blender/gpu/intern/gpu_draw.c
+++ b/source/blender/gpu/intern/gpu_draw.c
@@ -394,7 +394,7 @@ static void gpu_verify_reflection(Image *ima)
}
}
-int GPU_verify_image(Image *ima, ImageUser *iuser, int tftile, int tfmode, int compare, int mipmap)
+int GPU_verify_image(Image *ima, ImageUser *iuser, int tftile, int compare, int mipmap)
{
ImBuf *ibuf = NULL;
unsigned int *bind = NULL;
@@ -593,7 +593,7 @@ int GPU_set_tpage(MTFace *tface, int mipmap)
gpu_verify_alpha_mode(tface);
gpu_verify_reflection(ima);
- if(GPU_verify_image(ima, NULL, tface->tile, tface->mode, 1, mipmap)) {
+ if(GPU_verify_image(ima, NULL, tface->tile, 1, mipmap)) {
GTS.curtile= GTS.tile;
GTS.curima= GTS.ima;
GTS.curtilemode= GTS.tilemode;
@@ -911,10 +911,10 @@ static void gpu_material_to_fixed(GPUMaterialFixed *smat, const Material *bmat,
}
}
else {
- madd_v3_v3fl(smat->diff, &bmat->r, bmat->ref + bmat->emit);
+ mul_v3_v3fl(smat->diff, &bmat->r, bmat->ref + bmat->emit);
smat->diff[3]= 1.0; /* caller may set this to bmat->alpha */
- madd_v3_v3fl(smat->spec, &bmat->specr, bmat->spec);
+ mul_v3_v3fl(smat->spec, &bmat->specr, bmat->spec);
smat->spec[3]= 1.0; /* always 1 */
smat->hard= CLAMPIS(bmat->har, 0, 128);
@@ -1043,10 +1043,10 @@ int GPU_enable_material(int nr, void *attribs)
memset(&GMS, 0, sizeof(GMS));
- madd_v3_v3fl(diff, &defmaterial.r, defmaterial.ref + defmaterial.emit);
+ mul_v3_v3fl(diff, &defmaterial.r, defmaterial.ref + defmaterial.emit);
diff[3]= 1.0;
- madd_v3_v3fl(spec, &defmaterial.specr, defmaterial.spec);
+ mul_v3_v3fl(spec, &defmaterial.specr, defmaterial.spec);
spec[3]= 1.0;
glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, diff);
@@ -1286,7 +1286,7 @@ int GPU_scene_object_lights(Scene *scene, Object *ob, int lay, float viewmat[][4
}
/* setup energy */
- madd_v3_v3fl(energy, &la->r, la->energy);
+ mul_v3_v3fl(energy, &la->r, la->energy);
energy[3]= 1.0;
glLightfv(GL_LIGHT0+count, GL_DIFFUSE, energy);
diff --git a/source/blender/gpu/intern/gpu_extensions.c b/source/blender/gpu/intern/gpu_extensions.c
index fa8ff7a6354..c6b8a43918c 100644
--- a/source/blender/gpu/intern/gpu_extensions.c
+++ b/source/blender/gpu/intern/gpu_extensions.c
@@ -484,7 +484,7 @@ GPUTexture *GPU_texture_from_blender(Image *ima, ImageUser *iuser, double time,
glGetIntegerv(GL_TEXTURE_BINDING_2D, &lastbindcode);
GPU_update_image_time(ima, time);
- bindcode = GPU_verify_image(ima, iuser, 0, 0, 0, mipmap);
+ bindcode = GPU_verify_image(ima, iuser, 0, 0, mipmap);
if(ima->gputexture) {
ima->gputexture->bindcode = bindcode;
@@ -744,7 +744,7 @@ void GPU_framebuffer_texture_detach(GPUFrameBuffer *fb, GPUTexture *tex)
tex->fb = NULL;
}
-void GPU_framebuffer_texture_bind(GPUFrameBuffer *fb, GPUTexture *tex)
+void GPU_framebuffer_texture_bind(GPUFrameBuffer *UNUSED(fb), GPUTexture *tex)
{
/* push attributes */
glPushAttrib(GL_ENABLE_BIT);
@@ -766,7 +766,7 @@ void GPU_framebuffer_texture_bind(GPUFrameBuffer *fb, GPUTexture *tex)
glLoadIdentity();
}
-void GPU_framebuffer_texture_unbind(GPUFrameBuffer *fb, GPUTexture *tex)
+void GPU_framebuffer_texture_unbind(GPUFrameBuffer *UNUSED(fb), GPUTexture *UNUSED(tex))
{
/* restore matrix */
glMatrixMode(GL_PROJECTION);
@@ -1063,7 +1063,7 @@ int GPU_shader_get_uniform(GPUShader *shader, char *name)
return glGetUniformLocationARB(shader->object, name);
}
-void GPU_shader_uniform_vector(GPUShader *shader, int location, int length, int arraysize, float *value)
+void GPU_shader_uniform_vector(GPUShader *UNUSED(shader), int location, int length, int arraysize, float *value)
{
if(location == -1)
return;
@@ -1080,7 +1080,7 @@ void GPU_shader_uniform_vector(GPUShader *shader, int location, int length, int
GPU_print_error("Post Uniform Vector");
}
-void GPU_shader_uniform_texture(GPUShader *shader, int location, GPUTexture *tex)
+void GPU_shader_uniform_texture(GPUShader *UNUSED(shader), int location, GPUTexture *tex)
{
GLenum arbnumber;
diff --git a/source/blender/gpu/intern/gpu_material.c b/source/blender/gpu/intern/gpu_material.c
index 5f8015be52f..a31ec950711 100644
--- a/source/blender/gpu/intern/gpu_material.c
+++ b/source/blender/gpu/intern/gpu_material.c
@@ -605,7 +605,7 @@ static void shade_one_light(GPUShadeInput *shi, GPUShadeResult *shr, GPULamp *la
Material *ma= shi->mat;
GPUMaterial *mat= shi->gpumat;
GPUNodeLink *lv, *dist, *visifac, *is, *inp, *i, *vn, *view;
- GPUNodeLink *outcol, *specfac, *t, *shadfac;
+ GPUNodeLink *outcol, *specfac, *t, *shadfac= NULL;
float one = 1.0f;
if((lamp->mode & LA_ONLYSHADOW) && !(ma->mode & MA_SHADOW))