tag & comment unused vars with /* UNUSED */
This commit is contained in:
@@ -83,8 +83,13 @@ set(SRC
|
|||||||
intern/tnt/tnt_version.h
|
intern/tnt/tnt_version.h
|
||||||
)
|
)
|
||||||
|
|
||||||
|
# quiet -Wundef
|
||||||
|
add_definitions(-DDDF_DEBUG=0)
|
||||||
|
|
||||||
if(WITH_OPENMP)
|
if(WITH_OPENMP)
|
||||||
add_definitions(-DPARALLEL=1)
|
add_definitions(-DPARALLEL=1)
|
||||||
|
else()
|
||||||
|
add_definitions(-DPARALLEL=0)
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
if(WITH_FFTW3)
|
if(WITH_FFTW3)
|
||||||
|
@@ -989,13 +989,13 @@ static void emDM_drawMappedFacesGLSL(DerivedMesh *dm,
|
|||||||
DMVertexAttribs attribs= {{{0}}};
|
DMVertexAttribs attribs= {{{0}}};
|
||||||
GPUVertexAttribs gattribs;
|
GPUVertexAttribs gattribs;
|
||||||
/* int tfoffset; */ /* UNUSED */
|
/* int tfoffset; */ /* UNUSED */
|
||||||
int i, b, matnr, new_matnr, dodraw, layer;
|
int i, b, matnr, new_matnr, dodraw /* , layer */ /* UNUSED */;
|
||||||
|
|
||||||
dodraw = 0;
|
dodraw = 0;
|
||||||
matnr = -1;
|
matnr = -1;
|
||||||
|
|
||||||
layer = CustomData_get_layer_index(&em->fdata, CD_MTFACE);
|
/* layer = CustomData_get_layer_index(&em->fdata, CD_MTFACE); */ /* UNUSED */
|
||||||
/* tfoffset = (layer == -1)? -1: em->fdata.layers[layer].offset; */
|
/* tfoffset = (layer == -1)? -1: em->fdata.layers[layer].offset; */ /* UNUSED */
|
||||||
|
|
||||||
/* always use smooth shading even for flat faces, else vertex colors wont interpolate */
|
/* always use smooth shading even for flat faces, else vertex colors wont interpolate */
|
||||||
glShadeModel(GL_SMOOTH);
|
glShadeModel(GL_SMOOTH);
|
||||||
|
@@ -1557,7 +1557,7 @@ static NlaEvalChannel *nlaevalchan_verify (PointerRNA *ptr, ListBase *channels,
|
|||||||
PropertyRNA *prop;
|
PropertyRNA *prop;
|
||||||
PointerRNA new_ptr;
|
PointerRNA new_ptr;
|
||||||
char *path = NULL;
|
char *path = NULL;
|
||||||
short free_path=0;
|
/* short free_path=0; */
|
||||||
|
|
||||||
/* sanity checks */
|
/* sanity checks */
|
||||||
if (channels == NULL)
|
if (channels == NULL)
|
||||||
@@ -1565,7 +1565,7 @@ static NlaEvalChannel *nlaevalchan_verify (PointerRNA *ptr, ListBase *channels,
|
|||||||
|
|
||||||
/* get RNA pointer+property info from F-Curve for more convenient handling */
|
/* get RNA pointer+property info from F-Curve for more convenient handling */
|
||||||
/* get path, remapped as appropriate to work in its new environment */
|
/* get path, remapped as appropriate to work in its new environment */
|
||||||
free_path= animsys_remap_path(strip->remap, fcu->rna_path, &path);
|
/* free_path= */ /* UNUSED */ animsys_remap_path(strip->remap, fcu->rna_path, &path);
|
||||||
|
|
||||||
/* a valid property must be available, and it must be animateable */
|
/* a valid property must be available, and it must be animateable */
|
||||||
if (RNA_path_resolve(ptr, path, &new_ptr, &prop) == 0) {
|
if (RNA_path_resolve(ptr, path, &new_ptr, &prop) == 0) {
|
||||||
|
@@ -500,7 +500,7 @@ static int read_undosave(bContext *C, UndoElem *uel)
|
|||||||
void BKE_write_undo(bContext *C, const char *name)
|
void BKE_write_undo(bContext *C, const char *name)
|
||||||
{
|
{
|
||||||
uintptr_t maxmem, totmem, memused;
|
uintptr_t maxmem, totmem, memused;
|
||||||
int nr, success;
|
int nr /*, success */ /* UNUSED */;
|
||||||
UndoElem *uel;
|
UndoElem *uel;
|
||||||
|
|
||||||
if( (U.uiflag & USER_GLOBALUNDO)==0) return;
|
if( (U.uiflag & USER_GLOBALUNDO)==0) return;
|
||||||
@@ -552,7 +552,7 @@ void BKE_write_undo(bContext *C, const char *name)
|
|||||||
BLI_snprintf(numstr, sizeof(numstr), "%d.blend", counter);
|
BLI_snprintf(numstr, sizeof(numstr), "%d.blend", counter);
|
||||||
BLI_make_file_string("/", filepath, btempdir, numstr);
|
BLI_make_file_string("/", filepath, btempdir, numstr);
|
||||||
|
|
||||||
success= BLO_write_file(CTX_data_main(C), filepath, fileflags, NULL, NULL);
|
/* success= */ /* UNUSED */ BLO_write_file(CTX_data_main(C), filepath, fileflags, NULL, NULL);
|
||||||
|
|
||||||
BLI_strncpy(curundo->str, filepath, sizeof(curundo->str));
|
BLI_strncpy(curundo->str, filepath, sizeof(curundo->str));
|
||||||
}
|
}
|
||||||
@@ -562,7 +562,7 @@ void BKE_write_undo(bContext *C, const char *name)
|
|||||||
if(curundo->prev) prevfile= &(curundo->prev->memfile);
|
if(curundo->prev) prevfile= &(curundo->prev->memfile);
|
||||||
|
|
||||||
memused= MEM_get_memory_in_use();
|
memused= MEM_get_memory_in_use();
|
||||||
success= BLO_write_file_mem(CTX_data_main(C), prevfile, &curundo->memfile, G.fileflags);
|
/* success= */ /* UNUSED */ BLO_write_file_mem(CTX_data_main(C), prevfile, &curundo->memfile, G.fileflags);
|
||||||
curundo->undosize= MEM_get_memory_in_use() - memused;
|
curundo->undosize= MEM_get_memory_in_use() - memused;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@@ -1139,7 +1139,7 @@ static void cdDM_drawMappedFacesGLSL(DerivedMesh *dm, int (*setMaterial)(int, vo
|
|||||||
GPUBuffer *buffer = NULL;
|
GPUBuffer *buffer = NULL;
|
||||||
char *varray = NULL;
|
char *varray = NULL;
|
||||||
int numdata = 0, elementsize = 0, offset;
|
int numdata = 0, elementsize = 0, offset;
|
||||||
int start = 0, numfaces = 0, prevdraw = 0, curface = 0;
|
int start = 0, numfaces = 0 /* , prevdraw = 0 */ /* UNUSED */, curface = 0;
|
||||||
int i;
|
int i;
|
||||||
|
|
||||||
MFace *mf = mface;
|
MFace *mf = mface;
|
||||||
@@ -1183,7 +1183,7 @@ static void cdDM_drawMappedFacesGLSL(DerivedMesh *dm, int (*setMaterial)(int, vo
|
|||||||
}
|
}
|
||||||
numdata = 0;
|
numdata = 0;
|
||||||
start = curface;
|
start = curface;
|
||||||
prevdraw = dodraw;
|
/* prevdraw = dodraw; */ /* UNUSED */
|
||||||
dodraw = setMaterial(matnr = new_matnr, &gattribs);
|
dodraw = setMaterial(matnr = new_matnr, &gattribs);
|
||||||
if(dodraw) {
|
if(dodraw) {
|
||||||
DM_vertex_attributes_from_gpu(dm, &gattribs, &attribs);
|
DM_vertex_attributes_from_gpu(dm, &gattribs, &attribs);
|
||||||
@@ -1231,7 +1231,7 @@ static void cdDM_drawMappedFacesGLSL(DerivedMesh *dm, int (*setMaterial)(int, vo
|
|||||||
else {
|
else {
|
||||||
/* if the buffer was set, dont use it again.
|
/* if the buffer was set, dont use it again.
|
||||||
* prevdraw was assumed true but didnt run so set to false - [#21036] */
|
* prevdraw was assumed true but didnt run so set to false - [#21036] */
|
||||||
prevdraw= 0;
|
/* prevdraw= 0; */ /* UNUSED */
|
||||||
buffer= NULL;
|
buffer= NULL;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@@ -295,12 +295,12 @@ int nodeFindNode(bNodeTree *ntree, bNodeSocket *sock, bNode **nodep, int *sockin
|
|||||||
static void node_add_sockets_from_type(bNodeTree *ntree, bNode *node, bNodeType *ntype)
|
static void node_add_sockets_from_type(bNodeTree *ntree, bNode *node, bNodeType *ntype)
|
||||||
{
|
{
|
||||||
bNodeSocketTemplate *sockdef;
|
bNodeSocketTemplate *sockdef;
|
||||||
bNodeSocket *sock;
|
/* bNodeSocket *sock; */ /* UNUSED */
|
||||||
|
|
||||||
if(ntype->inputs) {
|
if(ntype->inputs) {
|
||||||
sockdef= ntype->inputs;
|
sockdef= ntype->inputs;
|
||||||
while(sockdef->type != -1) {
|
while(sockdef->type != -1) {
|
||||||
sock = node_add_input_from_template(ntree, node, sockdef);
|
/* sock = */ node_add_input_from_template(ntree, node, sockdef);
|
||||||
|
|
||||||
sockdef++;
|
sockdef++;
|
||||||
}
|
}
|
||||||
@@ -308,7 +308,7 @@ static void node_add_sockets_from_type(bNodeTree *ntree, bNode *node, bNodeType
|
|||||||
if(ntype->outputs) {
|
if(ntype->outputs) {
|
||||||
sockdef= ntype->outputs;
|
sockdef= ntype->outputs;
|
||||||
while(sockdef->type != -1) {
|
while(sockdef->type != -1) {
|
||||||
sock = node_add_output_from_template(ntree, node, sockdef);
|
/* sock = */ node_add_output_from_template(ntree, node, sockdef);
|
||||||
|
|
||||||
sockdef++;
|
sockdef++;
|
||||||
}
|
}
|
||||||
@@ -620,7 +620,7 @@ bNodeTree *ntreeAddTree(const char *name, int type, int nodetype)
|
|||||||
bNodeTree *ntreeCopyTree(bNodeTree *ntree)
|
bNodeTree *ntreeCopyTree(bNodeTree *ntree)
|
||||||
{
|
{
|
||||||
bNodeTree *newtree;
|
bNodeTree *newtree;
|
||||||
bNode *node, *nnode, *last;
|
bNode *node /*, *nnode */ /* UNUSED */, *last;
|
||||||
bNodeLink *link;
|
bNodeLink *link;
|
||||||
bNodeSocket *gsock, *oldgsock;
|
bNodeSocket *gsock, *oldgsock;
|
||||||
|
|
||||||
@@ -647,7 +647,7 @@ bNodeTree *ntreeCopyTree(bNodeTree *ntree)
|
|||||||
last = ntree->nodes.last;
|
last = ntree->nodes.last;
|
||||||
for(node= ntree->nodes.first; node; node= node->next) {
|
for(node= ntree->nodes.first; node; node= node->next) {
|
||||||
node->new_node= NULL;
|
node->new_node= NULL;
|
||||||
nnode= nodeCopyNode(newtree, node); /* sets node->new */
|
/* nnode= */ nodeCopyNode(newtree, node); /* sets node->new */
|
||||||
|
|
||||||
/* make sure we don't copy new nodes again! */
|
/* make sure we don't copy new nodes again! */
|
||||||
if (node==last)
|
if (node==last)
|
||||||
|
@@ -420,8 +420,8 @@ void UI_view2d_curRect_validate_resize(View2D *v2d, int resize)
|
|||||||
|
|
||||||
/* check if we should restore aspect ratio (if view size changed) */
|
/* check if we should restore aspect ratio (if view size changed) */
|
||||||
if (v2d->keepzoom & V2D_KEEPASPECT) {
|
if (v2d->keepzoom & V2D_KEEPASPECT) {
|
||||||
short do_x=0, do_y=0, do_cur, do_win;
|
short do_x=0, do_y=0, do_cur /* , do_win */ /* UNUSED */;
|
||||||
float curRatio, winRatio;
|
float /* curRatio, */ /* UNUSED */ winRatio;
|
||||||
|
|
||||||
/* when a window edge changes, the aspect ratio can't be used to
|
/* when a window edge changes, the aspect ratio can't be used to
|
||||||
* find which is the best new 'cur' rect. thats why it stores 'old'
|
* find which is the best new 'cur' rect. thats why it stores 'old'
|
||||||
@@ -429,7 +429,7 @@ void UI_view2d_curRect_validate_resize(View2D *v2d, int resize)
|
|||||||
if (winx != v2d->oldwinx) do_x= 1;
|
if (winx != v2d->oldwinx) do_x= 1;
|
||||||
if (winy != v2d->oldwiny) do_y= 1;
|
if (winy != v2d->oldwiny) do_y= 1;
|
||||||
|
|
||||||
curRatio= height / width;
|
/* curRatio= height / width; */ /* UNUSED */
|
||||||
winRatio= winy / winx;
|
winRatio= winy / winx;
|
||||||
|
|
||||||
/* both sizes change (area/region maximised) */
|
/* both sizes change (area/region maximised) */
|
||||||
@@ -443,7 +443,7 @@ void UI_view2d_curRect_validate_resize(View2D *v2d, int resize)
|
|||||||
else do_x= 1;
|
else do_x= 1;
|
||||||
}
|
}
|
||||||
do_cur= do_x;
|
do_cur= do_x;
|
||||||
do_win= do_y;
|
/* do_win= do_y; */ /* UNUSED */
|
||||||
|
|
||||||
if (do_cur) {
|
if (do_cur) {
|
||||||
if ((v2d->keeptot == V2D_KEEPTOT_STRICT) && (winx != v2d->oldwinx)) {
|
if ((v2d->keeptot == V2D_KEEPTOT_STRICT) && (winx != v2d->oldwinx)) {
|
||||||
|
@@ -238,7 +238,6 @@ int ED_mesh_uv_texture_remove(bContext *C, Object *ob, Mesh *me)
|
|||||||
int ED_mesh_color_add(bContext *C, Scene *UNUSED(scene), Object *UNUSED(ob), Mesh *me, const char *name, int active_set)
|
int ED_mesh_color_add(bContext *C, Scene *UNUSED(scene), Object *UNUSED(ob), Mesh *me, const char *name, int active_set)
|
||||||
{
|
{
|
||||||
EditMesh *em;
|
EditMesh *em;
|
||||||
MCol *mcol;
|
|
||||||
int layernum;
|
int layernum;
|
||||||
|
|
||||||
if(me->edit_mesh) {
|
if(me->edit_mesh) {
|
||||||
@@ -261,8 +260,6 @@ int ED_mesh_color_add(bContext *C, Scene *UNUSED(scene), Object *UNUSED(ob), Mes
|
|||||||
if(layernum >= MAX_MCOL)
|
if(layernum >= MAX_MCOL)
|
||||||
return 0;
|
return 0;
|
||||||
|
|
||||||
mcol= me->mcol;
|
|
||||||
|
|
||||||
if(me->mcol)
|
if(me->mcol)
|
||||||
CustomData_add_layer_named(&me->fdata, CD_MCOL, CD_DUPLICATE, me->mcol, me->totface, name);
|
CustomData_add_layer_named(&me->fdata, CD_MCOL, CD_DUPLICATE, me->mcol, me->totface, name);
|
||||||
else
|
else
|
||||||
|
@@ -1139,7 +1139,7 @@ static void mouse_action_keys (bAnimContext *ac, const int mval[2], short select
|
|||||||
static int actkeys_clickselect_invoke(bContext *C, wmOperator *op, wmEvent *event)
|
static int actkeys_clickselect_invoke(bContext *C, wmOperator *op, wmEvent *event)
|
||||||
{
|
{
|
||||||
bAnimContext ac;
|
bAnimContext ac;
|
||||||
ARegion *ar;
|
/* ARegion *ar; */ /* UNUSED */
|
||||||
short selectmode, column;
|
short selectmode, column;
|
||||||
|
|
||||||
/* get editor data */
|
/* get editor data */
|
||||||
@@ -1147,7 +1147,7 @@ static int actkeys_clickselect_invoke(bContext *C, wmOperator *op, wmEvent *even
|
|||||||
return OPERATOR_CANCELLED;
|
return OPERATOR_CANCELLED;
|
||||||
|
|
||||||
/* get useful pointers from animation context data */
|
/* get useful pointers from animation context data */
|
||||||
ar= ac.ar;
|
/* ar= ac.ar; */ /* UNUSED */
|
||||||
|
|
||||||
/* select mode is either replace (deselect all, then add) or add/extend */
|
/* select mode is either replace (deselect all, then add) or add/extend */
|
||||||
if (RNA_boolean_get(op->ptr, "extend"))
|
if (RNA_boolean_get(op->ptr, "extend"))
|
||||||
|
@@ -606,8 +606,8 @@ static void mouse_nla_strips (bContext *C, bAnimContext *ac, const int mval[2],
|
|||||||
static int nlaedit_clickselect_invoke(bContext *C, wmOperator *op, wmEvent *event)
|
static int nlaedit_clickselect_invoke(bContext *C, wmOperator *op, wmEvent *event)
|
||||||
{
|
{
|
||||||
bAnimContext ac;
|
bAnimContext ac;
|
||||||
Scene *scene;
|
/* Scene *scene; */ /* UNUSED */
|
||||||
ARegion *ar;
|
/* ARegion *ar; */ /* UNUSED */
|
||||||
// View2D *v2d; /*UNUSED*/
|
// View2D *v2d; /*UNUSED*/
|
||||||
short selectmode;
|
short selectmode;
|
||||||
|
|
||||||
@@ -616,8 +616,8 @@ static int nlaedit_clickselect_invoke(bContext *C, wmOperator *op, wmEvent *even
|
|||||||
return OPERATOR_CANCELLED;
|
return OPERATOR_CANCELLED;
|
||||||
|
|
||||||
/* get useful pointers from animation context data */
|
/* get useful pointers from animation context data */
|
||||||
scene= ac.scene;
|
/* scene= ac.scene; */ /* UNUSED */
|
||||||
ar= ac.ar;
|
/* ar= ac.ar; */ /* UNUSED */
|
||||||
// v2d= &ar->v2d;
|
// v2d= &ar->v2d;
|
||||||
|
|
||||||
/* select mode is either replace (deselect all, then add) or add/extend */
|
/* select mode is either replace (deselect all, then add) or add/extend */
|
||||||
|
@@ -179,6 +179,7 @@ static void node_socket_button_color(const bContext *C, uiBlock *block,
|
|||||||
|
|
||||||
/* ****************** BASE DRAW FUNCTIONS FOR NEW OPERATOR NODES ***************** */
|
/* ****************** BASE DRAW FUNCTIONS FOR NEW OPERATOR NODES ***************** */
|
||||||
|
|
||||||
|
#if 0 /* UNUSED */
|
||||||
static void node_draw_socket_new(bNodeSocket *sock, float size)
|
static void node_draw_socket_new(bNodeSocket *sock, float size)
|
||||||
{
|
{
|
||||||
float x=sock->locx, y=sock->locy;
|
float x=sock->locx, y=sock->locy;
|
||||||
@@ -216,6 +217,7 @@ static void node_draw_socket_new(bNodeSocket *sock, float size)
|
|||||||
glDisable( GL_LINE_SMOOTH );
|
glDisable( GL_LINE_SMOOTH );
|
||||||
glDisable(GL_BLEND);
|
glDisable(GL_BLEND);
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
/* ****************** BUTTON CALLBACKS FOR ALL TREES ***************** */
|
/* ****************** BUTTON CALLBACKS FOR ALL TREES ***************** */
|
||||||
|
|
||||||
@@ -894,14 +896,14 @@ static void node_browse_text_cb(bContext *C, void *ntree_v, void *node_v)
|
|||||||
Main *bmain= CTX_data_main(C);
|
Main *bmain= CTX_data_main(C);
|
||||||
bNodeTree *ntree= ntree_v;
|
bNodeTree *ntree= ntree_v;
|
||||||
bNode *node= node_v;
|
bNode *node= node_v;
|
||||||
ID *oldid;
|
/* ID *oldid; */ /* UNUSED */
|
||||||
|
|
||||||
if(node->menunr<1) return;
|
if(node->menunr<1) return;
|
||||||
|
|
||||||
if(node->id) {
|
if(node->id) {
|
||||||
node->id->us--;
|
node->id->us--;
|
||||||
}
|
}
|
||||||
oldid= node->id;
|
/* oldid= node->id; */ /* UNUSED */
|
||||||
node->id= BLI_findlink(&bmain->text, node->menunr-1);
|
node->id= BLI_findlink(&bmain->text, node->menunr-1);
|
||||||
id_us_plus(node->id);
|
id_us_plus(node->id);
|
||||||
BLI_strncpy(node->name, node->id->name+2, sizeof(node->name));
|
BLI_strncpy(node->name, node->id->name+2, sizeof(node->name));
|
||||||
|
@@ -757,6 +757,8 @@ void ED_node_update_hierarchy(bContext *UNUSED(C), bNodeTree *ntree)
|
|||||||
|
|
||||||
/* ***************** generic operator functions for nodes ***************** */
|
/* ***************** generic operator functions for nodes ***************** */
|
||||||
|
|
||||||
|
#if 0 /* UNUSED */
|
||||||
|
|
||||||
static int edit_node_poll(bContext *C)
|
static int edit_node_poll(bContext *C)
|
||||||
{
|
{
|
||||||
return ED_operator_node_active(C);
|
return ED_operator_node_active(C);
|
||||||
@@ -815,6 +817,7 @@ static void edit_node_properties_get(wmOperator *op, bNodeTree *ntree, bNode **r
|
|||||||
if (rin_out)
|
if (rin_out)
|
||||||
*rin_out = in_out;
|
*rin_out = in_out;
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
/* ***************** Edit Group operator ************* */
|
/* ***************** Edit Group operator ************* */
|
||||||
|
|
||||||
@@ -902,7 +905,7 @@ static int node_group_socket_add_exec(bContext *C, wmOperator *op)
|
|||||||
char name[32]= "";
|
char name[32]= "";
|
||||||
int type= SOCK_FLOAT;
|
int type= SOCK_FLOAT;
|
||||||
bNodeTree *ngroup= snode->edittree;
|
bNodeTree *ngroup= snode->edittree;
|
||||||
bNodeSocket *sock;
|
/* bNodeSocket *sock; */ /* UNUSED */
|
||||||
|
|
||||||
ED_preview_kill_jobs(C);
|
ED_preview_kill_jobs(C);
|
||||||
|
|
||||||
@@ -918,7 +921,7 @@ static int node_group_socket_add_exec(bContext *C, wmOperator *op)
|
|||||||
return OPERATOR_CANCELLED;
|
return OPERATOR_CANCELLED;
|
||||||
|
|
||||||
/* using placeholder subtype first */
|
/* using placeholder subtype first */
|
||||||
sock = node_group_add_socket(ngroup, name, type, in_out);
|
/* sock = */ /* UNUSED */ node_group_add_socket(ngroup, name, type, in_out);
|
||||||
|
|
||||||
ntreeUpdateTree(ngroup);
|
ntreeUpdateTree(ngroup);
|
||||||
|
|
||||||
|
@@ -109,7 +109,7 @@ static int node_select_exec(bContext *C, wmOperator *op)
|
|||||||
ARegion *ar= CTX_wm_region(C);
|
ARegion *ar= CTX_wm_region(C);
|
||||||
int mval[2];
|
int mval[2];
|
||||||
short extend;
|
short extend;
|
||||||
bNode *node= NULL;
|
/* bNode *node= NULL; */ /* UNUSED */
|
||||||
|
|
||||||
/* get settings from RNA properties for operator */
|
/* get settings from RNA properties for operator */
|
||||||
mval[0] = RNA_int_get(op->ptr, "mouse_x");
|
mval[0] = RNA_int_get(op->ptr, "mouse_x");
|
||||||
@@ -118,7 +118,7 @@ static int node_select_exec(bContext *C, wmOperator *op)
|
|||||||
extend = RNA_boolean_get(op->ptr, "extend");
|
extend = RNA_boolean_get(op->ptr, "extend");
|
||||||
|
|
||||||
/* perform the select */
|
/* perform the select */
|
||||||
node= node_mouse_select(bmain, snode, ar, mval, extend);
|
/* node= */ /* UNUSED*/ node_mouse_select(bmain, snode, ar, mval, extend);
|
||||||
|
|
||||||
/* send notifiers */
|
/* send notifiers */
|
||||||
WM_event_add_notifier(C, NC_NODE|NA_SELECTED, NULL);
|
WM_event_add_notifier(C, NC_NODE|NA_SELECTED, NULL);
|
||||||
|
@@ -214,12 +214,11 @@ void NODE_OT_visibility_toggle(wmOperatorType *ot)
|
|||||||
static void snode_home(ScrArea *UNUSED(sa), ARegion *ar, SpaceNode* snode)
|
static void snode_home(ScrArea *UNUSED(sa), ARegion *ar, SpaceNode* snode)
|
||||||
{
|
{
|
||||||
bNode *node;
|
bNode *node;
|
||||||
rctf *cur, *tot;
|
rctf *cur;
|
||||||
float oldwidth, oldheight, width, height;
|
float oldwidth, oldheight, width, height;
|
||||||
int first= 1;
|
int first= 1;
|
||||||
|
|
||||||
cur= &ar->v2d.cur;
|
cur= &ar->v2d.cur;
|
||||||
tot= &ar->v2d.tot;
|
|
||||||
|
|
||||||
oldwidth= cur->xmax - cur->xmin;
|
oldwidth= cur->xmax - cur->xmin;
|
||||||
oldheight= cur->ymax - cur->ymin;
|
oldheight= cur->ymax - cur->ymin;
|
||||||
|
@@ -969,7 +969,7 @@ static void tree_element_to_path(SpaceOops *soops, TreeElement *te, TreeStoreEle
|
|||||||
ListBase hierarchy = {NULL, NULL};
|
ListBase hierarchy = {NULL, NULL};
|
||||||
LinkData *ld;
|
LinkData *ld;
|
||||||
TreeElement *tem, *temnext, *temsub;
|
TreeElement *tem, *temnext, *temsub;
|
||||||
TreeStoreElem *tse, *tsenext;
|
TreeStoreElem *tse /* , *tsenext */ /* UNUSED */;
|
||||||
PointerRNA *ptr, *nextptr;
|
PointerRNA *ptr, *nextptr;
|
||||||
PropertyRNA *prop;
|
PropertyRNA *prop;
|
||||||
char *newpath=NULL;
|
char *newpath=NULL;
|
||||||
@@ -1018,7 +1018,7 @@ static void tree_element_to_path(SpaceOops *soops, TreeElement *te, TreeStoreEle
|
|||||||
char buf[128], *name;
|
char buf[128], *name;
|
||||||
|
|
||||||
temnext= (TreeElement*)(ld->next->data);
|
temnext= (TreeElement*)(ld->next->data);
|
||||||
tsenext= TREESTORE(temnext);
|
/* tsenext= TREESTORE(temnext); */ /* UNUSED */
|
||||||
|
|
||||||
nextptr= &temnext->rnaptr;
|
nextptr= &temnext->rnaptr;
|
||||||
name= RNA_struct_name_get_alloc(nextptr, buf, sizeof(buf));
|
name= RNA_struct_name_get_alloc(nextptr, buf, sizeof(buf));
|
||||||
|
@@ -1151,7 +1151,7 @@ static int need_add_seq_dup(Sequence *seq)
|
|||||||
|
|
||||||
static void outliner_add_seq_dup(SpaceOops *soops, Sequence *seq, TreeElement *te, short index)
|
static void outliner_add_seq_dup(SpaceOops *soops, Sequence *seq, TreeElement *te, short index)
|
||||||
{
|
{
|
||||||
TreeElement *ch;
|
/* TreeElement *ch; */ /* UNUSED */
|
||||||
Sequence *p;
|
Sequence *p;
|
||||||
|
|
||||||
p= seq;
|
p= seq;
|
||||||
@@ -1162,7 +1162,7 @@ static void outliner_add_seq_dup(SpaceOops *soops, Sequence *seq, TreeElement *t
|
|||||||
}
|
}
|
||||||
|
|
||||||
if(!strcmp(p->strip->stripdata->name, seq->strip->stripdata->name))
|
if(!strcmp(p->strip->stripdata->name, seq->strip->stripdata->name))
|
||||||
ch= outliner_add_element(soops, &te->subtree, (void*)p, te, TSE_SEQUENCE, index);
|
/* ch= */ /* UNUSED */ outliner_add_element(soops, &te->subtree, (void*)p, te, TSE_SEQUENCE, index);
|
||||||
p= p->next;
|
p= p->next;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@@ -1483,9 +1483,13 @@ static int sequencer_cut_exec(bContext *C, wmOperator *op)
|
|||||||
sort_seq(scene);
|
sort_seq(scene);
|
||||||
}
|
}
|
||||||
|
|
||||||
WM_event_add_notifier(C, NC_SCENE|ND_SEQUENCER, scene);
|
if(changed) {
|
||||||
|
WM_event_add_notifier(C, NC_SCENE|ND_SEQUENCER, scene);
|
||||||
return OPERATOR_FINISHED;
|
return OPERATOR_FINISHED;
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
return OPERATOR_CANCELLED;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@@ -1291,7 +1291,7 @@ static void draw_documentation(SpaceText *st, ARegion *ar)
|
|||||||
TextLine *tmp;
|
TextLine *tmp;
|
||||||
char *docs, buf[DOC_WIDTH+1], *p;
|
char *docs, buf[DOC_WIDTH+1], *p;
|
||||||
int i, br, lines;
|
int i, br, lines;
|
||||||
int boxw, boxh, l, x, y, top;
|
int boxw, boxh, l, x, y /* , top */ /* UNUSED */;
|
||||||
|
|
||||||
if(!st || !st->text) return;
|
if(!st || !st->text) return;
|
||||||
if(!texttool_text_is_active(st->text)) return;
|
if(!texttool_text_is_active(st->text)) return;
|
||||||
@@ -1314,7 +1314,7 @@ static void draw_documentation(SpaceText *st, ARegion *ar)
|
|||||||
x += SUGG_LIST_WIDTH*st->cwidth + 50;
|
x += SUGG_LIST_WIDTH*st->cwidth + 50;
|
||||||
}
|
}
|
||||||
|
|
||||||
top= y= ar->winy - st->lheight*l - 2;
|
/* top= */ /* UNUSED */ y= ar->winy - st->lheight*l - 2;
|
||||||
boxw= DOC_WIDTH*st->cwidth + 20;
|
boxw= DOC_WIDTH*st->cwidth + 20;
|
||||||
boxh= (DOC_HEIGHT+1)*st->lheight;
|
boxh= (DOC_HEIGHT+1)*st->lheight;
|
||||||
|
|
||||||
|
@@ -4057,7 +4057,7 @@ static void draw_new_particle_system(Scene *scene, View3D *v3d, RegionView3D *rv
|
|||||||
|
|
||||||
if(draw_as==PART_DRAW_PATH){
|
if(draw_as==PART_DRAW_PATH){
|
||||||
ParticleCacheKey **cache, *path;
|
ParticleCacheKey **cache, *path;
|
||||||
float *cd2=NULL,*cdata2=NULL;
|
float /* *cd2=NULL, */ /* UNUSED */ *cdata2=NULL;
|
||||||
|
|
||||||
/* setup gl flags */
|
/* setup gl flags */
|
||||||
if (1) { //ob_dt > OB_WIRE) {
|
if (1) { //ob_dt > OB_WIRE) {
|
||||||
@@ -4125,7 +4125,7 @@ static void draw_new_particle_system(Scene *scene, View3D *v3d, RegionView3D *rv
|
|||||||
|
|
||||||
if(cdata2)
|
if(cdata2)
|
||||||
MEM_freeN(cdata2);
|
MEM_freeN(cdata2);
|
||||||
cd2=cdata2=NULL;
|
/* cd2= */ /* UNUSED */ cdata2=NULL;
|
||||||
|
|
||||||
glLineWidth(1.0f);
|
glLineWidth(1.0f);
|
||||||
|
|
||||||
|
@@ -183,7 +183,7 @@ void draw_volume(ARegion *ar, GPUTexture *tex, float *min, float *max, int res[3
|
|||||||
|
|
||||||
float viewnormal[3];
|
float viewnormal[3];
|
||||||
int i, j, n, good_index;
|
int i, j, n, good_index;
|
||||||
float d, d0, dd, ds;
|
float d /*, d0 */ /* UNUSED */, dd, ds;
|
||||||
float *points = NULL;
|
float *points = NULL;
|
||||||
int numpoints = 0;
|
int numpoints = 0;
|
||||||
float cor[3] = {1.,1.,1.};
|
float cor[3] = {1.,1.,1.};
|
||||||
@@ -390,7 +390,8 @@ void draw_volume(ARegion *ar, GPUTexture *tex, float *min, float *max, int res[3
|
|||||||
// (a,b,c), the plane normal, are given by viewdir
|
// (a,b,c), the plane normal, are given by viewdir
|
||||||
// d is the parameter along the view direction. the first d is given by
|
// d is the parameter along the view direction. the first d is given by
|
||||||
// inserting previously found vertex into the plane equation
|
// inserting previously found vertex into the plane equation
|
||||||
d0 = (viewnormal[0]*cv[i][0] + viewnormal[1]*cv[i][1] + viewnormal[2]*cv[i][2]);
|
|
||||||
|
/* d0 = (viewnormal[0]*cv[i][0] + viewnormal[1]*cv[i][1] + viewnormal[2]*cv[i][2]); */ /* UNUSED */
|
||||||
ds = (ABS(viewnormal[0])*size[0] + ABS(viewnormal[1])*size[1] + ABS(viewnormal[2])*size[2]);
|
ds = (ABS(viewnormal[0])*size[0] + ABS(viewnormal[1])*size[1] + ABS(viewnormal[2])*size[2]);
|
||||||
dd = 0.05; // ds/512.0f;
|
dd = 0.05; // ds/512.0f;
|
||||||
n = 0;
|
n = 0;
|
||||||
|
@@ -2156,12 +2156,12 @@ static void paint_facesel_circle_select(ViewContext *vc, int select, const int m
|
|||||||
{
|
{
|
||||||
Object *ob= vc->obact;
|
Object *ob= vc->obact;
|
||||||
Mesh *me = ob?ob->data:NULL;
|
Mesh *me = ob?ob->data:NULL;
|
||||||
int bbsel;
|
/* int bbsel; */ /* UNUSED */
|
||||||
|
|
||||||
if (me) {
|
if (me) {
|
||||||
em_vertoffs= me->totface+1; /* max index array */
|
em_vertoffs= me->totface+1; /* max index array */
|
||||||
|
|
||||||
bbsel= EM_init_backbuf_circle(vc, mval[0], mval[1], (short)(rad+1.0f));
|
/* bbsel= */ /* UNUSED */ EM_init_backbuf_circle(vc, mval[0], mval[1], (short)(rad+1.0f));
|
||||||
EM_backbuf_checkAndSelectTFaces(me, select==LEFTMOUSE);
|
EM_backbuf_checkAndSelectTFaces(me, select==LEFTMOUSE);
|
||||||
EM_free_backbuf();
|
EM_free_backbuf();
|
||||||
}
|
}
|
||||||
@@ -2172,12 +2172,12 @@ static void paint_vertsel_circle_select(ViewContext *vc, int select, const int m
|
|||||||
{
|
{
|
||||||
Object *ob= vc->obact;
|
Object *ob= vc->obact;
|
||||||
Mesh *me = ob?ob->data:NULL;
|
Mesh *me = ob?ob->data:NULL;
|
||||||
int bbsel;
|
/* int bbsel; */ /* UNUSED */
|
||||||
/* struct {ViewContext *vc; short select; int mval[2]; float radius; } data = {NULL}; */ /* UNUSED */
|
/* struct {ViewContext *vc; short select; int mval[2]; float radius; } data = {NULL}; */ /* UNUSED */
|
||||||
if (me) {
|
if (me) {
|
||||||
em_vertoffs= me->totvert+1; /* max index array */
|
em_vertoffs= me->totvert+1; /* max index array */
|
||||||
|
|
||||||
bbsel= EM_init_backbuf_circle(vc, mval[0], mval[1], (short)(rad+1.0f));
|
/* bbsel= */ /* UNUSED */ EM_init_backbuf_circle(vc, mval[0], mval[1], (short)(rad+1.0f));
|
||||||
EM_backbuf_checkAndSelectVerts_obmode(me, select==LEFTMOUSE);
|
EM_backbuf_checkAndSelectVerts_obmode(me, select==LEFTMOUSE);
|
||||||
EM_free_backbuf();
|
EM_free_backbuf();
|
||||||
|
|
||||||
|
@@ -4260,7 +4260,6 @@ static int createSlideVerts(TransInfo *t)
|
|||||||
LinkNode *edgelist = NULL, *vertlist=NULL, *look;
|
LinkNode *edgelist = NULL, *vertlist=NULL, *look;
|
||||||
GHash *vertgh;
|
GHash *vertgh;
|
||||||
TransDataSlideVert *tempsv;
|
TransDataSlideVert *tempsv;
|
||||||
float vertdist; // XXX, projectMat[4][4];
|
|
||||||
int i, j, numsel, numadded=0, timesthrough = 0, vertsel=0;
|
int i, j, numsel, numadded=0, timesthrough = 0, vertsel=0;
|
||||||
/* UV correction vars */
|
/* UV correction vars */
|
||||||
GHash **uvarray= NULL;
|
GHash **uvarray= NULL;
|
||||||
@@ -4525,7 +4524,6 @@ static int createSlideVerts(TransInfo *t)
|
|||||||
|
|
||||||
look = vertlist;
|
look = vertlist;
|
||||||
nearest = NULL;
|
nearest = NULL;
|
||||||
vertdist = -1;
|
|
||||||
while(look) {
|
while(look) {
|
||||||
tempsv = BLI_ghash_lookup(vertgh,(EditVert*)look->link);
|
tempsv = BLI_ghash_lookup(vertgh,(EditVert*)look->link);
|
||||||
|
|
||||||
@@ -5563,7 +5561,7 @@ static void applyTimeTranslate(TransInfo *t, float UNUSED(sval))
|
|||||||
|
|
||||||
const short autosnap= getAnimEdit_SnapMode(t);
|
const short autosnap= getAnimEdit_SnapMode(t);
|
||||||
|
|
||||||
float deltax, val, valprev;
|
float deltax, val /* , valprev */;
|
||||||
|
|
||||||
/* it doesn't matter whether we apply to t->data or t->data2d, but t->data2d is more convenient */
|
/* it doesn't matter whether we apply to t->data or t->data2d, but t->data2d is more convenient */
|
||||||
for (i = 0 ; i < t->total; i++, td++, td2d++) {
|
for (i = 0 ; i < t->total; i++, td++, td2d++) {
|
||||||
@@ -5573,7 +5571,7 @@ static void applyTimeTranslate(TransInfo *t, float UNUSED(sval))
|
|||||||
*/
|
*/
|
||||||
AnimData *adt= (t->spacetype != SPACE_NLA) ? td->extra : NULL;
|
AnimData *adt= (t->spacetype != SPACE_NLA) ? td->extra : NULL;
|
||||||
|
|
||||||
valprev = *td->val;
|
/* valprev = *td->val; */ /* UNUSED */
|
||||||
|
|
||||||
/* check if any need to apply nla-mapping */
|
/* check if any need to apply nla-mapping */
|
||||||
if (adt && t->spacetype != SPACE_SEQ) {
|
if (adt && t->spacetype != SPACE_SEQ) {
|
||||||
|
@@ -1807,7 +1807,7 @@ void flushTransParticles(TransInfo *t)
|
|||||||
/* ********************* mesh ****************** */
|
/* ********************* mesh ****************** */
|
||||||
|
|
||||||
/* proportional distance based on connectivity */
|
/* proportional distance based on connectivity */
|
||||||
#define THRESHOLD 0.0001f
|
#define THRESHOLD 0.000000000000001f
|
||||||
|
|
||||||
static int connectivity_edge(float mtx[][3], EditVert *v1, EditVert *v2)
|
static int connectivity_edge(float mtx[][3], EditVert *v1, EditVert *v2)
|
||||||
{
|
{
|
||||||
@@ -3408,7 +3408,7 @@ static void createTransGraphEditData(bContext *C, TransInfo *t)
|
|||||||
const char sel3= use_handle ? bezt->f3 & SELECT : 0;
|
const char sel3= use_handle ? bezt->f3 & SELECT : 0;
|
||||||
|
|
||||||
TransDataCurveHandleFlags *hdata = NULL;
|
TransDataCurveHandleFlags *hdata = NULL;
|
||||||
short h1=1, h2=1;
|
/* short h1=1, h2=1; */ /* UNUSED */
|
||||||
|
|
||||||
/* only include handles if selected, irrespective of the interpolation modes.
|
/* only include handles if selected, irrespective of the interpolation modes.
|
||||||
* also, only treat handles specially if the center point isn't selected.
|
* also, only treat handles specially if the center point isn't selected.
|
||||||
@@ -3418,16 +3418,18 @@ static void createTransGraphEditData(bContext *C, TransInfo *t)
|
|||||||
hdata = initTransDataCurveHandles(td, bezt);
|
hdata = initTransDataCurveHandles(td, bezt);
|
||||||
bezt_to_transdata(td++, td2d++, adt, bezt, 0, 1, 1, intvals, mtx, smtx);
|
bezt_to_transdata(td++, td2d++, adt, bezt, 0, 1, 1, intvals, mtx, smtx);
|
||||||
}
|
}
|
||||||
else
|
else {
|
||||||
h1= 0;
|
/* h1= 0; */ /* UNUSED */
|
||||||
|
}
|
||||||
|
|
||||||
if (sel3) {
|
if (sel3) {
|
||||||
if (hdata==NULL)
|
if (hdata==NULL)
|
||||||
hdata = initTransDataCurveHandles(td, bezt);
|
hdata = initTransDataCurveHandles(td, bezt);
|
||||||
bezt_to_transdata(td++, td2d++, adt, bezt, 2, 1, 1, intvals, mtx, smtx);
|
bezt_to_transdata(td++, td2d++, adt, bezt, 2, 1, 1, intvals, mtx, smtx);
|
||||||
}
|
}
|
||||||
else
|
else {
|
||||||
h2= 0;
|
/* h2= 0; */ /* UNUSED */
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/* only include main vert if selected */
|
/* only include main vert if selected */
|
||||||
|
@@ -446,13 +446,13 @@ int calc_manipulator_stats(const bContext *C)
|
|||||||
}
|
}
|
||||||
else if(obedit->type==OB_MBALL) {
|
else if(obedit->type==OB_MBALL) {
|
||||||
MetaBall *mb = (MetaBall*)obedit->data;
|
MetaBall *mb = (MetaBall*)obedit->data;
|
||||||
MetaElem *ml, *ml_sel=NULL;
|
MetaElem *ml /* , *ml_sel=NULL */ /* UNUSED */;
|
||||||
|
|
||||||
ml= mb->editelems->first;
|
ml= mb->editelems->first;
|
||||||
while(ml) {
|
while(ml) {
|
||||||
if(ml->flag & SELECT) {
|
if(ml->flag & SELECT) {
|
||||||
calc_tw_center(scene, &ml->x);
|
calc_tw_center(scene, &ml->x);
|
||||||
ml_sel = ml;
|
/* ml_sel = ml; */ /* UNUSED */
|
||||||
totsel++;
|
totsel++;
|
||||||
}
|
}
|
||||||
ml= ml->next;
|
ml= ml->next;
|
||||||
|
@@ -391,6 +391,7 @@ static void rna_NodeGroupSocket_update(Main *bmain, Scene *scene, PointerRNA *pt
|
|||||||
node_update(bmain, scene, ntree, node);
|
node_update(bmain, scene, ntree, node);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#if 0 /* UNUSED */
|
||||||
static void rna_NodeLink_update(Main *bmain, Scene *scene, PointerRNA *ptr)
|
static void rna_NodeLink_update(Main *bmain, Scene *scene, PointerRNA *ptr)
|
||||||
{
|
{
|
||||||
bNodeTree *ntree= (bNodeTree*)ptr->id.data;
|
bNodeTree *ntree= (bNodeTree*)ptr->id.data;
|
||||||
@@ -398,6 +399,7 @@ static void rna_NodeLink_update(Main *bmain, Scene *scene, PointerRNA *ptr)
|
|||||||
ntree->update |= NTREE_UPDATE_LINKS;
|
ntree->update |= NTREE_UPDATE_LINKS;
|
||||||
ntreeUpdateTree(ntree);
|
ntreeUpdateTree(ntree);
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
static void rna_NodeSocketInt_range(PointerRNA *ptr, int *min, int *max)
|
static void rna_NodeSocketInt_range(PointerRNA *ptr, int *min, int *max)
|
||||||
{
|
{
|
||||||
|
@@ -192,7 +192,7 @@ static void node_composit_exec_color_spill(void *UNUSED(data), bNode *node, bNod
|
|||||||
/* Originally based on the information from the book "The Art and Science of Digital Composition" and
|
/* Originally based on the information from the book "The Art and Science of Digital Composition" and
|
||||||
* discussions from vfxtalk.com .*/
|
* discussions from vfxtalk.com .*/
|
||||||
CompBuf *cbuf;
|
CompBuf *cbuf;
|
||||||
CompBuf *mask;
|
/* CompBuf *mask; */ /* UNUSED */
|
||||||
CompBuf *rgbbuf;
|
CompBuf *rgbbuf;
|
||||||
CompBuf *spillmap;
|
CompBuf *spillmap;
|
||||||
NodeColorspill *ncs;
|
NodeColorspill *ncs;
|
||||||
@@ -204,7 +204,7 @@ static void node_composit_exec_color_spill(void *UNUSED(data), bNode *node, bNod
|
|||||||
if(in[0]->data==NULL) return;
|
if(in[0]->data==NULL) return;
|
||||||
|
|
||||||
cbuf=typecheck_compbuf(in[0]->data, CB_RGBA);
|
cbuf=typecheck_compbuf(in[0]->data, CB_RGBA);
|
||||||
mask=typecheck_compbuf(in[1]->data, CB_VAL);
|
/* mask= */ /* UNUSED */ typecheck_compbuf(in[1]->data, CB_VAL);
|
||||||
spillmap=alloc_compbuf(cbuf->x, cbuf->y, CB_VAL, 1);
|
spillmap=alloc_compbuf(cbuf->x, cbuf->y, CB_VAL, 1);
|
||||||
rgbbuf=dupalloc_compbuf(cbuf);
|
rgbbuf=dupalloc_compbuf(cbuf);
|
||||||
|
|
||||||
|
@@ -91,7 +91,7 @@ static void node_composit_exec_diff_matte(void *data, bNode *node, bNodeStack **
|
|||||||
CompBuf *outbuf= NULL;
|
CompBuf *outbuf= NULL;
|
||||||
CompBuf *imbuf1= NULL;
|
CompBuf *imbuf1= NULL;
|
||||||
CompBuf *imbuf2= NULL;
|
CompBuf *imbuf2= NULL;
|
||||||
NodeChroma *c;
|
/* NodeChroma *c; */ /* UNUSED */
|
||||||
|
|
||||||
/*is anything connected?*/
|
/*is anything connected?*/
|
||||||
if(out[0]->hasoutput==0 && out[1]->hasoutput==0) return;
|
if(out[0]->hasoutput==0 && out[1]->hasoutput==0) return;
|
||||||
@@ -107,7 +107,7 @@ static void node_composit_exec_diff_matte(void *data, bNode *node, bNodeStack **
|
|||||||
imbuf2=typecheck_compbuf(in[1]->data, CB_RGBA);
|
imbuf2=typecheck_compbuf(in[1]->data, CB_RGBA);
|
||||||
}
|
}
|
||||||
|
|
||||||
c=node->storage;
|
/* c=node->storage; */ /* UNUSED */
|
||||||
outbuf=dupalloc_compbuf(imbuf1);
|
outbuf=dupalloc_compbuf(imbuf1);
|
||||||
|
|
||||||
/* note, processor gets a keyvals array passed on as buffer constant */
|
/* note, processor gets a keyvals array passed on as buffer constant */
|
||||||
|
@@ -826,11 +826,11 @@ bNodeTemplate node_forloop_template(bNode *node)
|
|||||||
|
|
||||||
void node_forloop_init(bNodeTree *ntree, bNode *node, bNodeTemplate *ntemp)
|
void node_forloop_init(bNodeTree *ntree, bNode *node, bNodeTemplate *ntemp)
|
||||||
{
|
{
|
||||||
bNodeSocket *sock;
|
/* bNodeSocket *sock; */ /* UNUSED */
|
||||||
|
|
||||||
node->id = (ID*)ntemp->ngroup;
|
node->id = (ID*)ntemp->ngroup;
|
||||||
|
|
||||||
sock = nodeAddInputFloat(ntree, node, "Iterations", PROP_UNSIGNED, 1, 0, 10000);
|
/* sock = */ nodeAddInputFloat(ntree, node, "Iterations", PROP_UNSIGNED, 1, 0, 10000);
|
||||||
|
|
||||||
/* NB: group socket input/output roles are inverted internally!
|
/* NB: group socket input/output roles are inverted internally!
|
||||||
* Group "inputs" work as outputs in links and vice versa.
|
* Group "inputs" work as outputs in links and vice versa.
|
||||||
@@ -932,11 +932,11 @@ void node_loop_update_tree(bNodeTree *ngroup)
|
|||||||
|
|
||||||
void node_whileloop_init(bNodeTree *ntree, bNode *node, bNodeTemplate *ntemp)
|
void node_whileloop_init(bNodeTree *ntree, bNode *node, bNodeTemplate *ntemp)
|
||||||
{
|
{
|
||||||
bNodeSocket *sock;
|
/* bNodeSocket *sock; */ /* UNUSED */
|
||||||
|
|
||||||
node->id = (ID*)ntemp->ngroup;
|
node->id = (ID*)ntemp->ngroup;
|
||||||
|
|
||||||
sock = nodeAddInputFloat(ntree, node, "Condition", PROP_NONE, 1, 0, 1);
|
/* sock = */ nodeAddInputFloat(ntree, node, "Condition", PROP_NONE, 1, 0, 1);
|
||||||
|
|
||||||
/* max iterations */
|
/* max iterations */
|
||||||
node->custom1 = 10000;
|
node->custom1 = 10000;
|
||||||
|
@@ -306,7 +306,7 @@ int shadeHaloFloat(HaloRen *har, float *col, int zz,
|
|||||||
|
|
||||||
/* soften the halo if it intersects geometry */
|
/* soften the halo if it intersects geometry */
|
||||||
if(har->mat && har->mat->mode & MA_HALO_SOFT) {
|
if(har->mat && har->mat->mode & MA_HALO_SOFT) {
|
||||||
float segment_length, halo_depth, distance_from_z, visible_depth, soften;
|
float segment_length, halo_depth, distance_from_z /* , visible_depth */ /* UNUSED */, soften;
|
||||||
|
|
||||||
/* calculate halo depth */
|
/* calculate halo depth */
|
||||||
segment_length= har->hasize*sasqrt(1.0f - dist/(har->rad*har->rad));
|
segment_length= har->hasize*sasqrt(1.0f - dist/(har->rad*har->rad));
|
||||||
@@ -317,7 +317,7 @@ int shadeHaloFloat(HaloRen *har, float *col, int zz,
|
|||||||
|
|
||||||
/* calculate how much of this depth is visible */
|
/* calculate how much of this depth is visible */
|
||||||
distance_from_z = haloZtoDist(zz) - haloZtoDist(har->zs);
|
distance_from_z = haloZtoDist(zz) - haloZtoDist(har->zs);
|
||||||
visible_depth = halo_depth;
|
/* visible_depth = halo_depth; */ /* UNUSED */
|
||||||
if(distance_from_z < segment_length) {
|
if(distance_from_z < segment_length) {
|
||||||
soften= (segment_length + distance_from_z)/halo_depth;
|
soften= (segment_length + distance_from_z)/halo_depth;
|
||||||
|
|
||||||
|
@@ -107,7 +107,7 @@ static void pointdensity_cache_psys(Render *re, PointDensity *pd, Object *ob, Pa
|
|||||||
ParticleSimulationData sim= {NULL};
|
ParticleSimulationData sim= {NULL};
|
||||||
ParticleData *pa=NULL;
|
ParticleData *pa=NULL;
|
||||||
float cfra = BKE_curframe(re->scene);
|
float cfra = BKE_curframe(re->scene);
|
||||||
int i, childexists;
|
int i /*, childexists*/ /* UNUSED */;
|
||||||
int total_particles, offset=0;
|
int total_particles, offset=0;
|
||||||
int data_used = point_data_used(pd);
|
int data_used = point_data_used(pd);
|
||||||
float partco[3];
|
float partco[3];
|
||||||
@@ -143,9 +143,11 @@ static void pointdensity_cache_psys(Render *re, PointDensity *pd, Object *ob, Pa
|
|||||||
pd->totpoints = total_particles;
|
pd->totpoints = total_particles;
|
||||||
if (data_used & POINT_DATA_VEL) offset = pd->totpoints*3;
|
if (data_used & POINT_DATA_VEL) offset = pd->totpoints*3;
|
||||||
|
|
||||||
|
#if 0 /* UNUSED */
|
||||||
if (psys->totchild > 0 && !(psys->part->draw & PART_DRAW_PARENT))
|
if (psys->totchild > 0 && !(psys->part->draw & PART_DRAW_PARENT))
|
||||||
childexists = 1;
|
childexists = 1;
|
||||||
|
#endif
|
||||||
|
|
||||||
for (i=0, pa=psys->particles; i < total_particles; i++, pa++) {
|
for (i=0, pa=psys->particles; i < total_particles; i++, pa++) {
|
||||||
|
|
||||||
state.time = cfra;
|
state.time = cfra;
|
||||||
|
@@ -1994,7 +1994,7 @@ static int ntap_bump_compute(NTapBump *ntap_bump, ShadeInput *shi, MTex *mtex, T
|
|||||||
else {
|
else {
|
||||||
/* same as above, but doing 5 taps, increasing quality at cost of speed */
|
/* same as above, but doing 5 taps, increasing quality at cost of speed */
|
||||||
float STc[3], STl[3], STr[3], STd[3], STu[3];
|
float STc[3], STl[3], STr[3], STd[3], STu[3];
|
||||||
float Hc, Hl, Hr, Hd, Hu;
|
float /* Hc, */ /* UNUSED */ Hl, Hr, Hd, Hu;
|
||||||
|
|
||||||
texco_mapping(shi, tex, mtex, co, dx, dy, texvec, dxt, dyt);
|
texco_mapping(shi, tex, mtex, co, dx, dy, texvec, dxt, dyt);
|
||||||
|
|
||||||
@@ -2017,7 +2017,7 @@ static int ntap_bump_compute(NTapBump *ntap_bump, ShadeInput *shi, MTex *mtex, T
|
|||||||
|
|
||||||
// use texres for the center sample, set rgbnor
|
// use texres for the center sample, set rgbnor
|
||||||
rgbnor = multitex_mtex(shi, mtex, STc, dxt, dyt, texres);
|
rgbnor = multitex_mtex(shi, mtex, STc, dxt, dyt, texres);
|
||||||
Hc = (fromrgb)? RGBTOBW(texres->tr, texres->tg, texres->tb) : texres->tin;
|
/* Hc = (fromrgb)? RGBTOBW(texres->tr, texres->tg, texres->tb) : texres->tin; */ /* UNUSED */
|
||||||
|
|
||||||
// use ttexr for the other taps
|
// use ttexr for the other taps
|
||||||
multitex_mtex(shi, mtex, STl, dxt, dyt, &ttexr);
|
multitex_mtex(shi, mtex, STl, dxt, dyt, &ttexr);
|
||||||
|
@@ -1515,7 +1515,7 @@ static void shade_sample_sss(ShadeSample *ssamp, Material *mat, ObjectInstanceRe
|
|||||||
{
|
{
|
||||||
ShadeInput *shi= ssamp->shi;
|
ShadeInput *shi= ssamp->shi;
|
||||||
ShadeResult shr;
|
ShadeResult shr;
|
||||||
float texfac, orthoarea, nor[3], alpha, sx, sy;
|
float /* texfac,*/ /* UNUSED */ orthoarea, nor[3], alpha, sx, sy;
|
||||||
|
|
||||||
/* cache for shadow */
|
/* cache for shadow */
|
||||||
shi->samplenr= R.shadowsamplenr[shi->thread]++;
|
shi->samplenr= R.shadowsamplenr[shi->thread]++;
|
||||||
@@ -1578,7 +1578,7 @@ static void shade_sample_sss(ShadeSample *ssamp, Material *mat, ObjectInstanceRe
|
|||||||
VECCOPY(color, shr.combined);
|
VECCOPY(color, shr.combined);
|
||||||
|
|
||||||
/* texture blending */
|
/* texture blending */
|
||||||
texfac= shi->mat->sss_texfac;
|
/* texfac= shi->mat->sss_texfac; */ /* UNUSED */
|
||||||
|
|
||||||
alpha= shr.combined[3];
|
alpha= shr.combined[3];
|
||||||
*area *= alpha;
|
*area *= alpha;
|
||||||
|
@@ -1502,12 +1502,12 @@ static void shade_lamp_loop_only_shadow(ShadeInput *shi, ShadeResult *shr)
|
|||||||
LampRen *lar;
|
LampRen *lar;
|
||||||
GroupObject *go;
|
GroupObject *go;
|
||||||
float inpr, lv[3];
|
float inpr, lv[3];
|
||||||
float *view, shadfac[4];
|
float /* *view, */ shadfac[4];
|
||||||
float ir, accum, visifac, lampdist;
|
float ir, accum, visifac, lampdist;
|
||||||
float shaded = 0.0f, lightness = 0.0f;
|
float shaded = 0.0f, lightness = 0.0f;
|
||||||
|
|
||||||
|
|
||||||
view= shi->view;
|
/* view= shi->view; */ /* UNUSED */
|
||||||
accum= ir= 0.0f;
|
accum= ir= 0.0f;
|
||||||
|
|
||||||
lights= get_lights(shi);
|
lights= get_lights(shi);
|
||||||
|
@@ -2864,7 +2864,7 @@ void RE_zbuf_accumulate_vecblur(NodeBlurData *nbd, int xsize, int ysize, float *
|
|||||||
float v1[3], v2[3], v3[3], v4[3], fx, fy;
|
float v1[3], v2[3], v3[3], v4[3], fx, fy;
|
||||||
float *rectvz, *dvz, *dimg, *dvec1, *dvec2, *dz, *dz1, *dz2, *rectz;
|
float *rectvz, *dvz, *dimg, *dvec1, *dvec2, *dz, *dz1, *dz2, *rectz;
|
||||||
float *minvecbufrect= NULL, *rectweight, *rw, *rectmax, *rm, *ro;
|
float *minvecbufrect= NULL, *rectweight, *rw, *rectmax, *rm, *ro;
|
||||||
float maxspeedsq= (float)nbd->maxspeed*nbd->maxspeed, totfac;
|
float maxspeedsq= (float)nbd->maxspeed*nbd->maxspeed;
|
||||||
int y, x, step, maxspeed=nbd->maxspeed, samples= nbd->samples;
|
int y, x, step, maxspeed=nbd->maxspeed, samples= nbd->samples;
|
||||||
int tsktsk= 0;
|
int tsktsk= 0;
|
||||||
static int firsttime= 1;
|
static int firsttime= 1;
|
||||||
@@ -3038,7 +3038,6 @@ void RE_zbuf_accumulate_vecblur(NodeBlurData *nbd, int xsize, int ysize, float *
|
|||||||
}
|
}
|
||||||
|
|
||||||
memset(newrect, 0, sizeof(float)*xsize*ysize*4);
|
memset(newrect, 0, sizeof(float)*xsize*ysize*4);
|
||||||
totfac= 0.0f;
|
|
||||||
|
|
||||||
/* accumulate */
|
/* accumulate */
|
||||||
samples/= 2;
|
samples/= 2;
|
||||||
|
@@ -232,7 +232,7 @@ static void wm_gesture_draw_circle(wmGesture *gt)
|
|||||||
static void draw_filled_lasso(wmGesture *gt)
|
static void draw_filled_lasso(wmGesture *gt)
|
||||||
{
|
{
|
||||||
EditVert *v=NULL, *lastv=NULL, *firstv=NULL;
|
EditVert *v=NULL, *lastv=NULL, *firstv=NULL;
|
||||||
EditEdge *e;
|
/* EditEdge *e; */ /* UNUSED */
|
||||||
EditFace *efa;
|
EditFace *efa;
|
||||||
short *lasso= (short *)gt->customdata;
|
short *lasso= (short *)gt->customdata;
|
||||||
int i;
|
int i;
|
||||||
@@ -246,7 +246,7 @@ static void draw_filled_lasso(wmGesture *gt)
|
|||||||
|
|
||||||
v = BLI_addfillvert(co);
|
v = BLI_addfillvert(co);
|
||||||
if (lastv)
|
if (lastv)
|
||||||
e = BLI_addfilledge(lastv, v);
|
/* e = */ /* UNUSED */ BLI_addfilledge(lastv, v);
|
||||||
lastv = v;
|
lastv = v;
|
||||||
if (firstv==NULL) firstv = v;
|
if (firstv==NULL) firstv = v;
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user