Generic FunctionPackage: cgToCDocOverviewCGDocRelNotesIndexPermutedIndex
Allegro CL version 8.1
Unrevised from 8.0 to 8.1.
8.0 version

pixel

Arguments: stream position &optional result-rgb

Returns the color of the pixel at position in stream. The value will be stored in result-rgb (which must be a rgb color object, see make-rgb) if that value is specified.

position must be a position (see make-position). stream should be a cg-stream.

setf can be used with this function to set the value of a pixel. This is one way to draw something one pixel at a time. Thus if pane is a bitmap-pane, the dotimes form will draw a red line:

(setq win (make-window :mywin :class 'bitmap-window))
(setq pane (first (windows win)))
(dotimes (i 100) (setf (pixel pane (make-position 10 (+ 5 i))) red))

See also pixel-x-y.

GTK Note

The function pixel is not implemented on the GTK platform due to lack of support in GTK. But (setf pixel)  is implemented. Calling pixel on GTK will simply invoke the *gtk-compatibility-warning-action*.


Copyright (c) 1998-2007, Franz Inc. Oakland, CA., USA. All rights reserved.
Documentation for Allegro CL version 8.1. This page was not revised from the 8.0 page.
Created 2007.7.19.

ToCDocOverviewCGDocRelNotesIndexPermutedIndex
Allegro CL version 8.1
Unrevised from 8.0 to 8.1.
8.0 version