[id] = ImageRequest(id[, type])
id. If you specify Nil in the
ImageRequest()will automatically choose an identifier for the brush and return the identifier to you.
The optional type argument allows you to specify the image source to use when prompting the user for an image. This can currently be set to one of the following predefined constants:
The default mode is
ImageRequest() will prompt the user to select
an image from the device's gallery.
To find out if this function has failed because the user cancelled the image requester,
just use HaveObject() to see if the brush object exists after
ImageRequest() returns. If it doesn't exist, the user has cancelled the image
requester. See HaveObject for details.
ImageRequest(1, #REQ_CAMERA) If HaveObject(#BRUSH, 1) DisplayBrush(1, #CENTER, #CENTER) Else NPrint("Requester cancelled!") EndIfThe code above prompts the user to take a picture with the camera and then displays this picture. It also checks if the requester has been cancelled.