Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Shader files not loading in 1.7 #9354

Closed
Nacimota opened this issue Mar 3, 2021 · 7 comments · Fixed by #9371
Closed

Shader files not loading in 1.7 #9354

Nacimota opened this issue Mar 3, 2021 · 7 comments · Fixed by #9371
Assignees
Labels
Area-Rendering Text rendering, emoji, complex glyph & font-fallback issues Area-Settings Issues related to settings and customizability, for console or terminal Issue-Bug It either shouldn't be doing this or needs an investigation. Priority-3 A description (P3) Product-Terminal The new Windows Terminal. Resolution-Fix-Committed Fix is checked in, but it might be 3-4 weeks until a release.
Milestone

Comments

@Nacimota
Copy link
Contributor

Nacimota commented Mar 3, 2021

Environment

Windows build number: 10.0.19042.0
Windows Terminal version: 1.7.572.0

Steps to reproduce

  1. Build/Install Windows Terminal 1.7.572.0
  2. Set experimental.pixelShaderPath on a profile (or globally) such that it points to an appropriately structured HLSL file (such as Invert.hlsl from the samples folder)
  3. Run the terminal (with the appropriate profile if necessary)

Expected behavior

The pixel shader is loaded and executed.

Actual behavior

The pixel shader is not loaded.

Comments

I have not been able to load any shader files at all in 1.7 from the official release, nor when I build it from source. Poking around in the debugger, I can see that the shader file path is definitely there when the JSON is read in:

CascadiaSettingsSerialization.cpp 1.7 branch

However it seems to disappear at some point between being read and sent to SetPixelShaderPath(). I'm not sure if it's being deserialized correctly because I don't really understand how I'm supposed to inspect the settings object; it doesn't behave the way I'd expect it to (just C++ things, I assume).

release-1.7

DxRenderer.cpp 1.7 branch

release-1.6

DxRenderer.cpp 1.6 branch

I've tried this on other machines that have never had any version of the Terminal installed and they all exhibit the same issue.

@ghost ghost added Needs-Triage It's a new issue that the core contributor team needs to triage at the next triage meeting Needs-Tag-Fix Doesn't match tag requirements labels Mar 3, 2021
@zadjii-msft
Copy link
Member

Well that's batty. Maybe that's what's causing #9338?

I'm gonna real quick @DHowett because he was helping investigate another bug where the shader path would get absolutely mangled before making it into the DxRenderer.

@zadjii-msft zadjii-msft added Area-Rendering Text rendering, emoji, complex glyph & font-fallback issues Area-Settings Issues related to settings and customizability, for console or terminal Issue-Bug It either shouldn't be doing this or needs an investigation. Priority-3 A description (P3) Product-Terminal The new Windows Terminal. labels Mar 3, 2021
@ghost ghost removed the Needs-Tag-Fix Doesn't match tag requirements label Mar 3, 2021
@zadjii-msft zadjii-msft added this to the Terminal v2.0 milestone Mar 3, 2021
@Nacimota
Copy link
Contributor Author

Nacimota commented Mar 3, 2021

Well that's batty. Maybe that's what's causing #9338?

I did see that issue, but I decided to post a separate one because they're using 1.6, which has no problems for me, and they're also experiencing an error message, which I'm not getting even if use a non-existent path (because it just becomes an empty string, I guess). Could still be related though? ¯\_(ツ)_/¯

@zadjii-msft
Copy link
Member

Yea, after re-reading #9338, they do definitely seem different. The warning dialog in that one's really throwing me for a loop. I mean, this one's crazy too. They're both crazy, just, each their own unique kind of crazy 😄

@DHowett DHowett added the zPreview-Service-Queued-1.13 A floating label that tracks the current Preview version for servicing purposes. label Mar 3, 2021
@DHowett
Copy link
Member

DHowett commented Mar 3, 2021

@PankajBhojwani Check this out!

TerminalSettings.h:117

        GETSET_PROPERTY(hstring, PixelShaderPath);

But look at all the other settings ...

        GETSET_SETTING(TerminalApp::TerminalSettings, bool, RetroTerminalEffect, false);
        GETSET_SETTING(TerminalApp::TerminalSettings, bool, ForceFullRepaintRendering, false);
        GETSET_SETTING(TerminalApp::TerminalSettings, bool, SoftwareRendering, false);
        GETSET_SETTING(TerminalApp::TerminalSettings, bool, ForceVTInput, false);

When we create a new TerminalSettings leaf object, it has no PixelShaderPath because it is not an inheritable setting.

The danger of macros with a bunch of identical names.

@DHowett DHowett removed the Needs-Triage It's a new issue that the core contributor team needs to triage at the next triage meeting label Mar 3, 2021
@zadjii-msft
Copy link
Member

zadjii-msft commented Mar 3, 2021

Maybe we should GET rid of the GETSET_ prefix, because that's not really relevant anymore. Or maybe just change GETSET_SETTING to SETTING. That would be at least visually distinct and mentally distinct from GETSET_PROPERTY

@ghost ghost added the In-PR This issue has a related PR label Mar 4, 2021
@ghost ghost closed this as completed in #9371 Mar 4, 2021
@ghost ghost added Resolution-Fix-Committed Fix is checked in, but it might be 3-4 weeks until a release. and removed In-PR This issue has a related PR labels Mar 4, 2021
ghost pushed a commit that referenced this issue Mar 4, 2021
<!-- Enter a brief description/summary of your PR here. What does it fix/what does it change/how was it tested (even manually, if necessary)? -->
## Summary of the Pull Request
Fix for #9354 

<!-- Please review the items on the PR checklist before submitting-->
## PR Checklist
* [x] Closes #9354 
* [x] CLA signed. If not, go over [here](https://cla.opensource.microsoft.com/microsoft/Terminal) and sign the CLA
* [ ] Tests added/passed
* [ ] Documentation updated. If checked, please file a pull request on [our docs repo](https://github.com/MicrosoftDocs/terminal) and link it here: #xxx
* [ ] Schema updated.
* [x] I work here
DHowett pushed a commit that referenced this issue Mar 4, 2021
As mentioned in #9354 (comment)

`GETSET_SETTING` is too visually similar to `GETSET_PROPERTY`, but with a _VERY_ different meaning. I think that merely changing the name of the macro would make it harder for us to make this mistake again.
DHowett pushed a commit that referenced this issue Mar 15, 2021
<!-- Enter a brief description/summary of your PR here. What does it fix/what does it change/how was it tested (even manually, if necessary)? -->
## Summary of the Pull Request
Fix for #9354

<!-- Please review the items on the PR checklist before submitting-->
## PR Checklist
* [x] Closes #9354
* [x] CLA signed. If not, go over [here](https://cla.opensource.microsoft.com/microsoft/Terminal) and sign the CLA
* [ ] Tests added/passed
* [ ] Documentation updated. If checked, please file a pull request on [our docs repo](https://github.com/MicrosoftDocs/terminal) and link it here: #xxx
* [ ] Schema updated.
* [x] I work here

(cherry picked from commit 5aaf5b4)
@DHowett DHowett removed the zPreview-Service-Queued-1.13 A floating label that tracks the current Preview version for servicing purposes. label Apr 8, 2021
@ghost
Copy link

ghost commented Apr 14, 2021

🎉This issue was addressed in #9371, which has now been successfully released as Windows Terminal v1.7.1033.0.:tada:

Handy links:

@ghost
Copy link

ghost commented Apr 14, 2021

🎉This issue was addressed in #9371, which has now been successfully released as Windows Terminal Preview v1.8.1032.0.:tada:

Handy links:

This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Area-Rendering Text rendering, emoji, complex glyph & font-fallback issues Area-Settings Issues related to settings and customizability, for console or terminal Issue-Bug It either shouldn't be doing this or needs an investigation. Priority-3 A description (P3) Product-Terminal The new Windows Terminal. Resolution-Fix-Committed Fix is checked in, but it might be 3-4 weeks until a release.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants