code cleanup: rename G.rt to G.debug_value
This commit is contained in:
@@ -67,8 +67,14 @@ typedef struct Global {
|
|||||||
short winpos, displaymode; /* used to be in Render */
|
short winpos, displaymode; /* used to be in Render */
|
||||||
short rendering; /* to indicate render is busy, prevent renderwindow events etc */
|
short rendering; /* to indicate render is busy, prevent renderwindow events etc */
|
||||||
|
|
||||||
short rt;
|
/* debug value, can be set from the UI and python, used for testing nonstandard features */
|
||||||
|
short debug_value;
|
||||||
|
|
||||||
|
/* saved to the blend file as FileGlobal.globalf,
|
||||||
|
* however this is now only used for runtime options */
|
||||||
int f;
|
int f;
|
||||||
|
|
||||||
|
/* debug flag, G_DEBUG, G_DEBUG_PYTHON & friends, set python or command line args */
|
||||||
int debug;
|
int debug;
|
||||||
|
|
||||||
/* Used for BMesh transformations */
|
/* Used for BMesh transformations */
|
||||||
|
|||||||
@@ -662,7 +662,7 @@ void cloth_free_modifier(ClothModifierData *clmd )
|
|||||||
void cloth_free_modifier_extern(ClothModifierData *clmd )
|
void cloth_free_modifier_extern(ClothModifierData *clmd )
|
||||||
{
|
{
|
||||||
Cloth *cloth = NULL;
|
Cloth *cloth = NULL;
|
||||||
if (G.rt > 0)
|
if (G.debug_value > 0)
|
||||||
printf("cloth_free_modifier_extern\n");
|
printf("cloth_free_modifier_extern\n");
|
||||||
|
|
||||||
if ( !clmd )
|
if ( !clmd )
|
||||||
@@ -671,7 +671,7 @@ void cloth_free_modifier_extern(ClothModifierData *clmd )
|
|||||||
cloth = clmd->clothObject;
|
cloth = clmd->clothObject;
|
||||||
|
|
||||||
if ( cloth ) {
|
if ( cloth ) {
|
||||||
if (G.rt > 0)
|
if (G.debug_value > 0)
|
||||||
printf("cloth_free_modifier_extern in\n");
|
printf("cloth_free_modifier_extern in\n");
|
||||||
|
|
||||||
// If our solver provides a free function, call it
|
// If our solver provides a free function, call it
|
||||||
@@ -852,7 +852,7 @@ static int cloth_from_object(Object *ob, ClothModifierData *clmd, DerivedMesh *d
|
|||||||
// If we have a clothObject, free it.
|
// If we have a clothObject, free it.
|
||||||
if ( clmd->clothObject != NULL ) {
|
if ( clmd->clothObject != NULL ) {
|
||||||
cloth_free_modifier ( clmd );
|
cloth_free_modifier ( clmd );
|
||||||
if (G.rt > 0)
|
if (G.debug_value > 0)
|
||||||
printf("cloth_free_modifier cloth_from_object\n");
|
printf("cloth_free_modifier cloth_from_object\n");
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -1278,7 +1278,7 @@ static int cloth_build_springs ( ClothModifierData *clmd, DerivedMesh *dm )
|
|||||||
|
|
||||||
cloth->edgehash = edgehash;
|
cloth->edgehash = edgehash;
|
||||||
|
|
||||||
if (G.rt > 0)
|
if (G.debug_value > 0)
|
||||||
printf("avg_len: %f\n", clmd->sim_parms->avg_spring_len);
|
printf("avg_len: %f\n", clmd->sim_parms->avg_spring_len);
|
||||||
|
|
||||||
return 1;
|
return 1;
|
||||||
|
|||||||
@@ -710,7 +710,7 @@ int implicit_init(Object *UNUSED(ob), ClothModifierData *clmd)
|
|||||||
Implicit_Data *id = NULL;
|
Implicit_Data *id = NULL;
|
||||||
LinkNode *search = NULL;
|
LinkNode *search = NULL;
|
||||||
|
|
||||||
if (G.rt > 0)
|
if (G.debug_value > 0)
|
||||||
printf("implicit_init\n");
|
printf("implicit_init\n");
|
||||||
|
|
||||||
// init memory guard
|
// init memory guard
|
||||||
@@ -1918,7 +1918,7 @@ void implicit_set_positions(ClothModifierData *clmd)
|
|||||||
copy_v3_v3(id->X[i], verts[i].x);
|
copy_v3_v3(id->X[i], verts[i].x);
|
||||||
copy_v3_v3(id->V[i], verts[i].v);
|
copy_v3_v3(id->V[i], verts[i].v);
|
||||||
}
|
}
|
||||||
if (G.rt > 0)
|
if (G.debug_value > 0)
|
||||||
printf("implicit_set_positions\n");
|
printf("implicit_set_positions\n");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -1941,7 +1941,7 @@ static int sb_detect_vertex_collisionCached(float opco[3], float facenormal[3],
|
|||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
if ((deflected < 2)&& (G.rt != 444)) { /* we did not hit a face until now */
|
if ((deflected < 2)&& (G.debug_value != 444)) { /* we did not hit a face until now */
|
||||||
/* see if 'outer' hits an edge */
|
/* see if 'outer' hits an edge */
|
||||||
float dist;
|
float dist;
|
||||||
|
|
||||||
@@ -2493,7 +2493,7 @@ static void softbody_calc_forcesEx(Scene *scene, Object *ob, float forcetime, fl
|
|||||||
static void softbody_calc_forces(Scene *scene, Object *ob, float forcetime, float timenow, int nl_flags)
|
static void softbody_calc_forces(Scene *scene, Object *ob, float forcetime, float timenow, int nl_flags)
|
||||||
{
|
{
|
||||||
/* redirection to the new threaded Version */
|
/* redirection to the new threaded Version */
|
||||||
if (!(G.rt & 0x10)) { // 16
|
if (!(G.debug_value & 0x10)) { // 16
|
||||||
softbody_calc_forcesEx(scene, ob, forcetime, timenow, nl_flags);
|
softbody_calc_forcesEx(scene, ob, forcetime, timenow, nl_flags);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
@@ -2504,7 +2504,7 @@ static void softbody_calc_forces(Scene *scene, Object *ob, float forcetime, floa
|
|||||||
/*backward compatibility note:
|
/*backward compatibility note:
|
||||||
fixing bug [17428] which forces adaptive step size to tiny steps
|
fixing bug [17428] which forces adaptive step size to tiny steps
|
||||||
in some situations
|
in some situations
|
||||||
.. keeping G.rt==17 0x11 option for old files 'needing' the bug*/
|
.. keeping G.debug_value==17 0x11 option for old files 'needing' the bug*/
|
||||||
|
|
||||||
/* rule we never alter free variables :bp->vec bp->pos in here !
|
/* rule we never alter free variables :bp->vec bp->pos in here !
|
||||||
* this will ruin adaptive stepsize AKA heun! (BM)
|
* this will ruin adaptive stepsize AKA heun! (BM)
|
||||||
@@ -2756,9 +2756,9 @@ static void softbody_calc_forces(Scene *scene, Object *ob, float forcetime, floa
|
|||||||
|
|
||||||
if (sb_deflect_face(ob, bp->pos, facenormal, defforce, &cf, timenow, vel, &intrusion)) {
|
if (sb_deflect_face(ob, bp->pos, facenormal, defforce, &cf, timenow, vel, &intrusion)) {
|
||||||
if ((!nl_flags)&&(intrusion < 0.0f)) {
|
if ((!nl_flags)&&(intrusion < 0.0f)) {
|
||||||
if (G.rt & 0x01) { // 17 we did check for bit 0x10 before
|
if (G.debug_value & 0x01) { // 17 we did check for bit 0x10 before
|
||||||
/*fixing bug [17428] this forces adaptive step size to tiny steps
|
/*fixing bug [17428] this forces adaptive step size to tiny steps
|
||||||
in some situations .. keeping G.rt==17 option for old files 'needing' the bug
|
in some situations .. keeping G.debug_value==17 option for old files 'needing' the bug
|
||||||
*/
|
*/
|
||||||
/*bjornmose: uugh.. what an evil hack
|
/*bjornmose: uugh.. what an evil hack
|
||||||
violation of the 'don't touch bp->pos in here' rule
|
violation of the 'don't touch bp->pos in here' rule
|
||||||
@@ -2837,7 +2837,7 @@ static void softbody_calc_forces(Scene *scene, Object *ob, float forcetime, floa
|
|||||||
nlEnd(NL_MATRIX);
|
nlEnd(NL_MATRIX);
|
||||||
nlEnd(NL_SYSTEM);
|
nlEnd(NL_SYSTEM);
|
||||||
|
|
||||||
if ((G.rt == 32) && (nl_flags & NLF_BUILD)) {
|
if ((G.debug_value == 32) && (nl_flags & NLF_BUILD)) {
|
||||||
printf("####MEE#####\n");
|
printf("####MEE#####\n");
|
||||||
nlPrintMatrix();
|
nlPrintMatrix();
|
||||||
}
|
}
|
||||||
@@ -2849,7 +2849,7 @@ static void softbody_calc_forces(Scene *scene, Object *ob, float forcetime, floa
|
|||||||
float f;
|
float f;
|
||||||
int index =0;
|
int index =0;
|
||||||
/* for debug purpose .. anyhow cropping B vector looks like working */
|
/* for debug purpose .. anyhow cropping B vector looks like working */
|
||||||
if (G.rt ==32)
|
if (G.debug_value ==32)
|
||||||
for (a=2*sb->totpoint, bp= sb->bpoint; a>0; a--, bp++) {
|
for (a=2*sb->totpoint, bp= sb->bpoint; a>0; a--, bp++) {
|
||||||
f=nlGetVariable(0, index);
|
f=nlGetVariable(0, index);
|
||||||
printf("(%f ", f);index++;
|
printf("(%f ", f);index++;
|
||||||
|
|||||||
@@ -9430,7 +9430,7 @@ static void read_libraries(FileData *basefd, ListBase *mainlist)
|
|||||||
fd = blo_openblenderfile(mainptr->curlib->filepath, basefd->reports);
|
fd = blo_openblenderfile(mainptr->curlib->filepath, basefd->reports);
|
||||||
|
|
||||||
/* allow typing in a new lib path */
|
/* allow typing in a new lib path */
|
||||||
if (G.rt == -666) {
|
if (G.debug_value == -666) {
|
||||||
while (fd == NULL) {
|
while (fd == NULL) {
|
||||||
char newlib_path[FILE_MAX] = {0};
|
char newlib_path[FILE_MAX] = {0};
|
||||||
printf("Missing library...'\n");
|
printf("Missing library...'\n");
|
||||||
|
|||||||
@@ -502,7 +502,7 @@ void seam_mark_clear_tface(Scene *scene, short mode)
|
|||||||
BLI_edgehash_free(ehash2, NULL);
|
BLI_edgehash_free(ehash2, NULL);
|
||||||
}
|
}
|
||||||
|
|
||||||
// XXX if (G.rt == 8)
|
// XXX if (G.debug_value == 8)
|
||||||
// unwrap_lscm(1);
|
// unwrap_lscm(1);
|
||||||
|
|
||||||
me->drawflag |= ME_DRAWSEAMS;
|
me->drawflag |= ME_DRAWSEAMS;
|
||||||
|
|||||||
@@ -505,7 +505,7 @@ static int screen_render_invoke(bContext *C, wmOperator *op, wmEvent *event)
|
|||||||
WM_jobs_stop_all(CTX_wm_manager(C));
|
WM_jobs_stop_all(CTX_wm_manager(C));
|
||||||
|
|
||||||
/* get main */
|
/* get main */
|
||||||
if (G.rt == 101) {
|
if (G.debug_value == 101) {
|
||||||
/* thread-safety experiment, copy main from the undo buffer */
|
/* thread-safety experiment, copy main from the undo buffer */
|
||||||
mainp = BKE_undo_get_main(&scene);
|
mainp = BKE_undo_get_main(&scene);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -372,11 +372,11 @@ void ED_area_overdraw(bContext *C)
|
|||||||
if (az->ar) {
|
if (az->ar) {
|
||||||
/* only display tab or icons when the region is hidden */
|
/* only display tab or icons when the region is hidden */
|
||||||
if (az->ar->flag & (RGN_FLAG_HIDDEN | RGN_FLAG_TOO_SMALL)) {
|
if (az->ar->flag & (RGN_FLAG_HIDDEN | RGN_FLAG_TOO_SMALL)) {
|
||||||
if (G.rt == 3)
|
if (G.debug_value == 3)
|
||||||
region_draw_azone_icon(az);
|
region_draw_azone_icon(az);
|
||||||
else if (G.rt == 2)
|
else if (G.debug_value == 2)
|
||||||
region_draw_azone_tria(az);
|
region_draw_azone_tria(az);
|
||||||
else if (G.rt == 1)
|
else if (G.debug_value == 1)
|
||||||
region_draw_azone_tab(az);
|
region_draw_azone_tab(az);
|
||||||
else
|
else
|
||||||
region_draw_azone_tab_plus(az);
|
region_draw_azone_tab_plus(az);
|
||||||
@@ -858,11 +858,11 @@ static void region_azone_initialize(ScrArea *sa, ARegion *ar, AZEdge edge)
|
|||||||
az->edge = edge;
|
az->edge = edge;
|
||||||
|
|
||||||
if (ar->flag & (RGN_FLAG_HIDDEN | RGN_FLAG_TOO_SMALL)) {
|
if (ar->flag & (RGN_FLAG_HIDDEN | RGN_FLAG_TOO_SMALL)) {
|
||||||
if (G.rt == 3)
|
if (G.debug_value == 3)
|
||||||
region_azone_icon(sa, az, ar);
|
region_azone_icon(sa, az, ar);
|
||||||
else if (G.rt == 2)
|
else if (G.debug_value == 2)
|
||||||
region_azone_tria(sa, az, ar);
|
region_azone_tria(sa, az, ar);
|
||||||
else if (G.rt == 1)
|
else if (G.debug_value == 1)
|
||||||
region_azone_tab(sa, az, ar);
|
region_azone_tab(sa, az, ar);
|
||||||
else
|
else
|
||||||
region_azone_tab_plus(sa, az, ar);
|
region_azone_tab_plus(sa, az, ar);
|
||||||
@@ -1113,7 +1113,7 @@ static void region_rect_recursive(ScrArea *sa, ARegion *ar, rcti *remainder, int
|
|||||||
|
|
||||||
static void area_calc_totrct(ScrArea *sa, int sizex, int sizey)
|
static void area_calc_totrct(ScrArea *sa, int sizex, int sizey)
|
||||||
{
|
{
|
||||||
short rt = 0; // CLAMPIS(G.rt, 0, 16);
|
short rt = 0; // CLAMPIS(G.debug_value, 0, 16);
|
||||||
|
|
||||||
if (sa->v1->vec.x > 0) sa->totrct.xmin = sa->v1->vec.x + 1 + rt;
|
if (sa->v1->vec.x > 0) sa->totrct.xmin = sa->v1->vec.x + 1 + rt;
|
||||||
else sa->totrct.xmin = sa->v1->vec.x;
|
else sa->totrct.xmin = sa->v1->vec.x;
|
||||||
|
|||||||
@@ -913,7 +913,7 @@ static void drawscredge_area(ScrArea *sa, int sizex, int sizey, int center)
|
|||||||
short y2 = sa->v3->vec.y;
|
short y2 = sa->v3->vec.y;
|
||||||
short a, rt;
|
short a, rt;
|
||||||
|
|
||||||
rt = 0; // CLAMPIS(G.rt, 0, 16);
|
rt = 0; // CLAMPIS(G.debug_value, 0, 16);
|
||||||
|
|
||||||
if (center == 0) {
|
if (center == 0) {
|
||||||
cpack(0x505050);
|
cpack(0x505050);
|
||||||
|
|||||||
@@ -4783,7 +4783,7 @@ void logic_buttons(bContext *C, ARegion *ar)
|
|||||||
* pin so changing states dosnt hide the logic brick */
|
* pin so changing states dosnt hide the logic brick */
|
||||||
char pin;
|
char pin;
|
||||||
|
|
||||||
if (G.rt == 0) {
|
if (G.debug_value == 0) {
|
||||||
logic_buttons_new(C, ar);
|
logic_buttons_new(C, ar);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -136,7 +136,7 @@ static int node_sockets_poll(const bContext *C, PanelType *UNUSED(pt))
|
|||||||
{
|
{
|
||||||
SpaceNode *snode = CTX_wm_space_node(C);
|
SpaceNode *snode = CTX_wm_space_node(C);
|
||||||
|
|
||||||
return (snode && snode->nodetree && G.rt == 777);
|
return (snode && snode->nodetree && G.debug_value == 777);
|
||||||
}
|
}
|
||||||
|
|
||||||
static void node_sockets_panel(const bContext *C, Panel *pa)
|
static void node_sockets_panel(const bContext *C, Panel *pa)
|
||||||
|
|||||||
@@ -1532,7 +1532,7 @@ exit:
|
|||||||
/* ************************************************************* */
|
/* ************************************************************* */
|
||||||
|
|
||||||
static void view3d_draw_bgpic(Scene *scene, ARegion *ar, View3D *v3d,
|
static void view3d_draw_bgpic(Scene *scene, ARegion *ar, View3D *v3d,
|
||||||
const short do_forground, const short do_camera_frame)
|
const short do_foreground, const short do_camera_frame)
|
||||||
{
|
{
|
||||||
RegionView3D *rv3d = ar->regiondata;
|
RegionView3D *rv3d = ar->regiondata;
|
||||||
BGpic *bgpic;
|
BGpic *bgpic;
|
||||||
@@ -1541,7 +1541,7 @@ static void view3d_draw_bgpic(Scene *scene, ARegion *ar, View3D *v3d,
|
|||||||
ImBuf *ibuf = NULL, *freeibuf;
|
ImBuf *ibuf = NULL, *freeibuf;
|
||||||
float vec[4], fac, asp, zoomx, zoomy;
|
float vec[4], fac, asp, zoomx, zoomy;
|
||||||
float x1, y1, x2, y2, cx, cy;
|
float x1, y1, x2, y2, cx, cy;
|
||||||
int fg_flag = do_forground ? V3D_BGPIC_FOREGROUND : 0;
|
int fg_flag = do_foreground ? V3D_BGPIC_FOREGROUND : 0;
|
||||||
|
|
||||||
for (bgpic = v3d->bgpicbase.first; bgpic; bgpic = bgpic->next) {
|
for (bgpic = v3d->bgpicbase.first; bgpic; bgpic = bgpic->next) {
|
||||||
|
|
||||||
@@ -1772,7 +1772,7 @@ static void view3d_draw_bgpic(Scene *scene, ARegion *ar, View3D *v3d,
|
|||||||
}
|
}
|
||||||
|
|
||||||
static void view3d_draw_bgpic_test(Scene *scene, ARegion *ar, View3D *v3d,
|
static void view3d_draw_bgpic_test(Scene *scene, ARegion *ar, View3D *v3d,
|
||||||
const short do_forground, const short do_camera_frame)
|
const short do_foreground, const short do_camera_frame)
|
||||||
{
|
{
|
||||||
RegionView3D *rv3d = ar->regiondata;
|
RegionView3D *rv3d = ar->regiondata;
|
||||||
|
|
||||||
@@ -1788,11 +1788,11 @@ static void view3d_draw_bgpic_test(Scene *scene, ARegion *ar, View3D *v3d,
|
|||||||
|
|
||||||
if ((rv3d->view == RV3D_VIEW_USER) || (rv3d->persp != RV3D_ORTHO)) {
|
if ((rv3d->view == RV3D_VIEW_USER) || (rv3d->persp != RV3D_ORTHO)) {
|
||||||
if (rv3d->persp == RV3D_CAMOB) {
|
if (rv3d->persp == RV3D_CAMOB) {
|
||||||
view3d_draw_bgpic(scene, ar, v3d, do_forground, do_camera_frame);
|
view3d_draw_bgpic(scene, ar, v3d, do_foreground, do_camera_frame);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
view3d_draw_bgpic(scene, ar, v3d, do_forground, do_camera_frame);
|
view3d_draw_bgpic(scene, ar, v3d, do_foreground, do_camera_frame);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -855,7 +855,7 @@ static void draw_manipulator_rotate(View3D *v3d, RegionView3D *rv3d, int moving,
|
|||||||
float size, unitmat[4][4];
|
float size, unitmat[4][4];
|
||||||
float cywid = 0.33f * 0.01f * (float)U.tw_handlesize;
|
float cywid = 0.33f * 0.01f * (float)U.tw_handlesize;
|
||||||
float cusize = cywid * 0.65f;
|
float cusize = cywid * 0.65f;
|
||||||
int arcs = (G.rt != 2);
|
int arcs = (G.debug_value != 2);
|
||||||
int colcode;
|
int colcode;
|
||||||
int ortho;
|
int ortho;
|
||||||
|
|
||||||
@@ -1517,7 +1517,7 @@ void BIF_draw_manipulator(const bContext *C)
|
|||||||
glEnable(GL_BLEND);
|
glEnable(GL_BLEND);
|
||||||
if (v3d->twtype & V3D_MANIP_ROTATE) {
|
if (v3d->twtype & V3D_MANIP_ROTATE) {
|
||||||
|
|
||||||
if (G.rt == 3) {
|
if (G.debug_value == 3) {
|
||||||
if (G.moving) draw_manipulator_rotate_cyl(v3d, rv3d, 1, drawflags, v3d->twtype, MAN_MOVECOL);
|
if (G.moving) draw_manipulator_rotate_cyl(v3d, rv3d, 1, drawflags, v3d->twtype, MAN_MOVECOL);
|
||||||
else draw_manipulator_rotate_cyl(v3d, rv3d, 0, drawflags, v3d->twtype, MAN_RGB);
|
else draw_manipulator_rotate_cyl(v3d, rv3d, 0, drawflags, v3d->twtype, MAN_RGB);
|
||||||
}
|
}
|
||||||
@@ -1561,7 +1561,7 @@ static int manipulator_selectbuf(ScrArea *sa, ARegion *ar, const int mval[2], fl
|
|||||||
|
|
||||||
/* do the drawing */
|
/* do the drawing */
|
||||||
if (v3d->twtype & V3D_MANIP_ROTATE) {
|
if (v3d->twtype & V3D_MANIP_ROTATE) {
|
||||||
if (G.rt == 3) draw_manipulator_rotate_cyl(v3d, rv3d, 0, MAN_ROT_C & rv3d->twdrawflag, v3d->twtype, MAN_RGB);
|
if (G.debug_value == 3) draw_manipulator_rotate_cyl(v3d, rv3d, 0, MAN_ROT_C & rv3d->twdrawflag, v3d->twtype, MAN_RGB);
|
||||||
else draw_manipulator_rotate(v3d, rv3d, 0, MAN_ROT_C & rv3d->twdrawflag, v3d->twtype);
|
else draw_manipulator_rotate(v3d, rv3d, 0, MAN_ROT_C & rv3d->twdrawflag, v3d->twtype);
|
||||||
}
|
}
|
||||||
if (v3d->twtype & V3D_MANIP_SCALE)
|
if (v3d->twtype & V3D_MANIP_SCALE)
|
||||||
|
|||||||
@@ -169,7 +169,7 @@ static void freeData(ModifierData *md)
|
|||||||
ClothModifierData *clmd = (ClothModifierData *) md;
|
ClothModifierData *clmd = (ClothModifierData *) md;
|
||||||
|
|
||||||
if (clmd) {
|
if (clmd) {
|
||||||
if (G.rt > 0)
|
if (G.debug_value > 0)
|
||||||
printf("clothModifier_freeData\n");
|
printf("clothModifier_freeData\n");
|
||||||
|
|
||||||
cloth_free_modifier_extern(clmd);
|
cloth_free_modifier_extern(clmd);
|
||||||
|
|||||||
@@ -132,7 +132,7 @@ static void deformVerts(ModifierData *md, Object *ob,
|
|||||||
|
|
||||||
current_time = BKE_scene_frame_get(md->scene);
|
current_time = BKE_scene_frame_get(md->scene);
|
||||||
|
|
||||||
if (G.rt > 0)
|
if (G.debug_value > 0)
|
||||||
printf("current_time %f, collmd->time_xnew %f\n", current_time, collmd->time_xnew);
|
printf("current_time %f, collmd->time_xnew %f\n", current_time, collmd->time_xnew);
|
||||||
|
|
||||||
numverts = dm->getNumVerts(dm);
|
numverts = dm->getNumVerts(dm);
|
||||||
|
|||||||
@@ -274,7 +274,7 @@ static void meshdeformModifier_do(
|
|||||||
/* get cage vertex in world space with binding transform */
|
/* get cage vertex in world space with binding transform */
|
||||||
copy_v3_v3(co, cagecos[a]);
|
copy_v3_v3(co, cagecos[a]);
|
||||||
|
|
||||||
if (G.rt != 527) {
|
if (G.debug_value != 527) {
|
||||||
mul_m4_v3(mmd->bindmat, co);
|
mul_m4_v3(mmd->bindmat, co);
|
||||||
/* compute difference with world space bind coord */
|
/* compute difference with world space bind coord */
|
||||||
sub_v3_v3v3(dco[a], co, bindcagecos[a]);
|
sub_v3_v3v3(dco[a], co, bindcagecos[a]);
|
||||||
@@ -324,7 +324,7 @@ static void meshdeformModifier_do(
|
|||||||
if (totweight > 0.0f) {
|
if (totweight > 0.0f) {
|
||||||
mul_v3_fl(co, fac / totweight);
|
mul_v3_fl(co, fac / totweight);
|
||||||
mul_m3_v3(icagemat, co);
|
mul_m3_v3(icagemat, co);
|
||||||
if (G.rt != 527)
|
if (G.debug_value != 527)
|
||||||
add_v3_v3(vertexCos[b], co);
|
add_v3_v3(vertexCos[b], co);
|
||||||
else
|
else
|
||||||
copy_v3_v3(vertexCos[b], co);
|
copy_v3_v3(vertexCos[b], co);
|
||||||
|
|||||||
@@ -692,7 +692,7 @@ void *COM_linker_hack = NULL;
|
|||||||
void ntreeCompositExecTree(bNodeTree *ntree, RenderData *rd, int rendering, int do_preview)
|
void ntreeCompositExecTree(bNodeTree *ntree, RenderData *rd, int rendering, int do_preview)
|
||||||
{
|
{
|
||||||
#ifdef WITH_COMPOSITOR
|
#ifdef WITH_COMPOSITOR
|
||||||
if (G.rt == 200)
|
if (G.debug_value == 200)
|
||||||
ntreeCompositExecTreeOld(ntree, rd, do_preview);
|
ntreeCompositExecTreeOld(ntree, rd, do_preview);
|
||||||
else
|
else
|
||||||
COM_execute(rd, ntree, rendering);
|
COM_execute(rd, ntree, rendering);
|
||||||
|
|||||||
@@ -195,7 +195,7 @@ PyDoc_STRVAR(bpy_app_debug_value_doc,
|
|||||||
);
|
);
|
||||||
static PyObject *bpy_app_debug_value_get(PyObject *UNUSED(self), void *UNUSED(closure))
|
static PyObject *bpy_app_debug_value_get(PyObject *UNUSED(self), void *UNUSED(closure))
|
||||||
{
|
{
|
||||||
return PyLong_FromSsize_t(G.rt);
|
return PyLong_FromSsize_t(G.debug_value);
|
||||||
}
|
}
|
||||||
|
|
||||||
static int bpy_app_debug_value_set(PyObject *UNUSED(self), PyObject *value, void *UNUSED(closure))
|
static int bpy_app_debug_value_set(PyObject *UNUSED(self), PyObject *value, void *UNUSED(closure))
|
||||||
@@ -207,7 +207,7 @@ static int bpy_app_debug_value_set(PyObject *UNUSED(self), PyObject *value, void
|
|||||||
return -1;
|
return -1;
|
||||||
}
|
}
|
||||||
|
|
||||||
G.rt = param;
|
G.debug_value = param;
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1194,7 +1194,7 @@ int WM_operator_redo_popup(bContext *C, wmOperator *op)
|
|||||||
|
|
||||||
static int wm_debug_menu_exec(bContext *C, wmOperator *op)
|
static int wm_debug_menu_exec(bContext *C, wmOperator *op)
|
||||||
{
|
{
|
||||||
G.rt = RNA_int_get(op->ptr, "debug_value");
|
G.debug_value = RNA_int_get(op->ptr, "debug_value");
|
||||||
ED_screen_refresh(CTX_wm_manager(C), CTX_wm_window(C));
|
ED_screen_refresh(CTX_wm_manager(C), CTX_wm_window(C));
|
||||||
WM_event_add_notifier(C, NC_WINDOW, NULL);
|
WM_event_add_notifier(C, NC_WINDOW, NULL);
|
||||||
|
|
||||||
@@ -1203,7 +1203,7 @@ static int wm_debug_menu_exec(bContext *C, wmOperator *op)
|
|||||||
|
|
||||||
static int wm_debug_menu_invoke(bContext *C, wmOperator *op, wmEvent *UNUSED(event))
|
static int wm_debug_menu_invoke(bContext *C, wmOperator *op, wmEvent *UNUSED(event))
|
||||||
{
|
{
|
||||||
RNA_int_set(op->ptr, "debug_value", G.rt);
|
RNA_int_set(op->ptr, "debug_value", G.debug_value);
|
||||||
return WM_operator_props_dialog_popup(C, op, 9 * UI_UNIT_X, UI_UNIT_Y);
|
return WM_operator_props_dialog_popup(C, op, 9 * UI_UNIT_X, UI_UNIT_Y);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -390,7 +390,7 @@ static int debug_mode_libmv(int UNUSED(argc), const char **UNUSED(argv), void *U
|
|||||||
static int set_debug_value(int argc, const char **argv, void *UNUSED(data))
|
static int set_debug_value(int argc, const char **argv, void *UNUSED(data))
|
||||||
{
|
{
|
||||||
if (argc > 1) {
|
if (argc > 1) {
|
||||||
G.rt = atoi(argv[1]);
|
G.debug_value = atoi(argv[1]);
|
||||||
|
|
||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user