Welcome, Guest.
Username: Password: Remember me

TOPIC: Small features to ease development, debugging

Small features to ease development, debugging 2 months 2 weeks ago #1

Just found ReShade a couple of days ago.
It's been fun, but I've hit a couple of limitations I have to bring up right away (:

The log is a little clumsy. The scrollbar usually returns to the top when the log tab is opened. It would be more useful to see the latest messages at the bottom. There is also no way to clear the log. I would personally clear it before every reload so there's no uncertainty about whether an error message is from the current or previous compilation. In case of epic failure where whole screens of errors get printed, the log somehow glitches and can't be scrolled all the way to the bottom.

When switching back to a fullscreen game, ReShade seems to recompile all shaders in the current preset, not just the enabled ones. This can make it a bit slow to use task switching. The same applies to the Reload button of course. The workaround is to move other shaders elsewhere when iterating one of them.

I would like a bit more profiling information. I guess I could use some external tool to get more data, tho I'm not familiar with any such tools. But even getting to see individual timings for each rendering pass in the shader would be very helpful. Currently GPU time is also not available at all of course.
Last Edit: 2 months 2 weeks ago by Ruuttu. Reason: more clear
The administrator has disabled public write access.

Small features to ease development, debugging 2 months 2 weeks ago #2

Ruuttu wrote:
The log is a little clumsy. The scrollbar usually returns to the top when the log tab is opened. It would be more useful to see the latest messages at the bottom. There is also no way to clear the log. I would personally clear it before every reload so there's no uncertainty about whether an error message is from the current or previous compilation. In case of epic failure where whole screens of errors get printed, the log somehow glitches and can't be scrolled all the way to the bottom.
These are some good ideas. I'll will see what I can do.

Ruuttu wrote:
When switching back to a fullscreen game, ReShade seems to recompile all shaders in the current preset, not just the enabled ones.
This is necessary because the width and height are hardcoded into the shaders, so every mode switch forces a recompile. In DX9 it is actually necessary for ReShade to do a full reinitialization because of restrictions the API imposes (all resources have to be deleted and recreated before a mode switch). But in DX10+/OpenGL ReShade does this too for code simplicity and the aforementioned reason.

Ruuttu wrote:
The same applies to the Reload button of course.
ReShade shares textures and constant buffer data between shaders, so it's not easily possible to reload just a subset of the currently loaded effects (since constants could change which would change pointers and mess up everything). Therefore ReShade has to clean up and reload them all unfortunately. There is a fast-loading option available as long as the UI is not visible, which loads only those effects active in the current preset. But as soon as the UI is activated, ReShade has to go back and load all shaders, since the user might enable/disable techniques.

Ruuttu wrote:
Currently GPU time is also not available at all of course.
Oh, but it is. You just need a DX10+ or OpenGL game for it to work. GPU timings are not working correctly in DX9 and thus hidden there.
Cheers, crosire =)
The administrator has disabled public write access.

Small features to ease development, debugging 2 months 2 weeks ago #3

Updated the log page with a "Clear Log" button and made the top (with the filter box and button) sticky, so you can scroll through the log without losing those. github.com/crosire/reshade/commit/86dddf...bdd96fe8d37082db1a4b
Cheers, crosire =)
The administrator has disabled public write access.
The following user(s) said Thank You: Wicked Sick, Fu-Bama

Small features to ease development, debugging 2 months 1 week ago #4

Ruuttu wrote:
I would like a bit more profiling information. I guess I could use some external tool to get more data, tho I'm not familiar with any such tools.
Check out GPU Shader Analyzer by AMD (works on Nvidia). It can show you compiled code, instruction count and others, so you know if change in a code actually has some performance benefit.
To set it up you have to add #ifndef ShaderAnalyzer between menu uniforms and add some macros with those variables. Shader analyzer should automatically open ReShade.fxh for all functions.

The administrator has disabled public write access.

Small features to ease development, debugging 2 months 1 week ago #5

Isn't perfect for debugging though because quite often, the performance of a shader is depending on what is onscreen such as SSAO.
Last Edit: 2 months 1 week ago by Marty McFly.
The administrator has disabled public write access.