Fixed a drawing error in radial control and a warning in sculpt.c.
This commit is contained in:
@@ -271,7 +271,7 @@ static float brush_strength(Sculpt *sd, StrokeCache *cache)
|
||||
/* For clipping against a mirror modifier */
|
||||
static void sculpt_clip(StrokeCache *cache, float *co, const float val[3])
|
||||
{
|
||||
char i;
|
||||
int i;
|
||||
for(i=0; i<3; ++i) {
|
||||
if((cache->flag & (CLIP_X << i)) && (fabs(co[i]) <= cache->clip_tolerance[i]))
|
||||
co[i]= 0.0f;
|
||||
|
||||
@@ -34,15 +34,10 @@
|
||||
#include "DNA_vec_types.h"
|
||||
#include "BKE_sculpt.h"
|
||||
|
||||
struct BrushAction;
|
||||
struct Brush;
|
||||
struct IndexNode;
|
||||
struct KeyBlock;
|
||||
struct Mesh;
|
||||
struct Object;
|
||||
struct PartialVisibility;
|
||||
struct Scene;
|
||||
struct ScrArea;
|
||||
struct Sculpt;
|
||||
struct SculptStroke;
|
||||
|
||||
|
||||
@@ -924,7 +924,10 @@ static void wm_radial_control_paint(bContext *C, int x, int y, void *customdata)
|
||||
if(rc->tex) {
|
||||
const float str = rc->mode == WM_RADIALCONTROL_STRENGTH ? (rc->value + 0.5) : 1;
|
||||
|
||||
glRotatef(angle, 0, 0, 1);
|
||||
if(rc->mode == WM_RADIALCONTROL_ANGLE) {
|
||||
glRotatef(angle, 0, 0, 1);
|
||||
fdrawline(0, 0, WM_RADIAL_CONTROL_DISPLAY_SIZE, 0);
|
||||
}
|
||||
|
||||
glBindTexture(GL_TEXTURE_2D, rc->tex);
|
||||
|
||||
@@ -947,8 +950,6 @@ static void wm_radial_control_paint(bContext *C, int x, int y, void *customdata)
|
||||
}
|
||||
|
||||
glColor4ub(255, 255, 255, 128);
|
||||
if(rc->mode == WM_RADIALCONTROL_ANGLE)
|
||||
fdrawline(0, 0, WM_RADIAL_CONTROL_DISPLAY_SIZE, 0);
|
||||
glutil_draw_lined_arc(0.0, M_PI*2.0, r1, 40);
|
||||
glutil_draw_lined_arc(0.0, M_PI*2.0, r2, 40);
|
||||
glDisable(GL_BLEND);
|
||||
|
||||
Reference in New Issue
Block a user