[Bf-blender-cvs] [6d77187f098] custom-manipulators: Merge branch 'blender2.8' into custom-manipulators
Campbell Barton
noreply at git.blender.org
Fri Mar 31 08:16:45 CEST 2017
Commit: 6d77187f0989fc318b5209d6edc02e758c90fd27
Author: Campbell Barton
Date: Fri Mar 31 17:13:57 2017 +1100
Branches: custom-manipulators
https://developer.blender.org/rB6d77187f0989fc318b5209d6edc02e758c90fd27
Merge branch 'blender2.8' into custom-manipulators
===================================================================
===================================================================
diff --cc source/blender/editors/space_node/drawnode.c
index 228b665fa27,0b292e242f0..73cfe17ef1e
--- a/source/blender/editors/space_node/drawnode.c
+++ b/source/blender/editors/space_node/drawnode.c
@@@ -2173,11 -2173,11 +2173,11 @@@ static void node_composit_backdrop_view
if (node->custom1 == 0) {
const float backdropWidth = backdrop->x;
const float backdropHeight = backdrop->y;
- const float cx = x + snode->zoom * backdropWidth * node->custom3;
- const float cy = y + snode->zoom * backdropHeight * node->custom4;
+ const float cx = x + snode->backdrop_zoom * backdropWidth * node->custom3;
+ const float cy = y + snode->backdrop_zoom * backdropHeight * node->custom4;
- VertexFormat* format = immVertexFormat();
- unsigned pos = add_attrib(format, "pos", GL_FLOAT, 2, KEEP_FLOAT);
+ VertexFormat *format = immVertexFormat();
+ unsigned int pos = add_attrib(format, "pos", GL_FLOAT, 2, KEEP_FLOAT);
immBindBuiltinProgram(GPU_SHADER_2D_UNIFORM_COLOR);
@@@ -2209,20 -2209,20 +2209,20 @@@ static void node_composit_backdrop_boxm
float cx, cy, x1, x2, x3, x4;
float y1, y2, y3, y4;
- cx = x + snode->zoom * backdropWidth * boxmask->x;
- cy = y + snode->zoom * backdropHeight * boxmask->y;
+ cx = x + snode->backdrop_zoom * backdropWidth * boxmask->x;
+ cy = y + snode->backdrop_zoom * backdropHeight * boxmask->y;
- x1 = cx - (cosine * halveBoxWidth + sine * halveBoxHeight) * snode->zoom;
- x2 = cx - (cosine * -halveBoxWidth + sine * halveBoxHeight) * snode->zoom;
- x3 = cx - (cosine * -halveBoxWidth + sine * -halveBoxHeight) * snode->zoom;
- x4 = cx - (cosine * halveBoxWidth + sine * -halveBoxHeight) * snode->zoom;
- y1 = cy - (-sine * halveBoxWidth + cosine * halveBoxHeight) * snode->zoom;
- y2 = cy - (-sine * -halveBoxWidth + cosine * halveBoxHeight) * snode->zoom;
- y3 = cy - (-sine * -halveBoxWidth + cosine * -halveBoxHeight) * snode->zoom;
- y4 = cy - (-sine * halveBoxWidth + cosine * -halveBoxHeight) * snode->zoom;
+ x1 = cx - (cosine * halveBoxWidth + sine * halveBoxHeight) * snode->backdrop_zoom;
+ x2 = cx - (cosine * -halveBoxWidth + sine * halveBoxHeight) * snode->backdrop_zoom;
+ x3 = cx - (cosine * -halveBoxWidth + sine * -halveBoxHeight) * snode->backdrop_zoom;
+ x4 = cx - (cosine * halveBoxWidth + sine * -halveBoxHeight) * snode->backdrop_zoom;
+ y1 = cy - (-sine * halveBoxWidth + cosine * halveBoxHeight) * snode->backdrop_zoom;
+ y2 = cy - (-sine * -halveBoxWidth + cosine * halveBoxHeight) * snode->backdrop_zoom;
+ y3 = cy - (-sine * -halveBoxWidth + cosine * -halveBoxHeight) * snode->backdrop_zoom;
+ y4 = cy - (-sine * halveBoxWidth + cosine * -halveBoxHeight) * snode->backdrop_zoom;
- VertexFormat* format = immVertexFormat();
- unsigned pos = add_attrib(format, "pos", GL_FLOAT, 2, KEEP_FLOAT);
+ VertexFormat *format = immVertexFormat();
+ unsigned int pos = add_attrib(format, "pos", GL_FLOAT, 2, KEEP_FLOAT);
immBindBuiltinProgram(GPU_SHADER_2D_UNIFORM_COLOR);
@@@ -2253,20 -2253,20 +2253,20 @@@ static void node_composit_backdrop_elli
float cx, cy, x1, x2, x3, x4;
float y1, y2, y3, y4;
- cx = x + snode->zoom * backdropWidth * ellipsemask->x;
- cy = y + snode->zoom * backdropHeight * ellipsemask->y;
+ cx = x + snode->backdrop_zoom * backdropWidth * ellipsemask->x;
+ cy = y + snode->backdrop_zoom * backdropHeight * ellipsemask->y;
- x1 = cx - (cosine * halveBoxWidth + sine * halveBoxHeight) * snode->zoom;
- x2 = cx - (cosine * -halveBoxWidth + sine * halveBoxHeight) * snode->zoom;
- x3 = cx - (cosine * -halveBoxWidth + sine * -halveBoxHeight) * snode->zoom;
- x4 = cx - (cosine * halveBoxWidth + sine * -halveBoxHeight) * snode->zoom;
- y1 = cy - (-sine * halveBoxWidth + cosine * halveBoxHeight) * snode->zoom;
- y2 = cy - (-sine * -halveBoxWidth + cosine * halveBoxHeight) * snode->zoom;
- y3 = cy - (-sine * -halveBoxWidth + cosine * -halveBoxHeight) * snode->zoom;
- y4 = cy - (-sine * halveBoxWidth + cosine * -halveBoxHeight) * snode->zoom;
+ x1 = cx - (cosine * halveBoxWidth + sine * halveBoxHeight) * snode->backdrop_zoom;
+ x2 = cx - (cosine * -halveBoxWidth + sine * halveBoxHeight) * snode->backdrop_zoom;
+ x3 = cx - (cosine * -halveBoxWidth + sine * -halveBoxHeight) * snode->backdrop_zoom;
+ x4 = cx - (cosine * halveBoxWidth + sine * -halveBoxHeight) * snode->backdrop_zoom;
+ y1 = cy - (-sine * halveBoxWidth + cosine * halveBoxHeight) * snode->backdrop_zoom;
+ y2 = cy - (-sine * -halveBoxWidth + cosine * halveBoxHeight) * snode->backdrop_zoom;
+ y3 = cy - (-sine * -halveBoxWidth + cosine * -halveBoxHeight) * snode->backdrop_zoom;
+ y4 = cy - (-sine * halveBoxWidth + cosine * -halveBoxHeight) * snode->backdrop_zoom;
- VertexFormat* format = immVertexFormat();
- unsigned pos = add_attrib(format, "pos", GL_FLOAT, 2, KEEP_FLOAT);
+ VertexFormat *format = immVertexFormat();
+ unsigned int pos = add_attrib(format, "pos", GL_FLOAT, 2, KEEP_FLOAT);
immBindBuiltinProgram(GPU_SHADER_2D_UNIFORM_COLOR);
More information about the Bf-blender-cvs
mailing list