Would it be possible to make an FSR ‘injection’ program once code goes open-source?

1 : Anonymous2021/07/06 18:34 ID: of12bq

It's just a thought, but could it be possible to make an FSR injector program in the future with how FSR works/shown, as to give it to games 'universally'? Or would it not be as simple as that and developers would still have to implement that option into their games?

The thought mainly came from the recent GTA V FSR implementation that I saw, but again, I'm sure there's more work to it than just simply 'oh hey here's some funny code going brrrr'

2 : Anonymous2021/07/06 20:09 ID: h49xcjv

Possible, but not necessarily all that easy.

Since it's just another shader, getting it into a game isn't really the difficult part. The difficult part is getting the game to use the output correctly. The function of FSR is to upsample, so it modifies the size of the frame, which isn't going to just work out of the box with most games.

The reason it's easy to put into GTA V is because that game has a built-in frame scale option that renders at a lower resolution and upscales the output. All that needs to be done is to replace the built-in bilinear upsampler with the FSR shader, because the game already knows the output frame will be larger.

So I'd expect games which have some kind of built-in render scale option to be more easily modified, and I'd expect games which have no such functionality to be either difficult to modify or maybe even impossible.

ID: h4a55vh

This makes a ton of sense. Could be put into games like Resident Evil 2/3 remake then too 🙂

ID: h4euoav

I know it's a bad game but then maybe it will work on Cyberpunk 2077 too?

ID: h4bd8yj

Won't that just downsample as long as you have scaling set up in the gpu software? UI scaling would suck though.

ID: h4boc2k

It's possible to have ui at native and the game render at less or am I misinterpreting your comment?

3 : Anonymous2021/07/06 19:20 ID: h49qp3d

I don't know if it's possible to make it generic.

It's possible to apply it as a post-filter, but that's not optimal. It could still provide some benefit, and I'm sure that people will try it.

Other than this, it'd probably require some game-specific hacking, but that shouldn't be that hard, I think. My feeling is that in theory AMD could apply it themselves to specific games via the driver if they wanted.

ID: h49ta2n

Wouldn’t that make it an amd tech only? If it only came with amd drivers?

ID: h49tgfa

It's open source.

ID: h4bnhn4

NVIDIA and Intel could do the same thing. The only point of putting it in the driver is to make it more easily accessible to users. It's also possible that legally AMD will have to get permission from companies to do it.

I don't think that AMD will go this way anyway. The better way would be to get as many companies as possible to integrate it directly. However, that would still limit the scope of games.

4 : Anonymous2021/07/07 03:26 ID: h4bdgph

There is a guy experimenting with what seems to be an FSR injector for VR.

/comments/ob8vhm/ive_experimented_with_injecting_fsr_into_vr_games/?utm_source=share&utm_medium=web2x&context=3" class="reddit-press-link" target="_blank" rel="noopener">https://www.reddit.com//comments/ob8vhm/ive_experimented_with_injecting_fsr_into_vr_games/?utm_source=share&utm_medium=web2x&context=3

This post makes it sound like OP injected a version of Riftbreaker's fsr code and started testing it in fallout 4 vr.

I tried the build he has on github (which is just a dll for what I assume is fallout 4 vr and not the tool itself for VR) it definitely can be injected at least in VR through the openvr api dll. Injecting it into something else like an excecutable would likely be doable but it won't be "true" fsr due to where it gets placed in the rendering pipeline.

5 : Anonymous2021/07/06 18:46 ID: h49m76c

Yes, but it will not be as good as a native implementation, as it will also scale UI and text.

ID: h49mki3

That would be the case if it was added in post processing, like with ReShade.

OP asked for an "injection" type of thing where you, as I understood him, have a tool to patch any game to automatically place the FSR pass at the exact position it has to be within the render pipeline.

And that's very unlikely.

Adding it in post would even be possible for AMD themselfes, they'd just have to include the edge reconstruction algorithm in RIS. And even though it would also affect UI and text aswell as other not wanted post processing effects, the difference to a native implementation of FSR could be minimal in many games(especially if you turn off motion blur or film grain anyway) and would be worthy as an optional feature(also would give Radeon GPUs an additional selling point).

ID: h49qure

I'm told (don't use it myself) reshade has the option to ignore certain parts of the screen, specifically for UI elements. Once the game has a resolution scaler, then the UI would be native and you could use FSR on the rest.

6 : Anonymous2021/07/07 02:20 ID: h4b63la

I don't have an opinion on how easy injection will be, but I can predict that open source engines/games will receive "FSR modules" or whatever you'd call them pretty soon after it goes open source.

7 : Anonymous2021/07/06 20:22 ID: h49z8az

I would love to see it get added to something like steam proton to add the feature to games that don't already have it I know its unlikely but a man can dream

ID: h4as1rt

Basically exactly what I was going to say. Add it to Proton rendering with the default being the ultra quality setting. Similar quality to native and "better than Windows" gaming performance.

8 : Anonymous2021/07/07 16:46 ID: h4ddtq3

At that point it would be a post process which would bring some issues with it.

9 : Anonymous2021/07/07 06:55 ID: h4bv77a

Obviously possible, but also obviously not with a generic dll. It would have to be an implementation on a nearly per-game basis.

10 : Anonymous2021/07/06 20:35 ID: h4a1386

Isn't FSR kind of a "pre-processing" filter rather than a post processing filter?

I thought FSR did its magic before the frame hits the screen, not after. If it's a pre-processing filter then I'm not sure an after the fact, post processing filter would be able to do the job.

Chocolate syrup versus chocolate ice cream, y'know?

ID: h4a82u5

That's not really how that works... its *just a filter* ... it just happens that the best and least expensive place to apply it is before final render compositing. This is so things like HUD don't have to get processed and can run at normal full resolution rather than getting pushed through a wierd filter for no reason.

that said game developers can apply it anywhere they want... if a games HUD were for instance particularly GPU intensive for some reason, they could apply it there also.

ID: h4boi8z

What kind if things can make a hud intensive?

11 : Anonymous2021/07/07 15:51 ID: h4d6ay4

I entered the group thinking they will argue about GPUs ... WTF ARE YOU TALKING ABOUT BRO ? + random question , is programing that interesting and fun ?

12 : Anonymous2021/07/07 05:52 ID: h4bqpcw

FSR is supposed to explicitly implemented in the code as it, in order to work properly, has to does his work before certain steps of rendering.

So its not like you just slam it in there, you still have to place it in the right order and eventuall even adjust your rendering tho it is a lot easier than implementing DLSS.

So an "injector" program is BS since your "program" wouldnt know where to intervene in the rendering process since there is a lot of different ways to built your render algorithm and even more APIs...

ID: h4btfx7

The main reason for this, is to have speciifc passes,passed through to FSR, FSR to process it, then the UI elements to be added on top. If you just inject it, it will FSR everything and the UI wont look as crispy, and it may not have all the passes it needs to process the underlying image correctly

ID: h4dpmk9

And the other problem is that if you just inject it, it's trying to upscale to the size of the game's window. So if you have a game that just has resolution settings, you're out of luck. All you'll be getting is a sharpening pass, no upscaling since both the game resolution and the game window are the same.

ID: h4dhl14

I don't care about UI just give me FSR in all games or atleast in the games having a built in upscaler like gta V had.


Notify of
Inline Feedbacks
View all comments
Would love your thoughts, please comment.x