OpenJPEG  2.5.0
Data Structures | Typedefs | Functions
metadata_manager.h File Reference
#include "box_manager.h"
#include "placeholder_manager.h"

Go to the source code of this file.

Data Structures

struct  boxcontents_param
 
struct  metadata_param
 metadata-bin parameters More...
 
struct  metadatalist_param
 metadata-bin list parameters More...
 

Typedefs

typedef struct boxcontents_param boxcontents_param_t
 
typedef struct metadata_param metadata_param_t
 metadata-bin parameters More...
 
typedef struct metadatalist_param metadatalist_param_t
 metadata-bin list parameters More...
 

Functions

metadatalist_param_tgene_metadatalist (void)
 generate a metadata list More...
 
metadatalist_param_tconst_metadatalist (int fd)
 construct metadata-bin list of JP2 file More...
 
void delete_metadatalist (metadatalist_param_t **list)
 delete metadata list More...
 
metadata_param_tgene_metadata (Byte8_t idx, boxlist_param_t *boxlist, placeholderlist_param_t *phldlist, boxcontents_param_t *boxcontents)
 generate a metadata bin More...
 
void delete_metadata (metadata_param_t **metadata)
 delete a metadata bin More...
 
boxcontents_param_tgene_boxcontents (OPJ_OFF_T offset, OPJ_SIZE_T length)
 generate box contents More...
 
void print_metadata (metadata_param_t *metadata)
 print metadata-bin parameters More...
 
void print_allmetadata (metadatalist_param_t *list)
 print all metadata parameters More...
 
metadata_param_tsearch_metadata (Byte8_t idx, metadatalist_param_t *list)
 search a metadata bin by index More...
 
Byte8_t search_metadataidx (char boxtype[4], metadatalist_param_t *list)
 search a metadata index by box-type More...
 
void insert_metadata_into_list (metadata_param_t *metabin, metadatalist_param_t *metadatalist)
 insert a metadata-bin into list More...
 

Typedef Documentation

◆ boxcontents_param_t

◆ metadata_param_t

metadata-bin parameters

◆ metadatalist_param_t

metadata-bin list parameters

Function Documentation

◆ const_metadatalist()

metadatalist_param_t* const_metadatalist ( int  fd)

◆ delete_metadata()

void delete_metadata ( metadata_param_t **  metadata)

delete a metadata bin

Parameters
[in,out]metadataaddress of the deleting metadata bin pointer

References delete_boxlist(), and delete_placeholderlist().

Referenced by delete_metadatalist().

◆ delete_metadatalist()

void delete_metadatalist ( metadatalist_param_t **  list)

delete metadata list

Parameters
[in,out]listaddress of the metadata list pointer

References delete_metadata(), and metadata_param::next.

Referenced by delete_cache(), delete_index(), destroy_jpipdecoder(), and handle_JPIPstreamMSG().

◆ gene_boxcontents()

boxcontents_param_t* gene_boxcontents ( OPJ_OFF_T  offset,
OPJ_SIZE_T  length 
)

generate box contents

Returns
pointer to the box contents

References boxcontents_param::length, and boxcontents_param::offset.

Referenced by const_metadatalist(), and parse_metadata().

◆ gene_metadata()

metadata_param_t* gene_metadata ( Byte8_t  idx,
boxlist_param_t boxlist,
placeholderlist_param_t phldlist,
boxcontents_param_t boxcontents 
)

generate a metadata bin

Parameters
[in]idxmetadata-bin index
[in]boxlistbox list pointer
[in]phldlistplaceholder list pointer
[in]boxcontentsboxcontents pointer
Returns
pointer to the generated metadata bin

References metadata_param::boxcontents, metadata_param::boxlist, metadata_param::idx, metadata_param::next, and metadata_param::placeholderlist.

Referenced by const_metadatalist(), and parse_metamsg().

◆ gene_metadatalist()

metadatalist_param_t* gene_metadatalist ( void  )

generate a metadata list

Returns
pointer to the generated metadata list

References metadatalist_param::first, and metadatalist_param::last.

Referenced by const_metadatalist(), gene_cache(), handle_JPIPstreamMSG(), and init_jpipdecoder().

◆ insert_metadata_into_list()

void insert_metadata_into_list ( metadata_param_t metabin,
metadatalist_param_t metadatalist 
)

insert a metadata-bin into list

Parameters
[in]metabinmetadata-bin pointer
[in]metadatalistmetadata list pointer

References metadatalist_param::first, metadatalist_param::last, and metadata_param::next.

Referenced by const_metadatalist(), and parse_metamsg().

◆ print_allmetadata()

void print_allmetadata ( metadatalist_param_t list)

print all metadata parameters

Parameters
[in]listmetadata list pointer

References metadatalist_param::first, logstream, metadata_param::next, and print_metadata().

Referenced by output_log(), and print_index().

◆ print_metadata()

void print_metadata ( metadata_param_t metadata)

◆ search_metadata()

metadata_param_t* search_metadata ( Byte8_t  idx,
metadatalist_param_t list 
)

search a metadata bin by index

Parameters
[in]idxindex
[in]listmetadata-bin list pointer
Returns
found metadata-bin pointer

References metadatalist_param::first, metadata_param::idx, and metadata_param::next.

Referenced by enqueue_metadata().

◆ search_metadataidx()

Byte8_t search_metadataidx ( char  boxtype[4],
metadatalist_param_t list 
)

search a metadata index by box-type

Parameters
[in]boxtypebox-type
[in]listmetadata-bin list pointer
Returns
found metadata-bin index, if not found, -1

References metadata_param::boxlist, boxlist_param::first, metadatalist_param::first, placeholderlist_param::first, metadata_param::idx, box_param::next, metadata_param::next, placeholder_param::next, placeholder_param::OrigBH, placeholder_param::OrigID, metadata_param::placeholderlist, and box_param::type.

Referenced by enqueue_metabins().