This source file includes following definitions.
- hook_raw_image_addr
- vid_get_viewport_live_fb
- vid_get_bitmap_fb
- vid_get_viewport_fb
- vid_get_viewport_fb_d
- vid_get_viewport_height
- camera_jpeg_count_str
- vid_get_viewport_width_proper
- vid_get_viewport_height_proper
- vid_get_viewport_fullscreen_width
- vid_get_viewport_fullscreen_height
- vid_get_palette_type
- vid_get_palette_size
- vid_get_bitmap_active_palette
- vid_get_bitmap_active_buffer
1 #include "platform.h"
2
3 char *hook_raw_image_addr()
4 {
5
6
7 return (char*) (*(int*)(0x53A4+0x18) ? 0x11A34C40 : 0x10805040);
8 }
9
10 void *vid_get_viewport_live_fb()
11 {
12 void **fb=(void **)0x21a0;
13 unsigned char buff = *((unsigned char*)0x2014);
14 if (buff == 0) buff = 2; else buff--;
15 return fb[buff];
16 }
17
18 void *vid_get_bitmap_fb()
19 {
20 return (void*)0x10361000;
21 }
22
23 void *vid_get_viewport_fb()
24 {
25 return (void*)0x10659DE0;
26 }
27
28 void *vid_get_viewport_fb_d()
29 {
30 return (void*)(*(int*)0x5114);
31 }
32
33
34 long vid_get_viewport_height()
35 {
36 return vid_get_viewport_height_proper();
37 }
38 char *camera_jpeg_count_str()
39 {
40
41 return (void*)0x45E58;
42 }
43
44 extern int _GetVRAMHPixelsSize();
45 extern int _GetVRAMVPixelsSize();
46
47 int vid_get_viewport_width_proper() {
48 return ((mode_get()&MODE_MASK) == MODE_PLAY)?720:_GetVRAMHPixelsSize();
49 }
50
51 int vid_get_viewport_height_proper() {
52 return ((mode_get()&MODE_MASK) == MODE_PLAY)?240:_GetVRAMVPixelsSize();
53 }
54
55 int vid_get_viewport_fullscreen_width() {
56 return vid_get_viewport_width_proper();
57 }
58 int vid_get_viewport_fullscreen_height() {
59 return vid_get_viewport_height_proper();
60 }
61
62
63 int vid_get_palette_type() { return 4; }
64 int vid_get_palette_size() { return 16*4; }
65 void *vid_get_bitmap_active_palette() {
66 return (void *)*(unsigned int*)(0x7BCC+0x20);
67 }
68
69 void *vid_get_bitmap_active_buffer()
70 {
71 return (void*)(*(int*)(0x7BCC+0xC));
72 }
73