mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-07-25 07:09:48 -06:00
Fixed texture encoding. Fixes the interaction with objects in Another Code R. Thanks to wordmanwords for the patch.
Fixes issue 5405.
This commit is contained in:
@ -259,7 +259,7 @@ void WriteIncrementSampleX(char*& p,API_TYPE ApiType)
|
|||||||
|
|
||||||
void WriteToBitDepth(char*& p, u8 depth, const char* src, const char* dest)
|
void WriteToBitDepth(char*& p, u8 depth, const char* src, const char* dest)
|
||||||
{
|
{
|
||||||
float result = pow(2.0f, depth) - 1.0f;
|
float result = 255 / pow(2.0f, (8 - depth));
|
||||||
WRITE(p, " %s = floor(%s * %ff);\n", dest, src, result);
|
WRITE(p, " %s = floor(%s * %ff);\n", dest, src, result);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user