Skip to content

Add support for tiled rendering.#20912

Draft
brugger1 wants to merge 59 commits into
developfrom
task/brugger1/2026_01_12_tiled_rendering
Draft

Add support for tiled rendering.#20912
brugger1 wants to merge 59 commits into
developfrom
task/brugger1/2026_01_12_tiled_rendering

Conversation

@brugger1

Copy link
Copy Markdown
Collaborator

Description

I added support for tiled rendering when doing rendering in the engine. Tiled rendering is always enabled with a default tile width and height of 8192. The reason for always being enabled is that Mesa stops working properly somewhere between an image width and height of 8192 and 16384. This avoids that issue.

The tiled rendering width and height can be controlled with the tiledRenderingWidth and tiledRenderingHeight fields in the RenderingAttributes. For example:

renderAtts = RenderingAttributes()
renderAtts.tiledRenderingWidth = 512
renderAtts.tiledRenderingHeight = 512
SetRenderingAttributes(renderAtts)

sets the tiled rendering width and height to 512.

Internally, a fixed tile size is used that just covers the image being rendered that is smaller than the user selected size. For example, if the image size is 1024x1024 and the user selects a 512x512 tile size, then it uses the user selected tile size. If the tile size doesn't exactly divide the image size, then the tile size is chosen such that last tile in each direction will minimally extend beyond the image. For example, if the image size is 1021x1021 and the user selects a 512x512 tile size, then it uses a tile size of 511x511 and discards a row and/or column in the tiles along the right and bottom edges.

In order to add support for tiled rendering for annotations, the foreground view was changed as follows.

    vtkCamera *cam = foreground->GetActiveCamera();
    cam->SetFocalPoint(0.5, 0.5, 0.);
    cam->SetPosition(0.5, 0.5, 1.);
    cam->SetViewUp(0., 1., 0.);
    cam->SetParallelProjection(1);
    cam->SetParallelScale(0.5);
    foreground->SetActiveCamera(cam);

3D annotations worked fine with this change, but 2D annotations were all rendered in NormalizedViewport coordinates. The 2D annotations were all modified to use World coordinates.

Type of change

  • New feature~~

How Has This Been Tested?

Reminders:

  • Please follow the style guidelines of this project.
  • Please perform a self-review of your code before submitting a PR and asking others to review it.
  • Please assign reviewers (see VisIt's PR procedures for more information).

Checklist:

  • I have commented my code where applicable.~~
  • I have updated the release notes.~~
  • I have made corresponding changes to the documentation.~~
  • I have added debugging support to my changes.~~
  • I have added tests that prove my fix is effective or that my feature works.~~
  • I have confirmed new and existing unit tests pass locally with my changes.~~
  • I have added new baselines for any new tests to the repo.~~
  • I have NOT made any changes to protocol or public interfaces in an RC branch.~~

Eric Samuel Brugger and others added 30 commits February 2, 2026 15:51
Eric Samuel Brugger and others added 29 commits April 16, 2026 17:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants