divVerent / s2tc

S2TC - a subset of a wellknown texture compression scheme (actually Color Cell Compression)
https://github.com/divVerent/s2tc/wiki
Other
43 stars 6 forks source link

Segfault with ETQW and Quake 4 #1

Closed lordheavy closed 11 years ago

lordheavy commented 12 years ago

It's segfaulting with ETQW and Quake 4, testures are distorted.


found DLL in pak file: /home/lordh/jeux/etqw/base/game002.pk4/gamex86.so copy gamex86.so to /home/lordh/.etqwcl/base/gamex86.so game using generic code for SIMD processing enabled Flush-To-Zero mode --------- Initializing Game ---------- gamename: baseETQW-1 gamedate: May 8 2008 Initializing global UI namespaces ...23 namespaces ...240 properties Initializing event system ...903 event definitions Initializing class hierarchy ...163 classes, 397320 bytes for event callbacks WARNING: Couldn't load sound 'video/intro_1024x512.theora', defaulting WARNING: idDeclLocal::ParseLocal Failed to Parse decl 'video/intro' in file 'sounds/cinematics.sndshd' line 0 Erreur de segmentation

lordheavy commented 11 years ago

From 7cbc816f44087138c575d279cc5725a4dc18e08d Mon Sep 17 00:00:00 2001 From: Laurent Carlier lordheavym@gmail.com Date: Sun, 16 Dec 2012 18:10:18 +0100 Subject: [PATCH] Add missing break statement

This fix segfault and textures with etqw and quake4.

s2tc_algorithm.cpp | 2 ++ 1 file changed, 2 insertions(+)

diff --git a/s2tc_algorithm.cpp b/s2tc_algorithm.cpp index 7b7bccd..57bb293 100644 --- a/s2tc_algorithm.cpp +++ b/s2tc_algorithm.cpp @@ -1309,8 +1309,10 @@ void rgb565_image(unsigned char out, const unsigned char rgba, int w, int h, i { case 3: rgb565_image<3>(out, rgba, w, h, alphabits, dither);

divVerent commented 11 years ago

Sorry for taking so long. The fix is applied... and was a simple but stupid oversight. Thanks for the patch!