NVIDIAGameWorks / NVIDIAGameWorks/rtx-remix
Possible solution for replacing random material hashes attributes whenever diffuse texture changes
Nobody has claimed this yet.
- Dominant language
- No language data
- Stars
- 1.7k
- Forks
- 99
- PR merge metrics
- No merged PRs in 30d
Description
User story
- I, as a NFSU2 texture modder
- Would like to replace at least the roughness of car body materials, which by runtime's default are all rough, while keeping the game's original diffuse texture being fed to the new material.
Expected behaviour
A replacement material would set the roughness to a low value, and the diffuse texture would still be the same as the one set by the original game.
Actual behaviour
Since for each new customization the player does to the car (base paint, decals, vinyls...), a new diffuse texture is generated, the material captured by the runtime will have a new random hash for each combination of customizations (which is an exponentially large number)
Look at the Vinyl on the door
[EDIT]: Replacing the mesh's material with a new one, even if is just a roughness overwrite in the USD, also implicitly set the diffuse attribute to null.
Proposed Solution
Allow the diffuse texture (and likely other attributes) from the original game for the mesh to be forwarded to the replacement material, as long as the material's USD doesn't explicitly defines a diffuse asset input to replace with.
With that, a material could replace only the attributes it needs to and any other from the game would still render the same, instead of replacing every attribute implicitly.
With this constructive/incremental material overlay at attribute level, we could replace the mesh's materials for a lot of cases in which the resulting one would be a random mat_SOMEHASH, like animated ones, ingame generated textures like the mentioned case above, and so on.
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
No source file, test, or entry point is named. Start by tracing RTX Remix runtime material replacement while changing the car's customization and inspecting the generated material hashes; done means replacement materials preserve original diffuse and other unspecified attributes unless the USD explicitly overrides them.
Written by the indexing model from the issue text.
Assessment
- Domain
- computer-graphics, game-dev
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100