[Bf-blender-cvs] [107b585] blender2.8: OpenGL/gpencil: delete unused utility functions
Mike Erwin
noreply at git.blender.org
Fri Oct 7 09:18:01 CEST 2016
Commit: 107b585a417ddeb94e4ae7faae677f5cc4f3cd13
Author: Mike Erwin
Date: Fri Oct 7 03:17:23 2016 -0400
Branches: blender2.8
https://developer.blender.org/rB107b585a417ddeb94e4ae7faae677f5cc4f3cd13
OpenGL/gpencil: delete unused utility functions
Part of T49043 -- done with this file!
===================================================================
M source/blender/editors/gpencil/drawgpencil.c
===================================================================
diff --git a/source/blender/editors/gpencil/drawgpencil.c b/source/blender/editors/gpencil/drawgpencil.c
index 0f286bc..8e62066 100644
--- a/source/blender/editors/gpencil/drawgpencil.c
+++ b/source/blender/editors/gpencil/drawgpencil.c
@@ -60,7 +60,6 @@
#include "WM_api.h"
-#include "BIF_gl.h"
#include "BIF_glutil.h"
#include "GPU_immediate.h"
@@ -102,12 +101,6 @@ typedef enum eDrawStrokeFlags {
/* ----- Tool Buffer Drawing ------ */
/* helper functions to set color of buffer point */
-static void gp_set_tpoint_color(const tGPspoint *pt, const float ink[4])
-{
- float alpha = ink[3] * pt->strength;
- CLAMP(alpha, GPENCIL_STRENGTH_MIN, 1.0f);
- glColor4f(ink[0], ink[1], ink[2], alpha);
-}
static void gp_set_tpoint_varying_color(const tGPspoint *pt, const float ink[4], unsigned attrib_id)
{
@@ -116,14 +109,6 @@ static void gp_set_tpoint_varying_color(const tGPspoint *pt, const float ink[4],
immAttrib4ub(attrib_id, F2UB(ink[0]), F2UB(ink[1]), F2UB(ink[2]), F2UB(alpha));
}
-/* helper functions to set color of point */
-static void gp_set_point_color(const bGPDspoint *pt, const float ink[4])
-{
- float alpha = ink[3] * pt->strength;
- CLAMP(alpha, GPENCIL_STRENGTH_MIN, 1.0f);
- glColor4f(ink[0], ink[1], ink[2], alpha);
-}
-
static void gp_set_point_uniform_color(const bGPDspoint *pt, const float ink[4])
{
float alpha = ink[3] * pt->strength;
@@ -138,13 +123,6 @@ static void gp_set_point_varying_color(const bGPDspoint *pt, const float ink[4],
immAttrib4ub(attrib_id, F2UB(ink[0]), F2UB(ink[1]), F2UB(ink[2]), F2UB(alpha));
}
-/* helper function to set color and point */
-static void gp_set_color_and_tpoint(const tGPspoint *pt, const float ink[4])
-{
- gp_set_tpoint_color(pt, ink);
- glVertex2iv(&pt->x);
-}
-
/* draw stroke defined in buffer (simple ogl lines/points for now, as dotted lines) */
static void gp_draw_stroke_buffer(const tGPspoint *points, int totpoints, short thickness,
short dflag, short sflag, float ink[4])
More information about the Bf-blender-cvs
mailing list