Draw a pixel: Difference between revisions
Content added Content deleted
Childishbeat (talk | contribs) m (→{{header|Wee Basic}}: The correct numbers are in the code instead of pieces of text wrapped in inequality symbols.) |
(Add Factor example) |
||
Line 69: | Line 69: | ||
30 GET K$:IF K$="" THEN 30 |
30 GET K$:IF K$="" THEN 30 |
||
40 GRAPHIC 0,1 : REM RETURN TO TEXT MODE</lang> |
40 GRAPHIC 0,1 : REM RETURN TO TEXT MODE</lang> |
||
=={{header|Factor}}== |
|||
<lang factor>USING: accessors arrays images images.testing images.viewer |
|||
kernel literals math sequences ; |
|||
IN: rosetta-code.draw-pixel |
|||
: draw-pixel ( -- ) |
|||
B{ 255 0 0 } 100 100 <rgb-image> 320 240 [ 2array >>dim ] |
|||
[ * ] 2bi [ { 0 0 0 } ] replicate B{ } concat-as >>bitmap |
|||
[ set-pixel-at ] keep image-window ; |
|||
MAIN: draw-pixel</lang> |
|||
=={{Header|FreeBASIC}}== |
=={{Header|FreeBASIC}}== |