GPAC
Open Source Multimedia Framework. For more information, check out http://gpac.wp.mines-telecom.fr
 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups
media_dev.h File Reference
#include <gpac/media_tools.h>
#include <gpac/ietf.h>
+ Include dependency graph for media_dev.h:
+ This graph shows which files directly or indirectly include this file:

Data Structures

struct  AVC_HRD
 
struct  AVC_VUI
 
struct  AVC_SPS
 
struct  AVC_PPS
 
struct  SVC_NALUHeader
 
struct  AVCSliceInfo
 
struct  AVCSeiRecoveryPoint
 
struct  AVCSeiPicTiming
 
struct  AVCSei
 
struct  AVCState
 
struct  SVC_Extractor
 
struct  HEVC_SublayerPTL
 
struct  HEVC_ProfileTierLevel
 
struct  HEVC_ReferencePictureSets
 
struct  HEVC_SPS
 
struct  HEVC_PPS
 
struct  HEVC_RateInfo
 
struct  HEVC_VPS
 
struct  HEVC_SEI
 
struct  HEVCSliceInfo
 
struct  HEVCState
 
struct  QCPRateTable
 

Macros

#define GF_SVC_SSPS_ID_SHIFT   16
 

Enumerations

enum  {
  AVC_SPS_PARSED = 1, AVC_SPS_DECLARED = 1<<1, AVC_SUBSPS_PARSED = 1<<2, AVC_SUBSPS_DECLARED = 1<<3,
  AVC_SPS_EXT_DECLARED = 1<<4
}
 
enum  { GF_HEVC_TYPE_B = 0, GF_HEVC_TYPE_P = 1, GF_HEVC_TYPE_I = 2 }
 
enum  GF_DashTemplateSegmentType {
  GF_DASH_TEMPLATE_SEGMENT = 0, GF_DASH_TEMPLATE_INITIALIZATION, GF_DASH_TEMPLATE_TEMPLATE, GF_DASH_TEMPLATE_INITIALIZATION_TEMPLATE,
  GF_DASH_TEMPLATE_REPINDEX
}
 

Functions

void gf_media_get_sample_average_infos (GF_ISOFile *file, u32 Track, u32 *avgSize, u32 *MaxSize, u32 *TimeDelta, u32 *maxCTSDelta, u32 *const_duration, u32 *bandwidth)
 
GF_Err gf_import_message (GF_MediaImporter *import, GF_Err e, char *format,...)
 
u32 gf_latm_get_value (GF_BitStream *bs)
 
u32 gf_media_nalu_is_start_code (GF_BitStream *bs)
 
u32 gf_media_nalu_next_start_code_bs (GF_BitStream *bs)
 
u32 gf_media_nalu_next_start_code (u8 *data, u32 data_len, u32 *sc_size)
 
u8 AVC_NALUType (GF_BitStream *bs)
 
Bool SVC_NALUIsSlice (u8 type)
 
s32 gf_media_avc_read_sps (const char *sps_data, u32 sps_size, AVCState *avc, u32 subseq_sps, u32 *vui_flag_pos)
 
s32 gf_media_avc_read_pps (const char *pps_data, u32 pps_size, AVCState *avc)
 
s32 gf_media_avc_read_sps_ext (const char *spse_data, u32 spse_size)
 
Bool gf_media_avc_slice_is_IDR (AVCState *avc)
 
Bool gf_media_avc_slice_is_intra (AVCState *avc)
 
s32 gf_media_avc_parse_nalu (GF_BitStream *bs, u32 nal_hdr, AVCState *avc)
 
u32 gf_media_avc_reformat_sei (char *buffer, u32 nal_size, AVCState *avc)
 
GF_Err gf_media_avc_change_par (GF_AVCConfig *avcc, s32 ar_n, s32 ar_d)
 
GF_Err gf_media_hevc_change_par (GF_HEVCConfig *hvcc, s32 ar_n, s32 ar_d)
 
s32 gf_media_hevc_read_vps (char *data, u32 size, HEVCState *hevc)
 
s32 gf_media_hevc_read_sps (char *data, u32 size, HEVCState *hevc)
 
s32 gf_media_hevc_read_pps (char *data, u32 size, HEVCState *hevc)
 
s32 gf_media_hevc_parse_nalu (GF_BitStream *bs, HEVCState *hevc, u8 *nal_unit_type, u8 *temporal_id, u8 *layer_id)
 
Bool gf_media_hevc_slice_is_intra (HEVCState *hevc)
 
Bool gf_media_hevc_slice_is_IDR (HEVCState *hevc)
 
GP_RTPPacketizer * gf_rtp_packetizer_create_and_init_from_file (GF_ISOFile *file, u32 TrackNum, void *cbk_obj, void(*OnNewPacket)(void *cbk, GF_RTPHeader *header), void(*OnPacketDone)(void *cbk, GF_RTPHeader *header), void(*OnDataReference)(void *cbk, u32 payload_size, u32 offset_from_orig), void(*OnData)(void *cbk, char *data, u32 data_size, Bool is_head), u32 Path_MTU, u32 max_ptime, u32 default_rtp_rate, u32 flags, u8 PayloadID, Bool copy_media, u32 InterleaveGroupID, u8 InterleaveGroupPriority)
 
void gf_media_format_ttxt_sdp (GP_RTPPacketizer *builder, char *payload_name, char *sdpLine, GF_ISOFile *file, u32 track)
 
GF_Err gf_media_mpd_format_segment_name (GF_DashTemplateSegmentType seg_type, Bool is_bs_switching, char *segment_name, const char *output_file_name, const char *rep_id, const char *seg_rad_name, const char *seg_ext, u64 start_time, u32 bandwidth, u32 segment_number, Bool use_segment_timeline)
 
GF_WebVTTParser * gf_webvtt_parser_new ()
 
GF_Err gf_webvtt_parser_init (GF_WebVTTParser *parser, const char *input_file, void *user, GF_Err(*report_message)(void *, GF_Err, char *, const char *), void(*on_sample_parsed)(void *, GF_WebVTTSample *), void(*on_header_parsed)(void *, const char *))
 
GF_Err gf_webvtt_parser_parse (GF_WebVTTParser *parser, u32 duration)
 
u64 gf_webvtt_parser_last_duration (GF_WebVTTParser *parser)
 
void gf_webvtt_parser_del (GF_WebVTTParser *parser)
 
void gf_webvtt_sample_del (GF_WebVTTSample *samp)
 
u64 gf_webvtt_sample_get_start (GF_WebVTTSample *samp)
 
GF_Err gf_webvtt_dump_header (FILE *dump, GF_ISOFile *file, u32 track, u32 index)
 
GF_Err gf_webvtt_dump_sample (FILE *dump, GF_WebVTTSample *samp)
 
GF_Err gf_webvtt_parser_dump_done (GF_WebVTTParser *parser, u32 duration)
 

Data Structure Documentation

struct AVC_HRD
+ Collaboration diagram for AVC_HRD:
Data Fields
u8 cpb_removal_delay_length_minus1
u8 dpb_output_delay_length_minus1
u8 time_offset_length
struct AVC_VUI
+ Collaboration diagram for AVC_VUI:
Data Fields
s32 timing_info_present_flag
u32 num_units_in_tick
u32 time_scale
s32 fixed_frame_rate_flag
u32 par_num
u32 par_den
Bool nal_hrd_parameters_present_flag
Bool vcl_hrd_parameters_present_flag
AVC_HRD hrd
Bool pic_struct_present_flag
struct AVC_SPS
+ Collaboration diagram for AVC_SPS:
Data Fields
s32 profile_idc
s32 level_idc
s32 prof_compat
s32 log2_max_frame_num
u32 poc_type
u32 poc_cycle_length
s32 log2_max_poc_lsb
s32 delta_pic_order_always_zero_flag
s32 offset_for_non_ref_pic
s32 offset_for_top_to_bottom_field
Bool frame_mbs_only_flag
u8 chroma_format
u8 luma_bit_depth_m8
u8 chroma_bit_depth_m8
s16 offset_for_ref_frame[256]
u32 width
u32 height
AVC_VUI vui
u32 state
u32 nb_ei
u32 nb_ep
u32 nb_eb
struct AVC_PPS
+ Collaboration diagram for AVC_PPS:
Data Fields
s32 id
s32 sps_id
s32 pic_order_present
s32 redundant_pic_cnt_present
u32 slice_group_count
u32 status
struct SVC_NALUHeader
+ Collaboration diagram for SVC_NALUHeader:
Data Fields
s32 idr_pic_flag
u8 temporal_id
u8 priority_id
u8 dependency_id
u8 quality_id
struct AVCSliceInfo
+ Collaboration diagram for AVCSliceInfo:
Data Fields
u8 nal_ref_idc
u8 nal_unit_type
u8 field_pic_flag
u8 bottom_field_flag
u32 frame_num
u32 idr_pic_id
u32 poc_lsb
u32 slice_type
s32 delta_poc_bottom
s32 delta_poc[2]
s32 redundant_pic_cnt
s32 poc
u32 poc_msb
u32 poc_msb_prev
u32 poc_lsb_prev
u32 frame_num_prev
s32 frame_num_offset
s32 frame_num_offset_prev
AVC_SPS * sps
AVC_PPS * pps
SVC_NALUHeader NalHeader
struct AVCSeiRecoveryPoint
+ Collaboration diagram for AVCSeiRecoveryPoint:
Data Fields
u32 frame_cnt
u8 exact_match_flag
u8 broken_link_flag
u8 changing_slice_group_idc
u8 valid
struct AVCSeiPicTiming
+ Collaboration diagram for AVCSeiPicTiming:
Data Fields
u8 pic_struct
struct AVCSei
+ Collaboration diagram for AVCSei:
Data Fields
AVCSeiRecoveryPoint recovery_point
AVCSeiPicTiming pic_timing
struct AVCState
+ Collaboration diagram for AVCState:
Data Fields
AVC_SPS sps[32]
s8 sps_active_idx
AVC_PPS pps[255]
AVCSliceInfo s_info
AVCSei sei
Bool is_svc
struct SVC_Extractor
+ Collaboration diagram for SVC_Extractor:
Data Fields
u32 NALUnitHeader
u8 track_ref_index
s8 sample_offset
u32 data_offset
u32 data_length
struct HEVC_SublayerPTL
+ Collaboration diagram for HEVC_SublayerPTL:
Data Fields
Bool profile_present_flag
Bool level_present_flag
Bool tier_flag
u8 profile_space
u8 profile_idc
u32 profile_compatibility_flag
u8 level_idc
struct HEVC_ProfileTierLevel
+ Collaboration diagram for HEVC_ProfileTierLevel:
Data Fields
u8 profile_space
u8 tier_flag
u8 profile_idc
u8 level_idc
u32 profile_compatibility_flag
Bool general_progressive_source_flag
Bool general_interlaced_source_flag
Bool general_non_packed_constraint_flag
Bool general_frame_only_constraint_flag
u64 general_reserved_44bits
HEVC_SublayerPTL sub_ptl[8]
struct HEVC_ReferencePictureSets
+ Collaboration diagram for HEVC_ReferencePictureSets:
Data Fields
u32 num_negative_pics
u32 num_positive_pics
s32 delta_poc[16]
struct HEVC_SPS
+ Collaboration diagram for HEVC_SPS:
Data Fields
s32 id
s32 vps_id
u32 state
u32 crc
u32 width
u32 height
HEVC_ProfileTierLevel ptl
u8 chroma_format_idc
Bool cw_flag
u32 cw_left
u32 cw_right
u32 cw_top
u32 cw_bottom
u8 bit_depth_luma
u8 bit_depth_chroma
u8 log2_max_pic_order_cnt_lsb
Bool separate_colour_plane_flag
u32 max_CU_width
u32 max_CU_height
u32 max_CU_depth
u32 bitsSliceSegmentAddress
u32 num_short_term_ref_pic_sets
u32 num_long_term_ref_pic_sps
HEVC_ReferencePictureSets rps[64]
Bool aspect_ratio_info_present_flag
Bool long_term_ref_pics_present_flag
Bool temporal_mvp_enable_flag
Bool sample_adaptive_offset_enabled_flag
u8 sar_idc
u16 sar_width
u16 sar_height
Bool has_timing_info
u32 num_units_in_tick
u32 time_scale
Bool poc_proportional_to_timing_flag
u32 num_ticks_poc_diff_one_minus1
struct HEVC_PPS
+ Collaboration diagram for HEVC_PPS:
Data Fields
s32 id
u32 sps_id
u32 state
u32 crc
Bool dependent_slice_segments_enabled_flag
Bool tiles_enabled_flag
Bool uniform_spacing_flag
u32 num_extra_slice_header_bits
u32 num_ref_idx_l0_default_active
u32 num_ref_idx_l1_default_active
Bool slice_segment_header_extension_present_flag
Bool output_flag_present_flag
Bool lists_modification_present_flag
Bool cabac_init_present_flag
Bool weighted_pred_flag
Bool weighted_bipred_flag
Bool slice_chroma_qp_offsets_present_flag
Bool deblocking_filter_override_enabled_flag
Bool loop_filter_across_slices_enabled_flag
Bool entropy_coding_sync_enabled_flag
Bool loop_filter_across_tiles_enabled_flag
u32 num_tile_columns
u32 num_tile_rows
u32 column_width[22]
u32 row_height[20]
struct HEVC_RateInfo
+ Collaboration diagram for HEVC_RateInfo:
Data Fields
u16 avg_bit_rate
u16 max_bit_rate
u16 avg_pic_rate
u8 constand_pic_rate_idc
struct HEVC_VPS
+ Collaboration diagram for HEVC_VPS:
Data Fields
s32 id
u32 state
u32 crc
u8 max_sub_layer
Bool temporal_id_nesting
HEVC_ProfileTierLevel ptl
HEVC_SublayerPTL sub_ptl[8]
HEVC_RateInfo rates[8]
struct HEVC_SEI
+ Collaboration diagram for HEVC_SEI:
Data Fields
AVCSeiRecoveryPoint recovery_point
AVCSeiPicTiming pic_timing
struct HEVCSliceInfo
+ Collaboration diagram for HEVCSliceInfo:
Data Fields
u8 nal_unit_type
s8 temporal_id
u32 frame_num
u32 poc_lsb
u32 slice_type
s32 redundant_pic_cnt
s32 poc
u32 poc_msb
u32 poc_msb_prev
u32 poc_lsb_prev
u32 frame_num_prev
s32 frame_num_offset
s32 frame_num_offset_prev
Bool dependent_slice_segment_flag
Bool first_slice_segment_in_pic_flag
u32 slice_segment_address
HEVC_SPS * sps
HEVC_PPS * pps
struct HEVCState
+ Collaboration diagram for HEVCState:
Data Fields
HEVC_SPS sps[16]
s8 sps_active_idx
HEVC_PPS pps[64]
HEVC_VPS vps[16]
HEVCSliceInfo s_info
HEVC_SEI sei
Bool is_svc
struct QCPRateTable
+ Collaboration diagram for QCPRateTable:
Data Fields
u8 rate_idx
u8 pck_size

Macro Definition Documentation

#define GF_SVC_SSPS_ID_SHIFT   16

Enumeration Type Documentation

anonymous enum
Enumerator
AVC_SPS_PARSED 
AVC_SPS_DECLARED 
AVC_SUBSPS_PARSED 
AVC_SUBSPS_DECLARED 
AVC_SPS_EXT_DECLARED 
anonymous enum
Enumerator
GF_HEVC_TYPE_B 
GF_HEVC_TYPE_P 
GF_HEVC_TYPE_I 
Enumerator
GF_DASH_TEMPLATE_SEGMENT 
GF_DASH_TEMPLATE_INITIALIZATION 
GF_DASH_TEMPLATE_TEMPLATE 
GF_DASH_TEMPLATE_INITIALIZATION_TEMPLATE 
GF_DASH_TEMPLATE_REPINDEX 

Function Documentation

void gf_media_get_sample_average_infos ( GF_ISOFile *  file,
u32  Track,
u32 avgSize,
u32 MaxSize,
u32 TimeDelta,
u32 maxCTSDelta,
u32 const_duration,
u32 bandwidth 
)

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

GF_Err gf_import_message ( GF_MediaImporter import,
GF_Err  e,
char *  format,
  ... 
)

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

u32 gf_latm_get_value ( GF_BitStream *  bs)

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

u32 gf_media_nalu_is_start_code ( GF_BitStream *  bs)

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

u32 gf_media_nalu_next_start_code_bs ( GF_BitStream *  bs)

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

u32 gf_media_nalu_next_start_code ( u8 data,
u32  data_len,
u32 sc_size 
)

+ Here is the caller graph for this function:

u8 AVC_NALUType ( GF_BitStream *  bs)
Bool SVC_NALUIsSlice ( u8  type)
s32 gf_media_avc_read_sps ( const char *  sps_data,
u32  sps_size,
AVCState avc,
u32  subseq_sps,
u32 vui_flag_pos 
)

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

s32 gf_media_avc_read_pps ( const char *  pps_data,
u32  pps_size,
AVCState avc 
)

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

s32 gf_media_avc_read_sps_ext ( const char *  spse_data,
u32  spse_size 
)

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

Bool gf_media_avc_slice_is_IDR ( AVCState avc)

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

Bool gf_media_avc_slice_is_intra ( AVCState avc)

+ Here is the caller graph for this function:

s32 gf_media_avc_parse_nalu ( GF_BitStream *  bs,
u32  nal_hdr,
AVCState avc 
)

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

u32 gf_media_avc_reformat_sei ( char *  buffer,
u32  nal_size,
AVCState avc 
)

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

GF_Err gf_media_avc_change_par ( GF_AVCConfig avcc,
s32  ar_n,
s32  ar_d 
)

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

GF_Err gf_media_hevc_change_par ( GF_HEVCConfig hvcc,
s32  ar_n,
s32  ar_d 
)

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

s32 gf_media_hevc_read_vps ( char *  data,
u32  size,
HEVCState hevc 
)

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

s32 gf_media_hevc_read_sps ( char *  data,
u32  size,
HEVCState hevc 
)

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

s32 gf_media_hevc_read_pps ( char *  data,
u32  size,
HEVCState hevc 
)

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

s32 gf_media_hevc_parse_nalu ( GF_BitStream *  bs,
HEVCState hevc,
u8 nal_unit_type,
u8 temporal_id,
u8 layer_id 
)

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

Bool gf_media_hevc_slice_is_intra ( HEVCState hevc)

+ Here is the caller graph for this function:

Bool gf_media_hevc_slice_is_IDR ( HEVCState hevc)

+ Here is the caller graph for this function:

GP_RTPPacketizer* gf_rtp_packetizer_create_and_init_from_file ( GF_ISOFile *  file,
u32  TrackNum,
void *  cbk_obj,
void(*)(void *cbk, GF_RTPHeader *header)  OnNewPacket,
void(*)(void *cbk, GF_RTPHeader *header)  OnPacketDone,
void(*)(void *cbk, u32 payload_size, u32 offset_from_orig)  OnDataReference,
void(*)(void *cbk, char *data, u32 data_size, Bool is_head)  OnData,
u32  Path_MTU,
u32  max_ptime,
u32  default_rtp_rate,
u32  flags,
u8  PayloadID,
Bool  copy_media,
u32  InterleaveGroupID,
u8  InterleaveGroupPriority 
)
void gf_media_format_ttxt_sdp ( GP_RTPPacketizer *  builder,
char *  payload_name,
char *  sdpLine,
GF_ISOFile *  file,
u32  track 
)

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

GF_Err gf_media_mpd_format_segment_name ( GF_DashTemplateSegmentType  seg_type,
Bool  is_bs_switching,
char *  segment_name,
const char *  output_file_name,
const char *  rep_id,
const char *  seg_rad_name,
const char *  seg_ext,
u64  start_time,
u32  bandwidth,
u32  segment_number,
Bool  use_segment_timeline 
)

+ Here is the caller graph for this function:

GF_WebVTTParser* gf_webvtt_parser_new ( )

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

GF_Err gf_webvtt_parser_init ( GF_WebVTTParser *  parser,
const char *  input_file,
void *  user,
GF_Err(*)(void *, GF_Err, char *, const char *)  report_message,
void(*)(void *, GF_WebVTTSample *)  on_sample_parsed,
void(*)(void *, const char *)  on_header_parsed 
)

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

GF_Err gf_webvtt_parser_parse ( GF_WebVTTParser *  parser,
u32  duration 
)

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

u64 gf_webvtt_parser_last_duration ( GF_WebVTTParser *  parser)

+ Here is the caller graph for this function:

void gf_webvtt_parser_del ( GF_WebVTTParser *  parser)

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

void gf_webvtt_sample_del ( GF_WebVTTSample *  samp)

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

u64 gf_webvtt_sample_get_start ( GF_WebVTTSample *  samp)

+ Here is the caller graph for this function:

GF_Err gf_webvtt_dump_header ( FILE *  dump,
GF_ISOFile *  file,
u32  track,
u32  index 
)

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

GF_Err gf_webvtt_dump_sample ( FILE *  dump,
GF_WebVTTSample *  samp 
)

+ Here is the call graph for this function:

GF_Err gf_webvtt_parser_dump_done ( GF_WebVTTParser *  parser,
u32  duration 
)