Rendering tricks for improving workflow:
- Button option "Single" in render-layer panel will enable to only render the currently indicated render-layer. It will also skip compositing. - Brought back the 'Local View' render. This will only render the visible objects, but with lights from the original view-layers. To make the option useful, it also temporal enables 'Single', which has the a disadvantage that you need to set the correct render-layer. It is a bit a tricky option though... since its quite invisble and confusing for people who don't know the feature. This might become either a button in 3d header, or use a popup requester to confirm, or... will need to think over! At least; both options display in render window a text to denote the option.
This commit is contained in:
@@ -834,6 +834,11 @@ static void printrenderinfo_cb(RenderStats *rs)
|
||||
if(render_win) {
|
||||
megs_used_memory= mem_in_use/(1024.0*1024.0);
|
||||
|
||||
if(G.scene->lay & 0xFF000000)
|
||||
spos+= sprintf(spos, "Localview | ");
|
||||
else if(G.scene->r.scemode & R_SINGLE_LAYER)
|
||||
spos+= sprintf(spos, "Single Layer | ");
|
||||
|
||||
if(rs->tothalo)
|
||||
spos+= sprintf(spos, "Fra:%d Ve:%d Fa:%d Ha:%d La:%d Mem:%.2fM", (G.scene->r.cfra), rs->totvert, rs->totface, rs->tothalo, rs->totlamp, megs_used_memory);
|
||||
else
|
||||
@@ -854,7 +859,7 @@ static void printrenderinfo_cb(RenderStats *rs)
|
||||
}
|
||||
|
||||
/* temporal render debug printing, needed for testing orange renders atm... will be gone soon (or option) */
|
||||
if(rs->convertdone) {
|
||||
if(G.rt==7 && rs->convertdone) {
|
||||
spos= str;
|
||||
spos+= sprintf(spos, "Fra:%d Mem:%.2fM ", G.scene->r.cfra, megs_used_memory);
|
||||
|
||||
@@ -980,6 +985,8 @@ static void end_test_break_callback()
|
||||
static void do_render(int anim)
|
||||
{
|
||||
Render *re= RE_NewRender("Render");
|
||||
unsigned int lay= G.scene->lay;
|
||||
int scemode= G.scene->r.scemode;
|
||||
|
||||
/* we set this flag to prevent renderwindow queue to execute another render */
|
||||
G.rendering= 1;
|
||||
@@ -1000,11 +1007,24 @@ static void do_render(int anim)
|
||||
if(G.obedit)
|
||||
exit_editmode(0); /* 0 = no free data */
|
||||
|
||||
/* allow localview render for objects with lights in normal layers */
|
||||
if(curarea->spacetype==SPACE_VIEW3D) {
|
||||
if(G.vd->lay & 0xFF000000) {
|
||||
G.scene->lay |= G.vd->lay;
|
||||
G.scene->r.scemode |= R_SINGLE_LAYER;
|
||||
}
|
||||
else G.scene->lay= G.vd->lay;
|
||||
}
|
||||
|
||||
if(anim)
|
||||
RE_BlenderAnim(re, G.scene, G.scene->r.sfra, G.scene->r.efra);
|
||||
else
|
||||
RE_BlenderFrame(re, G.scene, G.scene->r.cfra);
|
||||
|
||||
/* restore local view exception */
|
||||
G.scene->lay= lay;
|
||||
G.scene->r.scemode= scemode;
|
||||
|
||||
if(render_win) window_set_cursor(render_win->win, CURSOR_STD);
|
||||
|
||||
free_filesel_spec(G.scene->r.pic);
|
||||
|
||||
Reference in New Issue
Block a user