Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use xxhash for textures and palettes #190

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

Jarcho
Copy link

@Jarcho Jarcho commented Mar 23, 2023

fixes #140

Both the river of flame and various parts of act 5 need to hash over 1MB per frame. I've measured hashing adding about 20ms-50ms per frame which causes the frame rate to drop below 25fps at times. xxhash is more than 10x which is enough to remove get rid of the stalls.

Also fixes a potential collision issue with 32bit hashes. There are over 2000 hash collisions with fnv. Mods can add more on top of that.

@CaptainRay1993
Copy link

CaptainRay1993 commented Mar 24, 2023

This commit seems incompatible with Median XL. With self-compiled glide dll the game window looks as followed:
Screenshot (103)

@Jarcho
Copy link
Author

Jarcho commented Mar 24, 2023

It was actually totally broken. Last change I made without testing caused all textures of the same size to get the same hash. Fixed now.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Framerate drop at River of Flame
2 participants