From eac9d5d60826fb303542b1dfed92478eaaa4ccae Mon Sep 17 00:00:00 2001 From: espes Date: Sun, 18 Oct 2015 02:40:58 +1100 Subject: [PATCH] texture cache and hash size tweak --- hw/xbox/nv2a.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/hw/xbox/nv2a.c b/hw/xbox/nv2a.c index 2a1c1e7afd..a67b7312e8 100644 --- a/hw/xbox/nv2a.c +++ b/hw/xbox/nv2a.c @@ -2786,7 +2786,7 @@ static void pgraph_bind_textures(NV2AState *d) #ifdef USE_TEXTURE_CACHE TextureKey key = { .state = state, - .data_hash = fast_hash(texture_data, length, 1000) + .data_hash = fast_hash(texture_data, length, 5003) ^ fnv_hash(palette_data, palette_length), .texture_data = texture_data, .palette_data = palette_data, @@ -3787,7 +3787,7 @@ static void pgraph_init(NV2AState *d) NULL, texture_key_retrieve, texture_key_destroy, texture_binding_destroy, NULL, NULL); - g_lru_cache_set_max_size(pg->texture_cache, 128); + g_lru_cache_set_max_size(pg->texture_cache, 512); pg->shader_cache = g_hash_table_new(shader_hash, shader_equal);