milk  1.01
Modular Image processing Library toolKit
IMAGE Struct Reference

IMAGE structure The IMAGE structure includes : More...

#include <ImageStruct.h>

Collaboration diagram for IMAGE:

Data Fields

char name [STRINGMAXLEN_IMAGE_NAME]
 
uint8_t used
 Image usage flag. More...
 
int32_t shmfd
 
uint64_t memsize
 
sem_t * semlog
 
IMAGE_METADATAmd
 
uint64_t __pad0__: 0
 
union {
   void *   raw
 
   uint8_t *   UI8
 
   int8_t *   SI8
 
   uint16_t *   UI16
 
   int16_t *   SI16
 
   uint32_t *   UI32
 
   int32_t *   SI32
 
   uint64_t *   UI64
 
   int64_t *   SI64
 
   float *   F
 
   double *   D
 
   complex_float *   CF
 
   complex_double *   CD
 
array
 data storage array More...
 
sem_t ** semptr
 
IMAGE_KEYWORDkw
 
pid_t * semReadPID
 
pid_t * semWritePID
 
STREAM_PROC_TRACEstreamproctrace
 
uint64_t * flagarray
 
uint64_t * cntarray
 
struct timespec * atimearray
 
struct timespec * writetimearray
 

Detailed Description

IMAGE structure The IMAGE structure includes :

  • an array of IMAGE_KEWORD structures
  • an array of IMAGE_METADATA structures (usually only 1 element)

Field Documentation

◆ array

union { ... } IMAGE::array

data storage array

The array is declared as a union, so that multiple data types can be supported
For 2D image with pixel indices ii (x-axis) and jj (y-axis), the pixel values are stored as array.<TYPE>[ jj * md[0].size[0] + ii ]
image md[0].size[0] is x-axis size, md[0].size[1] is y-axis size

For 3D image with pixel indices ii (x-axis), jj (y-axis) and kk (z-axis), the pixel values are stored as array.<TYPE>[ kk * md[0].size[1] * md[0].size[0] + jj * md[0].size[0] + ii ]
image md[0].size[0] is x-axis size, md[0].size[1] is y-axis size, md[0].size[2] is z-axis size

Note
Up to this point, all members of the structure have a fixed memory offset to the start point pointer to data array

◆ atimearray

struct timespec* IMAGE::atimearray

For each slice index: time at which data was acquires/created. This time CAN be copied from input to output

◆ cntarray

uint64_t* IMAGE::cntarray

For circular buffer: counter array for circular buffer, copy of cnt0 onto slice index

◆ flagarray

uint64_t* IMAGE::flagarray

flag for each slice if needed (depends on imagetype)

◆ memsize

uint64_t IMAGE::memsize

total size in memory if shared

◆ name

char IMAGE::name[STRINGMAXLEN_IMAGE_NAME]

local name (can be different from name in shared memory)

◆ semlog

sem_t* IMAGE::semlog

pointer to semaphore for logging (8 bytes on 64-bit system)

◆ semptr

sem_t** IMAGE::semptr

array of pointers to semaphores (each 8 bytes on 64-bit system)

◆ shmfd

int32_t IMAGE::shmfd

if shared memory, file descriptor

◆ used

uint8_t IMAGE::used

Image usage flag.

1 if image is used, 0 otherwise.
This flag is used when an array of IMAGE type is held in memory as a way to store multiple images.
When an image is freed, the corresponding memory (in array) is freed and this flag set to zero.
The active images can be listed by looking for IMAGE[i].used==1 entries.

◆ writetimearray

struct timespec* IMAGE::writetimearray

For each slice index: time at which data was acquires/created. This time CAN be copied from input to output


The documentation for this struct was generated from the following file: