World of Might and Magic  0.2.0
Open reimplementation of Might and Magic 6 7 8 game engine

Types and functions for working with AVPacket. Подробнее...

+ Граф связей класса AVPacket:

Классы

struct  AVPacketSideData
 
struct  AVPacket
 

Определения типов

typedef struct AVPacketSideData AVPacketSideData
 
typedef struct AVPacket AVPacket
 

Перечисления

enum  AVPacketSideDataType {
  AV_PKT_DATA_PALETTE, AV_PKT_DATA_NEW_EXTRADATA, AV_PKT_DATA_PARAM_CHANGE, AV_PKT_DATA_H263_MB_INFO,
  AV_PKT_DATA_REPLAYGAIN, AV_PKT_DATA_DISPLAYMATRIX, AV_PKT_DATA_STEREO3D, AV_PKT_DATA_AUDIO_SERVICE_TYPE,
  AV_PKT_DATA_QUALITY_STATS, AV_PKT_DATA_FALLBACK_TRACK, AV_PKT_DATA_CPB_PROPERTIES, AV_PKT_DATA_SKIP_SAMPLES,
  AV_PKT_DATA_JP_DUALMONO, AV_PKT_DATA_STRINGS_METADATA, AV_PKT_DATA_SUBTITLE_POSITION, AV_PKT_DATA_MATROSKA_BLOCKADDITIONAL,
  AV_PKT_DATA_WEBVTT_IDENTIFIER, AV_PKT_DATA_WEBVTT_SETTINGS, AV_PKT_DATA_METADATA_UPDATE, AV_PKT_DATA_MPEGTS_STREAM_ID,
  AV_PKT_DATA_MASTERING_DISPLAY_METADATA, AV_PKT_DATA_SPHERICAL, AV_PKT_DATA_CONTENT_LIGHT_LEVEL, AV_PKT_DATA_A53_CC,
  AV_PKT_DATA_ENCRYPTION_INIT_INFO, AV_PKT_DATA_ENCRYPTION_INFO, AV_PKT_DATA_AFD, AV_PKT_DATA_NB
}
 
enum  AVSideDataParamChangeFlags { AV_SIDE_DATA_PARAM_CHANGE_CHANNEL_COUNT = 0x0001, AV_SIDE_DATA_PARAM_CHANGE_CHANNEL_LAYOUT = 0x0002, AV_SIDE_DATA_PARAM_CHANGE_SAMPLE_RATE = 0x0004, AV_SIDE_DATA_PARAM_CHANGE_DIMENSIONS = 0x0008 }
 

Функции

AVPacketav_packet_alloc (void)
 
AVPacketav_packet_clone (const AVPacket *src)
 
void av_packet_free (AVPacket **pkt)
 
void av_init_packet (AVPacket *pkt)
 
int av_new_packet (AVPacket *pkt, int size)
 
void av_shrink_packet (AVPacket *pkt, int size)
 
int av_grow_packet (AVPacket *pkt, int grow_by)
 
int av_packet_from_data (AVPacket *pkt, uint8_t *data, int size)
 
attribute_deprecated int av_dup_packet (AVPacket *pkt)
 
attribute_deprecated int av_copy_packet (AVPacket *dst, const AVPacket *src)
 
attribute_deprecated int av_copy_packet_side_data (AVPacket *dst, const AVPacket *src)
 
attribute_deprecated void av_free_packet (AVPacket *pkt)
 
uint8_tav_packet_new_side_data (AVPacket *pkt, enum AVPacketSideDataType type, int size)
 
int av_packet_add_side_data (AVPacket *pkt, enum AVPacketSideDataType type, uint8_t *data, size_t size)
 
int av_packet_shrink_side_data (AVPacket *pkt, enum AVPacketSideDataType type, int size)
 
uint8_tav_packet_get_side_data (const AVPacket *pkt, enum AVPacketSideDataType type, int *size)
 
attribute_deprecated int av_packet_merge_side_data (AVPacket *pkt)
 
attribute_deprecated int av_packet_split_side_data (AVPacket *pkt)
 
const char * av_packet_side_data_name (enum AVPacketSideDataType type)
 
uint8_tav_packet_pack_dictionary (AVDictionary *dict, int *size)
 
int av_packet_unpack_dictionary (const uint8_t *data, int size, AVDictionary **dict)
 
void av_packet_free_side_data (AVPacket *pkt)
 
int av_packet_ref (AVPacket *dst, const AVPacket *src)
 
void av_packet_unref (AVPacket *pkt)
 
void av_packet_move_ref (AVPacket *dst, AVPacket *src)
 
int av_packet_copy_props (AVPacket *dst, const AVPacket *src)
 
int av_packet_make_refcounted (AVPacket *pkt)
 
int av_packet_make_writable (AVPacket *pkt)
 
void av_packet_rescale_ts (AVPacket *pkt, AVRational tb_src, AVRational tb_dst)
 

Подробное описание

Types and functions for working with AVPacket.

Типы

◆ AVPacketSideData

◆ AVPacket

typedef struct AVPacket AVPacket

#include <C:/git/world-of-might-and-magic/lib/win32/x86/ffmpeg-4.2.2/include/libavcodec/avcodec.h>

This structure stores compressed data. It is typically exported by demuxers and then passed as input to decoders, or received as output from encoders and then passed to muxers.

For video, it should typically contain one compressed frame. For audio it may contain several compressed frames. Encoders are allowed to output empty packets, with no compressed data, containing only side data (e.g. to update some stream parameters at the end of encoding).

AVPacket is one of the few structs in FFmpeg, whose size is a part of public ABI. Thus it may be allocated on stack and no new fields can be added to it without libavcodec and libavformat major bump.

The semantics of data ownership depends on the buf field. If it is set, the packet data is dynamically allocated and is valid indefinitely until a call to av_packet_unref() reduces the reference count to 0.

If the buf field is not set av_packet_ref() would make a copy instead of increasing the reference count.

The side data is always allocated with av_malloc(), copied by av_packet_ref() and freed by av_packet_unref().

См. также
av_packet_ref
av_packet_unref

Перечисления

◆ AVPacketSideDataType

#include <C:/git/world-of-might-and-magic/lib/win32/x86/ffmpeg-4.2.2/include/libavcodec/avcodec.h>

Элементы перечислений
AV_PKT_DATA_PALETTE 

An AV_PKT_DATA_PALETTE side data packet contains exactly AVPALETTE_SIZE bytes worth of palette. This side data signals that a new palette is present.

AV_PKT_DATA_NEW_EXTRADATA 

The AV_PKT_DATA_NEW_EXTRADATA is used to notify the codec or the format that the extradata buffer was changed and the receiving side should act upon it appropriately. The new extradata is embedded in the side data buffer and should be immediately used for processing the current frame or packet.

AV_PKT_DATA_PARAM_CHANGE 

An AV_PKT_DATA_PARAM_CHANGE side data packet is laid out as follows:

u32le param_flags
if (param_flags & AV_SIDE_DATA_PARAM_CHANGE_CHANNEL_COUNT)
s32le channel_count
if (param_flags & AV_SIDE_DATA_PARAM_CHANGE_CHANNEL_LAYOUT)
u64le channel_layout
if (param_flags & AV_SIDE_DATA_PARAM_CHANGE_SAMPLE_RATE)
s32le sample_rate
if (param_flags & AV_SIDE_DATA_PARAM_CHANGE_DIMENSIONS)
s32le width
s32le height
AV_PKT_DATA_H263_MB_INFO 

An AV_PKT_DATA_H263_MB_INFO side data packet contains a number of structures with info about macroblocks relevant to splitting the packet into smaller packets on macroblock edges (e.g. as for RFC 2190). That is, it does not necessarily contain info about all macroblocks, as long as the distance between macroblocks in the info is smaller than the target payload size. Each MB info structure is 12 bytes, and is laid out as follows:

u32le bit offset from the start of the packet
u8 current quantizer at the start of the macroblock
u8 GOB number
u16le macroblock address within the GOB
u8 horizontal MV predictor
u8 vertical MV predictor
u8 horizontal MV predictor for block number 3
u8 vertical MV predictor for block number 3
AV_PKT_DATA_REPLAYGAIN 

This side data should be associated with an audio stream and contains ReplayGain information in form of the AVReplayGain struct.

AV_PKT_DATA_DISPLAYMATRIX 

This side data contains a 3x3 transformation matrix describing an affine transformation that needs to be applied to the decoded video frames for correct presentation.

See libavutil/display.h for a detailed description of the data.

AV_PKT_DATA_STEREO3D 

This side data should be associated with a video stream and contains Stereoscopic 3D information in form of the AVStereo3D struct.

AV_PKT_DATA_AUDIO_SERVICE_TYPE 

This side data should be associated with an audio stream and corresponds to enum AVAudioServiceType.

AV_PKT_DATA_QUALITY_STATS 

This side data contains quality related information from the encoder.

u32le quality factor of the compressed frame. Allowed range is between 1 (good) and FF_LAMBDA_MAX (bad).
u8 picture type
u8 error count
u16 reserved
u64le[error count] sum of squared differences between encoder in and output
AV_PKT_DATA_FALLBACK_TRACK 

This side data contains an integer value representing the stream index of a "fallback" track. A fallback track indicates an alternate track to use when the current track can not be decoded for some reason. e.g. no decoder available for codec.

AV_PKT_DATA_CPB_PROPERTIES 

This side data corresponds to the AVCPBProperties struct.

AV_PKT_DATA_SKIP_SAMPLES 

Recommmends skipping the specified number of samples

u32le number of samples to skip from start of this packet
u32le number of samples to skip from end of this packet
u8 reason for start skip
u8 reason for end skip (0=padding silence, 1=convergence)
AV_PKT_DATA_JP_DUALMONO 

An AV_PKT_DATA_JP_DUALMONO side data packet indicates that the packet may contain "dual mono" audio specific to Japanese DTV and if it is true, recommends only the selected channel to be used.

u8 selected channels (0=mail/left, 1=sub/right, 2=both)
AV_PKT_DATA_STRINGS_METADATA 

A list of zero terminated key/value strings. There is no end marker for the list, so it is required to rely on the side data size to stop.

AV_PKT_DATA_SUBTITLE_POSITION 

Subtitle event position

u32le x1
u32le y1
u32le x2
u32le y2
AV_PKT_DATA_MATROSKA_BLOCKADDITIONAL 

Data found in BlockAdditional element of matroska container. There is no end marker for the data, so it is required to rely on the side data size to recognize the end. 8 byte id (as found in BlockAddId) followed by data.

AV_PKT_DATA_WEBVTT_IDENTIFIER 

The optional first identifier line of a WebVTT cue.

AV_PKT_DATA_WEBVTT_SETTINGS 

The optional settings (rendering instructions) that immediately follow the timestamp specifier of a WebVTT cue.

AV_PKT_DATA_METADATA_UPDATE 

A list of zero terminated key/value strings. There is no end marker for the list, so it is required to rely on the side data size to stop. This side data includes updated metadata which appeared in the stream.

AV_PKT_DATA_MPEGTS_STREAM_ID 

MPEGTS stream ID as uint8_t, this is required to pass the stream ID information from the demuxer to the corresponding muxer.

AV_PKT_DATA_MASTERING_DISPLAY_METADATA 

Mastering display metadata (based on SMPTE-2086:2014). This metadata should be associated with a video stream and contains data in the form of the AVMasteringDisplayMetadata struct.

AV_PKT_DATA_SPHERICAL 

This side data should be associated with a video stream and corresponds to the AVSphericalMapping structure.

AV_PKT_DATA_CONTENT_LIGHT_LEVEL 

Content light level (based on CTA-861.3). This metadata should be associated with a video stream and contains data in the form of the AVContentLightMetadata struct.

AV_PKT_DATA_A53_CC 

ATSC A53 Part 4 Closed Captions. This metadata should be associated with a video stream. A53 CC bitstream is stored as uint8_t in AVPacketSideData.data. The number of bytes of CC data is AVPacketSideData.size.

AV_PKT_DATA_ENCRYPTION_INIT_INFO 

This side data is encryption initialization data. The format is not part of ABI, use av_encryption_init_info_* methods to access.

AV_PKT_DATA_ENCRYPTION_INFO 

This side data contains encryption info for how to decrypt the packet. The format is not part of ABI, use av_encryption_info_* methods to access.

AV_PKT_DATA_AFD 

Active Format Description data consisting of a single byte as specified in ETSI TS 101 154 using AVActiveFormatDescription enum.

AV_PKT_DATA_NB 

The number of side data types. This is not part of the public API/ABI in the sense that it may change when new side data types are added. This must stay the last enum value. If its value becomes huge, some code using it needs to be updated as it assumes it to be smaller than other limits.

См. определение в файле avcodec.h строка 1184

◆ AVSideDataParamChangeFlags

#include <C:/git/world-of-might-and-magic/lib/win32/x86/ffmpeg-4.2.2/include/libavcodec/avcodec.h>

Элементы перечислений
AV_SIDE_DATA_PARAM_CHANGE_CHANNEL_COUNT 
AV_SIDE_DATA_PARAM_CHANGE_CHANNEL_LAYOUT 
AV_SIDE_DATA_PARAM_CHANGE_SAMPLE_RATE 
AV_SIDE_DATA_PARAM_CHANGE_DIMENSIONS 

См. определение в файле avcodec.h строка 1531

Функции

◆ av_packet_alloc()

AVPacket* av_packet_alloc ( void  )

#include <C:/git/world-of-might-and-magic/lib/win32/x86/ffmpeg-4.2.2/include/libavcodec/avcodec.h>

Allocate an AVPacket and set its fields to default values. The resulting struct must be freed using av_packet_free().

Возвращает
An AVPacket filled with default values or NULL on failure.
Заметки
this only allocates the AVPacket itself, not the data buffers. Those must be allocated through other means such as av_new_packet.
См. также
av_new_packet

Используется в Movie::GetFrame() и AudioBaseDataSource::GetNextBuffer().

+ Граф вызова функции:

◆ av_packet_clone()

AVPacket* av_packet_clone ( const AVPacket src)

#include <C:/git/world-of-might-and-magic/lib/win32/x86/ffmpeg-4.2.2/include/libavcodec/avcodec.h>

Create a new packet that references the same data as src.

This is a shortcut for av_packet_alloc()+av_packet_ref().

Возвращает
newly created AVPacket on success, NULL on error.
См. также
av_packet_alloc
av_packet_ref

◆ av_packet_free()

void av_packet_free ( AVPacket **  pkt)

#include <C:/git/world-of-might-and-magic/lib/win32/x86/ffmpeg-4.2.2/include/libavcodec/avcodec.h>

Free the packet, if the packet is reference counted, it will be unreferenced first.

Аргументы
pktpacket to be freed. The pointer will be set to NULL.
Заметки
passing NULL is a no-op.

Используется в Movie::GetFrame() и AudioBaseDataSource::GetNextBuffer().

+ Граф вызова функции:

◆ av_init_packet()

void av_init_packet ( AVPacket pkt)

#include <C:/git/world-of-might-and-magic/lib/win32/x86/ffmpeg-4.2.2/include/libavcodec/avcodec.h>

Initialize optional fields of a packet with default values.

Note, this does not touch the data and size members, which have to be initialized separately.

Аргументы
pktpacket

◆ av_new_packet()

int av_new_packet ( AVPacket pkt,
int  size 
)

#include <C:/git/world-of-might-and-magic/lib/win32/x86/ffmpeg-4.2.2/include/libavcodec/avcodec.h>

Allocate the payload of a packet and initialize its fields with default values.

Аргументы
pktpacket
sizewanted payload size
Возвращает
0 if OK, AVERROR_xxx otherwise

◆ av_shrink_packet()

void av_shrink_packet ( AVPacket pkt,
int  size 
)

#include <C:/git/world-of-might-and-magic/lib/win32/x86/ffmpeg-4.2.2/include/libavcodec/avcodec.h>

Reduce packet size, correctly zeroing padding

Аргументы
pktpacket
sizenew size

◆ av_grow_packet()

int av_grow_packet ( AVPacket pkt,
int  grow_by 
)

#include <C:/git/world-of-might-and-magic/lib/win32/x86/ffmpeg-4.2.2/include/libavcodec/avcodec.h>

Increase packet size, correctly zeroing padding

Аргументы
pktpacket
grow_bynumber of bytes by which to increase the size of the packet

◆ av_packet_from_data()

int av_packet_from_data ( AVPacket pkt,
uint8_t data,
int  size 
)

#include <C:/git/world-of-might-and-magic/lib/win32/x86/ffmpeg-4.2.2/include/libavcodec/avcodec.h>

Initialize a reference-counted packet from av_malloc()ed data.

Аргументы
pktpacket to be initialized. This function will set the data, size, and buf fields, all others are left untouched.
dataData allocated by av_malloc() to be used as packet data. If this function returns successfully, the data is owned by the underlying AVBuffer. The caller may not access the data through other means.
sizesize of data in bytes, without the padding. I.e. the full buffer size is assumed to be size + AV_INPUT_BUFFER_PADDING_SIZE.
Возвращает
0 on success, a negative AVERROR on error

◆ av_dup_packet()

attribute_deprecated int av_dup_packet ( AVPacket pkt)

#include <C:/git/world-of-might-and-magic/lib/win32/x86/ffmpeg-4.2.2/include/libavcodec/avcodec.h>

Предупреждения
This is a hack - the packet memory allocation stuff is broken. The packet is allocated if it was not really allocated.
Уст.:
Use av_packet_ref or av_packet_make_refcounted

◆ av_copy_packet()

attribute_deprecated int av_copy_packet ( AVPacket dst,
const AVPacket src 
)

#include <C:/git/world-of-might-and-magic/lib/win32/x86/ffmpeg-4.2.2/include/libavcodec/avcodec.h>

Copy packet, including contents

Возвращает
0 on success, negative AVERROR on fail
Уст.:
Use av_packet_ref

◆ av_copy_packet_side_data()

attribute_deprecated int av_copy_packet_side_data ( AVPacket dst,
const AVPacket src 
)

#include <C:/git/world-of-might-and-magic/lib/win32/x86/ffmpeg-4.2.2/include/libavcodec/avcodec.h>

Copy packet side data

Возвращает
0 on success, negative AVERROR on fail
Уст.:
Use av_packet_copy_props

◆ av_free_packet()

attribute_deprecated void av_free_packet ( AVPacket pkt)

#include <C:/git/world-of-might-and-magic/lib/win32/x86/ffmpeg-4.2.2/include/libavcodec/avcodec.h>

Free a packet.

Уст.:
Use av_packet_unref
Аргументы
pktpacket to free

◆ av_packet_new_side_data()

uint8_t* av_packet_new_side_data ( AVPacket pkt,
enum AVPacketSideDataType  type,
int  size 
)

#include <C:/git/world-of-might-and-magic/lib/win32/x86/ffmpeg-4.2.2/include/libavcodec/avcodec.h>

Allocate new information of a packet.

Аргументы
pktpacket
typeside information type
sizeside information size
Возвращает
pointer to fresh allocated data or NULL otherwise

◆ av_packet_add_side_data()

int av_packet_add_side_data ( AVPacket pkt,
enum AVPacketSideDataType  type,
uint8_t data,
size_t  size 
)

#include <C:/git/world-of-might-and-magic/lib/win32/x86/ffmpeg-4.2.2/include/libavcodec/avcodec.h>

Wrap an existing array as a packet side data.

Аргументы
pktpacket
typeside information type
datathe side data array. It must be allocated with the av_malloc() family of functions. The ownership of the data is transferred to pkt.
sizeside information size
Возвращает
a non-negative number on success, a negative AVERROR code on failure. On failure, the packet is unchanged and the data remains owned by the caller.

◆ av_packet_shrink_side_data()

int av_packet_shrink_side_data ( AVPacket pkt,
enum AVPacketSideDataType  type,
int  size 
)

#include <C:/git/world-of-might-and-magic/lib/win32/x86/ffmpeg-4.2.2/include/libavcodec/avcodec.h>

Shrink the already allocated side data buffer

Аргументы
pktpacket
typeside information type
sizenew side information size
Возвращает
0 on success, < 0 on failure

◆ av_packet_get_side_data()

uint8_t* av_packet_get_side_data ( const AVPacket pkt,
enum AVPacketSideDataType  type,
int *  size 
)

#include <C:/git/world-of-might-and-magic/lib/win32/x86/ffmpeg-4.2.2/include/libavcodec/avcodec.h>

Get side information from packet.

Аргументы
pktpacket
typedesired side information type
sizepointer for side information size to store (optional)
Возвращает
pointer to data if present or NULL otherwise

◆ av_packet_merge_side_data()

attribute_deprecated int av_packet_merge_side_data ( AVPacket pkt)

◆ av_packet_split_side_data()

attribute_deprecated int av_packet_split_side_data ( AVPacket pkt)

◆ av_packet_side_data_name()

◆ av_packet_pack_dictionary()

uint8_t* av_packet_pack_dictionary ( AVDictionary dict,
int *  size 
)

#include <C:/git/world-of-might-and-magic/lib/win32/x86/ffmpeg-4.2.2/include/libavcodec/avcodec.h>

Pack a dictionary for use in side_data.

Аргументы
dictThe dictionary to pack.
sizepointer to store the size of the returned data
Возвращает
pointer to data if successful, NULL otherwise

◆ av_packet_unpack_dictionary()

int av_packet_unpack_dictionary ( const uint8_t data,
int  size,
AVDictionary **  dict 
)

#include <C:/git/world-of-might-and-magic/lib/win32/x86/ffmpeg-4.2.2/include/libavcodec/avcodec.h>

Unpack a dictionary from side_data.

Аргументы
datadata from side_data
sizesize of the data
dictthe metadata storage dictionary
Возвращает
0 on success, < 0 on failure

◆ av_packet_free_side_data()

void av_packet_free_side_data ( AVPacket pkt)

#include <C:/git/world-of-might-and-magic/lib/win32/x86/ffmpeg-4.2.2/include/libavcodec/avcodec.h>

Convenience function to free all the side data stored. All the other fields stay untouched.

Аргументы
pktpacket

◆ av_packet_ref()

int av_packet_ref ( AVPacket dst,
const AVPacket src 
)

#include <C:/git/world-of-might-and-magic/lib/win32/x86/ffmpeg-4.2.2/include/libavcodec/avcodec.h>

Setup a new reference to the data described by a given packet

If src is reference-counted, setup dst as a new reference to the buffer in src. Otherwise allocate a new buffer in dst and copy the data from src into it.

All the other fields are copied from src.

См. также
av_packet_unref
Аргументы
dstDestination packet
srcSource packet
Возвращает
0 on success, a negative AVERROR on error.

◆ av_packet_unref()

void av_packet_unref ( AVPacket pkt)

#include <C:/git/world-of-might-and-magic/lib/win32/x86/ffmpeg-4.2.2/include/libavcodec/avcodec.h>

Wipe the packet.

Unreference the buffer referenced by the packet and reset the remaining packet fields to their default values.

Аргументы
pktThe packet to be unreferenced.

◆ av_packet_move_ref()

void av_packet_move_ref ( AVPacket dst,
AVPacket src 
)

#include <C:/git/world-of-might-and-magic/lib/win32/x86/ffmpeg-4.2.2/include/libavcodec/avcodec.h>

Move every field in src to dst and reset src.

См. также
av_packet_unref
Аргументы
srcSource packet, will be reset
dstDestination packet

◆ av_packet_copy_props()

int av_packet_copy_props ( AVPacket dst,
const AVPacket src 
)

#include <C:/git/world-of-might-and-magic/lib/win32/x86/ffmpeg-4.2.2/include/libavcodec/avcodec.h>

Copy only "properties" fields from src to dst.

Properties for the purpose of this function are all the fields beside those related to the packet data (buf, data, size)

Аргументы
dstDestination packet
srcSource packet
Возвращает
0 on success AVERROR on failure.

◆ av_packet_make_refcounted()

int av_packet_make_refcounted ( AVPacket pkt)

#include <C:/git/world-of-might-and-magic/lib/win32/x86/ffmpeg-4.2.2/include/libavcodec/avcodec.h>

Ensure the data described by a given packet is reference counted.

Заметки
This function does not ensure that the reference will be writable. Use av_packet_make_writable instead for that purpose.
См. также
av_packet_ref
av_packet_make_writable
Аргументы
pktpacket whose data should be made reference counted.
Возвращает
0 on success, a negative AVERROR on error. On failure, the packet is unchanged.

◆ av_packet_make_writable()

int av_packet_make_writable ( AVPacket pkt)

#include <C:/git/world-of-might-and-magic/lib/win32/x86/ffmpeg-4.2.2/include/libavcodec/avcodec.h>

Create a writable reference for the data described by a given packet, avoiding data copy if possible.

Аргументы
pktPacket whose data should be made writable.
Возвращает
0 on success, a negative AVERROR on failure. On failure, the packet is unchanged.

◆ av_packet_rescale_ts()

void av_packet_rescale_ts ( AVPacket pkt,
AVRational  tb_src,
AVRational  tb_dst 
)

#include <C:/git/world-of-might-and-magic/lib/win32/x86/ffmpeg-4.2.2/include/libavcodec/avcodec.h>

Convert valid timing fields (timestamps / durations) in a packet from one timebase to another. Timestamps with unknown values (AV_NOPTS_VALUE) will be ignored.

Аргументы
pktpacket on which the conversion will be performed
tb_srcsource timebase, in which the timing fields in pkt are expressed
tb_dstdestination timebase, to which the timing fields will be converted
AV_PKT_DATA_NB
@ AV_PKT_DATA_NB
Definition: avcodec.h:1415
AV_PKT_DATA_MPEGTS_STREAM_ID
@ AV_PKT_DATA_MPEGTS_STREAM_ID
Definition: avcodec.h:1359
AV_PKT_DATA_PARAM_CHANGE
@ AV_PKT_DATA_PARAM_CHANGE
Definition: avcodec.h:1216
AV_PKT_DATA_ENCRYPTION_INFO
@ AV_PKT_DATA_ENCRYPTION_INFO
Definition: avcodec.h:1399
AV_PKT_DATA_PALETTE
@ AV_PKT_DATA_PALETTE
Definition: avcodec.h:1190
AV_PKT_DATA_ENCRYPTION_INIT_INFO
@ AV_PKT_DATA_ENCRYPTION_INIT_INFO
Definition: avcodec.h:1393
AV_SIDE_DATA_PARAM_CHANGE_SAMPLE_RATE
@ AV_SIDE_DATA_PARAM_CHANGE_SAMPLE_RATE
Definition: avcodec.h:1534
AV_PKT_DATA_AFD
@ AV_PKT_DATA_AFD
Definition: avcodec.h:1405
AV_SIDE_DATA_PARAM_CHANGE_CHANNEL_LAYOUT
@ AV_SIDE_DATA_PARAM_CHANGE_CHANNEL_LAYOUT
Definition: avcodec.h:1533
AV_PKT_DATA_SPHERICAL
@ AV_PKT_DATA_SPHERICAL
Definition: avcodec.h:1372
AV_PKT_DATA_DISPLAYMATRIX
@ AV_PKT_DATA_DISPLAYMATRIX
Definition: avcodec.h:1252
AV_PKT_DATA_STRINGS_METADATA
@ AV_PKT_DATA_STRINGS_METADATA
Definition: avcodec.h:1316
AV_PKT_DATA_REPLAYGAIN
@ AV_PKT_DATA_REPLAYGAIN
Definition: avcodec.h:1243
AV_PKT_DATA_WEBVTT_SETTINGS
@ AV_PKT_DATA_WEBVTT_SETTINGS
Definition: avcodec.h:1346
AV_PKT_DATA_AUDIO_SERVICE_TYPE
@ AV_PKT_DATA_AUDIO_SERVICE_TYPE
Definition: avcodec.h:1264
AV_SIDE_DATA_PARAM_CHANGE_DIMENSIONS
@ AV_SIDE_DATA_PARAM_CHANGE_DIMENSIONS
Definition: avcodec.h:1535
AV_PKT_DATA_STEREO3D
@ AV_PKT_DATA_STEREO3D
Definition: avcodec.h:1258
AV_PKT_DATA_MASTERING_DISPLAY_METADATA
@ AV_PKT_DATA_MASTERING_DISPLAY_METADATA
Definition: avcodec.h:1366
AV_PKT_DATA_SUBTITLE_POSITION
@ AV_PKT_DATA_SUBTITLE_POSITION
Definition: avcodec.h:1327
AV_PKT_DATA_H263_MB_INFO
@ AV_PKT_DATA_H263_MB_INFO
Definition: avcodec.h:1237
AV_PKT_DATA_CONTENT_LIGHT_LEVEL
@ AV_PKT_DATA_CONTENT_LIGHT_LEVEL
Definition: avcodec.h:1379
AV_PKT_DATA_METADATA_UPDATE
@ AV_PKT_DATA_METADATA_UPDATE
Definition: avcodec.h:1353
AV_PKT_DATA_JP_DUALMONO
@ AV_PKT_DATA_JP_DUALMONO
Definition: avcodec.h:1310
AV_PKT_DATA_A53_CC
@ AV_PKT_DATA_A53_CC
Definition: avcodec.h:1386
AV_PKT_DATA_CPB_PROPERTIES
@ AV_PKT_DATA_CPB_PROPERTIES
Definition: avcodec.h:1289
AV_PKT_DATA_SKIP_SAMPLES
@ AV_PKT_DATA_SKIP_SAMPLES
Definition: avcodec.h:1300
AV_SIDE_DATA_PARAM_CHANGE_CHANNEL_COUNT
@ AV_SIDE_DATA_PARAM_CHANGE_CHANNEL_COUNT
Definition: avcodec.h:1532
AV_PKT_DATA_NEW_EXTRADATA
@ AV_PKT_DATA_NEW_EXTRADATA
Definition: avcodec.h:1199
AV_PKT_DATA_MATROSKA_BLOCKADDITIONAL
@ AV_PKT_DATA_MATROSKA_BLOCKADDITIONAL
Definition: avcodec.h:1335
AV_PKT_DATA_FALLBACK_TRACK
@ AV_PKT_DATA_FALLBACK_TRACK
Definition: avcodec.h:1284
AV_PKT_DATA_QUALITY_STATS
@ AV_PKT_DATA_QUALITY_STATS
Definition: avcodec.h:1276
AV_PKT_DATA_WEBVTT_IDENTIFIER
@ AV_PKT_DATA_WEBVTT_IDENTIFIER
Definition: avcodec.h:1340