dxvk-remix
dxvk-remix copied to clipboard
RemixApi: add AddTextureHash and RemoveTextureHash methods
This is one part of the PR that covers both the bridge and the runtime. The bridge PR can be found here: https://github.com/NVIDIAGameWorks/bridge-remix/pull/17
This PR implements two new API methods: AddTextureHash and RemoveTextureHash.
These can be used to add or remove individual texture hashes from texture category options (hash sets).
The SetConfigVariable is not practical in that regard as it only allows to set the entire option to the specified value and would require the user to craft the entire hash set string.
Example use cases:
- Some effect or similar that is using texture
XYis causing issues on a certain map and has to be hidden. But textureXYis also used in other parts of the game where it does not cause issues. - Multiplayer/Coop games where the player character is visible in first person view (and tagged as player body) to allow for shadows or virtual instances (Portal) but the player model changes based on the class/team etc. Prime example would be Portal 2 Coop where two different player models are in use. The two methods allow me to dynamically set/remove the player body texture hashes depending on which character you play.
Notheworthy changes:
- increased REMIXAPI_VERSION_MINOR from 5 to 6
Included fixes:
- fixes mismatching remixapi_InstanceCategoryBit enum (runtime issue #727) (https://github.com/NVIDIAGameWorks/rtx-remix/issues/727)
- fixes bridge issue #736 (https://github.com/NVIDIAGameWorks/rtx-remix/issues/736) that was caused by outdated api headers in
ext/remix/.
https://github.com/user-attachments/assets/c02047d9-7351-453f-9afd-cc49ed7ba973
if (ImGui::Button("Add Hash")) {
remix_api::get()->m_bridge.AddTextureHash("rtx.ignoreTextures", "0x990C1CCB42F806E0");
}
if (ImGui::Button("Remove Hash")) {
remix_api::get()->m_bridge.RemoveTextureHash("rtx.ignoreTextures", "0x990C1CCB42F806E0");
}
REMIX-4052