SUB Steve_SCLS
(x1
AS LONG, y1
AS LONG, x2
AS LONG, y2
AS LONG) 'for Hardware images. Create "window" in Software layer for view Hardware Layer in background. This is SteveMcNeill's upgrade for my previous but 80x slower version.
'memory out of range prevent
'---------------------------
REM LINE (W
(3).X1
, W
(3).Y1
)-(W
(3).X2
, W
(3).Y2
), _RGB32(183, 194, 200), BF
'create border between software and hardware area
y = y1 * w * 4 + x1 * 4
y2 = y2 * w * 4
xstop = x2 * 4 - x1 * 4
w = w * 4
o = m.OFFSET + y
y = y + w
'_MEMFREE m 'No need to memfree as we keep the memblock available to point to other images in the future