Minor fixes and changes

This commit is contained in:
Alexandro Sánchez Bach 2014-07-23 20:36:57 +02:00
parent 602c436e1c
commit 3689560617
4 changed files with 10 additions and 8 deletions

View file

@ -156,9 +156,9 @@ int decrypt_data(rFile *in, rFile *out, EDAT_SDAT_HEADER *edat, NPD_HEADER *npd,
int length = 0;
int compression_end = 0;
if ((edat->flags & EDAT_FLAG_0x3C) != 0 || (edat->flags & EDAT_FLAG_0x3D) != 0)
if ((edat->flags & EDAT_FLAG_0x04) != 0)
{
LOG_ERROR(LOADER, "EDAT: Flag 0x3C/0x3D EDAT files are unsupported yet");
LOG_ERROR(LOADER, "EDAT: Flag 0x04 is not yet supported");
return -1;
}

View file

@ -5,12 +5,11 @@
#define SDAT_FLAG 0x01000000
#define EDAT_COMPRESSED_FLAG 0x00000001
#define EDAT_FLAG_0x02 0x00000002
#define EDAT_FLAG_0x04 0x00000004
#define EDAT_ENCRYPTED_KEY_FLAG 0x00000008
#define EDAT_FLAG_0x10 0x00000010
#define EDAT_FLAG_0x20 0x00000020
#define EDAT_DEBUG_DATA_FLAG 0x80000000
#define EDAT_FLAG_0x3C 0x0000003C
#define EDAT_FLAG_0x3D 0x0000003D
typedef struct
{

View file

@ -248,7 +248,7 @@ template<typename T> std::string GLFragmentDecompilerThread::GetSRC(T src)
std::string GLFragmentDecompilerThread::BuildCode()
{
//main += fmt::Format("\tgl_FragColor = %c0;\n", m_ctrl & 0x40 ? 'r' : 'h');
static const std::pair<std::string, std::string> table[] =
const std::pair<std::string, std::string> table[] =
{
{ "ocol0", m_ctrl & 0x40 ? "r0" : "h0" },
{ "ocol1", m_ctrl & 0x40 ? "r2" : "h2" },

View file

@ -1969,8 +1969,11 @@ void RSXThread::DoCmd(const u32 fcmd, const u32 cmd, mem32_ptr_t args, const u32
case NV309E_SET_FORMAT:
{
if (ARGS(0))
LOG_WARNING(RSX, "NV309E_SET_FORMAT: %x", ARGS(0));
const u8 height = ARGS(0) >> 24;
const u8 width = ARGS(0) >> 16;
const u8 format = ARGS(0);
const u32 offset = ARGS(1);
LOG_WARNING(RSX, "NV309E_SET_FORMAT: Format:0x%x, Width:%d, Height:%d, Offset:0x%x", format, width, height, offset);
}
break;
@ -2041,7 +2044,7 @@ void RSXThread::DoCmd(const u32 fcmd, const u32 cmd, mem32_ptr_t args, const u32
case NV308A_SET_CONTEXT_SURFACE:
{
if (ARGS(0))
LOG_WARNING(RSX, "NV3089_SET_CONTEXT_SURFACE: %x", ARGS(0));
LOG_WARNING(RSX, "NV308A_SET_CONTEXT_SURFACE: %x", ARGS(0));
}
break;