namespace codec

// namespaces

namespace xf::codec::details
namespace xf::codec::internal

// enums

enum COLOR_FORMAT

// structs

struct decOutput
struct hls_compInfo
struct hls_huff_DHT
struct hls_huff_segment
struct img_info
struct sos_data

// global variables

static const uint8_t hls_jpeg_zigzag_to_raster[64]
const short hls_icos_base_8192_scaled[64]

hls_EncodeCoeffOrders

#include "hls_EncodeCoeffOrders.hpp"
void hls_EncodeCoeffOrders (
    ap_uint <32> used_orders,
    hls::stream <ap_uint <32>>& orderStrm,
    hls::stream <ap_uint <64>>& tokenStrm,
    hls::stream <bool>& e_tokenStrm
    )

jpegxl order tokenize function.

Parameters:

used_orders the input for complete ac type
orderStrm the input for image scan order
tokenStrm the output for tokens initialization
e_tokenStrm the output for tokens stream

kernelParserDecoderTop

#include "XAcc_jfifparser.hpp"
void kernelParserDecoderTop (
    ap_uint < (16)>* datatoDDR,
    const int size,
    xf::codec::img_info& img_info,
    xf::codec::hls_compInfo hls_cmpnfo [(3)],
    hls::stream <ap_uint <24>>& block_strm,
    int& rtn,
    bool& rtn2,
    xf::codec::decOutput* pout
    )

Level 2 : kernel for jfif parser + huffman decoder.

Parameters:

CH_W size of data path in dataflow region, in bit. when CH_W is 16, the decoder could decode one symbol per cycle in about 99% cases. when CH_W is 8 , the decoder could decode one symbol per cycle in about 80% cases, but use less resource.
datatoDDR the pointer to DDR.
size the total bytes to be read from DDR.
img_info information to recovery the image.
hls_compInfo the component info used to generate the decOutput .
block_strm the stream of coefficients in block,23:is_rst, 22:is_endblock,21~16:bpos,15~0:block val
rtn the flag of the jfif parser succeed
rtn2 the flag of the decode succeed