root/platform/g10/sub/104a/lib.c

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

DEFINITIONS

This source file includes following definitions.
  1. hook_raw_image_addr
  2. hook_alt_raw_image_addr
  3. camera_jpeg_count_str
  4. vid_get_bitmap_fb
  5. vid_get_viewport_fb
  6. vid_get_viewport_fb_d
  7. vid_get_viewport_live_fb
  8. vid_get_bitmap_active_buffer

   1 #include "platform.h"
   2 
   3 /*
   4 G10 sensor size from code at sub_FFACDE4C = (4480*3348)*(12/8) = 0x1574D00 = 22498560
   5 
   6 0x1180 = 4480   // raw sensor size  @ 0xFFACDE4C
   7 0xD14 =  3348   //                                      @ 0xFFACDE50
   8 0x1140 = 4416   // jpeg size 
   9 0xCF0 =  3312   //
  10 */
  11 
  12 char *hook_raw_image_addr()
  13 {
  14         // Appears to be two raw buffers (this returns active buffer)
  15         // Addresses below found in table at FFB1017C , ref at FFBBAD50
  16         // used in _sub_FF86837C__SsImgProcBuf.c__0 
  17         // checks [0x555C + 0x18] --> defines which buffer is active
  18 
  19         if (*((int*)0x5574) != 0)
  20                 return (char*)0x43164D80;                       // G10 @ 0xFFB101AC
  21         else
  22                 return (char*)0x413245A0;                       // G10 searched for aCrwaddressLxCr or for aCrawBuffP 0xFFACDE48
  23 }
  24 
  25 char *hook_alt_raw_image_addr()
  26 {
  27         // Appears to be two raw buffers (this returns active buffer)
  28         // Addresses below found in table at FFB1017C , ref at FFBBAD50
  29         // used in _sub_FF86837C__SsImgProcBuf.c__0 
  30         // checks [0x555C + 0x18] --> defines which buffer is active
  31 
  32         if (*((int*)0x5574) == 0)
  33                 return (char*) 0x43164D80;                      // G10 @ 0xFFB101AC
  34         else
  35                 return (char*)0x413245A0;                       // G10 searched for aCrwaddressLxCr or for aCrawBuffP 0xFFACDE48
  36 }
  37 
  38 
  39 char *camera_jpeg_count_str()
  40 {
  41         return (char*)0x0004c95c;                               // G10 autofound @0xff9cccdc
  42 } 
  43 
  44 void *vid_get_bitmap_fb()
  45 {
  46         return (void*)0x40471000;                               // G10 autofound @0xff846a4c DispCon_ShowBitmapColorBar 
  47 }
  48 
  49 void *vid_get_viewport_fb()
  50 {
  51         return (void*)0x40816dc0;                               // G10 autofound @0xffad4d70 -  search on VRAM Address
  52 }
  53 
  54 void *vid_get_viewport_fb_d()                           // G10 found
  55 {
  56         return (void*)(*(int*)(0x524C+0x54));   // @FF85ADD8 & FF85AE28 (comp S95, G11 - search for aImageplayer_c)
  57 }                                                                                       // @FF85B864 & FF85B89C
  58 
  59 void *vid_get_viewport_live_fb()        // G10 @ FF83A41C routine - match with IXUS980_SD990
  60 {       
  61     void **fb=(void **)0x2298;
  62     unsigned char buff = *((unsigned char*)0x20FC);
  63     if (buff == 0) {
  64         buff = 2;
  65     }
  66     else {
  67         buff--;
  68     }
  69     return fb[buff];
  70 }
  71 
  72 // ptp
  73 void *vid_get_bitmap_active_buffer()
  74 {
  75     return (void*)(*(int*)(0x8034+0x14)); // sub_FF8F331C via "Add: %p Width : %ld Hight : %ld", 
  76 }
  77 

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