CHDK_DE Vorschauversion  Trunk Rev. 5426
 Alle Datenstrukturen Dateien Funktionen Variablen Typdefinitionen Aufzählungen Aufzählungswerte Makrodefinitionen
movie_rec.c-Dateireferenz
#include "conf.h"
+ Include-Abhängigkeitsdiagramm für movie_rec.c:

gehe zum Quellcode dieser Datei

Funktionen

void change_video_tables (int a, int b)
 
void __attribute__ ((naked, noinline))
 

Variablen

int * video_quality = &conf.video_quality
 
int * video_mode = &conf.video_mode
 
long def_table1 [9] ={0x2000,0x38D,0x788,0x5800,0x9C5,0x14B8,0x10000,0x1C6A,0x3C45}
 
long def_table2 [9] ={0x1CCD,-0x2E1,-0x579,0x4F33,-0x7EB,-0xF0C,0xE666,-0x170A,-0x2BC6}
 
long table1 [9]
 
long table2 [9]
 
long CompressionRateTable [] ={0x60, 0x5D, 0x5A, 0x57, 0x54, 0x51, 0x4D, 0x48, 0x42, 0x3B, 0x32, 0x29, 0x22, 0x1D, 0x17, 0x14, 0x10, 0xE, 0xB, 9, 7, 6, 5, 4, 3, 2, 1}
 

Dokumentation der Funktionen

void __attribute__ ( (naked, noinline)  )

!!

Definiert in Zeile 19 der Datei movie_rec.c.

19  {
20  asm volatile(
21  "STMFD SP!, {R4-R11,LR}\n"
22  "LDR R5, =0x66A24\n"
23  "SUB SP, SP, #0x14\n"
24  "LDR LR, [R5]\n"
25  "LDR R12, =0x66A3C\n"
26  "ADD LR, LR, #1\n"
27  "LDR R4, [R12]\n"
28  "STR LR, [R5]\n"
29  "LDR R12, =0x66ABC\n"
30  "STR R0, [SP,#0x10]\n"
31  "STR R1, [SP,#0xC]\n"
32  "STR R2, [SP,#8]\n"
33  "STR R3, [SP,#4]\n"
34  "CMP LR, R4\n"
35  "LDR R11, [R12]\n"
36  "MOVHI R0, #0x80000001\n"
37  "BHI loc_FFD4AB84\n"
38  "LDR R3, =0x66AA0\n"
39  "MOV R0, LR\n"
40  "LDR R1, [R3]\n"
41  "BL sub_FFEE753C\n"
42  "CMP R0, #1\n"
43  "BNE loc_FFD4A8BC\n"
44  "LDR R0, =0x66AC4\n"
45  "LDR R1, =0x66A10\n"
46  "LDR R3, [R0]\n"
47  "LDR R2, [R1]\n"
48  "CMP R3, R2\n"
49  "LDREQ R3, =0x66AC0\n"
50  "LDREQ R5, [R3]\n"
51  "MOVNE R5, R2\n"
52  "LDR R3, =0x66A24\n"
53  "LDR R2, =0x66AA0\n"
54  "LDR R0, [R3]\n"
55  "LDR R1, [R2]\n"
56  "BL sub_FFEE6EAC\n"
57  "LDR R3, =0x66A18\n"
58  "ADD R0, R0, #1\n"
59  "AND R0, R0, #1\n"
60  "STR R5, [R3,R0,LSL#2]\n"
61  "LDR R3, =0x66A0C\n"
62  "LDR R2, [R3]\n"
63  "CMP R5, R2\n"
64  "BHI loc_FFD4A76C\n"
65  "LDR R4, =0x66A5C\n"
66  "LDR R3, [R4]\n"
67  "ADD R3, R5, R3\n"
68  "ADD R3, R3, #8\n"
69  "CMP R2, R3\n"
70  "BCS loc_FFD4A770\n"
71 
72 "loc_FFD4A764:\n"
73 
74  "MOV R0, #0x80000003\n"
75  "B loc_FFD4AB84\n"
76 
77 
78 "loc_FFD4A76C:\n"
79  "LDR R4, =0x66A5C\n"
80 
81 "loc_FFD4A770:\n"
82  "LDR R3, [R4]\n"
83  "LDR R2, =0x66AC4\n"
84  "ADD R1, R5, R3\n"
85  "LDR R3, [R2]\n"
86  "ADD R2, R1, #8\n"
87  "CMP R2, R3\n"
88  "BLS loc_FFD4A7BC\n"
89  "LDR R2, =0x66AC0\n"
90  "LDR R0, =0x66A0C\n"
91  "RSB R3, R3, R1\n"
92  "LDR R1, [R2]\n"
93  "ADD R3, R3, #8\n"
94  "LDR R2, [R0]\n"
95  "ADD R1, R1, R3\n"
96  "CMP R2, R1\n"
97  "BCC loc_FFD4A764\n"
98  "LDR R3, =0x66A10\n"
99  "STR R1, [R3]\n"
100  "B loc_FFD4A7C4\n"
101 
102 
103 "loc_FFD4A7BC:\n"
104  "LDR R3, =0x66A10\n"
105  "STR R2, [R3]\n"
106 
107 "loc_FFD4A7C4:\n"
108  "LDR R3, [R4]\n"
109  "LDR R12, =0x66A70\n"
110  "ADD R3, R3, #0x18\n"
111  "LDR R2, [R12,#4]\n"
112  "MOV R0, R3\n"
113  "MOV R1, #0\n"
114  "CMP R1, R2\n"
115  "BHI loc_FFD4AA08\n"
116  "BNE loc_FFD4A7F4\n"
117  "LDR R3, [R12]\n"
118  "CMP R0, R3\n"
119  "BHI loc_FFD4AA08\n"
120 
121 "loc_FFD4A7F4:\n"
122  "LDR R4, [R4]\n"
123  "LDR LR, =0x66A78\n"
124  "STR R4, [SP]\n"
125  "LDR R12, =0x66A70\n"
126  "LDR R3, =0x66A24\n"
127  "LDMIA LR, {R7,R8}\n"
128  "LDMIA R12, {R5,R6}\n"
129  "LDR R10, [R3]\n"
130  "LDR R2, =0x66AA0\n"
131  "MOV R3, R4\n"
132  "MOV R4, #0\n"
133  "ADDS R7, R7, R3\n"
134  "ADC R8, R8, R4\n"
135  "LDR R9, [R2]\n"
136  "SUBS R5, R5, R3\n"
137  "SBC R6, R6, R4\n"
138  "MVN R2, #0\n"
139  "MVN R1, #0x17\n"
140  "ADDS R5, R5, R1\n"
141  "MOV R4, #0\n"
142  "MOV R3, #0x18\n"
143  "ADC R6, R6, R2\n"
144  "ADDS R7, R7, R3\n"
145  "ADC R8, R8, R4\n"
146  "STMIA R12, {R5,R6}\n"
147  "SUB R0, R10, #1\n"
148  "MOV R1, R9\n"
149  "STMIA LR, {R7,R8}\n"
150  "BL sub_FFEE6EAC\n"
151  "CMP R10, #1\n"
152  "MLA R0, R9, R0, R0\n"
153  "BEQ loc_FFD4A8BC\n"
154  "SUB R3, R0, #1\n"
155  "MOV R3, R3,LSL#4\n"
156  "ADD R4, R11, #0x10\n"
157  "ADD R5, R11, #0x14\n"
158  "LDR R1, [R5,R3]\n"
159  "LDR R2, [R4,R3]\n"
160  "LDR LR, =0x62773130\n"
161  "ADD R2, R2, R1\n"
162  "MOV R3, R0,LSL#4\n"
163  "ADD R2, R2, #8\n"
164  "MOV R0, #0\n"
165  "ADD R12, R11, #0xC\n"
166  "ADD R1, R11, #8\n"
167  "STR LR, [R1,R3]\n"
168  "STR R0, [R12,R3]\n"
169  "STR R2, [R4,R3]\n"
170  "LDR R0, [SP]\n"
171  "STR R0, [R5,R3]\n"
172 
173 "loc_FFD4A8BC:\n"
174 
175  "LDR R2, =0x66A10\n"
176  "LDR R3, =0x66AC4\n"
177  "LDR R1, [R2]\n"
178  "LDR R0, [R3]\n"
179  "ADD R3, R1, #9\n"
180  "CMP R3, R0\n"
181  "BLS loc_FFD4A8F8\n"
182  "LDR R2, =0x66AC0\n"
183  "LDR R3, [R2]\n"
184  "ADD R3, R3, R1\n"
185  "RSB R3, R0, R3\n"
186  "LDR R0, [SP,#0x10]\n"
187  "ADD R3, R3, #8\n"
188  "STR R3, [R0]\n"
189  "B loc_FFD4A904\n"
190 
191 
192 "loc_FFD4A8F8:\n"
193  "ADD R3, R1, #8\n"
194  "LDR R1, [SP,#0x10]\n"
195  "STR R3, [R1]\n"
196 
197 "loc_FFD4A904:\n"
198  "LDR R2, [SP,#0x10]\n"
199  "LDR R1, =0x66A6C\n"
200  "LDR R3, =0x66AC4\n"
201  "LDR R12, [R2]\n"
202  "LDR R2, [R1]\n"
203  "LDR R0, [R3]\n"
204  "ADD R3, R12, R2\n"
205  "CMP R3, R0\n"
206  "BLS loc_FFD4A958\n"
207  "LDR R2, [SP,#0xC]\n"
208  "RSB R0, R12, R0\n"
209  "STR R0, [R2]\n"
210  "LDR R2, =0x66AC0\n"
211  "LDR R3, [R1]\n"
212  "LDR R1, [R2]\n"
213  "RSB R3, R0, R3\n"
214  "LDR R0, [SP,#8]\n"
215  "STR R1, [R0]\n"
216  "LDR R1, [SP,#4]\n"
217  "STR R3, [R1]\n"
218  "B loc_FFD4A974\n"
219 
220 
221 "loc_FFD4A958:\n"
222  "LDR R0, [SP,#0xC]\n"
223  "STR R2, [R0]\n"
224  "LDR R1, [SP,#4]\n"
225  "MOV R3, #0\n"
226  "STR R3, [R1]\n"
227  "LDR R2, [SP,#8]\n"
228  "STR R3, [R2]\n"
229 
230 "loc_FFD4A974:\n"
231  "LDR R0, =0x66A10\n"
232  "LDR R1, =0x66A0C\n"
233  "LDR R3, [R0]\n"
234  "LDR R2, [R1]\n"
235  "CMP R3, R2\n"
236  "BHI loc_FFD4A9A0\n"
237  "LDR R0, [SP,#0xC]\n"
238  "LDR R3, [R0]\n"
239  "ADD R3, R12, R3\n"
240  "CMP R2, R3\n"
241  "BCC loc_FFD4A764\n"
242 
243 "loc_FFD4A9A0:\n"
244  "LDR R1, [SP,#8]\n"
245  "LDR R2, [R1]\n"
246  "CMP R2, #0\n"
247  "BEQ loc_FFD4A9D4\n"
248  "LDR R3, =0x66A0C\n"
249  "LDR R1, [R3]\n"
250  "CMP R2, R1\n"
251  "BHI loc_FFD4A9D4\n"
252  "LDR R0, [SP,#4]\n"
253  "LDR R3, [R0]\n"
254  "ADD R3, R2, R3\n"
255  "CMP R1, R3\n"
256  "BCC loc_FFD4A764\n"
257 
258 "loc_FFD4A9D4:\n"
259 
260  "LDR R3, =0x66A6C\n"
261  "LDR R0, =0x66A70\n"
262  "LDR R2, [R3]\n"
263  "LDR R3, [R0,#4]\n"
264  "ADD R2, R2, #0x18\n"
265  "MOV R1, R2\n"
266  "MOV R2, #0\n"
267  "CMP R2, R3\n"
268  "BHI loc_FFD4AA08\n"
269  "BNE loc_FFD4AA10\n"
270  "LDR R3, [R0]\n"
271  "CMP R1, R3\n"
272  "BLS loc_FFD4AA10\n"
273 
274 "loc_FFD4AA08:\n"
275 
276  "MOV R0, #0x80000005\n"
277  "B loc_FFD4AB84\n"
278 
279 
280 "loc_FFD4AA10:\n"
281 
282  "LDR R1, =0x66A54\n"
283  "LDR R0, =0x66AA0\n"
284  "LDR R3, [R1]\n"
285  "LDR R2, [R0]\n"
286  "ADD R3, R3, R2,LSL#4\n"
287  "ADD R3, R3, R3,LSL#2\n"
288  "LDR R12, =0x66A70\n"
289  "MOV R3, R3,LSL#1\n"
290  "ADD R3, R3, #0xA0\n"
291  "LDR R2, [R12,#4]\n"
292  "MOV R0, R3\n"
293  "MOV R1, #0\n"
294  "CMP R1, R2\n"
295  "BHI loc_FFD4AA58\n"
296  "BNE loc_FFD4AA7C\n"
297  "LDR R3, [R12]\n"
298  "CMP R0, R3\n"
299  "BLS loc_FFD4AA7C\n"
300 
301 "loc_FFD4AA58:\n"
302  "LDR R4, =0x66A88\n"
303  "LDR R1, [R4]\n"
304  "CMP R1, #0\n"
305  "BNE loc_FFD4AA7C\n"
306  "MOV R0, #0x3140\n"
307  "ADD R0, R0, #8\n"
308  "BL sub_FFD63E6C\n"
309  "MOV R3, #1\n"
310  "STR R3, [R4]\n"
311 
312 "loc_FFD4AA7C:\n"
313 
314  "LDR R1, =0x66A54\n"
315  "LDR R0, =0x66AA0\n"
316  "LDR R2, [R1]\n"
317  "LDR R3, [R0]\n"
318  "LDR R0, =0x66A78\n"
319  "ADD R2, R2, R3,LSL#4\n"
320  "MVN R3, #0x9F\n"
321  "ADD R2, R2, R2,LSL#2\n"
322  "ADD R3, R3, #0x40000000\n"
323  "SUB R3, R3, R2,LSL#1\n"
324  "LDR R1, [R0,#4]\n"
325  "MOV R4, R3\n"
326  "MOV R5, #0\n"
327  "CMP R1, R5\n"
328  "BHI loc_FFD4AAC8\n"
329  "BNE loc_FFD4AAEC\n"
330  "LDR R3, [R0]\n"
331  "CMP R3, R4\n"
332  "BLS loc_FFD4AAEC\n"
333 
334 "loc_FFD4AAC8:\n"
335  "LDR R4, =0x66A88\n"
336  "LDR R1, [R4]\n"
337  "CMP R1, #0\n"
338  "BNE loc_FFD4AAEC\n"
339  "MOV R0, #0x3140\n"
340  "ADD R0, R0, #8\n"
341  "BL sub_FFD63E6C\n"
342  "MOV R3, #1\n"
343  "STR R3, [R4]\n"
344 
345 "loc_FFD4AAEC:\n"
346 
347  "LDR R3, =0x66AA0\n"
348  "LDR R0, =0x66A3C\n"
349  "LDR R2, [R3]\n"
350  "LDR R12, =0x66A24\n"
351  "LDR R1, [R0]\n"
352  "ADD R3, R2, R2,LSL#2\n"
353  "ADD R2, R2, R3,LSL#1\n"
354  "LDR R0, [R12]\n"
355  "RSB R1, R2, R1\n"
356  "CMP R0, R1\n"
357  "BLS loc_FFD4AB3C\n"
358  "LDR R4, =0x66A88\n"
359  "LDR R1, [R4]\n"
360  "CMP R1, #0\n"
361  "BNE loc_FFD4AB3C\n"
362  "MOV R0, #0x3140\n"
363  "ADD R0, R0, #8\n"
364  "BL sub_FFD63E6C\n"
365  "MOV R3, #1\n"
366  "STR R3, [R4]\n"
367 
368 "loc_FFD4AB3C:\n"
369 
370  "LDR R3, =0x66A78\n"
371  "LDR R12, =0x66A6C\n"
372  "LDMIA R3, {R1,R2}\n"
373  "LDR R0, [R12]\n"
374  "MOV R4, #0\n"
375  "MOV R3, #0x18\n"
376  "ADDS R1, R1, R0\n"
377  "ADC R2, R2, #0\n"
378  "ADDS R1, R1, R3\n"
379  "ADC R2, R2, R4\n"
380  "CMP R2, #0\n"
381  "BHI loc_FFD4AB78\n"
382  "BNE loc_FFD4AB80\n"
383  "CMP R1, #0x40000000\n"
384  // "BLS loc_FFD4AB80\n" //-
385  "B loc_FFD4AB80\n" //+
386 
387 "loc_FFD4AB78:\n"
388  "MOV R0, #0x80000007\n"
389  "B loc_FFD4AB84\n"
390 
391 
392 "loc_FFD4AB80:\n"
393 
394  "MOV R0, #0\n"
395 
396 "loc_FFD4AB84:\n"
397 
398  "ADD SP, SP, #0x14\n"
399  "LDMFD SP!, {R4-R11,PC}\n"
400  );
401 }
void change_video_tables ( int  a,
int  b 
)

Definiert in Zeile 11 der Datei movie_rec.c.

11  {
12  int i;
13  for (i=0;i<9;i++) {table1[i]=(def_table1[i]*a)/b; table2[i]=(def_table2[i]*a)/b;}
14 }

Variablen-Dokumentation

long CompressionRateTable[] ={0x60, 0x5D, 0x5A, 0x57, 0x54, 0x51, 0x4D, 0x48, 0x42, 0x3B, 0x32, 0x29, 0x22, 0x1D, 0x17, 0x14, 0x10, 0xE, 0xB, 9, 7, 6, 5, 4, 3, 2, 1}

Definiert in Zeile 16 der Datei movie_rec.c.

long def_table1[9] ={0x2000,0x38D,0x788,0x5800,0x9C5,0x14B8,0x10000,0x1C6A,0x3C45}

Definiert in Zeile 6 der Datei movie_rec.c.

long def_table2[9] ={0x1CCD,-0x2E1,-0x579,0x4F33,-0x7EB,-0xF0C,0xE666,-0x170A,-0x2BC6}

Definiert in Zeile 7 der Datei movie_rec.c.

long table1[9]

Definiert in Zeile 9 der Datei movie_rec.c.

long table2[9]

Definiert in Zeile 9 der Datei movie_rec.c.

int* video_mode = &conf.video_mode

Definiert in Zeile 4 der Datei movie_rec.c.

int* video_quality = &conf.video_quality

Definiert in Zeile 3 der Datei movie_rec.c.