[PR #13998] [MERGED] Relax shader strictness in RELEASE mode #29878

Open
opened 2026-01-31 09:37:24 +00:00 by claunia · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/microsoft/terminal/pull/13998
Author: @mrange
Created: 9/14/2022
Status: Merged
Merged: 9/14/2022
Merged by: @undefined

Base: mainHead: mrange/relax_shader_strictness


📝 Commits (3)

  • c46f81c Relax shader strictness in RELEASE mode
  • 5dee5e3 Fixed small spelling error suggested by the workflow
  • 1f19d66 cord format

📊 Changes

2 files changed (+11 additions, -4 deletions)

View changed files

📝 src/cascadia/TerminalCore/TerminalSelection.cpp (+1 -1)
📝 src/renderer/atlas/AtlasEngine.cpp (+10 -3)

📄 Description

Disables strictness and warnings as errors for custom pixel shaders in
RELEASE. Windows terminal is not telling the user why the shader won't
compile which makes it very frustrating for the shader hacker.

After trying the recent preview none of my shaders loaded anymore in
Windows Terminal Preview which made me very sad. I had no idea what was
wrong with them. After cloning the git repo, building it, fighting an
issue that prevent DEBUG SDK from being used I finally was able to
identify some issues that were blocking my shaders.

error X3556: integer modulus may be much slower, try using uints if possible.
error X4000: use of potentially uninitialized variable (rayCylinder)

While the first one is a good warning I don't think it is an error and
the tools I use didn't flag it so was hard to know.

The second one I was staring at the code and was unable to identify what
exactly was causing the issues, I fumbled with the code a few times and
just felt the fun drain away.

IMHO: I want it to be fun to develop shaders for windows terminal.
Fighting invisible errors are not fun. I am not after building
production shaders for Windows Terminal, I want some cool effects. So
while I am as a .NET developer always runs with Warning as errors I
don't think it's the right option here. Especially since Windows
Terminal doesn't tell what is the problem.

However, I understand if the shaders you ship with Windows Terminal
should be free of errors and silly mistakes, so I kept the stricter
setting in DEBUG mode.

Validation Steps Performed

Loaded Windows Terminal in RELEASE and DEBUG mode and validated that
RELEASE mode had reduced strictness but DEBUG retained the previous more
restrictive mode.


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/microsoft/terminal/pull/13998 **Author:** [@mrange](https://github.com/mrange) **Created:** 9/14/2022 **Status:** ✅ Merged **Merged:** 9/14/2022 **Merged by:** [@undefined](undefined) **Base:** `main` ← **Head:** `mrange/relax_shader_strictness` --- ### 📝 Commits (3) - [`c46f81c`](https://github.com/microsoft/terminal/commit/c46f81c61155e8f715722eb15a61bb671a3b98ff) Relax shader strictness in RELEASE mode - [`5dee5e3`](https://github.com/microsoft/terminal/commit/5dee5e3c1fd27de3670902e826f91a813acf4407) Fixed small spelling error suggested by the workflow - [`1f19d66`](https://github.com/microsoft/terminal/commit/1f19d66f5293d78919e1aca9b34b3ef30ca857ab) cord format ### 📊 Changes **2 files changed** (+11 additions, -4 deletions) <details> <summary>View changed files</summary> 📝 `src/cascadia/TerminalCore/TerminalSelection.cpp` (+1 -1) 📝 `src/renderer/atlas/AtlasEngine.cpp` (+10 -3) </details> ### 📄 Description Disables strictness and warnings as errors for custom pixel shaders in RELEASE. Windows terminal is not telling the user why the shader won't compile which makes it very frustrating for the shader hacker. After trying the recent preview none of my shaders loaded anymore in Windows Terminal Preview which made me very sad. I had no idea what was wrong with them. After cloning the git repo, building it, fighting an issue that prevent DEBUG SDK from being used I finally was able to identify some issues that were blocking my shaders. > error X3556: integer modulus may be much slower, try using uints if possible. > error X4000: use of potentially uninitialized variable (rayCylinder) While the first one is a good warning I don't think it is an error and the tools I use didn't flag it so was hard to know. The second one I was staring at the code and was unable to identify what exactly was causing the issues, I fumbled with the code a few times and just felt the fun drain away. IMHO: I want it to be fun to develop shaders for windows terminal. Fighting invisible errors are not fun. I am not after building production shaders for Windows Terminal, I want some cool effects. So while I am as a .NET developer always runs with Warning as errors I don't think it's the right option here. Especially since Windows Terminal doesn't tell what is the problem. However, I understand if the shaders you ship with Windows Terminal should be free of errors and silly mistakes, so I kept the stricter setting in DEBUG mode. ## Validation Steps Performed Loaded Windows Terminal in RELEASE and DEBUG mode and validated that RELEASE mode had reduced strictness but DEBUG retained the previous more restrictive mode. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
claunia added the pull-request label 2026-01-31 09:37:24 +00:00
Sign in to join this conversation.
No Label pull-request
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/terminal#29878