Teach the renderer to keep thread alive if engine requests it#9091
Merged
Teach the renderer to keep thread alive if engine requests it#9091
Conversation
… that it wants it so continuous draw shaders can keep drawing.
zadjii-msft
approved these changes
Feb 10, 2021
Member
zadjii-msft
left a comment
There was a problem hiding this comment.
This is GREAT. I don't think there's a way to be sure if a shader is actually using the Time variable or not - we'd somehow need to inspect the compiled shader to see if the variable was ever referenced? There's no way that's possible.
Lets ![]()
| // If the engine tells us it really wants to redraw immediately, | ||
| // tell the thread so it doesn't go to sleep and ticks again | ||
| // at the next opportunity. | ||
| if (pEngine->RequiresContinuousRedraw()) |
Member
There was a problem hiding this comment.
oh my gosh this is so clever, I love it
Member
Author
TODO
|
Member
|
nit: reword title to be imperative; pretend it completes the sentence "this commit will" |
Member
DHowett
approved these changes
Feb 10, 2021
Member
|
Clever as. |
DHowett
pushed a commit
that referenced
this pull request
Feb 10, 2021
Teaches renderer base to keep thread alive if engine requests it. `DxEngine` now requests it if shaders are on. - The render engine interface now has a true/false to return whether the specific renderer wants another frame to immediately follow up. The renderer base will ask for this information as it ends the paint on any particular engine (which is the time where invalid regions are typically cleaned up) and just poke the render thread the same as if an invalidation request came in from outside of render-land. That will trigger the render thread to just keep moving in the same way as any other invalidation. ## Validation Steps Performed - [x] Actually built it - [x] Actually try it I promised this in #8994 (cherry picked from commit 3b24781)
DHowett
added a commit
that referenced
this pull request
Feb 11, 2021
Dustin L. Howett (3) * Move CharToKeyEvents (and friends) into InteractivityBase (GH-9106) * Update Cascadia Code to 2102.03 (GH-9088) * verison: bump to 1.7 on main Josh Soref (1) * ci: update to Spell check to 0.0.17a (CC-9014) Leonard Hecker (3) * Fixed GH-5205: Ctrl+Alt+2 doesn't send ^[^@ (CC-5272) * Fix issues in tests.xml and OpenConsole.psm1 (CC-9011) * Fix GH-8458: Handle all Ctrl-key combinations (CC-8870) Mike Griese (1) * Add support for running a commandline in another WT window (GH-8898) Michael Niksa (1) * Teach the renderer to keep thread alive if engine requests it (GH-9091) Lachlan Picking (1) * Fix shader time input (CC-8994) PankajBhojwani (1) * Separate runtime TerminalSettings from profile-TerminalSettings (CC-8602) Chester Liu (2) * Add support for paste filtering and bracketed paste mode (CC-9034) * Add support for chaining OSC 10-12 (CC-8999) Related work items: MSFT-31692939
|
🎉 Handy links: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.


Teaches renderer base to keep thread alive if engine requests it.
DxEnginenow requests it if shaders are on.specific renderer wants another frame to immediately follow up. The
renderer base will ask for this information as it ends the paint on
any particular engine (which is the time where invalid regions are
typically cleaned up) and just poke the render thread the same as if
an invalidation request came in from outside of render-land. That will
trigger the render thread to just keep moving in the same way as any
other invalidation.
Validation Steps Performed
I promised this in #8994