Fix T61104 Compositing two scenes with different output scales crashes

Was due to incorrect output size. Use engine->resolution_x/y instead of
computing the size on the fly from the scene specific settings (which are
not overwritten by the rendering scene).
This commit is contained in:
Clément Foucault 2019-03-18 21:39:54 +01:00
parent fd63be0610
commit ce09b93955
Notes: blender-bot 2023-02-14 19:45:25 +01:00
Referenced by issue #77885, GPencil: Compositing different sized scenes with grease pencil crushes Blender
Referenced by issue #61104, Compositing two scenes with different output scales crashes blender
1 changed files with 1 additions and 1 deletions

View File

@ -1865,7 +1865,7 @@ void DRW_render_to_image(RenderEngine *engine, struct Depsgraph *depsgraph)
drw_context_state_init();
DST.viewport = GPU_viewport_create();
const int size[2] = {(r->size * r->xsch) / 100, (r->size * r->ysch) / 100};
const int size[2] = {engine->resolution_x, engine->resolution_y};
GPU_viewport_size_set(DST.viewport, size);
drw_viewport_var_init();