camxGetCameraName()
Description: returns the name for camera obtained from it. Name is a text string.
Parameters: None.
Return values: text string - camera name, or RET_NOT_CONNECTED, RET_CANT_GET_CAMNAME.
Example: SAY 'Camera full name = ' camxGetCameraName()
camxFramesTaken()
Description: returns the number of pictures taken. Note. It is not possible to get the number of taken pictures for all camera models, so this routine will return it approximately.
Parameters: None.
Return values: number of taken photos, if this number is negative, it is one of error codes : RET_NOT_CONNECTED, RET_CANT_GET_NUMBER.
Example: SAY 'Frames taken = ' camxFramesTaken()
camxFramesLeft()
Description: returns the number of pictures left. Note. It is not possible to get the number of pictures left for all camera models, so this routine will return it approximately.
Parameters: None.
Return values: number of photos left, if this number is negative, it is one of error codes : RET_NOT_CONNECTED, RET_CANT_GET_NUMBER.
Example: SAY 'Frames left = ' camxFramesLeft()
camxGetBatteryState()
Description: returns the battery state for the camera connected in percents (%). It is not possible to get the battery state all camera models, so this routine always returns 100.
Parameters: None.
Return values: number - value of battery state, if this value is negative, it is one of error codes : RET_NOT_CONNECTED, RET_CANT_GET_NUMBER.
Example: SAY 'Camera's battery = ' camxGetBatteryState()
camxGetPictureName(PicNumber)
Description: returns name of selected picture. Note. Not for all camera models it's possible to obtain a picture name, so this routine will return string '(None)' for such models.
Parameters: One mandatory parameter - the picture number to get a name.
Return values: text string - picture name (or '(None)' see note above). In case of error it returns : RET_NOT_CONNECTED, RET_INSUFF_PARAMS.
Example: picname = camxGetPictureName(10)
camxGetPictureSize(PicNumber,Thumbnail)
Description: returns size of selected picture in bytes.
Parameters: routine has two mandatory parameters. First - the picture number to get a size. Second parameter indicates either we want to get size for whole picture of just for its thumbnail. If the second parameter is 0 - return size for a picture, 1 - for a thumbnail.
Return values: value - picture size in bytes, or in case of error, one of those error codes : RET_NOT_CONNECTED, RET_INSUFF_PARAMS, RET_CANT_GET_NUMBER.
Example: picsize = camxGetPictureSize(5,0)
camxGetPictureDate(PicNumber)
Description: returns creation date/time of selected picture. Note. Not for all camera models it is possible to get a picture creation date/time, thus this routine will return current date/time for such sort of camera.
Parameters: routine has one mandatory parameter - the picture number to get a date/time.
Return values: text string in the following format - YYYY/MM/DD/hh/mm/ss. In case of error, one of those error codes : RET_NOT_CONNECTED, RET_INSUFF_PARAMS.
Example: picdate = camxGetPictureDate(14)
camxDelPicture(PicNumber)
Description: deletes the selected picture.
Parameters: routine has one mandatory parameter - the picture number to delete.
Return values: RET_OK, RET_CANT_DEL_PICTURE, RET_INSUFF_PARAMS, RET_NOT_CONNECTED.
Example: CALL camxDelPicture(8)
camxGetPicture(PicNumber,FileName,Thumbnail)
Description: downloads one selected picture.
Parameters: routine has three mandatory parameters. First - the picture number to download. Second parameter - the name of file to write picture to (should be a valid OS/2 file name). If such file already exists, it will be overwritten. Third parameter indicates either we want to get a whole picture of just its thumbnail. If the second parameter is 0 - download a picture, 1 - download a thumbnail.
Return values: RET_OK, RET_NOT_CONNECTED, RET_INSUFF_PARAMS, RET_CANT_GET_PICTURE.
Example: CALL camxGetPicture(8,'dsc008.jpg',0)
camxTakePicture()
Description: makes a shot, takes a picture. Note. Not every camera has such command - 'take a picture', thus this routine does nothing for such type of camera.
Parameters: None.
Return values: RET_OK, RET_NOT_CONNECTED, RET_CANT_TAKE_PIC.
Example: CALL camxTakePicture()
|