|
cbmimage
|
Functions | |
| static int | cbmimage_i_adjust_relative_address (cbmimage_fileimage *image, cbmimage_blockaddress *block) |
| uint8_t * | cbmimage_i_get_address_of_block (cbmimage_fileimage *image, cbmimage_blockaddress block) |
| int | cbmimage_read_block (cbmimage_fileimage *image, cbmimage_blockaddress block, void *buffer, size_t buffersize) |
| read a block from the image and copy it into the provided buffer | |
| int | cbmimage_write_block (cbmimage_fileimage *image, cbmimage_blockaddress block, void *buffer, size_t buffersize) |
| write a block to the image by copying it from the provided buffer | |
| int | cbmimage_read_next_block (cbmimage_fileimage *image, cbmimage_blockaddress *block, void *buffer, size_t buffersize) |
| read the next block from the image and copy it into the provided buffer | |
|
static |
adjust a relative address to a global address
| [in] | image | pointer to the image data |
| [in] | block | pointer to the block address for the block that is of interest |
| uint8_t * cbmimage_i_get_address_of_block | ( | cbmimage_fileimage * | image, |
| cbmimage_blockaddress | block ) |
get the address of a block
| [in] | image | pointer to the image data |
| [in] | block | pointer to the block address for the block that is of interest |
| int cbmimage_read_block | ( | cbmimage_fileimage * | image, |
| cbmimage_blockaddress | block, | ||
| void * | buffer, | ||
| size_t | buffersize ) |
read a block from the image and copy it into the provided buffer
| [in] | image | pointer to the image data |
| [in] | block | pointer to the block address for the block that is of interest |
| [out] | buffer | pointer to the buffer that will contain the block contents on termination |
| [in] | buffersize | the size of the buffer pointed to by the parameter buffer |
| int cbmimage_read_next_block | ( | cbmimage_fileimage * | image, |
| cbmimage_blockaddress * | block, | ||
| void * | buffer, | ||
| size_t | buffersize ) |
read the next block from the image and copy it into the provided buffer
The next block is the next one according to the chain at the beginning of the block.
| [in] | image | pointer to the image data |
| [out] | block | pointer to the block address that will get the block address that has been read on termination |
| [in,out] | buffer | pointer to the buffer that has the link address, and that will contain the contents of the new block on termination |
| [in] | buffersize | the size of the buffer pointed to by the parameter buffer |
| int cbmimage_write_block | ( | cbmimage_fileimage * | image, |
| cbmimage_blockaddress | block, | ||
| void * | buffer, | ||
| size_t | buffersize ) |
write a block to the image by copying it from the provided buffer
| [in] | image | pointer to the image data |
| [in] | block | pointer to the block address for the block that is of interest |
| [in] | buffer | pointer to the buffer that has the contents that are to be written into the image |
| [in] | buffersize | the size of the buffer pointed to by the parameter buffer |