Expose time, date, mouse, ideally CPU / GPU / memory utilization to custom HLSL shaders #9468
Labels
Area-Rendering
Text rendering, emoji, complex glyph & font-fallback issues
Issue-Feature
Complex enough to require an in depth planning process and actual budgeted, scheduled work.
Product-Terminal
The new Windows Terminal.
Milestone
Description of the new feature/enhancement
Custom shaders rock, but they would rock even more if they were interactive. They simply don't know what's happening outside of the shader. I would love to have my shaders respond to what's happening on the system: for example, have them change color by time of day, or have them act up and be all energetic when CPU utilization is high, and calm down when CPU utilization is low. That would be a totally sweet command prompt.
Proposed technical implementation details (optional)
On the HLSL side, expose additional state in the cbuffer. I don't think this would break existing shaders if we just add items to the end of the cbuffer, but even if it does, hey, it's an experimental feature as someone said. :)
Minor tech note: if fetching cpu / memory / gpu utilization is costly, it's ok to do them every 500ms or so. They don't need to be per-frame.
maintainer notes:
#15837 is another feature that might be a good thing to plumb through here. Consider: swapchainPosition, so that you can use the offset relative to the desktop origin. (we would of course have to plumb the desktop image into the shader, ala #14073)
The text was updated successfully, but these errors were encountered: