root/platform/ixus950_sd850/sub/100c/lib.c

/* [<][>][^][v][top][bottom][index][help] */

DEFINITIONS

This source file includes following definitions.
  1. hook_raw_fptr
  2. hook_raw_ret_addr
  3. hook_raw_image_addr
  4. vid_get_viewport_live_fb
  5. vid_get_bitmap_fb
  6. vid_get_viewport_fb
  7. vid_get_viewport_fb_d
  8. vid_get_viewport_height
  9. camera_jpeg_count_str

   1 #include "platform.h"
   2 #include "keyboard.h"
   3 
   4 /***********
   5 for the next two functions, see in loc_FF9B84F0:
   6 FF9B8510  LDR     R3, =0x55EA4
   7 FF9B8514  LDR     R2, =0x55EA0    ; <- *raw_fptr
   8 FF9B8518  LDR     R0, [R3]
   9 FF9B851C  MOV     LR, PC
  10 FF9B8520  LDR     PC, [R2]
  11 FF9B8524  BL      nullsub_106     ; <- raw_ret_addr should point here
  12 FF9B8528  LDR     R3, =0x6F14
  13 ***********/
  14 
  15 void *hook_raw_fptr()
  16 {
  17     return (void*)0x55EA0;
  18 }
  19 
  20 void *hook_raw_ret_addr()
  21 {
  22     return (void*)0xFF9B8524;
  23 }
  24 
  25 /***********
  26 for the next two functions, see after "A/%08x.CRW" at FF9A7A60:
  27   MOVL    R7, 0x10F3C000
  28   MOV     R3, #0x9D0000
  29   ADD     R7, R7, #0x1A00
  30   ADD     R3, R3, #0xCC00
  31   ...
  32   ADD     R3, R3, #0xE0
  33 ***********/
  34 
  35 char *hook_raw_image_addr()
  36 {
  37     return (char*)(0x10F3DA00); // 0x10F3C000 + 0x1A00
  38 }
  39 
  40 void *vid_get_viewport_live_fb() // live picture buffer (shoot not pressed)
  41 {
  42 //      return ((void **)0x8C58)[*((unsigned char*)0x8C74)];
  43     void **fb=(void **)0x8C58;
  44     unsigned char buff = *((unsigned char*)0x8C74);
  45     if (buff == 0) {
  46         buff = 2;
  47     }
  48     else {
  49         buff--;
  50     }
  51     return fb[buff];
  52 }
  53 
  54 void *vid_get_bitmap_fb()       // OSD buffer
  55 {
  56     return (void*)0x10361000;   // 0x10360000 + 0x1000, see after "BmpDDev.c" in loc_FFA2DDEC
  57 }
  58 
  59 void *vid_get_viewport_fb()     // live picture buffer (shoot half-pressed)
  60 {
  61         return ((void **)0x8C58)[*((unsigned char*)0x8C74)];
  62 }
  63 
  64 void *vid_get_viewport_fb_d()   // picture buffer (play mode)
  65 {
  66     return (void*)(*(int*)0x812C8); // see before "ImagePlayer.c" in loc_FFAC3E90
  67 }
  68 
  69 long vid_get_viewport_height()
  70 {
  71     return ((mode_get()&MODE_MASK) == MODE_PLAY)?240:230;
  72 }
  73 
  74 char *camera_jpeg_count_str()
  75 {
  76     return (char*)0x143D0;
  77 }

/* [<][>][^][v][top][bottom][index][help] */