Page MenuHome

EEVEE: "Viewport Render Image" and "Viewport Render Animation" different results (colormanagement)
Closed, DuplicatePublic

Description

System Information
Operating system: Win 10
Graphics card: 1080Ti

Blender Version
Broken: version: 2.83 (sub 11), branch: master, commit date: 2020-03-31 15:31, hash: rB1c1a14dcdfff
Worked: 2.81a

Short description of error
Result from viewport Render Image and Viewport Render Animation are different
The Render Animation frame has washed out and muted slightly green colour, as if it is not considering all the lighting correctly.
(especially visible on yellow front of truck

See attached images

Exact steps for others to reproduce the error

  1. Open file
  2. Set Start and End frame to 1
  3. Set viewport shading to Rendered
  4. In 3D view click View > Viewport Render Image, save as for comparison
  5. In 3D view click View > Viewport Render Animation, save as for comparison
  6. Compare saved images

There will be noticable difference.

Event Timeline

Richard Antalik (ISS) changed the task status from Needs Triage to Needs Information from User.Apr 1 2020, 4:37 PM

I can confirm difference, but not this big difference so I may be looking at completely different issue. Can you upload sample file?

I've stripped it back as best I can as it was a massive scene. Sorry it's still 56Mb
Problem persists, I've attached the file:

and here are two images showing the difference between Viewport Render Frame and Viewport Render Animation:

Thanks,

Chay

It's a difference across the entire scene but noticeable most in the muddy whites and greenish yellows

I can not reproduce this


Can you check if this happens if you click on File > Defaults > Load Factory Settings?

Your tests don't seem to show the scene lighting or textures, I think you have the viewport set to solid shading

I have my viewport shading set to "Rendered" not "Solid"
(The fourth of the four circles)

The problem occurs when the viewport is set to Rendered.

Then the Viewport Render Image and Viewport Render Animation options create the different lighting results
Which is weird because I would have thought "Viewport Render Animation" would just output a sequence of "Viewport Render Image"s

I have checked File > Defaults > Load Factory Settings
and on an initial cube scene, with a colour on the cube, and then sun for the light
if you choose Rendered as the viewport option, and then
View > Viewport Rendered Animation
it renders far more washed out than it does with
View> Viewport Rendered Image.
(in 2.82a)

Here is a video capture of the issue:

Thanks

In 2.81a the outputs from the two options are identical
in 2.82a they aren't

Richard Antalik (ISS) renamed this task from "Viewport Render Image" and "Viewport Render Animation" different results in 2.82a to "Viewport Render Image" and "Viewport Render Animation" different results.Apr 2 2020, 8:19 PM
Richard Antalik (ISS) changed the task status from Needs Information from User to Confirmed.
Richard Antalik (ISS) updated the task description. (Show Details)

Can confirm, had this problem for a while too and it seems to be a problem with color management since it happens only when Filmic is selected rather than Standard

@Jeroen Bakker (jbakker) any input on this issue? Seems like the issue is having the color management applied twice in one of the 2 cases.

Clément Foucault (fclem) renamed this task from "Viewport Render Image" and "Viewport Render Animation" different results to EEVEE: "Viewport Render Image" and "Viewport Render Animation" different results (colormanagement).Jun 30 2020, 12:44 AM
Clément Foucault (fclem) moved this task from Backlog to Bugs on the EEVEE & Viewport board.

TL;DR: Animations only get collorcorrected when the output format depth is more than 8 bit. I don't know why.
Workaround: Try PNG 16 bit.

Here's how it works:

Note: Some intermediate calls omitted for simplicity

in screen_opengl_render_init(bContext *C, wmOperator *op):
  // Images are always 32 bit, for animation use the output image format depth
  // Try setting it to R_IMF_CHAN_DEPTH_32 - both result will be collor corrected the same way
  const eImageFormatDepth color_depth = (is_animation) ? scene->r.im_format.depth : R_IMF_CHAN_DEPTH_32;
  oglrender = MEM_callocN(sizeof(OGLRender), "OGLRender");
  op->customdata = oglrender;
  oglrender->color_depth = color_depth;

then in screen_opengl_render_doit(const bContext *C, OGLRender *oglrender, RenderResult *rr):
  // Use floats for more than 8 bit
  eImBufFlags imbuf_flags = oglrender->color_depth <= R_IMF_CHAN_DEPTH_8 ? IB_rect : IB_rectfloat;

then in ED_view3d_draw_offscreen_imbuf(..., imbuf_flags, ...):
  ImBuf *ibuf = IMB_allocImBuf(sizex, sizey, 32, imbuf_flag);
  // Do color management only with float buffer
  const bool do_color_management = (ibuf->rect_float == NULL);

and in DRW_draw_render_loop_offscreen(..., do_color_management, ...):
  drw_state_prepare_clean_for_draw(&DST);
  DST.options.is_image_render = is_image_render;
  DST.options.do_color_management = do_color_management;
  DST.options.draw_background = draw_background;
  DRW_draw_render_loop_ex(depsgraph, engine_type, region, v3d, render_viewport, NULL);

Why it is this way - idk. Should it be this way - idk. Is this confusing to the user - idk.

PS: That's if I understood the problem correctly. For me all the images in this task look the same, did the research using fake colour.