![]() |
UltraGrid
UltraGrid Low-Latency High-Resolution Transmission System
|
#include "rtp/rtpdec_jpeg.h"#include <assert.h>#include <inttypes.h>#include <stdbool.h>#include <stdint.h>#include <stdio.h>#include <stdlib.h>#include <string.h>#include "debug.h"#include "rtp/pbuf.h"#include "rtp/rtp.h"#include "rtp/rtpdec_state.h"#include "types.h"#include "utils/jpeg_writer.h"#include "utils/macros.h"#include "video_frame.h"
Go to the source code of this file.
Macros | |
| #define | GET_2BYTE(data) |
| #define | GET_BYTE(data) |
| #define | MOD_NAME "[rtpdec_jpeg] " |
Enumerations | |
| enum | { QUANT_TAB_T_FIRST_STATIC = 128 , QUANT_TAB_T_DYN = 255 , RTP_SZ_MULTIPLIER = 8 , RTP_TYPE_RST_BIT = 64 } |
Functions | |
| static char * | create_jpeg_frame (struct video_frame *frame, unsigned char **pckt_data, char **dqt_start, int verbose_adj) |
| int | decode_frame_jpeg (struct coded_data *cdata, void *decode_data) |
| static void | MakeTables (int q, u_char *lqt, u_char *cqt) |
| static void | parse_quant_tables (struct decode_data_rtsp *dec, unsigned char **pckt_data, const unsigned char *end, int q) |
| static unsigned | parse_restart_interval (unsigned char **pckt_data, int verbose_adj) |
| static void | skip_jpeg_headers (unsigned char **pckt_data) |
Variables | |
| static const int | jpeg_chroma_quantizer [64] |
| static const int | jpeg_luma_quantizer [64] |
Definition in file rtpdec_jpeg.c.
| #define GET_2BYTE | ( | data | ) |
Definition at line 61 of file rtpdec_jpeg.c.
Referenced by parse_quant_tables(), and parse_restart_interval().
| #define GET_BYTE | ( | data | ) |
Definition at line 60 of file rtpdec_jpeg.c.
Referenced by create_jpeg_frame(), parse_quant_tables(), and skip_jpeg_headers().
| #define MOD_NAME "[rtpdec_jpeg] " |
Definition at line 58 of file rtpdec_jpeg.c.
Referenced by create_jpeg_frame(), and parse_quant_tables().
| anonymous enum |
| Enumerator | |
|---|---|
| QUANT_TAB_T_FIRST_STATIC | |
| QUANT_TAB_T_DYN | Q=255. |
| RTP_SZ_MULTIPLIER | size in RTP hdr is /8 |
| RTP_TYPE_RST_BIT | indicates presence of RST markers |
Definition at line 65 of file rtpdec_jpeg.c.
|
static |
Definition at line 142 of file rtpdec_jpeg.c.
References video_frame::callbacks, tile::data, video_frame_callbacks::data_deleter, frame, GET_BYTE, jpeg_writer_data::height, tile::height, jpeg_writer_write_headers(), LOG_LEVEL_WARNING, log_msg_once(), MOD_NAME, MSG, parse_restart_interval(), RTP_SZ_MULTIPLIER, RTP_TYPE_RST_BIT, video_frame::tiles, to_fourcc, type, vf_data_deleter(), jpeg_writer_data::width, and tile::width.
Referenced by decode_frame_jpeg().

| int decode_frame_jpeg | ( | struct coded_data * | cdata, |
| void * | decode_data ) |
Definition at line 267 of file rtpdec_jpeg.c.
References create_jpeg_frame(), coded_data::data, tile::data, tile::data_len, DEBUG, decode_data_rtsp::dqt_start, decode_data_rtsp::frame, frame, decode_data_rtsp::jpeg, jpeg_writer_fill_dqt(), jpeg_writer_write_eoi(), MakeTables(), MAX, MSG, decode_data_rtsp::not_first_run, coded_data::nxt, decode_data_rtsp::offset_len, parse_quant_tables(), QUANT_TAB_T_DYN, QUANT_TAB_T_FIRST_STATIC, decode_data_rtsp::quantization_table_set, decode_data_rtsp::quantization_tables, rtp_packet, skip_jpeg_headers(), video_frame::tiles, and tile::width.
Referenced by init_rtsp().

|
static |
Definition at line 239 of file rtpdec_jpeg.c.
References jpeg_chroma_quantizer, and jpeg_luma_quantizer.
Referenced by decode_frame_jpeg().
|
static |
Definition at line 89 of file rtpdec_jpeg.c.
References GET_2BYTE, GET_BYTE, JPEG_QUANT_SIZE, LOG_LEVEL_WARNING, log_msg_once(), MOD_NAME, MSG, QUANT_TAB_T_FIRST_STATIC, and to_fourcc.
Referenced by decode_frame_jpeg().

|
static |
Definition at line 73 of file rtpdec_jpeg.c.
References GET_2BYTE, and MSG.
Referenced by create_jpeg_frame().
|
static |
Definition at line 196 of file rtpdec_jpeg.c.
References GET_BYTE, RTP_TYPE_RST_BIT, and type.
Referenced by decode_frame_jpeg().
|
static |
Definition at line 224 of file rtpdec_jpeg.c.
Referenced by MakeTables().
|
static |
Definition at line 210 of file rtpdec_jpeg.c.
Referenced by MakeTables().