code cleanup: rename G.afbreek --> is_break, G.rendering --> is_rendering
This commit is contained in:
@@ -527,7 +527,7 @@ int cocoa_request_qtcodec_settings(bContext *C, wmOperator *op)
|
||||
// So WM_exit needs to be called directly, as the event loop will never run before termination
|
||||
- (void)applicationWillTerminate:(NSNotification *)aNotification
|
||||
{
|
||||
/*G.afbreek = 0; //Let Cocoa perform the termination at the end
|
||||
/*G.is_break = FALSE; //Let Cocoa perform the termination at the end
|
||||
WM_exit(C);*/
|
||||
}
|
||||
|
||||
|
||||
@@ -61,11 +61,16 @@ typedef struct Global {
|
||||
/* strings of recent opened files */
|
||||
struct ListBase recent_files;
|
||||
|
||||
short afbreek, moving, file_loaded;
|
||||
/* has escape been pressed or Ctrl+C pressed in background mode, used for render quit */
|
||||
short is_break;
|
||||
|
||||
short moving, file_loaded;
|
||||
char background;
|
||||
char factory_startup;
|
||||
short winpos, displaymode; /* used to be in Render */
|
||||
short rendering; /* to indicate render is busy, prevent renderwindow events etc */
|
||||
|
||||
/* to indicate render is busy, prevent renderwindow events etc */
|
||||
short is_rendering;
|
||||
|
||||
/* debug value, can be set from the UI and python, used for testing nonstandard features */
|
||||
short debug_value;
|
||||
@@ -129,7 +134,7 @@ enum {
|
||||
G_DEBUG_JOBS = (1 << 5) /* jobs time profiling */
|
||||
};
|
||||
|
||||
#define G_DEBUG_ALL (G_DEBUG | G_DEBUG_FFMPEG | G_DEBUG_PYTHON | G_DEBUG_EVENTS | G_DEBUG_WM)
|
||||
#define G_DEBUG_ALL (G_DEBUG | G_DEBUG_FFMPEG | G_DEBUG_PYTHON | G_DEBUG_EVENTS | G_DEBUG_WM | G_DEBUG_JOBS)
|
||||
|
||||
|
||||
/* G.fileflags */
|
||||
|
||||
@@ -755,8 +755,8 @@ static void group_duplilist(ListBase *lb, Scene *scene, Object *ob, int par_inde
|
||||
|
||||
/* check the group instance and object layers match, also that the object visible flags are ok. */
|
||||
if ((dob->origlay & group->layer) == 0 ||
|
||||
(G.rendering == 0 && dob->ob->restrictflag & OB_RESTRICT_VIEW) ||
|
||||
(G.rendering && dob->ob->restrictflag & OB_RESTRICT_RENDER))
|
||||
((G.is_rendering == FALSE) && dob->ob->restrictflag & OB_RESTRICT_VIEW) ||
|
||||
((G.is_rendering == TRUE) && dob->ob->restrictflag & OB_RESTRICT_RENDER))
|
||||
{
|
||||
dob->no_draw = TRUE;
|
||||
}
|
||||
@@ -934,7 +934,7 @@ static void vertex_duplilist(ListBase *lb, ID *id, Scene *scene, Object *par, fl
|
||||
else
|
||||
dm = mesh_get_derived_deform(scene, par, CD_MASK_BAREMESH);
|
||||
|
||||
if (G.rendering) {
|
||||
if (G.is_rendering) {
|
||||
vdd.orco = (float(*)[3])BKE_mesh_orco_verts_get(par);
|
||||
BKE_mesh_orco_verts_transform(me, vdd.orco, me->totvert, 0);
|
||||
}
|
||||
@@ -1066,7 +1066,7 @@ static void face_duplilist(ListBase *lb, ID *id, Scene *scene, Object *par, floa
|
||||
mloop = dm->getLoopArray(dm);
|
||||
mvert = dm->getVertArray(dm);
|
||||
|
||||
if (G.rendering) {
|
||||
if (G.is_rendering) {
|
||||
|
||||
orco = (float(*)[3])BKE_mesh_orco_verts_get(par);
|
||||
BKE_mesh_orco_verts_transform(me, orco, me->totvert, 0);
|
||||
@@ -1177,7 +1177,7 @@ static void face_duplilist(ListBase *lb, ID *id, Scene *scene, Object *par, floa
|
||||
mul_m4_m4m3(obmat, tmat, mat);
|
||||
|
||||
dob = new_dupli_object(lb, ob, obmat, par->lay, a, par_index, OB_DUPLIFACES, animated);
|
||||
if (G.rendering) {
|
||||
if (G.is_rendering) {
|
||||
w = 1.0f / (float)mp->totloop;
|
||||
|
||||
if (orco) {
|
||||
@@ -1251,7 +1251,7 @@ static void new_particle_duplilist(ListBase *lb, ID *id, Scene *scene, Object *p
|
||||
if (!psys_check_enabled(par, psys))
|
||||
return;
|
||||
|
||||
if (G.rendering == 0)
|
||||
if (G.is_rendering == FALSE)
|
||||
no_draw_flag |= PARS_NO_DISP;
|
||||
|
||||
ctime = BKE_scene_frame_get(scene); /* NOTE: in old animsys, used parent object's timeoffset... */
|
||||
@@ -1445,7 +1445,7 @@ static void new_particle_duplilist(ListBase *lb, ID *id, Scene *scene, Object *p
|
||||
|
||||
dob = new_dupli_object(lb, go->ob, mat, par->lay, counter, index, OB_DUPLIPARTS, animated);
|
||||
copy_m4_m4(dob->omat, obcopylist[b].obmat);
|
||||
if (G.rendering)
|
||||
if (G.is_rendering)
|
||||
psys_get_dupli_texture(psys, part, sim.psmd, pa, cpa, dob->uv, dob->orco);
|
||||
}
|
||||
}
|
||||
@@ -1493,7 +1493,7 @@ static void new_particle_duplilist(ListBase *lb, ID *id, Scene *scene, Object *p
|
||||
|
||||
dob = new_dupli_object(lb, ob, mat, ob->lay, counter, index, GS(id->name) == ID_GR ? OB_DUPLIGROUP : OB_DUPLIPARTS, animated);
|
||||
copy_m4_m4(dob->omat, oldobmat);
|
||||
if (G.rendering)
|
||||
if (G.is_rendering)
|
||||
psys_get_dupli_texture(psys, part, sim.psmd, pa, cpa, dob->uv, dob->orco);
|
||||
}
|
||||
|
||||
@@ -1599,7 +1599,7 @@ static void object_duplilist_recursive(ID *id, Scene *scene, Object *ob, ListBas
|
||||
return;
|
||||
|
||||
/* Should the dupli's be generated for this object? - Respect restrict flags */
|
||||
if (G.rendering) {
|
||||
if (G.is_rendering) {
|
||||
if (ob->restrictflag & OB_RESTRICT_RENDER) {
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -457,7 +457,7 @@ int blender_test_break(void)
|
||||
blender_test_break_cb();
|
||||
}
|
||||
|
||||
return (G.afbreek == 1);
|
||||
return (G.is_break == TRUE);
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -2222,7 +2222,7 @@ void BKE_curve_bevelList_make(Object *ob)
|
||||
bl->nr = 0;
|
||||
}
|
||||
else {
|
||||
if (G.rendering && cu->resolu_ren != 0)
|
||||
if (G.is_rendering && cu->resolu_ren != 0)
|
||||
resolu = cu->resolu_ren;
|
||||
else
|
||||
resolu = nu->resolu;
|
||||
|
||||
@@ -677,7 +677,7 @@ void BKE_displist_make_mball(Scene *scene, Object *ob)
|
||||
/* XXX: mball stuff uses plenty of global variables
|
||||
* while this is unchanged updating during render is unsafe
|
||||
*/
|
||||
if (G.rendering)
|
||||
if (G.is_rendering)
|
||||
return;
|
||||
|
||||
BKE_displist_free(&(ob->disp));
|
||||
|
||||
@@ -741,7 +741,7 @@ void free_old_images(void)
|
||||
return;
|
||||
|
||||
/* of course not! */
|
||||
if (G.rendering)
|
||||
if (G.is_rendering)
|
||||
return;
|
||||
|
||||
lasttime = ctime;
|
||||
|
||||
@@ -2288,7 +2288,7 @@ void BKE_mball_polygonize(Scene *scene, Object *ob, ListBase *dispbase)
|
||||
mb = ob->data;
|
||||
|
||||
if (totelem == 0) return;
|
||||
if (!(G.rendering) && (mb->flag == MB_UPDATE_NEVER)) return;
|
||||
if ((G.is_rendering == FALSE) && (mb->flag == MB_UPDATE_NEVER)) return;
|
||||
if (G.moving && mb->flag == MB_UPDATE_FAST) return;
|
||||
|
||||
curindex = totindex = 0;
|
||||
@@ -2335,7 +2335,7 @@ void BKE_mball_polygonize(Scene *scene, Object *ob, ListBase *dispbase)
|
||||
}
|
||||
|
||||
/* width is size per polygonize cube */
|
||||
if (G.rendering) width = mb->rendersize;
|
||||
if (G.is_rendering) width = mb->rendersize;
|
||||
else {
|
||||
width = mb->wiresize;
|
||||
if (G.moving && mb->flag == MB_UPDATE_HALFRES) width *= 2;
|
||||
|
||||
@@ -2643,7 +2643,7 @@ void BKE_object_handle_update(Scene *scene, Object *ob)
|
||||
while (psys) {
|
||||
if (psys_check_enabled(ob, psys)) {
|
||||
/* check use of dupli objects here */
|
||||
if (psys->part && (psys->part->draw_as == PART_DRAW_REND || G.rendering) &&
|
||||
if (psys->part && (psys->part->draw_as == PART_DRAW_REND || G.is_rendering) &&
|
||||
((psys->part->ren_as == PART_DRAW_OB && psys->part->dup_ob) ||
|
||||
(psys->part->ren_as == PART_DRAW_GR && psys->part->dup_group)))
|
||||
{
|
||||
@@ -2663,7 +2663,7 @@ void BKE_object_handle_update(Scene *scene, Object *ob)
|
||||
psys = psys->next;
|
||||
}
|
||||
|
||||
if (G.rendering && ob->transflag & OB_DUPLIPARTS) {
|
||||
if (G.is_rendering && ob->transflag & OB_DUPLIPARTS) {
|
||||
/* this is to make sure we get render level duplis in groups:
|
||||
* the derivedmesh must be created before init_render_mesh,
|
||||
* since object_duplilist does dupliparticles before that */
|
||||
|
||||
@@ -276,7 +276,7 @@ int psys_check_enabled(Object *ob, ParticleSystem *psys)
|
||||
return 0;
|
||||
|
||||
psmd = psys_get_modifier(ob, psys);
|
||||
if (psys->renderdata || G.rendering) {
|
||||
if (psys->renderdata || G.is_rendering) {
|
||||
if (!(psmd->modifier.mode & eModifierMode_Render))
|
||||
return 0;
|
||||
}
|
||||
@@ -681,7 +681,7 @@ void psys_render_set(Object *ob, ParticleSystem *psys, float viewmat[][4], float
|
||||
ParticleRenderData *data;
|
||||
ParticleSystemModifierData *psmd = psys_get_modifier(ob, psys);
|
||||
|
||||
if (!G.rendering)
|
||||
if (G.is_rendering == FALSE)
|
||||
return;
|
||||
if (psys->renderdata)
|
||||
return;
|
||||
@@ -2356,7 +2356,7 @@ void psys_find_parents(ParticleSimulationData *sim)
|
||||
int from = PART_FROM_FACE;
|
||||
totparent = (int)(totchild * part->parents * 0.3f);
|
||||
|
||||
if (G.rendering && part->child_nbr && part->ren_child_nbr)
|
||||
if (G.is_rendering && part->child_nbr && part->ren_child_nbr)
|
||||
totparent *= (float)part->child_nbr / (float)part->ren_child_nbr;
|
||||
|
||||
tree = BLI_kdtree_new(totparent);
|
||||
@@ -2433,7 +2433,7 @@ static int psys_threads_init_path(ParticleThread *threads, Scene *scene, float c
|
||||
if (totchild && part->childtype == PART_CHILD_FACES) {
|
||||
totparent = (int)(totchild * part->parents * 0.3f);
|
||||
|
||||
if (G.rendering && part->child_nbr && part->ren_child_nbr)
|
||||
if (G.is_rendering && part->child_nbr && part->ren_child_nbr)
|
||||
totparent *= (float)part->child_nbr / (float)part->ren_child_nbr;
|
||||
|
||||
/* part->parents could still be 0 so we can't test with totparent */
|
||||
|
||||
@@ -4104,7 +4104,7 @@ static void particles_fluid_step(ParticleSimulationData *sim, int UNUSED(cfra))
|
||||
}
|
||||
|
||||
gzread(gzf, &totpart, sizeof(totpart));
|
||||
totpart = (G.rendering)?totpart:(part->disp*totpart)/100;
|
||||
totpart = (G.is_rendering)?totpart:(part->disp*totpart) / 100;
|
||||
|
||||
part->totpart= totpart;
|
||||
part->sta=part->end = 1.0f;
|
||||
|
||||
@@ -2807,7 +2807,7 @@ void BKE_ptcache_bake(PTCacheBaker* baker)
|
||||
thread_data.scene = baker->scene;
|
||||
thread_data.main = baker->main;
|
||||
|
||||
G.afbreek = 0;
|
||||
G.is_break = FALSE;
|
||||
|
||||
/* set caches to baking mode and figure out start frame */
|
||||
if (pid) {
|
||||
|
||||
@@ -1329,7 +1329,7 @@ void BKE_sequencer_proxy_rebuild(SeqIndexBuildContext *context, short *stop, sho
|
||||
*progress = (float) cfra / (seq->enddisp - seq->endstill - seq->startdisp + seq->startstill);
|
||||
*do_update = TRUE;
|
||||
|
||||
if (*stop || G.afbreek)
|
||||
if (*stop || G.is_break)
|
||||
break;
|
||||
}
|
||||
}
|
||||
@@ -2127,7 +2127,7 @@ static ImBuf *seq_render_scene_strip(SeqRenderData context, Sequence *seq, float
|
||||
* for display in render/imagewindow
|
||||
*
|
||||
* Hmm, don't see, why we can't do that all the time,
|
||||
* and since G.rendering is uhm, gone... (Peter)
|
||||
* and since G.is_rendering is uhm, gone... (Peter)
|
||||
*/
|
||||
|
||||
/* New info:
|
||||
@@ -2148,9 +2148,9 @@ static ImBuf *seq_render_scene_strip(SeqRenderData context, Sequence *seq, float
|
||||
* -jahka
|
||||
*/
|
||||
|
||||
int rendering = G.rendering;
|
||||
int rendering = G.is_rendering;
|
||||
int doseq;
|
||||
int doseq_gl = G.rendering ? /*(scene->r.seq_flag & R_SEQ_GL_REND)*/ 0 : /*(scene->r.seq_flag & R_SEQ_GL_PREV)*/ 1;
|
||||
int doseq_gl = G.is_rendering ? /*(scene->r.seq_flag & R_SEQ_GL_REND)*/ 0 : /*(scene->r.seq_flag & R_SEQ_GL_PREV)*/ 1;
|
||||
int have_seq = FALSE;
|
||||
Scene *scene;
|
||||
|
||||
@@ -2218,7 +2218,7 @@ static ImBuf *seq_render_scene_strip(SeqRenderData context, Sequence *seq, float
|
||||
RE_BlenderFrame(re, context.bmain, scene, NULL, camera, scene->lay, frame, FALSE);
|
||||
|
||||
/* restore previous state after it was toggled on & off by RE_BlenderFrame */
|
||||
G.rendering = rendering;
|
||||
G.is_rendering = rendering;
|
||||
}
|
||||
|
||||
RE_AcquireResultImage(re, &rres);
|
||||
|
||||
@@ -252,7 +252,7 @@ static int handle_request(RenderData *rd, char *req)
|
||||
}
|
||||
if (strcmp(path, "/close.txt") == 0) {
|
||||
safe_puts(good_bye);
|
||||
G.afbreek = 1; /* Abort render */
|
||||
G.is_break = TRUE; /* Abort render */
|
||||
return -1;
|
||||
}
|
||||
return -1;
|
||||
|
||||
@@ -283,7 +283,7 @@ AnimData *ANIM_nla_mapping_get(bAnimContext *ac, bAnimListElem *ale)
|
||||
return NULL;
|
||||
|
||||
/* abort if rendering - we may get some race condition issues... */
|
||||
if (G.rendering) return NULL;
|
||||
if (G.is_rendering) return NULL;
|
||||
|
||||
/* handling depends on the type of animation-context we've got */
|
||||
if (ale)
|
||||
@@ -422,7 +422,7 @@ void ANIM_unit_mapping_apply_fcurve(Scene *scene, ID *id, FCurve *fcu, short fla
|
||||
float fac;
|
||||
|
||||
/* abort if rendering - we may get some race condition issues... */
|
||||
if (G.rendering) return;
|
||||
if (G.is_rendering) return;
|
||||
|
||||
/* calculate mapping factor, and abort if nothing to change */
|
||||
fac = ANIM_unit_mapping_get_factor(scene, id, fcu, (flag & ANIM_UNITCONV_RESTORE));
|
||||
|
||||
@@ -65,7 +65,7 @@ static int change_frame_poll(bContext *C)
|
||||
ScrArea *curarea = CTX_wm_area(C);
|
||||
|
||||
/* XXX temp? prevent changes during render */
|
||||
if (G.rendering) return 0;
|
||||
if (G.is_rendering) return 0;
|
||||
|
||||
/* as long as there is an active area, and it isn't a Graph Editor
|
||||
* (since the Graph Editor has its own version which does extra stuff),
|
||||
|
||||
@@ -2562,7 +2562,7 @@ static void do_running_jobs(bContext *C, void *UNUSED(arg), int event)
|
||||
{
|
||||
switch (event) {
|
||||
case B_STOPRENDER:
|
||||
G.afbreek = 1;
|
||||
G.is_break = TRUE;
|
||||
break;
|
||||
case B_STOPCAST:
|
||||
WM_jobs_stop(CTX_wm_manager(C), CTX_wm_screen(C), NULL);
|
||||
|
||||
@@ -358,7 +358,7 @@ static int multiresbake_test_break(MultiresBakeRender *bkr)
|
||||
return 0;
|
||||
}
|
||||
|
||||
return G.afbreek;
|
||||
return G.is_break;
|
||||
}
|
||||
|
||||
static void do_multires_bake(MultiresBakeRender *bkr, Image *ima, MPassKnownData passKnownData,
|
||||
@@ -1260,7 +1260,7 @@ static int multiresbake_image_exec(bContext *C, wmOperator *op)
|
||||
WM_jobs_timer(steve, 0.2, NC_IMAGE, 0); /* TODO - only draw bake image, can we enforce this */
|
||||
WM_jobs_callbacks(steve, multiresbake_startjob, NULL, NULL, NULL);
|
||||
|
||||
G.afbreek = 0;
|
||||
G.is_break = FALSE;
|
||||
|
||||
WM_jobs_start(CTX_wm_manager(C), steve);
|
||||
WM_cursor_wait(0);
|
||||
@@ -1276,7 +1276,7 @@ static int multiresbake_image_exec(bContext *C, wmOperator *op)
|
||||
/* threaded break test */
|
||||
static int thread_break(void *UNUSED(arg))
|
||||
{
|
||||
return G.afbreek;
|
||||
return G.is_break;
|
||||
}
|
||||
|
||||
typedef struct BakeRender {
|
||||
@@ -1401,7 +1401,7 @@ static void bake_startjob(void *bkv, short *stop, short *do_update, float *progr
|
||||
bkr->progress = progress;
|
||||
|
||||
RE_test_break_cb(bkr->re, NULL, thread_break);
|
||||
G.afbreek = 0; /* blender_test_break uses this global */
|
||||
G.is_break = FALSE; /* blender_test_break uses this global */
|
||||
|
||||
RE_Database_Baking(bkr->re, bmain, scene, scene->lay, scene->r.bake_mode, bkr->actob);
|
||||
|
||||
@@ -1431,7 +1431,7 @@ static void bake_freejob(void *bkv)
|
||||
BKE_report(bkr->reports, RPT_WARNING, "Feedback loop detected");
|
||||
|
||||
MEM_freeN(bkr);
|
||||
G.rendering = 0;
|
||||
G.is_rendering = FALSE;
|
||||
}
|
||||
|
||||
/* catch esc */
|
||||
@@ -1487,8 +1487,8 @@ static int objects_bake_render_invoke(bContext *C, wmOperator *op, wmEvent *UNUS
|
||||
WM_jobs_timer(steve, 0.2, NC_IMAGE, 0); /* TODO - only draw bake image, can we enforce this */
|
||||
WM_jobs_callbacks(steve, bake_startjob, NULL, bake_update, NULL);
|
||||
|
||||
G.afbreek = 0;
|
||||
G.rendering = 1;
|
||||
G.is_break = FALSE;
|
||||
G.is_rendering = TRUE;
|
||||
|
||||
WM_jobs_start(CTX_wm_manager(C), steve);
|
||||
|
||||
@@ -1528,7 +1528,7 @@ static int bake_image_exec(bContext *C, wmOperator *op)
|
||||
bkr.reports = op->reports;
|
||||
|
||||
RE_test_break_cb(bkr.re, NULL, thread_break);
|
||||
G.afbreek = 0; /* blender_test_break uses this global */
|
||||
G.is_break = FALSE; /* blender_test_break uses this global */
|
||||
|
||||
RE_Database_Baking(bkr.re, bmain, scene, scene->lay, scene->r.bake_mode, (scene->r.bake_flag & R_BAKE_TO_ACTIVE) ? OBACT : NULL);
|
||||
|
||||
|
||||
@@ -2060,7 +2060,7 @@ static int oceanbake_breakjob(void *UNUSED(customdata))
|
||||
/* this is not nice yet, need to make the jobs list template better
|
||||
* for identifying/acting upon various different jobs */
|
||||
/* but for now we'll reuse the render break... */
|
||||
return (G.afbreek);
|
||||
return (G.is_break);
|
||||
}
|
||||
|
||||
/* called by oceanbake, wmJob sends notifier */
|
||||
@@ -2083,7 +2083,7 @@ static void oceanbake_startjob(void *customdata, short *stop, short *do_update,
|
||||
oj->do_update = do_update;
|
||||
oj->progress = progress;
|
||||
|
||||
G.afbreek = 0; /* XXX shared with render - replace with job 'stop' switch */
|
||||
G.is_break = FALSE; /* XXX shared with render - replace with job 'stop' switch */
|
||||
|
||||
BKE_bake_ocean(oj->ocean, oj->och, oceanbake_update, (void *)oj);
|
||||
|
||||
|
||||
@@ -369,7 +369,7 @@ static int dynamicPaint_initBake(struct bContext *C, struct wmOperator *op)
|
||||
/* Set state to baking and init surface */
|
||||
canvas->error[0] = '\0';
|
||||
canvas->flags |= MOD_DPAINT_BAKING;
|
||||
G.afbreek= 0; /* reset blender_test_break*/
|
||||
G.is_break = FALSE; /* reset blender_test_break*/
|
||||
|
||||
/* Bake Dynamic Paint */
|
||||
status = dynamicPaint_bakeImageSequence(C, surface, ob);
|
||||
|
||||
@@ -745,7 +745,7 @@ static int fluidbake_breakjob(void *customdata)
|
||||
/* this is not nice yet, need to make the jobs list template better
|
||||
* for identifying/acting upon various different jobs */
|
||||
/* but for now we'll reuse the render break... */
|
||||
return (G.afbreek);
|
||||
return (G.is_break);
|
||||
}
|
||||
|
||||
/* called by fluidbake, wmJob sends notifier */
|
||||
@@ -765,7 +765,7 @@ static void fluidbake_startjob(void *customdata, short *stop, short *do_update,
|
||||
fb->do_update = do_update;
|
||||
fb->progress = progress;
|
||||
|
||||
G.afbreek= 0; /* XXX shared with render - replace with job 'stop' switch */
|
||||
G.is_break = FALSE; /* XXX shared with render - replace with job 'stop' switch */
|
||||
|
||||
elbeemSimulate();
|
||||
*do_update = TRUE;
|
||||
|
||||
@@ -61,7 +61,7 @@
|
||||
|
||||
static int cache_break_test(void *UNUSED(cbd))
|
||||
{
|
||||
return G.afbreek==1;
|
||||
return (G.is_break == TRUE);
|
||||
}
|
||||
static int ptcache_bake_all_poll(bContext *C)
|
||||
{
|
||||
|
||||
@@ -213,7 +213,7 @@ static int screen_render_exec(bContext *C, wmOperator *op)
|
||||
re = RE_NewRender(scene->id.name);
|
||||
lay = (v3d) ? v3d->lay : scene->lay;
|
||||
|
||||
G.afbreek = 0;
|
||||
G.is_break = FALSE;
|
||||
RE_test_break_cb(re, NULL, (int (*)(void *))blender_test_break);
|
||||
|
||||
ima = BKE_image_verify_viewer(IMA_TYPE_R_RESULT, "Render Result");
|
||||
@@ -427,7 +427,7 @@ static void render_endjob(void *rjv)
|
||||
}
|
||||
|
||||
/* XXX render stability hack */
|
||||
G.rendering = 0;
|
||||
G.is_rendering = FALSE;
|
||||
WM_main_add_notifier(NC_WINDOW, NULL);
|
||||
}
|
||||
|
||||
@@ -436,7 +436,7 @@ static int render_breakjob(void *rjv)
|
||||
{
|
||||
RenderJob *rj = rjv;
|
||||
|
||||
if (G.afbreek)
|
||||
if (G.is_break)
|
||||
return 1;
|
||||
if (rj->stop && *(rj->stop))
|
||||
return 1;
|
||||
@@ -584,7 +584,7 @@ static int screen_render_invoke(bContext *C, wmOperator *op, wmEvent *event)
|
||||
RE_progress_cb(re, rj, render_progress_update);
|
||||
|
||||
rj->re = re;
|
||||
G.afbreek = 0;
|
||||
G.is_break = FALSE;
|
||||
|
||||
/* store actual owner of job, so modal operator could check for it,
|
||||
* the reason of this is that active scene could change when rendering
|
||||
@@ -597,10 +597,10 @@ static int screen_render_invoke(bContext *C, wmOperator *op, wmEvent *event)
|
||||
WM_cursor_wait(0);
|
||||
WM_event_add_notifier(C, NC_SCENE | ND_RENDER_RESULT, scene);
|
||||
|
||||
/* we set G.rendering here already instead of only in the job, this ensure
|
||||
/* we set G.is_rendering here already instead of only in the job, this ensure
|
||||
* main loop or other scene updates are disabled in time, since they may
|
||||
* have started before the job thread */
|
||||
G.rendering = 1;
|
||||
G.is_rendering = TRUE;
|
||||
|
||||
/* add modal handler for ESC */
|
||||
WM_event_add_modal_handler(C, op);
|
||||
|
||||
@@ -683,7 +683,7 @@ static void shader_preview_render(ShaderPreview *sp, ID *id, int split, int firs
|
||||
if (ELEM(sp->pr_method, PR_BUTS_RENDER, PR_NODE_RENDER)) {
|
||||
RE_display_draw_cb(re, sp, shader_preview_draw);
|
||||
}
|
||||
/* set this for all previews, default is react to G.afbreek still */
|
||||
/* set this for all previews, default is react to G.is_break still */
|
||||
RE_test_break_cb(re, sp, shader_preview_break);
|
||||
|
||||
/* lens adjust */
|
||||
|
||||
@@ -297,7 +297,7 @@ static int render_view_show_invoke(bContext *C, wmOperator *UNUSED(op), wmEvent
|
||||
/* determine if render already shows */
|
||||
if (sa) {
|
||||
/* but don't close it when rendering */
|
||||
if (!G.rendering) {
|
||||
if (G.is_rendering == FALSE) {
|
||||
SpaceImage *sima = sa->spacedata.first;
|
||||
|
||||
if (sima->flag & SI_PREVSPACE) {
|
||||
|
||||
@@ -119,7 +119,7 @@ int ED_operator_screenactive(bContext *C)
|
||||
/* XXX added this to prevent anim state to change during renders */
|
||||
static int ED_operator_screenactive_norender(bContext *C)
|
||||
{
|
||||
if (G.rendering) return 0;
|
||||
if (G.is_rendering) return 0;
|
||||
if (CTX_wm_window(C) == NULL) return 0;
|
||||
if (CTX_wm_screen(C) == NULL) return 0;
|
||||
return 1;
|
||||
|
||||
@@ -803,7 +803,7 @@ void CLIP_OT_view_selected(wmOperatorType *ot)
|
||||
static int change_frame_poll(bContext *C)
|
||||
{
|
||||
/* prevent changes during render */
|
||||
if (G.rendering)
|
||||
if (G.is_rendering)
|
||||
return 0;
|
||||
|
||||
return ED_space_clip_poll(C);
|
||||
@@ -1000,7 +1000,7 @@ static void proxy_startjob(void *pjv, short *stop, short *do_update, float *prog
|
||||
BKE_movieclip_build_proxy_frame(clip, pj->clip_flag, distortion, cfra,
|
||||
build_undistort_sizes, build_undistort_count, 1);
|
||||
|
||||
if (*stop || G.afbreek)
|
||||
if (*stop || G.is_break)
|
||||
break;
|
||||
|
||||
*do_update = TRUE;
|
||||
@@ -1058,7 +1058,7 @@ static int clip_rebuild_proxy_exec(bContext *C, wmOperator *UNUSED(op))
|
||||
WM_jobs_timer(steve, 0.2, NC_MOVIECLIP | ND_DISPLAY, 0);
|
||||
WM_jobs_callbacks(steve, proxy_startjob, NULL, NULL, proxy_endjob);
|
||||
|
||||
G.afbreek = 0;
|
||||
G.is_break = FALSE;
|
||||
WM_jobs_start(CTX_wm_manager(C), steve);
|
||||
|
||||
ED_area_tag_redraw(CTX_wm_area(C));
|
||||
|
||||
@@ -952,7 +952,7 @@ typedef struct TrackMarkersJob {
|
||||
|
||||
static int track_markers_testbreak(void)
|
||||
{
|
||||
return G.afbreek;
|
||||
return G.is_break;
|
||||
}
|
||||
|
||||
static int track_count_markers(SpaceClip *sc, MovieClip *clip)
|
||||
@@ -1275,7 +1275,7 @@ static int track_markers_invoke(bContext *C, wmOperator *op, wmEvent *UNUSED(eve
|
||||
|
||||
WM_jobs_callbacks(steve, track_markers_startjob, NULL, track_markers_updatejob, NULL);
|
||||
|
||||
G.afbreek = 0;
|
||||
G.is_break = FALSE;
|
||||
|
||||
WM_jobs_start(CTX_wm_manager(C), steve);
|
||||
WM_cursor_wait(0);
|
||||
@@ -1497,7 +1497,7 @@ static int solve_camera_invoke(bContext *C, wmOperator *op, wmEvent *UNUSED(even
|
||||
WM_jobs_timer(steve, 0.1, NC_MOVIECLIP | NA_EVALUATED, 0);
|
||||
WM_jobs_callbacks(steve, solve_camera_startjob, NULL, solve_camera_updatejob, NULL);
|
||||
|
||||
G.afbreek = 0;
|
||||
G.is_break = FALSE;
|
||||
|
||||
WM_jobs_start(CTX_wm_manager(C), steve);
|
||||
WM_cursor_wait(0);
|
||||
|
||||
@@ -238,7 +238,7 @@ void image_preview_event(int event)
|
||||
|
||||
ntreeCompositTagGenerators(G.scene->nodetree);
|
||||
|
||||
G.afbreek = 0;
|
||||
G.is_break = FALSE;
|
||||
G.scene->nodetree->timecursor = set_timecursor;
|
||||
G.scene->nodetree->test_break = blender_test_break;
|
||||
|
||||
|
||||
@@ -177,7 +177,7 @@ void ED_node_composite_job(const bContext *C, struct bNodeTree *nodetree, Scene
|
||||
CompoJob *cj;
|
||||
|
||||
/* to fix bug: [#32272] */
|
||||
if (G.rendering) {
|
||||
if (G.is_rendering) {
|
||||
return;
|
||||
}
|
||||
|
||||
|
||||
@@ -849,7 +849,7 @@ void draw_image_seq(const bContext *C, Scene *scene, ARegion *ar, SpaceSeq *sseq
|
||||
UI_view2d_curRect_validate(v2d);
|
||||
|
||||
/* only initialize the preview if a render is in progress */
|
||||
if (G.rendering)
|
||||
if (G.is_rendering)
|
||||
return;
|
||||
|
||||
context = BKE_sequencer_new_render_data(bmain, scene, rectx, recty, proxy_size);
|
||||
|
||||
@@ -212,7 +212,7 @@ static void seq_proxy_build_job(const bContext *C)
|
||||
SEQ_END
|
||||
|
||||
if (!WM_jobs_is_running(steve)) {
|
||||
G.afbreek = 0;
|
||||
G.is_break = FALSE;
|
||||
WM_jobs_start(CTX_wm_manager(C), steve);
|
||||
}
|
||||
|
||||
|
||||
@@ -6581,7 +6581,7 @@ void draw_object(Scene *scene, ARegion *ar, View3D *v3d, Base *base, const short
|
||||
}
|
||||
|
||||
/* XXX particles are not safe for simultaneous threaded render */
|
||||
if (G.rendering && ob->particlesystem.first)
|
||||
if (G.is_rendering && ob->particlesystem.first)
|
||||
return;
|
||||
|
||||
/* xray delay? */
|
||||
|
||||
@@ -347,10 +347,10 @@ void rna_Object_create_duplilist(Object *ob, ReportList *reports, Scene *sce)
|
||||
free_object_duplilist(ob->duplilist);
|
||||
ob->duplilist = NULL;
|
||||
}
|
||||
if (G.rendering)
|
||||
if (G.is_rendering)
|
||||
dupli_render_particle_set(sce, ob, 0, 1);
|
||||
ob->duplilist = object_duplilist(sce, ob);
|
||||
if (G.rendering)
|
||||
if (G.is_rendering)
|
||||
dupli_render_particle_set(sce, ob, 0, 0);
|
||||
/* ob->duplilist should now be freed with Object.free_duplilist */
|
||||
}
|
||||
|
||||
@@ -391,7 +391,7 @@ static void exec_output_file(void *data, bNode *node, bNodeStack **in, bNodeStac
|
||||
RenderData *rd= data;
|
||||
NodeImageMultiFile *nimf= node->storage;
|
||||
|
||||
if (!G.rendering) {
|
||||
if (G.is_rendering == FALSE) {
|
||||
/* only output files when rendering a sequence -
|
||||
* otherwise, it overwrites the output files just
|
||||
* scrubbing through the timeline when the compositor updates */
|
||||
|
||||
@@ -309,7 +309,7 @@ void RE_make_stars(Render *re, Scene *scenev3d, void (*initfunc)(void),
|
||||
totstar++;
|
||||
}
|
||||
/* do not call blender_test_break() here, since it is used in UI as well, confusing the callback system */
|
||||
/* main cause is G.afbreek of course, a global again... (ton) */
|
||||
/* main cause is G.is_break of course, a global again... (ton) */
|
||||
}
|
||||
}
|
||||
if (termfunc) termfunc();
|
||||
@@ -1613,7 +1613,7 @@ static int render_new_particle_system(Render *re, ObjectRen *obr, ParticleSystem
|
||||
if (part->type==PART_HAIR && !psys->childcache)
|
||||
totchild= 0;
|
||||
|
||||
if (G.rendering == 0) { /* preview render */
|
||||
if (G.is_rendering == FALSE) { /* preview render */
|
||||
totchild = (int)((float)totchild * (float)part->disp / 100.0f);
|
||||
}
|
||||
|
||||
@@ -3876,7 +3876,7 @@ static GroupObject *add_render_lamp(Render *re, Object *ob)
|
||||
if (la->mtex[c]->mapto & LAMAP_SHAD)
|
||||
lar->mode |= LA_SHAD_TEX;
|
||||
|
||||
if (G.rendering) {
|
||||
if (G.is_rendering) {
|
||||
if (re->osa) {
|
||||
if (la->mtex[c]->tex->type==TEX_IMAGE) lar->mode |= LA_OSATEX;
|
||||
}
|
||||
@@ -4650,7 +4650,7 @@ void RE_Database_Free(Render *re)
|
||||
LampRen *lar;
|
||||
|
||||
/* statistics for debugging render memory usage */
|
||||
if ((G.debug & G_DEBUG) && (G.rendering)) {
|
||||
if ((G.debug & G_DEBUG) && (G.is_rendering)) {
|
||||
if ((re->r.scemode & R_PREVIEWBUTS)==0) {
|
||||
BKE_image_print_memlist();
|
||||
MEM_printmemlist_stats();
|
||||
|
||||
@@ -331,7 +331,7 @@ int RE_engine_render(Render *re, int do_all)
|
||||
RE_engine_free(engine);
|
||||
|
||||
if (BKE_reports_contain(re->reports, RPT_ERROR))
|
||||
G.afbreek = 1;
|
||||
G.is_break = TRUE;
|
||||
|
||||
return 1;
|
||||
}
|
||||
|
||||
@@ -138,7 +138,7 @@ static void result_nothing(void *UNUSED(arg), RenderResult *UNUSED(rr)) {}
|
||||
static void result_rcti_nothing(void *UNUSED(arg), RenderResult *UNUSED(rr), volatile struct rcti *UNUSED(rect)) {}
|
||||
static void stats_nothing(void *UNUSED(arg), RenderStats *UNUSED(rs)) {}
|
||||
static void float_nothing(void *UNUSED(arg), float UNUSED(val)) {}
|
||||
static int default_break(void *UNUSED(arg)) {return G.afbreek == 1;}
|
||||
static int default_break(void *UNUSED(arg)) { return G.is_break == TRUE; }
|
||||
|
||||
static void stats_background(void *UNUSED(arg), RenderStats *rs)
|
||||
{
|
||||
@@ -1199,7 +1199,7 @@ static void do_render_fields_blur_3d(Render *re)
|
||||
/* also check for camera here */
|
||||
if (camera == NULL) {
|
||||
printf("ERROR: Cannot render, no camera\n");
|
||||
G.afbreek = 1;
|
||||
G.is_break = TRUE;
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -1495,7 +1495,7 @@ void RE_MergeFullSample(Render *re, Main *bmain, Scene *sce, bNodeTree *ntree)
|
||||
bNode *node;
|
||||
|
||||
/* default start situation */
|
||||
G.afbreek = 0;
|
||||
G.is_break = FALSE;
|
||||
|
||||
re->main = bmain;
|
||||
re->scene = sce;
|
||||
@@ -2034,7 +2034,7 @@ void RE_SetReports(Render *re, ReportList *reports)
|
||||
void RE_BlenderFrame(Render *re, Main *bmain, Scene *scene, SceneRenderLayer *srl, Object *camera_override, unsigned int lay, int frame, const short write_still)
|
||||
{
|
||||
/* ugly global still... is to prevent preview events and signal subsurfs etc to make full resol */
|
||||
G.rendering = 1;
|
||||
G.is_rendering = TRUE;
|
||||
|
||||
scene->r.cfra = frame;
|
||||
|
||||
@@ -2045,7 +2045,7 @@ void RE_BlenderFrame(Render *re, Main *bmain, Scene *scene, SceneRenderLayer *sr
|
||||
|
||||
do_render_all_options(re);
|
||||
|
||||
if (write_still && !G.afbreek) {
|
||||
if (write_still && !G.is_break) {
|
||||
if (BKE_imtype_is_movie(scene->r.im_format.imtype)) {
|
||||
/* operator checks this but in case its called from elsewhere */
|
||||
printf("Error: cant write single images with a movie format!\n");
|
||||
@@ -2062,10 +2062,10 @@ void RE_BlenderFrame(Render *re, Main *bmain, Scene *scene, SceneRenderLayer *sr
|
||||
BLI_callback_exec(re->main, (ID *)scene, BLI_CB_EVT_RENDER_POST); /* keep after file save */
|
||||
}
|
||||
|
||||
BLI_callback_exec(re->main, (ID *)scene, G.afbreek ? BLI_CB_EVT_RENDER_CANCEL : BLI_CB_EVT_RENDER_COMPLETE);
|
||||
BLI_callback_exec(re->main, (ID *)scene, G.is_break ? BLI_CB_EVT_RENDER_CANCEL : BLI_CB_EVT_RENDER_COMPLETE);
|
||||
|
||||
/* UGLY WARNING */
|
||||
G.rendering = 0;
|
||||
G.is_rendering = FALSE;
|
||||
}
|
||||
|
||||
static int do_write_image_or_movie(Render *re, Main *bmain, Scene *scene, bMovieHandle *mh, const char *name_override)
|
||||
@@ -2161,16 +2161,16 @@ void RE_BlenderAnim(Render *re, Main *bmain, Scene *scene, Object *camera_overri
|
||||
|
||||
/* ugly global still... is to prevent renderwin events and signal subsurfs etc to make full resol */
|
||||
/* is also set by caller renderwin.c */
|
||||
G.rendering = 1;
|
||||
G.is_rendering = TRUE;
|
||||
|
||||
re->flag |= R_ANIMATION;
|
||||
|
||||
if (BKE_imtype_is_movie(scene->r.im_format.imtype))
|
||||
if (!mh->start_movie(scene, &re->r, re->rectx, re->recty, re->reports))
|
||||
G.afbreek = 1;
|
||||
G.is_break = TRUE;
|
||||
|
||||
if (mh->get_next_frame) {
|
||||
while (!(G.afbreek == 1)) {
|
||||
while (!(G.is_break == 1)) {
|
||||
int nf = mh->get_next_frame(&re->r, re->reports);
|
||||
if (nf >= 0 && nf >= scene->r.sfra && nf <= scene->r.efra) {
|
||||
scene->r.cfra = re->r.cfra = nf;
|
||||
@@ -2182,16 +2182,17 @@ void RE_BlenderAnim(Render *re, Main *bmain, Scene *scene, Object *camera_overri
|
||||
|
||||
if (re->test_break(re->tbh) == 0) {
|
||||
if (!do_write_image_or_movie(re, bmain, scene, mh, NULL))
|
||||
G.afbreek = 1;
|
||||
G.is_break = TRUE;
|
||||
}
|
||||
|
||||
if (G.afbreek == 0) {
|
||||
if (G.is_break == FALSE) {
|
||||
BLI_callback_exec(re->main, (ID *)scene, BLI_CB_EVT_RENDER_POST); /* keep after file save */
|
||||
}
|
||||
}
|
||||
else {
|
||||
if (re->test_break(re->tbh))
|
||||
G.afbreek = 1;
|
||||
if (re->test_break(re->tbh)) {
|
||||
G.is_break = TRUE;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -2247,14 +2248,14 @@ void RE_BlenderAnim(Render *re, Main *bmain, Scene *scene, Object *camera_overri
|
||||
totrendered++;
|
||||
|
||||
if (re->test_break(re->tbh) == 0) {
|
||||
if (!G.afbreek)
|
||||
if (!G.is_break)
|
||||
if (!do_write_image_or_movie(re, bmain, scene, mh, NULL))
|
||||
G.afbreek = 1;
|
||||
G.is_break = TRUE;
|
||||
}
|
||||
else
|
||||
G.afbreek = 1;
|
||||
G.is_break = TRUE;
|
||||
|
||||
if (G.afbreek == 1) {
|
||||
if (G.is_break == TRUE) {
|
||||
/* remove touched file */
|
||||
if (BKE_imtype_is_movie(scene->r.im_format.imtype) == 0) {
|
||||
if (scene->r.mode & R_TOUCH && BLI_exists(name) && BLI_file_size(name) == 0) {
|
||||
@@ -2265,7 +2266,7 @@ void RE_BlenderAnim(Render *re, Main *bmain, Scene *scene, Object *camera_overri
|
||||
break;
|
||||
}
|
||||
|
||||
if (G.afbreek == 0) {
|
||||
if (G.is_break == FALSE) {
|
||||
BLI_callback_exec(re->main, (ID *)scene, BLI_CB_EVT_RENDER_POST); /* keep after file save */
|
||||
}
|
||||
}
|
||||
@@ -2282,10 +2283,10 @@ void RE_BlenderAnim(Render *re, Main *bmain, Scene *scene, Object *camera_overri
|
||||
|
||||
re->flag &= ~R_ANIMATION;
|
||||
|
||||
BLI_callback_exec(re->main, (ID *)scene, G.afbreek ? BLI_CB_EVT_RENDER_CANCEL : BLI_CB_EVT_RENDER_COMPLETE);
|
||||
BLI_callback_exec(re->main, (ID *)scene, G.is_break ? BLI_CB_EVT_RENDER_CANCEL : BLI_CB_EVT_RENDER_COMPLETE);
|
||||
|
||||
/* UGLY WARNING */
|
||||
G.rendering = 0;
|
||||
G.is_rendering = FALSE;
|
||||
}
|
||||
|
||||
void RE_PreviewRender(Render *re, Main *bmain, Scene *sce)
|
||||
|
||||
@@ -112,7 +112,7 @@ static void init_render_texture(Render *re, Tex *tex)
|
||||
tex->extend= TEX_EXTEND;
|
||||
|
||||
/* only free envmap when rendermode was set to render envmaps, for previewrender */
|
||||
if (G.rendering && re) {
|
||||
if (G.is_rendering && re) {
|
||||
if (re->r.mode & R_ENVMAP)
|
||||
if (tex->env->stype==ENV_ANIM)
|
||||
BKE_free_envmapdata(tex->env);
|
||||
|
||||
@@ -848,7 +848,7 @@ void threaded_makeshadowbufs(Render *re)
|
||||
int (*test_break)(void *);
|
||||
|
||||
/* count number of threads to use */
|
||||
if (G.rendering) {
|
||||
if (G.is_rendering) {
|
||||
for (lar=re->lampren.first; lar; lar= lar->next)
|
||||
if (lar->shb)
|
||||
totthread++;
|
||||
|
||||
@@ -88,7 +88,7 @@ int ocean_texture(Tex *tex, float *texvec, TexResult *texres)
|
||||
}
|
||||
else { /* non-cached */
|
||||
|
||||
if (G.rendering)
|
||||
if (G.is_rendering)
|
||||
BKE_ocean_eval_uv_catrom(omd->ocean, &ocr, u, v);
|
||||
else
|
||||
BKE_ocean_eval_uv(omd->ocean, &ocr, u, v);
|
||||
|
||||
@@ -3975,9 +3975,9 @@ unsigned short *zbuffer_transp_shade(RenderPart *pa, RenderLayer *rl, float *pas
|
||||
if (R.test_break(R.tbh))
|
||||
return NULL;
|
||||
|
||||
if (R.osa>16) { /* MAX_OSA */
|
||||
if (R.osa > 16) { /* MAX_OSA */
|
||||
printf("zbuffer_transp_shade: osa too large\n");
|
||||
G.afbreek= 1;
|
||||
G.is_break = TRUE;
|
||||
return NULL;
|
||||
}
|
||||
|
||||
|
||||
@@ -242,7 +242,7 @@ void wm_event_do_notifiers(bContext *C)
|
||||
/* XXX, quick frame changes can cause a crash if framechange and rendering
|
||||
* collide (happens on slow scenes), BKE_scene_update_for_newframe can be called
|
||||
* twice which can depgraph update the same object at once */
|
||||
if (!G.rendering) {
|
||||
if (G.is_rendering == FALSE) {
|
||||
|
||||
/* depsgraph gets called, might send more notifiers */
|
||||
ED_update_for_newframe(CTX_data_main(C), win->screen->scene, 1);
|
||||
@@ -301,7 +301,7 @@ void wm_event_do_notifiers(bContext *C)
|
||||
}
|
||||
|
||||
/* XXX make lock in future, or separated derivedmesh users in scene */
|
||||
if (!G.rendering) {
|
||||
if (G.is_rendering == FALSE) {
|
||||
/* depsgraph & animation: update tagged datablocks */
|
||||
Main *bmain = CTX_data_main(C);
|
||||
|
||||
@@ -2906,7 +2906,7 @@ void wm_event_add_ghostevent(wmWindowManager *wm, wmWindow *win, int type, int U
|
||||
|
||||
/* if test_break set, it catches this. XXX Keep global for now? */
|
||||
if (event.type == ESCKEY)
|
||||
G.afbreek = 1;
|
||||
G.is_break = TRUE;
|
||||
|
||||
wm_event_add(win, &event);
|
||||
|
||||
|
||||
@@ -497,5 +497,5 @@ void WM_exit_ext(bContext *C, const short do_python)
|
||||
void WM_exit(bContext *C)
|
||||
{
|
||||
WM_exit_ext(C, 1);
|
||||
exit(G.afbreek == 1);
|
||||
exit(G.is_break == TRUE);
|
||||
}
|
||||
|
||||
@@ -174,7 +174,7 @@ static void blender_esc(int sig)
|
||||
{
|
||||
static int count = 0;
|
||||
|
||||
G.afbreek = 1; /* forces render loop to read queue, not sure if its needed */
|
||||
G.is_break = TRUE; /* forces render loop to read queue, not sure if its needed */
|
||||
|
||||
if (sig == 2) {
|
||||
if (count) {
|
||||
|
||||
Reference in New Issue
Block a user