FFmpeg
Data Structures | Macros | Enumerations | Functions | Variables
asf.h File Reference
#include <stdint.h>
#include "avformat.h"
#include "metadata.h"
#include "riff.h"

Go to the source code of this file.

Data Structures

struct  ASFMainHeader
 
struct  ASFIndex
 

Macros

#define ASF_PACKET_FLAG_ERROR_CORRECTION_PRESENT   0x80
 
#define ASF_PPI_FLAG_MULTIPLE_PAYLOADS_PRESENT   1
 
#define ASF_PPI_FLAG_SEQUENCE_FIELD_IS_BYTE   0x02
 
#define ASF_PPI_FLAG_SEQUENCE_FIELD_IS_WORD   0x04
 
#define ASF_PPI_FLAG_SEQUENCE_FIELD_IS_DWORD   0x06
 
#define ASF_PPI_MASK_SEQUENCE_FIELD_SIZE   0x06
 
#define ASF_PPI_FLAG_PADDING_LENGTH_FIELD_IS_BYTE   0x08
 
#define ASF_PPI_FLAG_PADDING_LENGTH_FIELD_IS_WORD   0x10
 
#define ASF_PPI_FLAG_PADDING_LENGTH_FIELD_IS_DWORD   0x18
 
#define ASF_PPI_MASK_PADDING_LENGTH_FIELD_SIZE   0x18
 
#define ASF_PPI_FLAG_PACKET_LENGTH_FIELD_IS_BYTE   0x20
 
#define ASF_PPI_FLAG_PACKET_LENGTH_FIELD_IS_WORD   0x40
 
#define ASF_PPI_FLAG_PACKET_LENGTH_FIELD_IS_DWORD   0x60
 
#define ASF_PPI_MASK_PACKET_LENGTH_FIELD_SIZE   0x60
 
#define ASF_PL_FLAG_REPLICATED_DATA_LENGTH_FIELD_IS_BYTE   0x01
 
#define ASF_PL_FLAG_REPLICATED_DATA_LENGTH_FIELD_IS_WORD   0x02
 
#define ASF_PL_FLAG_REPLICATED_DATA_LENGTH_FIELD_IS_DWORD   0x03
 
#define ASF_PL_MASK_REPLICATED_DATA_LENGTH_FIELD_SIZE   0x03
 
#define ASF_PL_FLAG_OFFSET_INTO_MEDIA_OBJECT_LENGTH_FIELD_IS_BYTE   0x04
 
#define ASF_PL_FLAG_OFFSET_INTO_MEDIA_OBJECT_LENGTH_FIELD_IS_WORD   0x08
 
#define ASF_PL_FLAG_OFFSET_INTO_MEDIA_OBJECT_LENGTH_FIELD_IS_DWORD   0x0c
 
#define ASF_PL_MASK_OFFSET_INTO_MEDIA_OBJECT_LENGTH_FIELD_SIZE   0x0c
 
#define ASF_PL_FLAG_MEDIA_OBJECT_NUMBER_LENGTH_FIELD_IS_BYTE   0x10
 
#define ASF_PL_FLAG_MEDIA_OBJECT_NUMBER_LENGTH_FIELD_IS_WORD   0x20
 
#define ASF_PL_FLAG_MEDIA_OBJECT_NUMBER_LENGTH_FIELD_IS_DWORD   0x30
 
#define ASF_PL_MASK_MEDIA_OBJECT_NUMBER_LENGTH_FIELD_SIZE   0x30
 
#define ASF_PL_FLAG_STREAM_NUMBER_LENGTH_FIELD_IS_BYTE   0x40
 
#define ASF_PL_MASK_STREAM_NUMBER_LENGTH_FIELD_SIZE   0xc0
 
#define ASF_PL_FLAG_PAYLOAD_LENGTH_FIELD_IS_BYTE   0x40
 
#define ASF_PL_FLAG_PAYLOAD_LENGTH_FIELD_IS_WORD   0x80
 
#define ASF_PL_MASK_PAYLOAD_LENGTH_FIELD_SIZE   0xc0
 
#define ASF_PL_FLAG_KEY_FRAME   0x80
 

Enumerations

enum  ASFDataType {
  ASF_UNICODE = 0, ASF_BYTE_ARRAY = 1, ASF_BOOL = 2, ASF_DWORD = 3,
  ASF_QWORD = 4, ASF_WORD = 5, ASF_GUID = 6
}
 

Functions

int ff_asf_handle_byte_array (AVFormatContext *s, const char *name, int val_len)
 Handles both attached pictures as well as id3 tags. More...
 

Variables

const ff_asf_guid ff_asf_header
 
const ff_asf_guid ff_asf_file_header
 
const ff_asf_guid ff_asf_stream_header
 
const ff_asf_guid ff_asf_ext_stream_header
 
const ff_asf_guid ff_asf_audio_stream
 
const ff_asf_guid ff_asf_audio_conceal_spread
 
const ff_asf_guid ff_asf_video_stream
 
const ff_asf_guid ff_asf_jfif_media
 
const ff_asf_guid ff_asf_video_conceal_none
 
const ff_asf_guid ff_asf_command_stream
 
const ff_asf_guid ff_asf_comment_header
 
const ff_asf_guid ff_asf_codec_comment_header
 
const ff_asf_guid ff_asf_codec_comment1_header
 
const ff_asf_guid ff_asf_data_header
 
const ff_asf_guid ff_asf_head1_guid
 
const ff_asf_guid ff_asf_head2_guid
 
const ff_asf_guid ff_asf_extended_content_header
 
const ff_asf_guid ff_asf_simple_index_header
 
const ff_asf_guid ff_asf_ext_stream_embed_stream_header
 
const ff_asf_guid ff_asf_ext_stream_audio_stream
 
const ff_asf_guid ff_asf_metadata_header
 
const ff_asf_guid ff_asf_metadata_library_header
 
const ff_asf_guid ff_asf_marker_header
 
const ff_asf_guid ff_asf_reserved_4
 
const ff_asf_guid ff_asf_my_guid
 
const ff_asf_guid ff_asf_language_guid
 
const ff_asf_guid ff_asf_content_encryption
 
const ff_asf_guid ff_asf_ext_content_encryption
 
const ff_asf_guid ff_asf_digital_signature
 
const ff_asf_guid ff_asf_extended_stream_properties_object
 
const ff_asf_guid ff_asf_group_mutual_exclusion_object
 
const ff_asf_guid ff_asf_mutex_language
 
const AVMetadataConv ff_asf_metadata_conv []
 

Macro Definition Documentation

◆ ASF_PACKET_FLAG_ERROR_CORRECTION_PRESENT

#define ASF_PACKET_FLAG_ERROR_CORRECTION_PRESENT   0x80

Definition at line 117 of file asf.h.

◆ ASF_PPI_FLAG_MULTIPLE_PAYLOADS_PRESENT

#define ASF_PPI_FLAG_MULTIPLE_PAYLOADS_PRESENT   1

Definition at line 136 of file asf.h.

◆ ASF_PPI_FLAG_SEQUENCE_FIELD_IS_BYTE

#define ASF_PPI_FLAG_SEQUENCE_FIELD_IS_BYTE   0x02

Definition at line 138 of file asf.h.

◆ ASF_PPI_FLAG_SEQUENCE_FIELD_IS_WORD

#define ASF_PPI_FLAG_SEQUENCE_FIELD_IS_WORD   0x04

Definition at line 139 of file asf.h.

◆ ASF_PPI_FLAG_SEQUENCE_FIELD_IS_DWORD

#define ASF_PPI_FLAG_SEQUENCE_FIELD_IS_DWORD   0x06

Definition at line 140 of file asf.h.

◆ ASF_PPI_MASK_SEQUENCE_FIELD_SIZE

#define ASF_PPI_MASK_SEQUENCE_FIELD_SIZE   0x06

Definition at line 141 of file asf.h.

◆ ASF_PPI_FLAG_PADDING_LENGTH_FIELD_IS_BYTE

#define ASF_PPI_FLAG_PADDING_LENGTH_FIELD_IS_BYTE   0x08

Definition at line 143 of file asf.h.

◆ ASF_PPI_FLAG_PADDING_LENGTH_FIELD_IS_WORD

#define ASF_PPI_FLAG_PADDING_LENGTH_FIELD_IS_WORD   0x10

Definition at line 144 of file asf.h.

◆ ASF_PPI_FLAG_PADDING_LENGTH_FIELD_IS_DWORD

#define ASF_PPI_FLAG_PADDING_LENGTH_FIELD_IS_DWORD   0x18

Definition at line 145 of file asf.h.

◆ ASF_PPI_MASK_PADDING_LENGTH_FIELD_SIZE

#define ASF_PPI_MASK_PADDING_LENGTH_FIELD_SIZE   0x18

Definition at line 146 of file asf.h.

◆ ASF_PPI_FLAG_PACKET_LENGTH_FIELD_IS_BYTE

#define ASF_PPI_FLAG_PACKET_LENGTH_FIELD_IS_BYTE   0x20

Definition at line 148 of file asf.h.

◆ ASF_PPI_FLAG_PACKET_LENGTH_FIELD_IS_WORD

#define ASF_PPI_FLAG_PACKET_LENGTH_FIELD_IS_WORD   0x40

Definition at line 149 of file asf.h.

◆ ASF_PPI_FLAG_PACKET_LENGTH_FIELD_IS_DWORD

#define ASF_PPI_FLAG_PACKET_LENGTH_FIELD_IS_DWORD   0x60

Definition at line 150 of file asf.h.

◆ ASF_PPI_MASK_PACKET_LENGTH_FIELD_SIZE

#define ASF_PPI_MASK_PACKET_LENGTH_FIELD_SIZE   0x60

Definition at line 151 of file asf.h.

◆ ASF_PL_FLAG_REPLICATED_DATA_LENGTH_FIELD_IS_BYTE

#define ASF_PL_FLAG_REPLICATED_DATA_LENGTH_FIELD_IS_BYTE   0x01

Definition at line 154 of file asf.h.

◆ ASF_PL_FLAG_REPLICATED_DATA_LENGTH_FIELD_IS_WORD

#define ASF_PL_FLAG_REPLICATED_DATA_LENGTH_FIELD_IS_WORD   0x02

Definition at line 155 of file asf.h.

◆ ASF_PL_FLAG_REPLICATED_DATA_LENGTH_FIELD_IS_DWORD

#define ASF_PL_FLAG_REPLICATED_DATA_LENGTH_FIELD_IS_DWORD   0x03

Definition at line 156 of file asf.h.

◆ ASF_PL_MASK_REPLICATED_DATA_LENGTH_FIELD_SIZE

#define ASF_PL_MASK_REPLICATED_DATA_LENGTH_FIELD_SIZE   0x03

Definition at line 157 of file asf.h.

◆ ASF_PL_FLAG_OFFSET_INTO_MEDIA_OBJECT_LENGTH_FIELD_IS_BYTE

#define ASF_PL_FLAG_OFFSET_INTO_MEDIA_OBJECT_LENGTH_FIELD_IS_BYTE   0x04

Definition at line 159 of file asf.h.

◆ ASF_PL_FLAG_OFFSET_INTO_MEDIA_OBJECT_LENGTH_FIELD_IS_WORD

#define ASF_PL_FLAG_OFFSET_INTO_MEDIA_OBJECT_LENGTH_FIELD_IS_WORD   0x08

Definition at line 160 of file asf.h.

◆ ASF_PL_FLAG_OFFSET_INTO_MEDIA_OBJECT_LENGTH_FIELD_IS_DWORD

#define ASF_PL_FLAG_OFFSET_INTO_MEDIA_OBJECT_LENGTH_FIELD_IS_DWORD   0x0c

Definition at line 161 of file asf.h.

◆ ASF_PL_MASK_OFFSET_INTO_MEDIA_OBJECT_LENGTH_FIELD_SIZE

#define ASF_PL_MASK_OFFSET_INTO_MEDIA_OBJECT_LENGTH_FIELD_SIZE   0x0c

Definition at line 162 of file asf.h.

◆ ASF_PL_FLAG_MEDIA_OBJECT_NUMBER_LENGTH_FIELD_IS_BYTE

#define ASF_PL_FLAG_MEDIA_OBJECT_NUMBER_LENGTH_FIELD_IS_BYTE   0x10

Definition at line 164 of file asf.h.

◆ ASF_PL_FLAG_MEDIA_OBJECT_NUMBER_LENGTH_FIELD_IS_WORD

#define ASF_PL_FLAG_MEDIA_OBJECT_NUMBER_LENGTH_FIELD_IS_WORD   0x20

Definition at line 165 of file asf.h.

◆ ASF_PL_FLAG_MEDIA_OBJECT_NUMBER_LENGTH_FIELD_IS_DWORD

#define ASF_PL_FLAG_MEDIA_OBJECT_NUMBER_LENGTH_FIELD_IS_DWORD   0x30

Definition at line 166 of file asf.h.

◆ ASF_PL_MASK_MEDIA_OBJECT_NUMBER_LENGTH_FIELD_SIZE

#define ASF_PL_MASK_MEDIA_OBJECT_NUMBER_LENGTH_FIELD_SIZE   0x30

Definition at line 167 of file asf.h.

◆ ASF_PL_FLAG_STREAM_NUMBER_LENGTH_FIELD_IS_BYTE

#define ASF_PL_FLAG_STREAM_NUMBER_LENGTH_FIELD_IS_BYTE   0x40

Definition at line 169 of file asf.h.

◆ ASF_PL_MASK_STREAM_NUMBER_LENGTH_FIELD_SIZE

#define ASF_PL_MASK_STREAM_NUMBER_LENGTH_FIELD_SIZE   0xc0

Definition at line 170 of file asf.h.

◆ ASF_PL_FLAG_PAYLOAD_LENGTH_FIELD_IS_BYTE

#define ASF_PL_FLAG_PAYLOAD_LENGTH_FIELD_IS_BYTE   0x40

Definition at line 172 of file asf.h.

◆ ASF_PL_FLAG_PAYLOAD_LENGTH_FIELD_IS_WORD

#define ASF_PL_FLAG_PAYLOAD_LENGTH_FIELD_IS_WORD   0x80

Definition at line 173 of file asf.h.

◆ ASF_PL_MASK_PAYLOAD_LENGTH_FIELD_SIZE

#define ASF_PL_MASK_PAYLOAD_LENGTH_FIELD_SIZE   0xc0

Definition at line 174 of file asf.h.

◆ ASF_PL_FLAG_KEY_FRAME

#define ASF_PL_FLAG_KEY_FRAME   0x80

Definition at line 176 of file asf.h.

Enumeration Type Documentation

◆ ASFDataType

Enumerator
ASF_UNICODE 
ASF_BYTE_ARRAY 
ASF_BOOL 
ASF_DWORD 
ASF_QWORD 
ASF_WORD 
ASF_GUID 

Definition at line 29 of file asf.h.

Function Documentation

◆ ff_asf_handle_byte_array()

int ff_asf_handle_byte_array ( AVFormatContext s,
const char *  name,
int  val_len 
)

Handles both attached pictures as well as id3 tags.

Returns
Returns < 0 on error, 1 if the type of the byte array is unsupported by this function and 0 otherwise.

Definition at line 269 of file asf.c.

Referenced by get_tag(), and process_metadata().

Variable Documentation

◆ ff_asf_header

const ff_asf_guid ff_asf_header

◆ ff_asf_file_header

const ff_asf_guid ff_asf_file_header

◆ ff_asf_stream_header

const ff_asf_guid ff_asf_stream_header

Definition at line 33 of file asf.c.

Referenced by asf_read_header(), asf_write_header1(), and ff_mms_asf_header_parser().

◆ ff_asf_ext_stream_header

const ff_asf_guid ff_asf_ext_stream_header

Definition at line 37 of file asf.c.

Referenced by asf_read_header(), and ff_mms_asf_header_parser().

◆ ff_asf_audio_stream

const ff_asf_guid ff_asf_audio_stream

Definition at line 41 of file asf.c.

Referenced by asf_read_stream_properties(), and asf_write_header1().

◆ ff_asf_audio_conceal_spread

const ff_asf_guid ff_asf_audio_conceal_spread

Definition at line 45 of file asf.c.

Referenced by asf_write_header1().

◆ ff_asf_video_stream

const ff_asf_guid ff_asf_video_stream

Definition at line 49 of file asf.c.

Referenced by asf_read_stream_properties(), and asf_write_header1().

◆ ff_asf_jfif_media

const ff_asf_guid ff_asf_jfif_media

Definition at line 53 of file asf.c.

Referenced by asf_read_stream_properties().

◆ ff_asf_video_conceal_none

const ff_asf_guid ff_asf_video_conceal_none

Definition at line 57 of file asf.c.

Referenced by asf_write_header1().

◆ ff_asf_command_stream

const ff_asf_guid ff_asf_command_stream

Definition at line 61 of file asf.c.

Referenced by asf_read_stream_properties().

◆ ff_asf_comment_header

const ff_asf_guid ff_asf_comment_header

Definition at line 65 of file asf.c.

Referenced by asf_read_header(), and asf_write_header1().

◆ ff_asf_codec_comment_header

const ff_asf_guid ff_asf_codec_comment_header

Definition at line 69 of file asf.c.

Referenced by asf_write_header1().

◆ ff_asf_codec_comment1_header

const ff_asf_guid ff_asf_codec_comment1_header

Definition at line 72 of file asf.c.

Referenced by asf_write_header1().

◆ ff_asf_data_header

const ff_asf_guid ff_asf_data_header

Definition at line 76 of file asf.c.

Referenced by asf_read_header(), asf_write_header1(), and ff_mms_asf_header_parser().

◆ ff_asf_head1_guid

const ff_asf_guid ff_asf_head1_guid

Definition at line 80 of file asf.c.

Referenced by asf_read_header(), asf_write_header1(), and ff_mms_asf_header_parser().

◆ ff_asf_head2_guid

const ff_asf_guid ff_asf_head2_guid

Definition at line 84 of file asf.c.

Referenced by asf_write_header1().

◆ ff_asf_extended_content_header

const ff_asf_guid ff_asf_extended_content_header

Definition at line 88 of file asf.c.

Referenced by asf_read_header(), and asf_write_header1().

◆ ff_asf_simple_index_header

const ff_asf_guid ff_asf_simple_index_header

Definition at line 92 of file asf.c.

Referenced by asf_build_simple_index(), and asf_write_index().

◆ ff_asf_ext_stream_embed_stream_header

const ff_asf_guid ff_asf_ext_stream_embed_stream_header

Definition at line 96 of file asf.c.

Referenced by asf_read_stream_properties().

◆ ff_asf_ext_stream_audio_stream

const ff_asf_guid ff_asf_ext_stream_audio_stream

Definition at line 100 of file asf.c.

Referenced by asf_read_stream_properties().

◆ ff_asf_metadata_header

const ff_asf_guid ff_asf_metadata_header

Definition at line 104 of file asf.c.

Referenced by asf_read_header(), and asf_write_header1().

◆ ff_asf_metadata_library_header

const ff_asf_guid ff_asf_metadata_library_header

Definition at line 108 of file asf.c.

Referenced by asf_read_header().

◆ ff_asf_marker_header

const ff_asf_guid ff_asf_marker_header

Definition at line 112 of file asf.c.

Referenced by asf_read_header(), and asf_write_markers().

◆ ff_asf_reserved_4

const ff_asf_guid ff_asf_reserved_4

Definition at line 116 of file asf.c.

Referenced by asf_write_markers().

◆ ff_asf_my_guid

const ff_asf_guid ff_asf_my_guid

Definition at line 122 of file asf.c.

Referenced by asf_write_header1(), and asf_write_index().

◆ ff_asf_language_guid

const ff_asf_guid ff_asf_language_guid

Definition at line 126 of file asf.c.

Referenced by asf_read_header(), and asf_write_header1().

◆ ff_asf_content_encryption

const ff_asf_guid ff_asf_content_encryption

Definition at line 130 of file asf.c.

Referenced by asf_read_header().

◆ ff_asf_ext_content_encryption

const ff_asf_guid ff_asf_ext_content_encryption

Definition at line 134 of file asf.c.

Referenced by asf_read_header().

◆ ff_asf_digital_signature

const ff_asf_guid ff_asf_digital_signature

Definition at line 138 of file asf.c.

Referenced by asf_read_header().

◆ ff_asf_extended_stream_properties_object

const ff_asf_guid ff_asf_extended_stream_properties_object

Definition at line 142 of file asf.c.

Referenced by asf_write_header1().

◆ ff_asf_group_mutual_exclusion_object

const ff_asf_guid ff_asf_group_mutual_exclusion_object

Definition at line 146 of file asf.c.

Referenced by asf_write_header1().

◆ ff_asf_mutex_language

const ff_asf_guid ff_asf_mutex_language

Definition at line 150 of file asf.c.

Referenced by asf_write_header1().

◆ ff_asf_metadata_conv

const AVMetadataConv ff_asf_metadata_conv[]