equal
deleted
inserted
replaced
1263 |
1263 |
1264 cScaleFactor:= f; |
1264 cScaleFactor:= f; |
1265 end; |
1265 end; |
1266 |
1266 |
1267 //////////////////////////////////////////////////////////////////////////////// |
1267 //////////////////////////////////////////////////////////////////////////////// |
|
1268 {$IFDEF IPHONEOS} |
|
1269 procedure startSpinning; cdecl; external; |
|
1270 procedure stopSpinning; cdecl; external; |
|
1271 {$ENDIF} |
1268 procedure AddProgress; |
1272 procedure AddProgress; |
1269 var r: TSDL_Rect; |
1273 var r: TSDL_Rect; |
1270 texsurf: PSDL_Surface; |
1274 texsurf: PSDL_Surface; |
1271 begin |
1275 begin |
1272 if Step = 0 then |
1276 if Step = 0 then |
1277 ProgrTex:= Surface2Tex(texsurf, false); |
1281 ProgrTex:= Surface2Tex(texsurf, false); |
1278 |
1282 |
1279 squaresize:= texsurf^.w shr 1; |
1283 squaresize:= texsurf^.w shr 1; |
1280 numsquares:= texsurf^.h div squaresize; |
1284 numsquares:= texsurf^.h div squaresize; |
1281 SDL_FreeSurface(texsurf); |
1285 SDL_FreeSurface(texsurf); |
|
1286 {$IFDEF IPHONEOS} |
|
1287 startSpinning(); |
|
1288 {$ENDIF} |
1282 end; |
1289 end; |
1283 |
1290 |
1284 TryDo(ProgrTex <> nil, 'Error - Progress Texure is nil!', true); |
1291 TryDo(ProgrTex <> nil, 'Error - Progress Texure is nil!', true); |
1285 |
1292 |
1286 glClear(GL_COLOR_BUFFER_BIT); |
1293 glClear(GL_COLOR_BUFFER_BIT); |
1299 {$ENDIF} |
1306 {$ENDIF} |
1300 inc(Step); |
1307 inc(Step); |
1301 |
1308 |
1302 end; |
1309 end; |
1303 |
1310 |
1304 {$IFDEF IPHONEOS} |
|
1305 procedure spinningWheelDone; cdecl; external; |
|
1306 {$ENDIF} |
|
1307 procedure FinishProgress; |
1311 procedure FinishProgress; |
1308 begin |
1312 begin |
1309 WriteLnToConsole('Freeing progress surface... '); |
1313 WriteLnToConsole('Freeing progress surface... '); |
1310 FreeTexture(ProgrTex); |
1314 FreeTexture(ProgrTex); |
1311 {$IFDEF IPHONEOS} |
1315 {$IFDEF IPHONEOS} |
1312 spinningWheelDone(); |
1316 stopSpinning(); |
1313 {$ENDIF} |
1317 {$ENDIF} |
1314 end; |
1318 end; |
1315 |
1319 |
1316 procedure flipSurface(Surface: PSDL_Surface; Vertical: Boolean); |
1320 procedure flipSurface(Surface: PSDL_Surface; Vertical: Boolean); |
1317 var y, x, i, j: LongInt; |
1321 var y, x, i, j: LongInt; |