TI-BASIC:Pxl Test
From Learn @ Cemetech
Jump to navigationJump to searchCommand Summary
Tests a pixel on the graph screen to see if it is on or off.
Command Syntax
pxl-Test(Y,X)
Menu Location
While editing a program press:
- 2nd PRGM to enter the DRAW menu
- RIGHT to enter the POINTS menu
- 7 to choose pxl-Test(, or use arrows
TI-83/84/+/SE
1 byte
The pxl-Test( command is used to test a pixel at the given (Y,X) coordinates of the graph screen, to see whether it is on or off. One is returned if the pixel is on and zero is returned if the pixel is off. Please note that the coordinates are switched around so that the row comes first and then the column -- it's (Y,X) instead of (X,Y). This command's coordinates are independent of the window settings.
You can store the result of pxl-Test( to a variable for later use, or use the command in a conditional or loop.
:Pxl-On(25,25 :If pxl-Test(25,25 :Disp "Pixel turned on!
Error Conditions
- ERR:DOMAIN is triggered if the coordinates are not whole numbers or not in the right range ([0..62] for row, [0..94] for column). These bounds are also affected by split screen mode.