Welcome, Guest.
Username: Password: Remember me

TOPIC: Reshade 3.0 file structure

Reshade 3.0 file structure 7 months 1 week ago #1

  • piltrafus
  • piltrafus's Avatar
  • Offline
  • Posts: 73
  • Thank you received: 15
Hi Crosire,
you already mentioned that 3.0 won't carry on with framework structure. That's great if it makes easier to customize reshade. I wanted to share my ideal of how a simpler file structure would work. Many people have hinted at similar ideas and I believe you mentioned something about it somewhere. Perhaps it'll be good to have a post dedicated to it so people can share their preferences.

* I would like for reshade to work with self contained shader files. Every shader.fx file should contain this three main parts (among other things)
- #defines / settings
- shader code
- techiques
* every shader.fx would be wrapped inside it's own namespace.
* the RESHADE folder could have a SHADERS, TEXTURES, SHADER_UNUSED subfolders. Only .fx files thrown in SHADERS would be read and compiled by reshade.
* The only extra file needed (aside from textures) would be the pipeline.cfg (created by reshade itself) that contains the order of the shader execution.
-EDIT- (moved this part to a different post)

I'm sure you already have a better plan for all this, but here's my view of it anyway.
Last Edit: 7 months 1 week ago by piltrafus.
The administrator has disabled public write access.

Reshade 3.0 file structure 7 months 1 week ago #2

  • crosire
  • crosire's Avatar
  • Offline
  • Posts: 2451
  • Thank you received: 1391
Current state of things:
  • Shaders are self-contained, because ReShade can now load multiple fx files. How the code inside is organized is up to the developer.
  • There is no ReShade folder. You can specify a number of search paths and ReShade will load every fx file it can find from those directories. Same for textures, ReShade searches for an image file in the specified texture search paths (options can be seen in gif #3).
  • There is no Pipeline.cfg either. Effects aren't ordered by changing their include order. That system is flawed and superfluous now. Instead you can order techniques directly (independent from the file they were loaded from, again, shown in gif #3). The order is saved and restored between game starts.
Cheers, crosire =)
The administrator has disabled public write access.
The following user(s) said Thank You: DeMondo, piltrafus, OtisInf

Reshade 3.0 file structure 7 months 1 week ago #3

crosire, can you give more detail on the new standard?

in 2.0, everything is basically pack inside reshade.fx, is it still the case in 3.0?
or is the .fx files consideared standalone in 3.0?
The administrator has disabled public write access.

Reshade 3.0 file structure 7 months 1 week ago #4

  • piltrafus
  • piltrafus's Avatar
  • Offline
  • Posts: 73
  • Thank you received: 15
That sounds perfect. You solved all the OP suggestions then. Hard to come with any good idea when you had them all already :P

Now I'll like to ask. How/where are the per shader settings stored? And how/where is the technique execution order stored? it's going to be easy to control by editing text files directly? I hope it is. some games may not allow the UI interaction for example. And I guess is necessary to share presets, right?
The administrator has disabled public write access.

Reshade 3.0 file structure 7 months 1 week ago #5

  • crosire
  • crosire's Avatar
  • Offline
  • Posts: 2451
  • Thank you received: 1391
kingeric1992 wrote:
crosire, can you give more detail on the new standard?

in 2.0, everything is basically pack inside reshade.fx, is it still the case in 3.0?
or is the .fx files consideared standalone in 3.0?
The latter. It's ok to have multiple techniques in one file too, doesn't matter. You can have as many fx files as you want. There's no single global ReShade.fx file anymore.

piltrafus wrote:
TNow I'll like to ask. How/where are the per shader settings stored? And how/where is the technique execution order stored? it's going to be easy to control by editing text files directly? I hope it is. some games may not allow the UI interaction for example. And I guess is necessary to share presets, right?
Don't know yet. Depends on how shaders should expose them, which I haven't decided yet: uniform variables, static constant variables or preprocessor defines.
Cheers, crosire =)
Last Edit: 7 months 1 week ago by crosire.
The administrator has disabled public write access.

Reshade 3.0 file structure 7 months 1 week ago #6

Does that means texture/uniforms/macros will not share between effect files?
The administrator has disabled public write access.

Reshade 3.0 file structure 7 months 1 week ago #7

  • crosire
  • crosire's Avatar
  • Offline
  • Posts: 2451
  • Thank you received: 1391
Yes. If you want that, create a "root" fx file which includes the other effects.
Cheers, crosire =)
The administrator has disabled public write access.
The following user(s) said Thank You: kingeric1992

Reshade 3.0 file structure 5 months 3 weeks ago #8

Correct me if I am wrong, but this seems to be more confusing than Reshade has been in the past. I haven't been keeping up with the updates to Reshade. I somehow completely missed the release of 2.0. Can you confirm that everything will be explained in a tutorial? Will all the effects we have now in 2.0 be available to add to 3.0?


Witanlore: Dreamtime
The administrator has disabled public write access.

Reshade 3.0 file structure 5 months 3 weeks ago #9

piltrafus wrote:
some games may not allow the UI interaction for example. And I guess is necessary to share presets, right?

I can confirm that all the media players that I have tried do not allow the UI to be brought up at all (probably because the video render window handle isnt the window handle that gets the keyboard messages), but ReShade 3 still loads and applies the effects if you manually create the necessary preset file. This was also the case with previous ReShade's tho, so....
The administrator has disabled public write access.