Changeset 449 for GraphicTest
- Timestamp:
- Nov 22, 2012, 3:02:54 PM (12 years ago)
- Location:
- GraphicTest
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
GraphicTest/Methods/UBitmapRawImageDataPaintBox.pas
r447 r449 36 36 hBmp := TempBitmap.Canvas.Handle; 37 37 hPaint := PaintBox.Canvas.Handle; 38 PaintBox.Canvas.CopyRect(Rect(0, 0, PaintBox.Width, PaintBox.Height), TempBitmap.Canvas,39 Rect(0, 0, TempBitmap.Width, TempBitmap.Height));40 //PaintBox.Canvas.Draw(0, 0, TempBitmap);38 //PaintBox.Canvas.CopyRect(Rect(0, 0, PaintBox.Width, PaintBox.Height), TempBitmap.Canvas, 39 // Rect(0, 0, TempBitmap.Width, TempBitmap.Height)); 40 PaintBox.Canvas.Draw(0, 0, TempBitmap); 41 41 //BitBlt(hPaint, 0, 0, TempBitmap.Width, TempBitmap.Height, hBmp, 0, 0, srcCopy); 42 42 end; -
GraphicTest/UDrawMethod.pas
r448 r449 19 19 private 20 20 FControl: TControl; 21 function GetFPS: Real;21 FFPS: Real; 22 22 public 23 23 Caption: string; … … 30 30 FrameCounter: Integer; 31 31 FrameCounterStart: TDateTime; 32 property FPS: Real read GetFPS; 32 function GetFPS: Real; 33 property FPS: Real read FFPS write FFPS; 33 34 procedure Init(Parent: TWinControl; Size: TPoint); virtual; 34 35 procedure Done; virtual; … … 60 61 61 62 {$IFDEF opengl} 63 62 64 { TDrawMethodOpenGL } 63 65 -
GraphicTest/UMainForm.pas
r448 r449 127 127 //Application.ProcessMessages; 128 128 StartTime := NowPrecise; 129 FrameCounterStart := NowPrecise; 130 FrameCounter := 0; 129 131 repeat 130 132 StepStartTime := NowPrecise; … … 136 138 until TestTerminated or 137 139 ((TestTimeout > 0) and ((NowPrecise - StartTime) > OneSecond * TestTimeout)); 140 FPS := GetFPS; 138 141 Done; 139 142 end;
Note:
See TracChangeset
for help on using the changeset viewer.