source: branches/release-1_0/platform/ixus65_sd630/sub/100a/lib.c @ 1860

Revision 1860, 1.8 KB checked in by philmoz, 13 months ago (diff)

Update to IXUS65 from srsa_4c
http://chdk.setepontos.com/index.php?topic=650.msg85583#msg85583

  • Property svn:eol-style set to native
Line 
1#include "platform.h"
2
3char *hook_raw_image_addr()
4{
5    return (char*)0x105B8AC0;
6}
7
8long hook_raw_size()
9{
10    return 0x75A8F0;
11}
12
13/**
14 * OSD screen
15 */
16void *vid_get_bitmap_fb()
17{
18    return (void*)0x103C79A0;
19}
20
21void *vid_get_viewport_live_fb() // from a420
22{
23       void **fb=(void **)0x52c8; // ixus65, @ 0xff8a7b94
24       unsigned char buff = *((unsigned char*)0x52d8);
25       if (buff == 0) {
26           buff = 2;
27       }
28       else {
29           buff--;
30       }
31       return fb[buff];
32}
33
34/**
35 * IMG viewport in 'rec' mode
36 */
37void *vid_get_viewport_fb()
38{
39    return (void*)0x105f17a0; //ixus65, the first of the 3 buffers
40}
41
42/**
43 * IMG viewport in 'play' mode
44 */
45void *vid_get_viewport_fb_d()
46{
47    //return (void*)0x104AFCA0;
48    int x=(*(int*)0x6dd4c);
49    return (void*) (x ? x : 0x105599a0) ; //ixus65, still incorrect when a stopped movie is displayed
50}
51
52long vid_get_bitmap_screen_width()
53{
54    return 360;
55}
56
57long vid_get_bitmap_screen_height()
58{
59    return 240;
60}
61
62long vid_get_viewport_height()
63{
64    return 240;
65}
66
67char *camera_jpeg_count_str()
68{
69    return (char*)0x79358;
70}
71
72void *vid_get_bitmap_active_buffer()
73{
74    return (void*)(*(int*)0x5ee4); // sub_ff93606c DisplayPhysicalScreenWithYUVPalette
75}
76
77void *vid_get_bitmap_active_palette() {
78    return (void *)0x6d6b0; // found also in sub_ff93606c
79}
80
81int vid_get_palette_type() { return 1; }
82int vid_get_palette_size() { return 16*4; }
83
84int vid_get_viewport_width_proper()  { return ((mode_get()&MODE_MASK) == MODE_PLAY)?720:*(int*)0x3d0e8;} //sub_ff8aa408
85int vid_get_viewport_height_proper() { return ((mode_get()&MODE_MASK) == MODE_PLAY)?240:*(int*)0x3d0ec;} //"VRAM DataSize H : %04ld, V : %04ld"
86
87int movie_status = 0;
88
89long vid_get_bitmap_buffer_width() { return 360; }
90
91long vid_get_bitmap_buffer_height() { return 240; }
Note: See TracBrowser for help on using the repository browser.