' GDI Pixels — GetPixel/SetPixel via Win32 DECLARE
#COMPILE EXE
#DIM ALL

DECLARE FUNCTION GetDC LIB "USER32.DLL" (BYVAL hWnd AS LONG) AS LONG
DECLARE FUNCTION ReleaseDC LIB "USER32.DLL" (BYVAL hWnd AS LONG, BYVAL hDC AS LONG) AS LONG
DECLARE FUNCTION SetPixel LIB "GDI32.DLL" (BYVAL hDC AS LONG, BYVAL x AS LONG, BYVAL y AS LONG, BYVAL crColor AS LONG) AS LONG
DECLARE FUNCTION GetPixel LIB "GDI32.DLL" (BYVAL hDC AS LONG, BYVAL x AS LONG, BYVAL y AS LONG) AS LONG

FUNCTION PBMAIN() AS LONG
    PRINT "GDI Pixel Operations via DECLARE:"
    PRINT "- SetPixel draws a pixel at (x, y)"
    PRINT "- GetPixel reads pixel color value"
    PRINT "- LoadImage / CreateBitmap for bitmap handling"
    FUNCTION = 0
END FUNCTION
