3Dickulus / FragM

Derived from https://github.com/Syntopia/Fragmentarium/
GNU General Public License v3.0
344 stars 30 forks source link

GL progress #153

Closed 3Dickulus closed 3 years ago

3Dickulus commented 3 years ago

Description When rendering a hires tiled image the GL area does not update until after the first tile is complete

To Reproduce Steps to reproduce the behavior:

  1. Go to Edit->Preferences
  2. Click on GUI stylesheet file load button '...'
  3. Load the Misc/qss/DarkOrange.qss file
  4. Select the 'Ok' button in the Preferences dialog
  5. render a tiled image
  6. Note that the GL area remains gray

Expected behavior The GL area should be updated with the image before tiles begin rendering

Desktop:

3Dickulus commented 3 years ago

Propose rendering a single subframe of the full image in the GL area and overlaying scaled tiles as they render.

Current behaviour is to overlay tiles on whatever was last rendered in the GL area. If the GL area has an image that is the same number of subframes as the tiles then the progress is almost invisible.

By using a single subframe image to start with will ensure that progress is always easily observable, unless of course, the tiles are rendered using a single subframe too. Maybe in that case the GL area should be cleared so progress is still visible because single subframes render quickly?

This should fix the "gray area" when using stylesheets because it will be manually taking control of the state of the widget background before rendering and displaying the initial thumbnail and tile overlay.