root/platform/ixus240_elph320hs/sub/101a/movie_rec.c

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

DEFINITIONS

This source file includes following definitions.
  1. change_video_tables
  2. set_quality
  3. movie_record_task
  4. sub_FF1E9670_my
  5. sub_FF3BE1E8_my

   1 /*
   2  * movie_rec.c - auto-generated by CHDK code_gen.
   3  */
   4 #include "conf.h"
   5 
   6 void change_video_tables(__attribute__ ((unused))int a, __attribute__ ((unused))int b) {}
   7 
   8 void  set_quality(int *x){ // -17 highest; +12 lowest
   9  if (conf.video_mode) *x=12-((conf.video_quality-1)*(12+17)/(99-1));
  10 }
  11 
  12 /*************************************************************/
  13 //** movie_record_task @ 0xFF1EA0F0 - 0xFF1EA268, length=95
  14 void __attribute__((naked,noinline)) movie_record_task() {
  15 asm volatile (
  16 "    STMFD   SP!, {R2-R10,LR} \n"
  17 "    LDR     R6, =0xFF1E8D78 \n"
  18 "    LDR     R7, =0xFF1E9AE4 \n"
  19 "    LDR     R4, =0xAC60 \n"
  20 "    LDR     R9, =0x69B \n"
  21 "    LDR     R10, =0x2710 \n"
  22 "    MOV     R8, #1 \n"
  23 "    MOV     R5, #0 \n"
  24 
  25 "loc_FF1EA110:\n"
  26 "    LDR     R0, [R4, #0x24] \n"
  27 "    MOV     R2, #0 \n"
  28 "    ADD     R1, SP, #4 \n"
  29 "    BL      sub_0068EF6C /*_ReceiveMessageQueue*/ \n"
  30 "    LDR     R0, [R4, #0x2C] \n"
  31 "    CMP     R0, #0 \n"
  32 "    LDRNE   R0, [R4, #0xC] \n"
  33 "    CMPNE   R0, #2 \n"
  34 "    LDRNE   R0, [R4, #0x44] \n"
  35 "    CMPNE   R0, #6 \n"
  36 "    BNE     loc_FF1EA24C \n"
  37 "    LDR     R0, [SP, #4] \n"
  38 "    LDR     R1, [R0] \n"
  39 "    SUB     R1, R1, #2 \n"
  40 "    CMP     R1, #0xD \n"
  41 "    ADDCC   PC, PC, R1, LSL#2 \n"
  42 "    B       loc_FF1EA24C \n"
  43 "    B       loc_FF1EA1EC \n"
  44 "    B       loc_FF1EA210 \n"
  45 "    B       loc_FF1EA220 \n"
  46 "    B       loc_FF1EA228 \n"
  47 "    B       loc_FF1EA230 \n"
  48 "    B       loc_FF1EA238 \n"
  49 "    B       loc_FF1EA1F4 \n"
  50 "    B       loc_FF1EA240 \n"
  51 "    B       loc_FF1EA200 \n"
  52 "    B       loc_FF1EA24C \n"
  53 "    B       loc_FF1EA248 \n"
  54 "    B       loc_FF1EA1B8 \n"
  55 "    B       loc_FF1EA188 \n"
  56 
  57 "loc_FF1EA188:\n"
  58 "    STR     R5, [R4, #0x40] \n"
  59 "    STR     R5, [R4, #0x30] \n"
  60 "    STR     R5, [R4, #0x34] \n"
  61 "    STRH    R5, [R4, #6] \n"
  62 "    STR     R6, [R4, #0xD4] \n"
  63 "    STR     R7, [R4, #0xF0] \n"
  64 "    LDR     R0, [R4, #0xC] \n"
  65 "    ADD     R0, R0, #1 \n"
  66 "    STR     R0, [R4, #0xC] \n"
  67 "    MOV     R0, #6 \n"
  68 "    STR     R0, [R4, #0x44] \n"
  69 "    B       loc_FF1EA1D8 \n"
  70 
  71 "loc_FF1EA1B8:\n"
  72 "    STR     R5, [R4, #0x40] \n"
  73 "    STR     R5, [R4, #0x30] \n"
  74 "    STR     R6, [R4, #0xD4] \n"
  75 "    STR     R7, [R4, #0xF0] \n"
  76 "    LDR     R0, [R4, #0xC] \n"
  77 "    ADD     R0, R0, #1 \n"
  78 "    STR     R0, [R4, #0xC] \n"
  79 "    STR     R8, [R4, #0x44] \n"
  80 
  81 "loc_FF1EA1D8:\n"
  82 "    LDR     R2, =0xFF1E8250 \n"
  83 "    LDR     R1, =0x121A5C \n"
  84 "    LDR     R0, =0xFF1E8364 \n"
  85 "    BL      sub_FF055528 \n"
  86 "    B       loc_FF1EA24C \n"
  87 
  88 "loc_FF1EA1EC:\n"
  89 );
  90 if (conf.ext_video_time == 1)
  91 {
  92 asm volatile (
  93 "    BL      sub_FF1E9670_my \n"  // --> Patched. Old value = 0xFF1E9670.
  94 );
  95 }
  96 else
  97 {
  98 asm volatile (
  99 "    BL      sub_FF1E9670 \n"
 100 );
 101 }
 102 asm volatile (
 103 "    B       loc_FF1EA24C \n"
 104 
 105 "loc_FF1EA1F4:\n"
 106 "    LDR     R1, [R4, #0xF0] \n"
 107 "    BLX     R1 \n"
 108 //begin patch
 109 "    LDR     R0, =video_compression_rate\n" //added
 110 "    BL      set_quality\n"                 //added
 111 //end patch
 112 "    B       loc_FF1EA24C \n"
 113 
 114 "loc_FF1EA200:\n"
 115 "    LDR     R1, [R0, #0x18] \n"
 116 "    LDR     R0, [R0, #4] \n"
 117 "    BL      sub_FF3BFA94 \n"
 118 "    B       loc_FF1EA24C \n"
 119 
 120 "loc_FF1EA210:\n"
 121 "    LDR     R0, [R4, #0x44] \n"
 122 "    CMP     R0, #5 \n"
 123 "    STRNE   R8, [R4, #0x34] \n"
 124 "    B       loc_FF1EA24C \n"
 125 
 126 "loc_FF1EA220:\n"
 127 "    BL      sub_FF1E89E0 \n"
 128 "    B       loc_FF1EA24C \n"
 129 
 130 "loc_FF1EA228:\n"
 131 "    BL      sub_FF1E86C4 \n"
 132 "    B       loc_FF1EA24C \n"
 133 
 134 "loc_FF1EA230:\n"
 135 "    BL      sub_FF1E83C8 \n"
 136 "    B       loc_FF1EA24C \n"
 137 
 138 "loc_FF1EA238:\n"
 139 "    BL      sub_FF1E7F78 \n"
 140 "    B       loc_FF1EA24C \n"
 141 
 142 "loc_FF1EA240:\n"
 143 "    BL      sub_FF1E7EF8 \n"
 144 "    B       loc_FF1EA24C \n"
 145 
 146 "loc_FF1EA248:\n"
 147 "    BL      sub_FF1EA824 \n"
 148 
 149 "loc_FF1EA24C:\n"
 150 "    LDR     R1, [SP, #4] \n"
 151 "    LDR     R3, =0xFF1E7B90 /*'MovieRecorder.c'*/ \n"
 152 "    STR     R5, [R1] \n"
 153 "    STR     R9, [SP] \n"
 154 "    LDR     R0, [R4, #0x28] \n"
 155 "    MOV     R2, R10 \n"
 156 "    BL      sub_0068AF18 /*_PostMessageQueueStrictly*/ \n"
 157 "    B       loc_FF1EA110 \n"
 158 );
 159 }
 160 
 161 /*************************************************************/
 162 //** sub_FF1E9670_my @ 0xFF1E9670 - 0xFF1E99A8, length=207
 163 void __attribute__((naked,noinline)) sub_FF1E9670_my() {
 164 asm volatile (
 165 "    STMFD   SP!, {R0-R10,LR} \n"
 166 "    LDR     R6, =0xAC60 \n"
 167 "    MOV     R0, #0 \n"
 168 "    STR     R0, [R6, #0x34] \n"
 169 "    STR     R0, [R6, #0x38] \n"
 170 "    MOV     R0, R6 \n"
 171 "    LDR     R4, [R0, #0x58] \n"
 172 "    LDRH    R1, [R6, #6] \n"
 173 "    MOV     R0, #0x3E8 \n"
 174 "    MUL     R0, R4, R0 \n"
 175 "    LDR     R8, =0xFFF00 \n"
 176 "    CMP     R1, #0 \n"
 177 "    MOV     R2, #1 \n"
 178 "    BNE     loc_FF1E96B8 \n"
 179 "    LDR     R1, [R6, #0x90] \n"
 180 "    CMP     R1, #0 \n"
 181 "    BNE     loc_FF1E96C8 \n"
 182 "    B       loc_FF1E96C0 \n"
 183 
 184 "loc_FF1E96B8:\n"
 185 "    CMP     R1, #3 \n"
 186 "    BNE     loc_FF1E96C8 \n"
 187 
 188 "loc_FF1E96C0:\n"
 189 "    STR     R2, [R6, #0x48] \n"
 190 "    B       loc_FF1E96D4 \n"
 191 
 192 "loc_FF1E96C8:\n"
 193 "    MOV     R1, #0x3E8 \n"
 194 "    BL      sub_006ACF38 /*__divmod_unsigned_int*/ \n"
 195 "    STR     R0, [R6, #0x48] \n"
 196 
 197 "loc_FF1E96D4:\n"
 198 "    LDR     R5, =0x121A90 \n"
 199 "    MOV     R7, #2 \n"
 200 "    LDR     R0, [R5, #8] \n"
 201 "    CMP     R0, #0 \n"
 202 "    BEQ     loc_FF1E9740 \n"
 203 "    CMP     R4, #0x18 \n"
 204 "    MOV     R0, #4 \n"
 205 "    BEQ     loc_FF1E972C \n"
 206 "    BGT     loc_FF1E9714 \n"
 207 "    CMP     R4, #0xA \n"
 208 "    CMPNE   R4, #0xF \n"
 209 "    STREQ   R7, [R5, #0x14] \n"
 210 "    BEQ     loc_FF1E9740 \n"
 211 "    CMP     R4, #0x14 \n"
 212 "    BNE     loc_FF1E9734 \n"
 213 "    B       loc_FF1E972C \n"
 214 
 215 "loc_FF1E9714:\n"
 216 "    CMP     R4, #0x19 \n"
 217 "    CMPNE   R4, #0x1E \n"
 218 "    BEQ     loc_FF1E972C \n"
 219 "    CMP     R4, #0x3C \n"
 220 "    BNE     loc_FF1E9734 \n"
 221 "    MOV     R0, #8 \n"
 222 
 223 "loc_FF1E972C:\n"
 224 "    STR     R0, [R5, #0x14] \n"
 225 "    B       loc_FF1E9740 \n"
 226 
 227 "loc_FF1E9734:\n"
 228 "    LDR     R0, =0xFF1E7B90 /*'MovieRecorder.c'*/ \n"
 229 "    MOV     R1, #0x790 \n"
 230 "    BL      _DebugAssert \n"
 231 
 232 "loc_FF1E9740:\n"
 233 "    LDR     R0, [R6, #0x64] \n"
 234 "    CMP     R0, #1 \n"
 235 "    BNE     loc_FF1E9758 \n"
 236 "    BL      sub_FF372B44 \n"
 237 "    LDR     R0, =0x121AA8 \n"
 238 "    BL      sub_FF3BBEE4 \n"
 239 
 240 "loc_FF1E9758:\n"
 241 "    LDR     R2, =0xAC62 \n"
 242 "    LDR     R0, [R6, #0xB4] \n"
 243 "    MOV     R3, #2 \n"
 244 "    MOV     R1, #0xAA \n"
 245 "    BL      sub_FF0B6B68 \n"
 246 "    LDR     R2, =0xAC64 \n"
 247 "    LDR     R0, [R6, #0xB4] \n"
 248 "    MOV     R3, #2 \n"
 249 "    MOV     R1, #0xA9 \n"
 250 "    BL      sub_FF0B6B68 \n"
 251 "    LDR     R2, =0xACB0 \n"
 252 "    LDR     R0, [R6, #0xB4] \n"
 253 "    MOV     R3, #4 \n"
 254 "    MOV     R1, #0xA2 \n"
 255 "    BL      sub_FF0B6B68 \n"
 256 "    LDR     R2, =0xACB4 \n"
 257 "    LDR     R0, [R6, #0xB4] \n"
 258 "    MOV     R3, #4 \n"
 259 "    MOV     R1, #0xA3 \n"
 260 "    BL      sub_FF0B6B68 \n"
 261 "    LDR     R0, [R6, #0x90] \n"
 262 "    CMP     R0, #0 \n"
 263 "    LDRNE   R2, =0xAD60 \n"
 264 "    MOVNE   R1, #0 \n"
 265 "    MOVNE   R0, #0xE \n"
 266 "    BLNE    _exmem_ualloc \n"
 267 "    LDR     R0, [R6, #0x4C] \n"
 268 "    LDR     R4, =0xAD60 \n"
 269 "    LDR     R9, =0x121A78 \n"
 270 "    CMP     R0, #1 \n"
 271 "    CMPNE   R0, #2 \n"
 272 "    BNE     loc_FF1E988C \n"
 273 "    LDR     R0, [R6, #0x90] \n"
 274 "    CMP     R0, #0 \n"
 275 "    LDRNE   R0, =0x483FC000 \n"
 276 "    STRNE   R0, [R4] \n"
 277 "    BNE     loc_FF1E988C \n"
 278 "    LDR     R1, =0x499EBCAC \n"
 279 "    LDR     R0, =0x2520754 \n"
 280 "    STR     R1, [R4] \n"
 281 "    STR     R0, [R4, #4] \n"
 282 "    LDMIA   R9, {R0,R2} \n"
 283 "    MUL     R0, R2, R0 \n"
 284 "    MOV     R3, R0, LSL#1 \n"
 285 "    CMP     R3, R8 \n"
 286 "    STR     R3, [R6, #0x9C] \n"
 287 "    MOVCC   R2, #0 \n"
 288 "    STR     R1, [R6, #0xA0] \n"
 289 "    BCC     loc_FF1E9854 \n"
 290 "    MOV     R2, #0 \n"
 291 "    STMEA   SP, {R1,R2,R8} \n"
 292 "    MOV     R3, R2 \n"
 293 "    MOV     R2, #9 \n"
 294 "    MOV     R1, #5 \n"
 295 "    MOV     R0, #0x16 \n"
 296 "    BL      sub_FF36CBA8 \n"
 297 "    LDR     R0, [R6, #0x9C] \n"
 298 "    MOV     R2, #0 \n"
 299 "    SUB     R3, R0, #0xF0000 \n"
 300 "    LDR     R0, [R6, #0xA0] \n"
 301 "    SUB     R3, R3, #0xFF00 \n"
 302 "    ADD     R1, R0, #0xF0000 \n"
 303 "    ADD     R1, R1, #0xFF00 \n"
 304 
 305 "loc_FF1E9854:\n"
 306 "    STMEA   SP, {R1-R3} \n"
 307 "    MOV     R3, #0 \n"
 308 "    MOV     R2, #9 \n"
 309 "    MOV     R1, #5 \n"
 310 "    MOV     R0, #0x16 \n"
 311 "    BL      sub_FF36CBA8 \n"
 312 "    LDR     R1, [R4] \n"
 313 "    LDR     R0, [R6, #0x9C] \n"
 314 "    ADD     R1, R1, R0, LSL#1 \n"
 315 "    STR     R1, [R4] \n"
 316 "    LDR     R1, [R4, #4] \n"
 317 "    RSB     R0, R0, #0 \n"
 318 "    ADD     R0, R1, R0, LSL#1 \n"
 319 "    STR     R0, [R4, #4] \n"
 320 
 321 "loc_FF1E988C:\n"
 322 "    LDR     R2, =0x121A90 \n"
 323 "    LDR     R3, =0xFF1E963C \n"
 324 "    LDR     R0, [R4, #4] \n"
 325 "    LDR     R1, [R4] \n"
 326 "    STRD    R2, [SP] \n"
 327 "    SUB     R3, R2, #0x18 \n"
 328 "    MOV     R2, R0 \n"
 329 "    LDR     R0, [R6, #0x90] \n"
 330 "    BL      sub_FF3BE1E8_my \n"  // --> Patched. Old value = 0xFF3BE1E8.
 331 "    LDRD    R0, [R6, #0xF8] \n"
 332 "    LDR     R2, [R6, #0xB4] \n"
 333 "    BL      sub_FF3BE7C4 \n"
 334 "    LDR     R3, =0xACE8 \n"
 335 "    STR     R3, [SP] \n"
 336 "    LDR     R0, [R6, #0x64] \n"
 337 "    LDR     R1, [R9, #8] \n"
 338 "    AND     R2, R0, #0xFF \n"
 339 "    LDR     R0, [R9] \n"
 340 "    SUB     R3, R3, #4 \n"
 341 "    BL      sub_FF3BBA4C \n"
 342 "    LDRH    R0, [R6, #6] \n"
 343 "    CMP     R0, #2 \n"
 344 "    LDREQ   R0, =0xFF1E9310 \n"
 345 "    STREQ   R0, [R6, #0xF0] \n"
 346 "    LDR     R0, [R6, #0x90] \n"
 347 "    CMP     R0, #0 \n"
 348 "    LDREQ   R1, =0xFF1E8EE0 \n"
 349 "    STREQ   R1, [R6, #0xF0] \n"
 350 "    LDR     R2, [R6, #0xC] \n"
 351 "    LDR     R1, =0xFF604014 \n"
 352 "    CMP     R2, #2 \n"
 353 "    BNE     loc_FF1E9930 \n"
 354 "    LDR     R0, [R6, #0x4C] \n"
 355 "    ADD     R0, R1, R0, LSL#3 \n"
 356 "    LDR     R1, [R9, #0xC] \n"
 357 "    LDR     R0, [R0, R1, LSL#2] \n"
 358 "    BL      sub_FF3718D8 \n"
 359 "    LDR     R0, =0xFF1E8E54 \n"
 360 "    MOV     R1, #0 \n"
 361 "    BL      sub_FF371E5C \n"
 362 "    B       loc_FF1E9968 \n"
 363 
 364 "loc_FF1E9930:\n"
 365 "    CMP     R0, #0 \n"
 366 "    LDR     R0, [R6, #0x4C] \n"
 367 "    ADD     R0, R1, R0, LSL#3 \n"
 368 "    LDR     R1, [R9, #0xC] \n"
 369 "    LDR     R0, [R0, R1, LSL#2] \n"
 370 "    BNE     loc_FF1E9958 \n"
 371 "    LDR     R1, [R6, #0x98] \n"
 372 "    BL      sub_FF371F3C \n"
 373 "    BL      sub_FF371FC0 \n"
 374 "    B       loc_FF1E9968 \n"
 375 
 376 "loc_FF1E9958:\n"
 377 "    BL      sub_FF36FAC4 \n"
 378 "    LDR     R0, =0xFF1E8E54 \n"
 379 "    MOV     R1, #0 \n"
 380 "    BL      sub_FF3702D4 \n"
 381 
 382 "loc_FF1E9968:\n"
 383 "    LDR     R0, [R5, #8] \n"
 384 "    CMP     R0, #0 \n"
 385 "    BEQ     loc_FF1E999C \n"
 386 "    ADD     R0, SP, #0xC \n"
 387 "    BL      sub_FF3BF7FC \n"
 388 "    LDR     R1, [R5, #0xC] \n"
 389 "    LDR     R0, [SP, #0xC] \n"
 390 "    BL      sub_FF068250 \n"
 391 "    ADD     R0, SP, #0xC \n"
 392 "    BL      sub_FF3BF7FC \n"
 393 "    LDR     R1, [R5, #0xC] \n"
 394 "    LDR     R0, [SP, #0xC] \n"
 395 "    BL      sub_FF068250 \n"
 396 
 397 "loc_FF1E999C:\n"
 398 "    LDR     R0, =0xFF1E8E0C \n"
 399 "    STR     R7, [R6, #0x44]! \n"
 400 "    STR     R0, [R6, #0x90] \n"
 401 "    LDMFD   SP!, {R0-R10,PC} \n"
 402 );
 403 }
 404 
 405 /*************************************************************/
 406 //** sub_FF3BE1E8_my @ 0xFF3BE1E8 - 0xFF3BE768, length=353
 407 void __attribute__((naked,noinline)) sub_FF3BE1E8_my() {
 408 asm volatile (
 409 "    STMFD   SP!, {R0-R11,LR} \n"
 410 "    MOV     R9, R0 \n"
 411 "    LDR     R0, [R3, #0x10] \n"
 412 "    SUB     SP, SP, #0xC \n"
 413 "    CMP     R0, #0 \n"
 414 "    LDR     R7, [SP, #0x40] \n"
 415 "    LDREQ   R1, =0x36A \n"
 416 "    LDREQ   R0, =0xFF3BC4D8 /*'MovWriter.c'*/ \n"
 417 "    MOV     R6, #0 \n"
 418 "    MOV     R4, R3 \n"
 419 "    MOV     R5, R6 \n"
 420 "    BLEQ    _DebugAssert \n"
 421 "    LDR     R8, =0x10D98 \n"
 422 "    CMP     R9, #0 \n"
 423 "    MOV     R11, #0 \n"
 424 "    STR     R9, [R8, #0x94] \n"
 425 "    MOVEQ   R0, #1 \n"
 426 "    STRNE   R11, [R8, #0xD8] \n"
 427 "    STREQ   R0, [R8, #0xD8] \n"
 428 "    LDR     R0, [R4] \n"
 429 "    LDR     R3, =0x61A8 \n"
 430 "    STR     R0, [R8, #0xE0] \n"
 431 "    LDR     R0, [R4, #4] \n"
 432 "    LDR     R1, =0x7530 \n"
 433 "    STR     R0, [R8, #0xE4] \n"
 434 "    LDR     R0, [R4, #0x10] \n"
 435 "    MOV     R2, #0x18 \n"
 436 "    STR     R0, [R8, #0xF0] \n"
 437 "    LDR     R9, [R4, #8] \n"
 438 "    LDR     R0, =0x3E9 \n"
 439 "    CMP     R9, #0xF \n"
 440 "    MOV     R12, #0x3E8 \n"
 441 "    MOV     R10, #0x1E \n"
 442 "    ADDCC   PC, PC, R9, LSL#2 \n"
 443 "    B       loc_FF3BE340 \n"
 444 "    B       loc_FF3BE2C8 \n"
 445 "    B       loc_FF3BE2C0 \n"
 446 "    B       loc_FF3BE2B0 \n"
 447 "    B       loc_FF3BE31C \n"
 448 "    B       loc_FF3BE32C \n"
 449 "    B       loc_FF3BE340 \n"
 450 "    B       loc_FF3BE340 \n"
 451 "    B       loc_FF3BE340 \n"
 452 "    B       loc_FF3BE340 \n"
 453 "    B       loc_FF3BE2E8 \n"
 454 "    B       loc_FF3BE2E0 \n"
 455 "    B       loc_FF3BE2D8 \n"
 456 "    B       loc_FF3BE314 \n"
 457 "    B       loc_FF3BE30C \n"
 458 "    B       loc_FF3BE2F8 \n"
 459 
 460 "loc_FF3BE2B0:\n"
 461 "    LDR     R5, =0x5DC0 \n"
 462 "    STR     R2, [R8, #0xE8] \n"
 463 "    STR     R5, [R8, #0x13C] \n"
 464 "    B       loc_FF3BE2D0 \n"
 465 
 466 "loc_FF3BE2C0:\n"
 467 "    MOV     R5, R3 \n"
 468 "    B       loc_FF3BE2FC \n"
 469 
 470 "loc_FF3BE2C8:\n"
 471 "    MOV     R5, R1 \n"
 472 "    B       loc_FF3BE2EC \n"
 473 
 474 "loc_FF3BE2D0:\n"
 475 "    STR     R0, [R8, #0x140] \n"
 476 "    B       loc_FF3BE34C \n"
 477 
 478 "loc_FF3BE2D8:\n"
 479 "    LDR     R5, =0x5DC \n"
 480 "    B       loc_FF3BE2EC \n"
 481 
 482 "loc_FF3BE2E0:\n"
 483 "    LDR     R5, =0xBB8 \n"
 484 "    B       loc_FF3BE2EC \n"
 485 
 486 "loc_FF3BE2E8:\n"
 487 "    LDR     R5, =0x1770 \n"
 488 
 489 "loc_FF3BE2EC:\n"
 490 "    STR     R1, [R8, #0x13C] \n"
 491 "    STR     R10, [R8, #0xE8] \n"
 492 "    B       loc_FF3BE2D0 \n"
 493 
 494 "loc_FF3BE2F8:\n"
 495 "    LDR     R5, =0x4E2 \n"
 496 
 497 "loc_FF3BE2FC:\n"
 498 "    STR     R2, [R8, #0xE8] \n"
 499 "    STR     R3, [R8, #0x13C] \n"
 500 "    STR     R12, [R8, #0x140] \n"
 501 "    B       loc_FF3BE34C \n"
 502 
 503 "loc_FF3BE30C:\n"
 504 "    LDR     R5, =0x9C4 \n"
 505 "    B       loc_FF3BE2FC \n"
 506 
 507 "loc_FF3BE314:\n"
 508 "    LDR     R5, =0x1388 \n"
 509 "    B       loc_FF3BE2FC \n"
 510 
 511 "loc_FF3BE31C:\n"
 512 "    STR     R1, [R8, #0x13C] \n"
 513 "    LDR     R5, =0x57600000 \n"  // --> Patched. Old value = 0x3A980. 2hrs 240fps
 514 "    MOV     R1, #0xF0 \n"
 515 "    B       loc_FF3BE338 \n"
 516 
 517 "loc_FF3BE32C:\n"
 518 "    LDR     R5, =0x28800000 \n"  // --> Patched. Old value = 0x1D4C0. 2hrs 120fps
 519 "    STR     R1, [R8, #0x13C] \n"
 520 "    MOV     R1, #0x78 \n"
 521 
 522 "loc_FF3BE338:\n"
 523 "    STR     R1, [R8, #0xE8] \n"
 524 "    B       loc_FF3BE2D0 \n"
 525 
 526 "loc_FF3BE340:\n"
 527 "    LDR     R0, =0xFF3BC4D8 /*'MovWriter.c'*/ \n"
 528 "    MOV     R1, #0x3C4 \n"
 529 "    BL      _DebugAssert \n"
 530 
 531 "loc_FF3BE34C:\n"
 532 "    LDR     R0, [R8, #0xE8] \n"
 533 "    LDR     R1, =0x1C20 \n"  // --> Patched. Old value = 0xE0F. 2hrs
 534 "    MOV     R0, R0, LSR#1 \n"
 535 "    STR     R0, [R8, #0xEC] \n"
 536 "    LDR     R0, [R7] \n"
 537 "    STR     R0, [R8, #0xF4] \n"
 538 "    LDRH    R0, [R7, #0x10] \n"
 539 "    STR     R0, [R8, #0xF8] \n"
 540 "    LDR     R0, [R7, #4] \n"
 541 "    STRH    R0, [R8, #2] \n"
 542 "    LDR     R0, [R7, #8] \n"
 543 "    STRH    R0, [R8, #4] \n"
 544 "    LDR     R0, [R7, #0x14] \n"
 545 "    STR     R0, [R8, #0xFC] \n"
 546 "    LDR     R0, [SP, #0x44] \n"
 547 "    STR     R0, [R8, #0x138] \n"
 548 "    LDR     R0, [R8, #0xE0] \n"
 549 "    CMP     R0, #0x140 \n"
 550 "    MOVEQ   R0, #0x20000 \n"
 551 "    MOVEQ   R6, #1 \n"
 552 "    STREQ   R0, [R8, #0xB8] \n"
 553 "    BEQ     loc_FF3BE3E4 \n"
 554 "    CMP     R0, #0x280 \n"
 555 "    LDREQ   R0, =0x7A760 \n"
 556 "    MOVEQ   R6, #2 \n"
 557 "    STREQ   R0, [R8, #0xB8] \n"
 558 "    BEQ     loc_FF3BE3E4 \n"
 559 "    CMP     R0, #0x500 \n"
 560 "    LDREQ   R0, =0x11DA50 \n"
 561 "    LDR     R1, =0x1C20 \n"  // --> Patched. Old value = 0x257. 2hrs
 562 "    MOVEQ   R6, #4 \n"
 563 "    STREQ   R0, [R8, #0xB8] \n"
 564 "    BEQ     loc_FF3BE3E4 \n"
 565 "    CMP     R0, #0x780 \n"
 566 "    BNE     loc_FF3BE3EC \n"
 567 //"  MOV     R0, #0x200000 \n"
 568 "    MOV     R0, #2097152 \n" // 10 mins
 569 "    MOV     R6, #5 \n"
 570 "    STR     R0, [R8, #0xB8] \n"
 571 
 572 "loc_FF3BE3E4:\n"
 573 "    STR     R1, [R8, #0x54] \n"
 574 "    B       loc_FF3BE3F8 \n"
 575 
 576 "loc_FF3BE3EC:\n"
 577 "    LDR     R0, =0xFF3BC4D8 /*'MovWriter.c'*/ \n"
 578 "    MOV     R1, #0x3EC \n"
 579 "    BL      _DebugAssert \n"
 580 
 581 "loc_FF3BE3F8:\n"
 582 "    LDR     R0, [R8, #0x54] \n"
 583 "    LDR     R1, [R8, #0x140] \n"
 584 "    MUL     R0, R5, R0 \n"
 585 "    STR     R1, [SP, #8] \n"
 586 "    BL      sub_006ACF38 /*__divmod_unsigned_int*/ \n"
 587 "    MOV     R1, #5 \n"
 588 "    BL      sub_006ACF38 /*__divmod_unsigned_int*/ \n"
 589 "    ADD     R0, R0, #1 \n"
 590 "    ADD     R0, R0, R0, LSL#2 \n"
 591 "    STR     R0, [R8, #0x50] \n"
 592 "    LDR     R9, [R4, #8] \n"
 593 "    CMP     R9, #0xB \n"
 594 "    CMPNE   R9, #0xA \n"
 595 "    CMPNE   R9, #9 \n"
 596 "    BNE     loc_FF3BE448 \n"
 597 "    LDR     R1, [SP, #8] \n"
 598 "    MUL     R0, R1, R0 \n"
 599 "    MOV     R1, R5 \n"
 600 "    BL      sub_006ACF38 /*__divmod_unsigned_int*/ \n"
 601 "    STR     R0, [R8, #0x54] \n"
 602 
 603 "loc_FF3BE448:\n"
 604 "    CMP     R9, #3 \n"
 605 "    CMPNE   R9, #4 \n"
 606 "    BNE     loc_FF3BE480 \n"
 607 "    RSB     R0, R5, R5, LSL#4 \n"
 608 "    STR     R10, [R8, #0x54] \n"
 609 "    LDR     R1, [SP, #8] \n"
 610 "    MOV     R0, R0, LSL#1 \n"
 611 "    BL      sub_006ACF38 /*__divmod_unsigned_int*/ \n"
 612 "    LDR     R1, [R8, #0xF0] \n"
 613 "    MOV     R10, R1 \n"
 614 "    BL      sub_006ACF38 /*__divmod_unsigned_int*/ \n"
 615 "    ADD     R0, R0, #1 \n"
 616 "    MUL     R0, R10, R0 \n"
 617 "    STR     R0, [R8, #0x50] \n"
 618 
 619 "loc_FF3BE480:\n"
 620 "    ADD     R0, R5, R5, LSL#8 \n"
 621 "    LDR     R1, [SP, #8] \n"
 622 "    RSB     R0, R0, R0, LSL#3 \n"
 623 "    BL      sub_006ACF38 /*__divmod_unsigned_int*/ \n"
 624 "    STR     R0, [R8, #0x80] \n"
 625 "    LDR     R0, [R4, #0xC] \n"
 626 "    CMP     R0, #0 \n"
 627 "    MOVNE   R0, #1 \n"
 628 "    STR     R0, [SP, #4] \n"
 629 "    LDR     R5, [R7, #0xC] \n"
 630 "    MOV     R0, R5, LSR#1 \n"
 631 "    STR     R5, [R8, #0xA0] \n"
 632 "    STR     R0, [R8, #0xA4] \n"
 633 "    LDR     R0, [SP, #0x10] \n"
 634 "    ADD     R0, R0, #3 \n"
 635 "    BIC     R1, R0, #3 \n"
 636 "    STR     R1, [R8, #0x104] \n"
 637 "    LDR     R0, [R8, #0x50] \n"
 638 "    MOV     R0, R0, LSL#2 \n"
 639 "    ADD     R1, R1, R0 \n"
 640 "    STR     R1, [R8, #0x108] \n"
 641 "    LDRH    R7, [R8, #4] \n"
 642 "    LDR     R2, [SP, #0x14] \n"
 643 "    LDR     R3, [SP, #0x10] \n"
 644 "    CMP     R7, #0 \n"
 645 "    ADD     R10, R3, R2 \n"
 646 "    BEQ     loc_FF3BE71C \n"
 647 "    ADD     R9, R1, R0 \n"
 648 "    STR     R9, [R8, #0x10C] \n"
 649 "    LDR     R1, [R8, #0xEC] \n"
 650 "    BL      sub_006ACF38 /*__divmod_unsigned_int*/ \n"
 651 "    ADD     R0, R0, R9 \n"
 652 "    ADD     R0, R0, #0x1F \n"
 653 "    BIC     R0, R0, #0x1F \n"
 654 "    STR     R0, [R8, #0x110] \n"
 655 "    LDR     R1, [R8, #0xD8] \n"
 656 "    CMP     R1, #0 \n"
 657 "    STREQ   R11, [R8, #0x84] \n"
 658 "    LDREQ   R2, [R8, #0xB8] \n"
 659 "    ADDEQ   R0, R0, R2 \n"
 660 "    STREQ   R0, [R8, #0x114] \n"
 661 "    MOVEQ   R0, #2 \n"
 662 "    STREQ   R0, [R8, #0x40] \n"
 663 "    BEQ     loc_FF3BE5D0 \n"
 664 "    LDR     R2, [R8, #0xB8] \n"
 665 "    CMP     R7, #1 \n"
 666 "    ADD     R0, R0, R2 \n"
 667 "    STR     R0, [R8, #0x84] \n"
 668 "    ADD     R0, R0, #0x100000 \n"
 669 "    STR     R0, [R8, #0x114] \n"
 670 "    MOV     R2, #5 \n"
 671 "    STR     R2, [R8, #0x40] \n"
 672 "    ADDEQ   R2, R5, R5, LSL#1 \n"
 673 "    SUBEQ   R0, R10, R0 \n"
 674 "    MOVEQ   R2, R2, LSL#1 \n"
 675 "    BEQ     loc_FF3BE5E0 \n"
 676 
 677 "loc_FF3BE560:\n"
 678 //SKIP DATA
 679 
 680 "loc_FF3BE5D0:\n"
 681 "    LDR     R2, [R8, #0x40] \n"
 682 "    LDR     R0, [R8, #0x114] \n"
 683 "    MUL     R2, R5, R2 \n"
 684 "    SUB     R0, R10, R0 \n"
 685 
 686 "loc_FF3BE5E0:\n"
 687 "    SUB     R0, R0, R2 \n"
 688 "    MOV     R0, R0, LSR#15 \n"
 689 "    MOV     R0, R0, LSL#15 \n"
 690 "    STR     R0, [R8, #0x120] \n"
 691 "    LDR     R2, [R8, #0x114] \n"
 692 "    CMP     R1, #0 \n"
 693 "    ADD     R0, R0, R2 \n"
 694 "    STR     R0, [R8, #0x118] \n"
 695 "    BEQ     loc_FF3BE614 \n"
 696 "    CMP     R7, #1 \n"
 697 "    BICEQ   R0, R0, #3 \n"
 698 "    STREQ   R0, [R8, #0x28] \n"
 699 "    ADDEQ   R0, R0, R5 \n"
 700 
 701 "loc_FF3BE614:\n"
 702 "    LDR     R1, =0x10D98 \n"
 703 "    STR     R0, [R8, #0x11C] \n"
 704 "    LDR     R10, =0x2299F0 \n"
 705 "    LDR     R8, [R1, #0x40] \n"
 706 "    LDR     R9, [R1, #0x11C] \n"
 707 "    MOV     R0, #0 \n"
 708 "    SUB     LR, R10, #0x28 \n"
 709 
 710 "loc_FF3BE630:\n"
 711 "    CMP     R0, R8 \n"
 712 "    MLACC   R1, R0, R5, R9 \n"
 713 "    LDR     R3, =0x2299A0 \n"
 714 "    ADDCC   R1, R1, #3 \n"
 715 "    BICCC   R1, R1, #3 \n"
 716 "    STRCS   R11, [R10, R0, LSL#2] \n"
 717 "    STRCC   R1, [R10, R0, LSL#2] \n"
 718 "    MOV     R1, #0 \n"
 719 "    ADD     R3, R3, R0, LSL#3 \n"
 720 "    ADD     R12, LR, R0, LSL#3 \n"
 721 
 722 "loc_FF3BE658:\n"
 723 "    STR     R2, [R3, R1, LSL#2] \n"
 724 "    STR     R2, [R12, R1, LSL#2] \n"
 725 "    ADD     R1, R1, #1 \n"
 726 "    CMP     R1, #2 \n"
 727 "    BLT     loc_FF3BE658 \n"
 728 "    ADD     R0, R0, #1 \n"
 729 "    CMP     R0, #5 \n"
 730 "    BLT     loc_FF3BE630 \n"
 731 "    LDR     R5, =0x10D98 \n"
 732 "    CMP     R7, #1 \n"
 733 "    STRNE   R11, [R5, #0xDC] \n"
 734 "    BNE     loc_FF3BE6D8 \n"
 735 "    LDRH    R0, [R5, #2] \n"
 736 "    CMP     R0, #0x10 \n"
 737 "    LDRNE   R1, =0x48D \n"
 738 "    LDRNE   R0, =0xFF3BC4D8 /*'MovWriter.c'*/ \n"
 739 "    BLNE    _DebugAssert \n"
 740 "    MOV     R0, #1 \n"
 741 "    STR     R0, [R5, #0xDC] \n"
 742 "    LDRH    R0, [R5, #4] \n"
 743 "    MVN     R1, #0x10000 \n"
 744 "    AND     R0, R1, R0, LSL#1 \n"
 745 "    STRH    R0, [R5, #4] \n"
 746 "    LDR     R0, [R5, #0xF8] \n"
 747 "    MOV     R0, R0, LSL#1 \n"
 748 "    STR     R0, [R5, #0xF8] \n"
 749 "    LDR     R0, [R5, #0xA0] \n"
 750 "    MOV     R0, R0, LSL#1 \n"
 751 "    STR     R0, [R5, #0xA0] \n"
 752 "    LDR     R0, [R5, #0xA4] \n"
 753 "    MOV     R0, R0, LSL#1 \n"
 754 "    STR     R0, [R5, #0xA4] \n"
 755 
 756 "loc_FF3BE6D8:\n"
 757 "    LDR     R0, [R5, #0xD8] \n"
 758 "    CMP     R0, #0 \n"
 759 "    BEQ     loc_FF3BE6F4 \n"
 760 "    LDR     R1, [R4, #8] \n"
 761 "    MOV     R0, R6 \n"
 762 "    BL      sub_FF1078AC \n"
 763 "    B       loc_FF3BE708 \n"
 764 
 765 "loc_FF3BE6F4:\n"
 766 "    LDRH    R3, [R4, #0x14] \n"
 767 "    LDR     R2, [R4, #8] \n"
 768 "    LDR     R1, [SP, #4] \n"
 769 "    MOV     R0, R6 \n"
 770 "    BL      sub_FF1077E0 \n"
 771 
 772 "loc_FF3BE708:\n"
 773 "    LDR     R1, [R5, #0xA0] \n"
 774 "    ADD     R0, R0, R1 \n"
 775 "    STR     R0, [R5, #0x98] \n"
 776 
 777 "loc_FF3BE714:\n"
 778 "    ADD     SP, SP, #0x1C \n"
 779 "    LDMFD   SP!, {R4-R11,PC} \n"
 780 
 781 "loc_FF3BE71C:\n"
 782 "    ADD     R0, R0, R1 \n"
 783 "    ADD     R0, R0, #0x1F \n"
 784 "    BIC     R0, R0, #0x1F \n"
 785 "    STR     R0, [R8, #0x110] \n"
 786 "    LDR     R1, [R8, #0xB8] \n"
 787 "    MOV     R2, R9 \n"
 788 "    ADD     R0, R0, R1 \n"
 789 "    SUB     R1, R10, R0 \n"
 790 "    MOV     R1, R1, LSR#15 \n"
 791 "    MOV     R1, R1, LSL#15 \n"
 792 "    STR     R0, [R8, #0x114] \n"
 793 "    ADD     R0, R0, R1 \n"
 794 "    STR     R1, [R8, #0x120] \n"
 795 "    STR     R0, [R8, #0x118] \n"
 796 "    LDRH    R3, [R4, #0x14] \n"
 797 "    LDR     R1, [SP, #4] \n"
 798 "    MOV     R0, R6 \n"
 799 "    BL      sub_FF1077E0 \n"
 800 "    STR     R0, [R8, #0x98] \n"
 801 "    B       loc_FF3BE714 \n"
 802 );
 803 }

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