Addon that reads in-game FOV

  • Fu-Bama
  • Topic Author
More
3 years 2 months ago #1 by Fu-Bama Addon that reads in-game FOV was created by Fu-Bama
Would it be possible to create addon that gets field of view value from projection matrix?
It would be useful for RTGI and PerfectPerspective, to expose FOV as a global variable.

Here, on DirectX website, projection matrix components are explained:
docs.microsoft.com/en-us/windows/win32/d...projection-transform
From that, an FOV angle could be retrieved using:
float getFov(float w) { return 2f*atan(1f/w); }
Is it possible?

Please Log in or Create an account to join the conversation.

  • crosire
More
3 years 2 months ago - 3 years 2 months ago #2 by crosire Replied by crosire on topic Addon that reads in-game FOV
Sure, if you know where the game stores that in memory (can e.g. find out with Cheat Engine), then it's not difficult to read that an expose it with crosire.github.io/reshade-docs/structres...94e4289d30605a5c9742 .
Last edit: 3 years 2 months ago by crosire.
The following user(s) said Thank You: Fu-Bama

Please Log in or Create an account to join the conversation.

We use cookies
We use cookies on our website. Some of them are essential for the operation of the forum. You can decide for yourself whether you want to allow cookies or not. Please note that if you reject them, you may not be able to use all the functionalities of the site.