aboutsummaryrefslogtreecommitdiff
path: root/libpsn00b/psxgpu/gettimimage.c
diff options
context:
space:
mode:
authorJohn "Lameguy" Wilbert Villamor <lameguy64@gmail.com>2022-09-26 16:49:56 +0800
committerGitHub <noreply@github.com>2022-09-26 16:49:56 +0800
commitc4a2533d21dfd05cde841ea48c67b05e0e6a853f (patch)
treec7ef61653b157b69fb0956709366996ddbc4ecfa /libpsn00b/psxgpu/gettimimage.c
parenta8b404b3400c3ebd8e0b923dcaefcc49ea563e36 (diff)
parent86f0064afb8200e60dd80827535cac30d0eab028 (diff)
downloadpsn00bsdk-c4a2533d21dfd05cde841ea48c67b05e0e6a853f.tar.gz
Merge pull request #55 from spicyjpeg/psxmdec
Full MDEC support, C library refactors, cleanups and bugfixes (v0.20)
Diffstat (limited to 'libpsn00b/psxgpu/gettimimage.c')
-rw-r--r--libpsn00b/psxgpu/gettimimage.c40
1 files changed, 0 insertions, 40 deletions
diff --git a/libpsn00b/psxgpu/gettimimage.c b/libpsn00b/psxgpu/gettimimage.c
deleted file mode 100644
index 5598e07..0000000
--- a/libpsn00b/psxgpu/gettimimage.c
+++ /dev/null
@@ -1,40 +0,0 @@
-#include <sys/types.h>
-#include <psxgpu.h>
-
-int GetTimInfo(const u_long *tim, TIM_IMAGE *timimg) {
-
- u_long *rtim;
-
- // Check ID
- if( ( tim[0]&0xff ) != 0x10 ) {
- return 1;
- }
-
- // Check version
- if( ( (tim[0]>>8)&0xff ) != 0x0 ) {
- return 2;
- }
-
- timimg->mode = tim[1];
- rtim = tim+2;
-
- // Clut present?
- if( timimg->mode & 0x8 ) {
-
- timimg->crect = (RECT*)(rtim+1);
- timimg->caddr = (u_long*)(rtim+3);
-
- rtim += rtim[0]>>2;
-
- } else {
-
- timimg->caddr = 0;
-
- }
-
- timimg->prect = (RECT*)(rtim+1);
- timimg->paddr = (u_long*)(rtim+3);
-
- return 0;
-
-}