Home
JAQForum Ver 20.06
Log In or Join  
Active Topics
Local Time 00:03 20 Apr 2024 Privacy Policy
Jump to

Notice. New forum software under development. It's going to miss a few functions and look a bit ugly for a while, but I'm working on it full time now as the old forum was too unstable. Couple days, all good. If you notice any issues, please contact me.

Forum Index : Microcontroller and PC projects : CMM2 Manual Errata

     Page 6 of 6    
Author Message
TassyJim

Guru

Joined: 07/08/2011
Location: Australia
Posts: 5882
Posted: 11:45pm 22 Mar 2021
Copy link to clipboard 
Print this post

  Quote  And BEIGE goes into memory as colour number 255, even though RGB(BEIGE) <> RGB(WHITE).


Look at the values before putting them on screen.
BEIGE is RGB(245,245,220)

mode 1,12
PRINT "BLACK           ";: parts(RGB(BLACK))
PRINT "BLUE            ";: parts(RGB(BLUE))
PRINT "GREEN           ";: parts(RGB(GREEN))
PRINT "CYAN            ";: parts(RGB(CYAN))
PRINT "RED             ";: parts(RGB(RED))
PRINT "MAGENTA         ";: parts(RGB(MAGENTA))
PRINT "YELLOW          ";: parts(RGB(YELLOW))
PRINT "BROWN           ";: parts(RGB(BROWN))
PRINT "GRAY            ";: parts(RGB(GRAY))
PRINT "LIGHTGRAY       ";: parts(RGB(LIGHTGRAY))
PRINT "WHITE           ";: parts(RGB(WHITE))
PRINT "ORANGE          ";: parts(RGB(ORANGE))
PRINT "PINK           ";: parts(RGB(PINK))
PRINT "GOLD           ";: parts(RGB(GOLD))
PRINT "SALMON         ";: parts(RGB(SALMON))
PRINT "BEIGE           ";: parts(RGB(BEIGE))
PRINT "NOTBLACK        ";: parts(RGB(NOTBLACK))

do:loop until inkey$<>""

SUB parts(COL AS INTEGER)
PRINT STR$((col >> 16) AND &hFF,5);STR$((col >> 8) AND &hFF,5);STR$(col AND &hFF,5);STR$((col >> 24) AND &hF,5);
pixel 400,100,col
colx=pixel(400,100)
print "  =";STR$((colx >> 16) AND &hFF,5);STR$((colx >> 8) AND &hFF,5);STR$(colx AND &hFF,5);STR$((colx >> 24) AND &hF,5)
print
END SUB


Edited to show colour values before and after PIXEL functions.

Try different MODEs

Jim
Edited 2021-03-23 10:08 by TassyJim
VK7JH
MMedit   MMBasic Help
 
     Page 6 of 6    
Print this page


To reply to this topic, you need to log in.

© JAQ Software 2024