root/platform/s95/sub/100k/lib.c

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

DEFINITIONS

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

   1 #include "platform.h"
   2 #include "stdlib.h"
   3 #include "lolevel.h"
   4 
   5 /*
   6 sensor size from code at FFB64E84 = (3744*2784)*(12/8) = 0xee9200 = 15634944
   7 
   8 @FFB64AAC = 0xea0 = 3744        // raw sensor size
   9 @FFB64AB4 = 0xae0 = 2784
  10 @FFB64ABC = 0xe40 = 3648        // cropped size ??
  11 @FFB64AC4 = 0xab0 = 2736
  12 */
  13 
  14 
  15 char *hook_raw_image_addr()
  16 {
  17         if (*((int*)0x2ECC) != 0)
  18                 return (char*) 0x46000000;
  19         else
  20                 return (char*) 0x41269150;
  21 }
  22 
  23 
  24 void *vid_get_viewport_live_fb()
  25 {
  26             return (void*) 0;
  27 
  28         // TODO - implement for s95 ?
  29 
  30 #if 0
  31         void **fb=(void **)0x94E18;
  32         unsigned char buff = *((unsigned char*)0x9114+6);
  33     if (buff == 0) buff = 2;  else buff--;
  34     return fb[buff];
  35 #endif
  36 }
  37 
  38 
  39 void *vid_get_bitmap_fb()
  40 {
  41         return (void*) 0x40471000;                                      // @FF85E704 - ok
  42 }
  43 
  44 
  45 void *vid_get_viewport_fb()
  46 {
  47         return (void*) 0x40587700;                                      // @FFB619C4 - ok
  48 }
  49 
  50 
  51 // Histo etc. when in play mode maybe ?
  52 void *vid_get_viewport_fb_d()
  53 {
  54         return (void*)(*(int*) (0x2c20+0x58));          // @FF87822C, FF878264 - ok
  55 }
  56 
  57 
  58 void JogDial_CW(void){
  59         _PostLogicalEventForNotPowerType(0x874, 2);  // RotateJogDialRight
  60 }
  61 
  62 
  63 void JogDial_CCW(void){
  64         _PostLogicalEventForNotPowerType(0x875, 2);  // RotateJogDialLeft
  65 }
  66 
  67 
  68 char *camera_jpeg_count_str()
  69 {
  70     return (char*) 0xBBC9C;                                             // @FFA3ACC4 - ok
  71 }

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