Unexpected renderer error occurred after specifying pixel shader path. #12804

Closed
opened 2026-01-31 03:25:25 +00:00 by claunia · 8 comments
Owner

Originally created by @lgx98 on GitHub (Mar 2, 2021).

Environment

Windows build number: 10.0.19042.0
Windows Terminal version (if applicable): 1.6.10571.0

Any other software?
* Cascadia Code
* Cascadia Code PL
* Cascadia Mono
* Cascadia Mono PL

Steps to reproduce

I had a fresh new Windows Terminal install from Microsoft Store;

downloaded example shaders from here;

added the following line to "Windows PowerShell" profile in settings.json and saved changes to file;

"experimental.pixelShaderPath": "‪‪D:\\temp\\Invert.hlsl",

restarted Windows Terminal and a warning popped up:
image
which translates to:

Warning
Renderer encountered an unexpected error: -2147024773
[OK]

And I think this warning message comes from this line.

I also tried changing the path to ‪D:/temp/Invert.hlsl; changing the path to an empty folder; adding obvious syntax errors to the hlsl file.
But nothing changed, every time the exact same warning message popped up.

Expected behavior

Nothing pops up and the screen color is inverted.

Actual behavior

Described above.

Originally created by @lgx98 on GitHub (Mar 2, 2021). <!-- 🚨🚨🚨🚨🚨🚨🚨🚨🚨🚨 I ACKNOWLEDGE THE FOLLOWING BEFORE PROCEEDING: 1. If I delete this entire template and go my own path, the core team may close my issue without further explanation or engagement. 2. If I list multiple bugs/concerns in this one issue, the core team may close my issue without further explanation or engagement. 3. If I write an issue that has many duplicates, the core team may close my issue without further explanation or engagement (and without necessarily spending time to find the exact duplicate ID number). 4. If I leave the title incomplete when filing the issue, the core team may close my issue without further explanation or engagement. 5. If I file something completely blank in the body, the core team may close my issue without further explanation or engagement. All good? Then proceed! --> <!-- This bug tracker is monitored by Windows Terminal development team and other technical folks. **Important: When reporting BSODs or security issues, DO NOT attach memory dumps, logs, or traces to Github issues**. Instead, send dumps/traces to secure@microsoft.com, referencing this GitHub issue. If this is an application crash, please also provide a Feedback Hub submission link so we can find your diagnostic data on the backend. Use the category "Apps > Windows Terminal (Preview)" and choose "Share My Feedback" after submission to get the link. Please use this form and describe your issue, concisely but precisely, with as much detail as possible. --> # Environment ```none Windows build number: 10.0.19042.0 Windows Terminal version (if applicable): 1.6.10571.0 Any other software? * Cascadia Code * Cascadia Code PL * Cascadia Mono * Cascadia Mono PL ``` # Steps to reproduce I had a fresh new Windows Terminal install from Microsoft Store; downloaded example shaders from [here](https://github.com/microsoft/terminal/tree/main/samples/PixelShaders); added the following line to "Windows PowerShell" profile in `settings.json` and saved changes to file; ```json "experimental.pixelShaderPath": "‪‪D:\\temp\\Invert.hlsl", ``` restarted Windows Terminal and a warning popped up: ![image](https://user-images.githubusercontent.com/25564437/109655324-1c9c8100-7b9e-11eb-91cd-0a4366b7f5b9.png) which translates to: > Warning > Renderer encountered an unexpected error: -2147024773 > [OK] And I think this warning message comes from [this line](https://github.com/microsoft/terminal/blob/81d773d2bfad7c906a42e47dc12569ec892ace69/src/cascadia/TerminalControl/TermControl.cpp#L698). I also tried changing the path to `‪D:/temp/Invert.hlsl`; changing the path to an empty folder; adding obvious syntax errors to the hlsl file. But nothing changed, every time the exact same warning message popped up. <!-- A description of how to trigger this bug. --> # Expected behavior Nothing pops up and the screen color is inverted. <!-- A description of what you're expecting, possibly containing screenshots or reference material. --> # Actual behavior Described above. <!-- What's actually happening? -->
Author
Owner

@zadjii-msft commented on GitHub (Mar 2, 2021):

Weird, that error is:

ERROR_INVALID_NAME The filename, directory name, or volume label syntax is incorrect. winerror.h

Which I don't think makes any sense. Does the retro terminal effect work for you? Use "experimental.retroTerminalEffect": true instead of experimental.pixelShaderPath

@zadjii-msft commented on GitHub (Mar 2, 2021): Weird, that error is: ERROR_INVALID_NAME | The filename, directory name, or volume label syntax is incorrect. | winerror.h -- | -- | -- Which I don't think makes any sense. Does the retro terminal effect work for you? Use `"experimental.retroTerminalEffect": true` instead of `experimental.pixelShaderPath`
Author
Owner

@lgx98 commented on GitHub (Mar 3, 2021):

"experimental.retroTerminalEffect": true works fine.

image

@lgx98 commented on GitHub (Mar 3, 2021): `"experimental.retroTerminalEffect": true` works fine. ![image](https://user-images.githubusercontent.com/25564437/109734160-7ed79f00-7bfb-11eb-881f-c65d6dd5f49f.png)
Author
Owner

@lgx98 commented on GitHub (Mar 3, 2021):

After trying "‪‪D:\temp\Invert.hlsl", "‪‪D:\temp\\Invert.hlsl" , "‪‪D:\\temp\Invert.hlsl" and several other strings, I somehow managed to "glitch" it and made it work properly with shader files under ‪‪D:\temp\.

image

However, when I changed the path from D:\temp\ to C:\Users\{Username}\temp\, the same warning message popped up just like before. (these two folders contain the same files)

image

Then I restarted Windows Terminal; changed path to other shader files in the same folder; tried to "glitch" again. But nothing new happened.

@lgx98 commented on GitHub (Mar 3, 2021): After trying `"‪‪D:\temp\Invert.hlsl"`, `"‪‪D:\temp\\Invert.hlsl"` , `"‪‪D:\\temp\Invert.hlsl"` and several other strings, I somehow managed to "glitch" it and made it work properly with shader files under `‪‪D:\temp\`. ![image](https://user-images.githubusercontent.com/25564437/109749677-15b15500-7c16-11eb-81e5-d0b3d93e1636.png) However, when I changed the path from `D:\temp\` to `C:\Users\{Username}\temp\`, the same warning message popped up just like before. (these two folders contain the same files) ![image](https://user-images.githubusercontent.com/25564437/109750472-78572080-7c17-11eb-97dd-322c546cb7a5.png) Then I restarted Windows Terminal; changed path to other shader files in the same folder; tried to "glitch" again. But nothing new happened.
Author
Owner

@zadjii-msft commented on GitHub (Mar 3, 2021):

Hey so, I know you've gone through the trouble of hiding your Windows username in your screenshots, but I'm worried now if that might be part of the problem. Does your username have any Chinese characters in it? I'm worried that the shader might fail to load if the path has non-ascii characters in it. If you don't want to share your username, could you try some other path with Chinese characters in it?

@zadjii-msft commented on GitHub (Mar 3, 2021): Hey so, I know you've gone through the trouble of hiding your Windows username in your screenshots, but I'm worried now if that might be part of the problem. Does your username have any Chinese characters in it? I'm worried that the shader might fail to load if the path has non-ascii characters in it. If you don't want to share your username, could you try some other path with Chinese characters in it?
Author
Owner

@lgx98 commented on GitHub (Mar 3, 2021):

Hey so, I know you've gone through the trouble of hiding your Windows username in your screenshots, but I'm worried now if that might be part of the problem. Does your username have any Chinese characters in it? I'm worried that the shader might fail to load if the path has non-ascii characters in it. If you don't want to share your username, could you try some other path with Chinese characters in it?

No, my username is made up of English letters and number digits. It's even a valid variable name in C/C++.

@lgx98 commented on GitHub (Mar 3, 2021): > Hey so, I know you've gone through the trouble of hiding your Windows username in your screenshots, but I'm worried now if that might be part of the problem. Does your username have any Chinese characters in it? I'm worried that the shader might fail to load if the path has non-ascii characters in it. If you don't want to share your username, could you try some other path with Chinese characters in it? No, my username is made up of English letters and number digits. It's even a valid variable name in C/C++.
Author
Owner

@zadjii-msft commented on GitHub (Mar 3, 2021):

Huh. Well there goes that theory. Here's another totally wild theory - does the drive matter? Can the Terminal consistently load shaders from the D:\ drive, but not the C:\ drive?

@zadjii-msft commented on GitHub (Mar 3, 2021): Huh. Well there goes that theory. Here's another totally wild theory - does the _drive_ matter? Can the Terminal consistently load shaders from the `D:\` drive, but not the `C:\` drive?
Author
Owner

@lgx98 commented on GitHub (Mar 4, 2021):

Everything is working perfectly today. I've tried both drives, path with Chinese characters, inside and outside $HOME.

But I have no idea on what caused this change. Basically I was browsing the Internet and making PowerPoints these days. There was neither system update, nor Windows Terminal Update.😂

@lgx98 commented on GitHub (Mar 4, 2021): Everything is working perfectly today. I've tried both drives, path with Chinese characters, inside and outside `$HOME`. But I have no idea on what caused this change. Basically I was browsing the Internet and making PowerPoints these days. There was neither system update, nor Windows Terminal Update.😂
Author
Owner

@zadjii-msft commented on GitHub (Mar 4, 2021):

Well. That's annoying that the repro is gone before we could figure it out. But I'm glad that it's fixed! I still have no idea what might have caused this. I suppose I'll keep my eyes open for future reports.

Thanks!

@zadjii-msft commented on GitHub (Mar 4, 2021): Well. That's annoying that the repro is gone before we could figure it out. But I'm glad that it's fixed! I still have no idea what might have caused this. I suppose I'll keep my eyes open for future reports. Thanks!
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/terminal#12804