[== 2dDrawing Coding rulez? ==]
-------------------------------
When using any 2dDrawing operation like Plot(), Line(), FrontColour() i.e, we have to use StartDrawing() before calling one of the 2dDraw comamnds and finish our operation with StopDrawing() - Up to here it is all ok but does there are any coding rulez using Start-/StopDrawing() ? Please tell me what usage of the following examples is correct... Since i have had the GDI/DDHelp bugs i complete rewrote my code like the first example to be sure that i am not responsible for the problems/bugs! the problems/bugs are not by me! Does both examples are correct of handling the Start/StopDrawing() command?
Code: Select all
;----------------------------------------
; 2dDrawing exampe source 1 - question
;----------------------------------------
;
For x = 0 to 9
StartDrawing(ScreenOutput())
FrontColour (255, 255, 255)
Line (10*x, 10, 10, 10)
StopDrawing()
Next
;
a$ = "Just a small question"
;
For y = 0 to 4
StartDrawing(ScreenOutput())
FrontColour (255, 0, 255)
Line (10, 10*y, 10, 10)
StopDrawing()
Next
;
;----------------------------------------
Code: Select all
;----------------------------------------
; 2dDrawing exampe source 2 - question
;----------------------------------------
;
StartDrawing(ScreenOutput())
For x = 0 to 9
FrontColour (255, 255, 255)
Line (10*x, 10, 10, 10)
Next
;
a$ = "Just a small question"
;
For y = 0 to 4
FrontColour (255, 0, 255)
Line (10, 10*y, 10, 10)
Next
StopDrawing()
;
;----------------------------------------

PIII450, 256MB Ram, 6GB HD, RivaTNT, DirectX8.1, SB AWE64, Win98SE + Updates...
greetz
MrVainSCL! aka Thorsten