format

package
v0.0.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Dec 3, 2021 License: MIT Imports: 1 Imported by: 1

Documentation

Index

Constants

View Source
const (
	ALL = "all"

	PROBE       = "probe"
	IMAGE       = "image"
	TCP_STREAM  = "tcp_stream"
	UDP_PAYLOAD = "udp_payload"

	RAW  = "raw"
	JSON = "json"

	DNS             = "dns"
	DNS_TCP         = "dns_tcp"
	ETHER8023_FRAME = "ether8023_frame"
	SLL_PACKET      = "sll_packet"
	SLL2_PACKET     = "sll2_packet"
	IPV4_PACKET     = "ipv4_packet"
	UDP_DATAGRAM    = "udp_datagram"
	TCP_SEGMENT     = "tcp_segment"
	ICMP            = "icmp"

	AAC_FRAME           = "aac_frame"
	ADTS                = "adts"
	ADTS_FRAME          = "adts_frame"
	APEV2               = "apev2"
	AV1_CCR             = "av1_ccr"
	AV1_FRAME           = "av1_frame"
	AV1_OBU             = "av1_obu"
	BZIP2               = "bzip2"
	ELF                 = "elf"
	EXIF                = "exif"
	FLAC                = "flac"
	FLAC_FRAME          = "flac_frame"
	FLAC_METADATABLOCK  = "flac_metadatablock"
	FLAC_METADATABLOCKS = "flac_metadatablocks"
	FLAC_STREAMINFO     = "flac_streaminfo"
	FLAC_PICTURE        = "flac_picture"
	FLV                 = "flv" // TODO:
	GIF                 = "gif"
	GZIP                = "gzip"
	ICC_PROFILE         = "icc_profile"
	ID3V1               = "id3v1"
	ID3V11              = "id3v11"
	ID3V2               = "id3v2"
	JPEG                = "jpeg"
	MATROSKA            = "matroska"
	MP3                 = "mp3"
	MP3_FRAME           = "mp3_frame"
	XING                = "xing"
	MP4                 = "mp4"
	MPEG_ASC            = "mpeg_asc"
	AVC_ANNEXB          = "avc_annexb"
	AVC_DCR             = "avc_dcr"
	AVC_SPS             = "avc_sps"
	AVC_PPS             = "avc_pps"
	AVC_SEI             = "avc_sei"
	AVC_NALU            = "avc_nalu"
	AVC_AU              = "avc_au"
	HEVC_ANNEXB         = "hevc_annexb"
	HEVC_AU             = "hevc_au"
	HEVC_NALU           = "hevc_nalu"
	HEVC_DCR            = "hevc_dcr"
	MPEG_ES             = "mpeg_es"
	MPEG_PES            = "mpeg_pes"
	MPEG_PES_PACKET     = "mpeg_pes_packet"
	MPEG_SPU            = "mpeg_spu"
	MPEG_TS             = "mpeg_ts"
	OGG                 = "ogg"
	OGG_PAGE            = "ogg_page"
	OPUS_PACKET         = "opus_packet"
	PCAP                = "pcap"
	PCAPNG              = "pcapng"
	PNG                 = "png"
	PROTOBUF            = "protobuf"
	PROTOBUF_WIDEVINE   = "protobuf_widevine"
	PSSH_PLAYREADY      = "pssh_playready"
	TAR                 = "tar"
	TIFF                = "tiff"
	VORBIS_COMMENT      = "vorbis_comment"
	VORBIS_PACKET       = "vorbis_packet"
	VP8_FRAME           = "vp8_frame"
	VP9_FRAME           = "vp9_frame"
	VP9_CFM             = "vp9_cfm"
	VPX_CCR             = "vpx_ccr"
	WAV                 = "wav"
	WEBP                = "webp"
	ZIP                 = "zip"
)
View Source
const (
	LinkTypeNULL                       = 0
	LinkTypeETHERNET                   = 1
	LinkTypeAX25                       = 3
	LinkTypeIEEE802_5                  = 6
	LinkTypeARCNET_BSD                 = 7
	LinkTypeSLIP                       = 8
	LinkTypePPP                        = 9
	LinkTypeFDDI                       = 10
	LinkTypePPP_HDLC                   = 50
	LinkTypePPP_ETHER                  = 51
	LinkTypeATM_RFC1483                = 100
	LinkTypeRAW                        = 101
	LinkTypeC_HDLC                     = 104
	LinkTypeIEEE802_11                 = 105
	LinkTypeFRELAY                     = 107
	LinkTypeLOOP                       = 108
	LinkTypeLINUX_SLL                  = 113
	LinkTypeLTALK                      = 114
	LinkTypePFLOG                      = 117
	LinkTypeIEEE802_11_PRISM           = 119
	LinkTypeIP_OVER_FC                 = 122
	LinkTypeSUNATM                     = 123
	LinkTypeIEEE802_11_RADIOTAP        = 127
	LinkTypeARCNET_LINUX               = 129
	LinkTypeAPPLE_IP_OVER_IEEE1394     = 138
	LinkTypeMTP2_WITH_PHDR             = 139
	LinkTypeMTP2                       = 140
	LinkTypeMTP3                       = 141
	LinkTypeSCCP                       = 142
	LinkTypeDOCSIS                     = 143
	LinkTypeLINUX_IRDA                 = 144
	LinkTypeUSER0                      = 147
	LinkTypeUSER1                      = 148
	LinkTypeUSER2                      = 149
	LinkTypeUSER3                      = 150
	LinkTypeUSER4                      = 151
	LinkTypeUSER5                      = 152
	LinkTypeUSER6                      = 153
	LinkTypeUSER7                      = 154
	LinkTypeUSER8                      = 155
	LinkTypeUSER9                      = 156
	LinkTypeUSER10                     = 157
	LinkTypeUSER11                     = 158
	LinkTypeUSER12                     = 159
	LinkTypeUSER13                     = 160
	LinkTypeUSER14                     = 161
	LinkTypeUSER15                     = 162
	LinkTypeIEEE802_11_AVS             = 163
	LinkTypeBACNET_MS_TP               = 165
	LinkTypePPP_PPPD                   = 166
	LinkTypeGPRS_LLC                   = 169
	LinkTypeGPF_T                      = 170
	LinkTypeGPF_F                      = 171
	LinkTypeLINUX_LAPD                 = 177
	LinkTypeMFR                        = 182
	LinkTypeBLUETOOTH_HCI_H4           = 187
	LinkTypeUSB_LINUX                  = 189
	LinkTypePPI                        = 192
	LinkTypeIEEE802_15_4_WITHFCS       = 195
	LinkTypeSITA                       = 196
	LinkTypeERF                        = 197
	LinkTypeBLUETOOTH_HCI_H4_WITH_PHDR = 201
	LinkTypeAX25_KISS                  = 202
	LinkTypeLAPD                       = 203
	LinkTypePPP_WITH_DIR               = 204
	LinkTypeC_HDLC_WITH_DIR            = 205
	LinkTypeFRELAY_WITH_DIR            = 206
	LinkTypeLAPB_WITH_DIR              = 207
	LinkTypeIPMB_LINUX                 = 209
	LinkTypeFLEXRAY                    = 210
	LinkTypeLIN                        = 212
	LinkTypeIEEE802_15_4_NONASK_PHY    = 215
	LinkTypeUSB_LINUX_MMAPPED          = 220
	LinkTypeFC_2                       = 224
	LinkTypeFC_2_WITH_FRAME_DELIMS     = 225
	LinkTypeIPNET                      = 226
	LinkTypeCAN_SOCKETCAN              = 227
	LinkTypeIPV4                       = 228
	LinkTypeIPV6                       = 229
	LinkTypeIEEE802_15_4_NOFCS         = 230
	LinkTypeDBUS                       = 231
	LinkTypeDVB_CI                     = 235
	LinkTypeMUX27010                   = 236
	LinkTypeSTANAG_5066_D_PDU          = 237
	LinkTypeNFLOG                      = 239
	LinkTypeNETANALYZER                = 240
	LinkTypeNETANALYZER_TRANSPARENT    = 241
	LinkTypeIPOIB                      = 242
	LinkTypeMPEG_2_TS                  = 243
	LinkTypeNG40                       = 244
	LinkTypeNFC_LLCP                   = 245
	LinkTypeINFINIBAND                 = 247
	LinkTypeSCTP                       = 248
	LinkTypeUSBPCAP                    = 249
	LinkTypeRTAC_SERIAL                = 250
	LinkTypeBLUETOOTH_LE_LL            = 251
	LinkTypeNETLINK                    = 253
	LinkTypeBLUETOOTH_LINUX_MONITOR    = 254
	LinkTypeBLUETOOTH_BREDR_BB         = 255
	LinkTypeBLUETOOTH_LE_LL_WITH_PHDR  = 256
	LinkTypePROFIBUS_DL                = 257
	LinkTypePKTAP                      = 258
	LinkTypeEPON                       = 259
	LinkTypeIPMI_HPM_2                 = 260
	LinkTypeZWAVE_R1_R2                = 261
	LinkTypeZWAVE_R3                   = 262
	LinkTypeWATTSTOPPER_DLM            = 263
	LinkTypeISO_14443                  = 264
	LinkTypeRDS                        = 265
	LinkTypeUSB_DARWIN                 = 266
	LinkTypeSDLC                       = 268
	LinkTypeLORATAP                    = 270
	LinkTypeVSOCK                      = 271
	LinkTypeNORDIC_BLE                 = 272
	LinkTypeDOCSIS31_XRA31             = 273
	LinkTypeETHERNET_MPACKET           = 274
	LinkTypeDISPLAYPORT_AUX            = 275
	LinkTypeLINUX_SLL2                 = 276
	LinkTypeOPENVIZSLA                 = 278
	LinkTypeEBHSCR                     = 279
	LinkTypeVPP_DISPATCH               = 280
	LinkTypeDSA_TAG_BRCM               = 281
	LinkTypeDSA_TAG_BRCM_PREPEND       = 282
	LinkTypeIEEE802_15_4_TAP           = 283
	LinkTypeDSA_TAG_DSA                = 284
	LinkTypeDSA_TAG_EDSA               = 285
	LinkTypeELEE                       = 286
	LinkTypeZ_WAVE_SERIAL              = 287
	LinkTypeUSB_2_0                    = 288
	LinkTypeATSC_ALP                   = 289
	LinkTypeETW                        = 290
)

from https://www.tcpdump.org/linktypes.html TODO cleanup

View Source
const (
	IPv4ProtocolICMP = 1
	IPv4ProtocolIGMP = 2
	IPv4ProtocolTCP  = 6
	IPv4ProtocolUDP  = 17
)
View Source
const (
	UDPPortDomain = 53
	UDPPortMDNS   = 5353
)
View Source
const (
	MPEGObjectTypeMOV_TEXT          = 0x08
	MPEGObjectTypeMPEG4             = 0x20
	MPEGObjectTypeH264              = 0x21
	MPEGObjectTypeHEVC              = 0x23
	MPEGObjectTypeAAC               = 0x40
	MPEGObjectTypeMPEG2VideoMain    = 0x61 /* MPEG-2 Main */
	MPEGObjectTypeMPEG2VideoSimple  = 0x60 /* MPEG-2 Simple */
	MPEGObjectTypeMPEG2VideoSNR     = 0x62 /* MPEG-2 SNR */
	MPEGObjectTypeMPEG2VideoSpatial = 0x63 /* MPEG-2 Spatial */
	MPEGObjectTypeMPEG2VideoHigh    = 0x64 /* MPEG-2 High */
	MPEGObjectTypeMPEG2Video422     = 0x65 /* MPEG-2 422 */
	MPEGObjectTypeAACMain           = 0x66 /* MPEG-2 AAC Main */
	MPEGObjectTypeAACLow            = 0x67 /* MPEG-2 AAC Low */
	MPEGObjectTypeAACSSR            = 0x68 /* MPEG-2 AAC SSR */
	MPEGObjectTypeMP32MP3           = 0x69 /* 13818-3 */
	MPEGObjectTypeMPEG1VIDEO        = 0x6a /* 11172-2 */
	MPEGObjectTypeMP3               = 0x6b /* 11172-3 */
	MPEGObjectTypeMJPEG             = 0x6c /* 10918-1 */
	MPEGObjectTypePNG               = 0x6d
	MPEGObjectTypeJPEG2000          = 0x6e /* 15444-1 */
	MPEGObjectTypeVC1               = 0xa3
	MPEGObjectTypeDIRAC             = 0xa4
	MPEGObjectTypeAC3               = 0xa5
	MPEGObjectTypeEAC3              = 0xa6
	MPEGObjectTypeDTS               = 0xa9 /* mp4ra.org */
	MPEGObjectTypeOPUS              = 0xad /* mp4ra.org */
	MPEGObjectTypeVP9               = 0xb1 /* mp4ra.org */
	MPEGObjectTypeFLAC              = 0xc1 /* nonstandard, update when there is a standard value */
	MPEGObjectTypeTSCC2             = 0xd0 /* nonstandard, camtasia uses it */
	MPEGObjectTypeEVRC              = 0xd1 /* nonstandard, pvAuthor uses it */
	MPEGObjectTypeVORBIS            = 0xdd /* nonstandard, gpac uses it */
	MPEGObjectTypeDVDSubtitle       = 0xe0 /* nonstandard, see unsupported-embedded-subs-2.mp4 */
	MPEGObjectTypeQCELP             = 0xe1
	MPEGObjectTypeMPEG4SYSTEMS1     = 0x01
	MPEGObjectTypeMPEG4SYSTEMS2     = 0x02
	MPEGObjectTypeNONE              = 0
)

based on ffmpeg libavformat/isom.c ff_mp4_obj_type

View Source
const (
	MPEGStreamTypeUnknown = iota
	MPEGStreamTypeVideo
	MPEGStreamTypeAudio
	MPEGStreamTypeText
)
View Source
const (
	MPEGAudioObjectTypeMain      = 1
	MPEGAudioObjectTypeLC        = 2
	MPEGAudioObjectTypeSSR       = 3
	MPEGAudioObjectTypeLTP       = 4
	MPEGAudioObjectTypeSBR       = 5
	MPEGAudioObjectTypeER_AAC_LD = 23
)
View Source
const (
	ProtoBufTypeInt32 = iota
	ProtoBufTypeInt64
	ProtoBufTypeUInt32
	ProtoBufTypeUInt64
	ProtoBufTypeSInt32
	ProtoBufTypeSInt64
	ProtoBufTypeBool
	ProtoBufTypeEnum
	ProtoBufTypeFixed64
	ProtoBufTypeSFixed64
	ProtoBufTypeDouble
	ProtoBufTypeString
	ProtoBufTypeBytes
	ProtoBufTypeMessage
	ProtoBufTypePackedRepeated
	ProtoBufTypeFixed32
	ProtoBufTypeSFixed32
	ProtoBufTypeFloat
)
View Source
const (
	EtherTypeIPv4 = 0x0800
)
View Source
const (
	TCPPortDomain = 53
)

Variables

View Source
var EtherTypeMap = scalar.UToScalar{
	EtherTypeIPv4: {Sym: "ipv4", Description: `Internet Protocol version 4`},
	0x0806:        {Sym: "arp", Description: `Address Resolution Protocol`},
	0x0842:        {Sym: "wake", Description: `Wake-on-LAN[9]`},
	0x22f0:        {Sym: "audio", Description: `Audio Video Transport Protocol`},
	0x22f3:        {Sym: "trill", Description: `IETF TRILL Protocol`},
	0x22ea:        {Sym: "srp", Description: `Stream Reservation Protocol`},
	0x6002:        {Sym: "dec", Description: `DEC MOP RC`},
	0x6003:        {Sym: "decnet", Description: `DECnet Phase IV, DNA Routing`},
	0x6004:        {Sym: "declat", Description: `DEC LAT`},
	0x8035:        {Sym: "Reverse", Description: `Reverse Address Resolution Protocol`},
	0x809b:        {Sym: "appletalk", Description: `AppleTalk`},
	0x80f3:        {Sym: "appletalk_arp", Description: `AppleTalk Address Resolution Protocol`},
	0x8100:        {Sym: "vlan", Description: `VLAN-tagged (IEEE 802.1Q)`},
	0x8102:        {Sym: "slpp", Description: `Simple Loop Prevention Protocol`},
	0x8103:        {Sym: "vlacp", Description: `Virtual Link Aggregation Control Protocol`},
	0x8137:        {Sym: "ipx", Description: `IPX`},
	0x8204:        {Sym: "qnx", Description: `QNX Qnet`},
	0x86dd:        {Sym: "ipv6", Description: `Internet Protocol Version 6`},
	0x8808:        {Sym: "flow_control", Description: `Ethernet flow control`},
	0x8809:        {Sym: "lacp", Description: `Ethernet Slow Protocols] such as the Link Aggregation Control Protocol`},
	0x8819:        {Sym: "cobranet", Description: `CobraNet`},
	0x8847:        {Sym: "mpls", Description: `MPLS unicast`},
	0x8848:        {Sym: "mpls", Description: `MPLS multicast`},
	0x8863:        {Sym: "pppoe_discovery", Description: `PPPoE Discovery Stage`},
	0x8864:        {Sym: "pppoe_session", Description: `PPPoE Session Stage`},
	0x887b:        {Sym: "homeplug", Description: `HomePlug 1.0 MME`},
	0x888e:        {Sym: "eap", Description: `EAP over LAN (IEEE 802.1X)`},
	0x8892:        {Sym: "profinet", Description: `PROFINET Protocol`},
	0x889a:        {Sym: "hyperscsi", Description: `HyperSCSI (SCSI over Ethernet)`},
	0x88a2:        {Sym: "ata", Description: `ATA over Ethernet`},
	0x88a4:        {Sym: "ethercat", Description: `EtherCAT Protocol`},
	0x88a8:        {Sym: "service", Description: `Service VLAN tag identifier (S-Tag) on Q-in-Q tunnel`},
	0x88ab:        {Sym: "ethernet", Description: `Ethernet Powerlink`},
	0x88b8:        {Sym: "goose", Description: `GOOSE (Generic Object Oriented Substation event)`},
	0x88b9:        {Sym: "gse", Description: `GSE (Generic Substation Events) Management Services`},
	0x88ba:        {Sym: "sv", Description: `SV (Sampled Value Transmission)`},
	0x88bf:        {Sym: "mikrotik", Description: `MikroTik RoMON (unofficial)`},
	0x88cc:        {Sym: "link", Description: `Link Layer Discovery Protocol (LLDP)`},
	0x88cd:        {Sym: "sercos", Description: `SERCOS III`},
	0x88e1:        {Sym: "homeplug", Description: `HomePlug Green PHY`},
	0x88e3:        {Sym: "media", Description: `Media Redundancy Protocol (IEC62439-2)`},
	0x88e5:        {Sym: "ieee", Description: `IEEE 802.1AE MAC security (MACsec)`},
	0x88e7:        {Sym: "provider", Description: `Provider Backbone Bridges (PBB) (IEEE 802.1ah)`},
	0x88f7:        {Sym: "precision", Description: `Precision Time Protocol (PTP) over IEEE 802.3 Ethernet`},
	0x88f8:        {Sym: "nc", Description: `NC-SI`},
	0x88fb:        {Sym: "parallel", Description: `Parallel Redundancy Protocol (PRP)`},
	0x8902:        {Sym: "ieee", Description: `IEEE 802.1ag Connectivity Fault Management (CFM) Protocol / ITU-T Recommendation Y.1731 (OAM)`},
	0x8906:        {Sym: "fibre", Description: `Fibre Channel over Ethernet (FCoE)`},
	0x8914:        {Sym: "fcoe", Description: `FCoE Initialization Protocol`},
	0x8915:        {Sym: "rdma", Description: `RDMA over Converged Ethernet (RoCE)`},
	0x891d:        {Sym: "ttethernet", Description: `TTEthernet Protocol Control Frame (TTE)`},
	0x893a:        {Sym: "1905", Description: `1905.1 IEEE Protocol`},
	0x892f:        {Sym: "high", Description: `High-availability Seamless Redundancy (HSR)`},
	0x9000:        {Sym: "ethernet", Description: `Ethernet Configuration Testing Protocol[12]`},
	0xf1c1:        {Sym: "redundancy", Description: `Redundancy Tag (IEEE 802.1CB Frame Replication and Elimination for Reliability)`},
}

from https://en.wikipedia.org/wiki/EtherType TODO: cleanup

View Source
var IPv4ProtocolMap = scalar.UToScalar{}/* 136 elements not displayed */
View Source
var ISO_23091_2_ColourPrimariesMap = scalar.UToScalar{
	1:  {Sym: "bt709", Description: "ITU-R BT1361 / IEC 61966-2-4 / SMPTE RP 177 Annex B"},
	2:  {Sym: "unspecified", Description: "Unspecified"},
	3:  {Sym: "reserved", Description: "Reserved"},
	4:  {Sym: "bt470m", Description: "FCC Title 47 Code of Federal Regulations 73.682 (a)(20)"},
	5:  {Sym: "bt470bg", Description: "ITU-R BT601-6 625 / ITU-R BT1358 625 / ITU-R BT1700 625 PAL & SECAM"},
	6:  {Sym: "smpte170m", Description: "ITU-R BT601-6 525 / ITU-R BT1358 525 / ITU-R BT1700 NTSC"},
	7:  {Sym: "smpte240m", Description: "ITU-R BT601-6 525 / ITU-R BT1358 525 / ITU-R BT1700 NTSC"},
	8:  {Sym: "film", Description: "Illuminant C"},
	9:  {Sym: "bt2020", Description: "ITU-R BT2020"},
	10: {Sym: "smpte428", Description: "SMPTE ST 428-1 (CIE 1931 XYZ)"},
	11: {Sym: "smpte431", Description: "SMPTE ST 431-2 (2011) / DCI P3"},
	12: {Sym: "smpte432", Description: "SMPTE ST 432-1 (2010) / P3 D65 / Display P3"},
	22: {Sym: "ebu3213", Description: "EBU Tech. 3213-E (nothing there) / one of JEDEC P22 group phosphors"},
}

based on ffmpeg/libavutil/pixfmt.h

View Source
var ISO_23091_2_MatrixCoefficients = scalar.UToScalar{
	0:  {Sym: "rgb", Description: "GBR, IEC 61966-2-1 (sRGB), YZX and ST 428-1"},
	1:  {Sym: "bt709", Description: "ITU-R BT1361 / IEC 61966-2-4 xvYCC709 / derived in SMPTE RP 177 Annex B"},
	2:  {Sym: "unspecified", Description: "Unspecified"},
	3:  {Sym: "reserved", Description: "Reserved"},
	4:  {Sym: "fcc", Description: "FCC Title 47 Code of Federal Regulations 73.682 (a)(20)"},
	5:  {Sym: "bt470bg", Description: "ITU-R BT601-6 625 / ITU-R BT1358 625 / ITU-R BT1700 625 PAL & SECAM / IEC 61966-2-4 xvYCC601"},
	6:  {Sym: "smpte170m", Description: "ITU-R BT601-6 525 / ITU-R BT1358 525 / ITU-R BT1700 NTSC"},
	7:  {Sym: "smpte240m", Description: "Derived from 170M primaries and D65 white point"},
	8:  {Sym: "ycgco", Description: "VC-2 and H.264 FRext"},
	9:  {Sym: "bt2020_ncl", Description: "ITU-R BT2020 non-constant luminance system"},
	10: {Sym: "bt2020_cl", Description: "ITU-R BT2020 constant luminance system"},
	11: {Sym: "smpte2085", Description: "SMPTE 2085, Y'D'zD'x"},
	12: {Sym: "chroma_derived_ncl", Description: "Chromaticity-derived non-constant luminance system"},
	13: {Sym: "chroma_derived_cl", Description: "Chromaticity-derived constant luminance system"},
	14: {Sym: "ictcp", Description: "ITU-R BT.2100-0, ICtCp"},
}
View Source
var ISO_23091_2_TransferCharacteristicMap = scalar.UToScalar{
	1:  {Sym: "bt709", Description: "ITU-R BT1361"},
	2:  {Sym: "unspecified", Description: "Unspecified"},
	3:  {Sym: "reserved", Description: "Reserved"},
	4:  {Sym: "gamma22", Description: "ITU-R BT470M / ITU-R BT1700 625 PAL & SECAM"},
	5:  {Sym: "gamma28", Description: "ITU-R BT470BG"},
	6:  {Sym: "smpte170m", Description: "ITU-R BT601-6 525 or 625 / ITU-R BT1358 525 or 625 / ITU-R BT1700 NTSC"},
	7:  {Sym: "smpte240m"},
	8:  {Sym: "linear", Description: "Linear transfer characteristics"},
	9:  {Sym: "log", Description: "Logarithmic transfer characteristic (100:1 range)"},
	10: {Sym: "log_sqrt", Description: "Logarithmic transfer characteristic (100 * Sqrt(10) : 1 range)"},
	11: {Sym: "iec61966_2_4", Description: "IEC 61966-2-4"},
	12: {Sym: "bt1361_ecg", Description: "ITU-R BT1361 Extended Colour Gamut"},
	13: {Sym: "iec61966_2_1", Description: "IEC 61966-2-1 (sRGB or sYCC)"},
	14: {Sym: "bt2020_10", Description: "ITU-R BT2020 for 10-bit system"},
	15: {Sym: "bt2020_12", Description: "ITU-R BT2020 for 12-bit system"},
	16: {Sym: "smpte2084", Description: "SMPTE ST 2084 for 10-, 12-, 14- and 16-bit systems"},
	17: {Sym: "smpte428", Description: "SMPTE ST 428-1"},
	18: {Sym: "arib_std_b67", Description: "ARIB STD-B67, known as Hybrid log-gamma"},
}
View Source
var LinkTypeMap = scalar.UToScalar{}/* 131 elements not displayed */
View Source
var MPEGAudioObjectTypeNames = scalar.UToScalar{
	0:                            {Sym: "mull", Description: "Null"},
	MPEGAudioObjectTypeMain:      {Sym: "aac_main", Description: "AAC Main"},
	MPEGAudioObjectTypeLC:        {Sym: "aac_lc", Description: "AAC Low Complexity)"},
	MPEGAudioObjectTypeSSR:       {Sym: "aac_ssr", Description: "AAC Scalable Sample Rate"},
	MPEGAudioObjectTypeLTP:       {Sym: "aac_ltp", Description: "AAC Long Term Prediction"},
	MPEGAudioObjectTypeSBR:       {Sym: "sbr", Description: "Spectral Band Replication"},
	6:                            {Sym: "aac_scalable", Description: "AAC Scalable"},
	7:                            {Sym: "twinvq", Description: "TwinVQ"},
	8:                            {Sym: "celp", Description: "Code Excited Linear Prediction"},
	9:                            {Sym: "hxvc", Description: "Harmonic Vector eXcitation Coding"},
	10:                           {Sym: "reserved", Description: "Reserved"},
	11:                           {Sym: "reserved", Description: "Reserved"},
	12:                           {Sym: "ttsi", Description: "TTSI (Text-To-Speech Interface)"},
	13:                           {Sym: "main_synthesis", Description: "Main Synthesis"},
	14:                           {Sym: "wavetable_synthesis", Description: "Wavetable Synthesis"},
	15:                           {Sym: "general_midi", Description: "General MIDI"},
	16:                           {Sym: "algorithmic", Description: "Algorithmic Synthesis and Audio Effects"},
	17:                           {Sym: "er_aac_lc", Description: "Error Resilient AAC LC"},
	18:                           {Sym: "reserved", Description: "Reserved"},
	19:                           {Sym: "er_aac_ltp", Description: "ER AAC LTP"},
	20:                           {Sym: "er_aac_Scalable", Description: "ER AAC Scalable"},
	21:                           {Sym: "er_twinvq", Description: "ER TwinVQ"},
	22:                           {Sym: "er_bsac", Description: "ER BSAC Bit-Sliced Arithmetic Coding"},
	MPEGAudioObjectTypeER_AAC_LD: {Sym: "er_aac_ld", Description: "ER AAC LD Low Delay"},
	24:                           {Sym: "er_celp", Description: "ER CELP"},
	25:                           {Sym: "er_hvxc", Description: "ER HVXC"},
	26:                           {Sym: "er_hiln", Description: "ER HILN Harmonic and Individual Lines plus Noise"},
	27:                           {Sym: "er_parametric", Description: "ER Parametric"},
	28:                           {Sym: "ssc", Description: "SinuSoidal Coding"},
	29:                           {Sym: "ps", Description: "Parametric Stereo"},
	30:                           {Sym: "mpeg_surround", Description: "MPEG Surround"},
	31:                           {Sym: "(escape value)", Description: "(Escape value)"},
	32:                           {Sym: "layer_1", Description: "MPEG Layer-1"},
	33:                           {Sym: "layer_2", Description: "MPEG Layer-2"},
	34:                           {Sym: "layer_3", Description: "MPEG Layer-3"},
	35:                           {Sym: "dst", Description: "Direct Stream Transfer"},
	36:                           {Sym: "als", Description: "Audio Lossless"},
	37:                           {Sym: "sls", Description: "Scalable Lossless"},
	38:                           {Sym: "sls_non_core", Description: "SLS non-core"},
	39:                           {Sym: "er_aac_eld", Description: "ER AAC ELD Enhanced Low Delay"},
	40:                           {Sym: "smr_simple", Description: "Symbolic Music Representation Simple"},
	41:                           {Sym: "smr_main", Description: "Symbolic Music Representation Main"},
	42:                           {Sym: "usac_no_sbr", Description: "Unified Speech and Audio Coding (no SBR)"},
	43:                           {Sym: "saoc", Description: "Spatial Audio Object Coding"},
	44:                           {Sym: "ld_mpeg_surround", Description: "LD MPEG Surround"},
	45:                           {Sym: "usac", Description: "USAC"},
}
View Source
var MpegObjectTypeNames = scalar.UToSymStr{
	MPEGObjectTypeMOV_TEXT:          "MPEGObjectTypeMOV_TEXT",
	MPEGObjectTypeMPEG4:             "MPEGObjectTypeMPEG4",
	MPEGObjectTypeH264:              "MPEGObjectTypeH264",
	MPEGObjectTypeHEVC:              "MPEGObjectTypeHEVC",
	MPEGObjectTypeAAC:               "MPEGObjectTypeAAC",
	MPEGObjectTypeMPEG2VideoMain:    "MPEGObjectTypeMPEG2VideoMain",
	MPEGObjectTypeMPEG2VideoSimple:  "MPEGObjectTypeMPEG2VideoSimple",
	MPEGObjectTypeMPEG2VideoSNR:     "MPEGObjectTypeMPEG2VideoSNR",
	MPEGObjectTypeMPEG2VideoSpatial: "MPEGObjectTypeMPEG2VideoSpatial",
	MPEGObjectTypeMPEG2VideoHigh:    "MPEGObjectTypeMPEG2VideoHigh",
	MPEGObjectTypeMPEG2Video422:     "MPEGObjectTypeMPEG2Video422",
	MPEGObjectTypeAACMain:           "MPEGObjectTypeAACMain",
	MPEGObjectTypeAACLow:            "MPEGObjectTypeAACLow",
	MPEGObjectTypeAACSSR:            "MPEGObjectTypeAACSSR",
	MPEGObjectTypeMP32MP3:           "MPEGObjectTypeMP32MP3",
	MPEGObjectTypeMPEG1VIDEO:        "MPEGObjectTypeMPEG1VIDEO",
	MPEGObjectTypeMP3:               "MPEGObjectTypeMP3",
	MPEGObjectTypeMJPEG:             "MPEGObjectTypeMJPEG",
	MPEGObjectTypePNG:               "MPEGObjectTypePNG",
	MPEGObjectTypeJPEG2000:          "MPEGObjectTypeJPEG2000",
	MPEGObjectTypeVC1:               "MPEGObjectTypeVC1",
	MPEGObjectTypeDIRAC:             "MPEGObjectTypeDIRAC",
	MPEGObjectTypeAC3:               "MPEGObjectTypeAC3",
	MPEGObjectTypeEAC3:              "MPEGObjectTypeEAC3",
	MPEGObjectTypeDTS:               "MPEGObjectTypeDTS",
	MPEGObjectTypeOPUS:              "MPEGObjectTypeOPUS",
	MPEGObjectTypeVP9:               "MPEGObjectTypeVP9",
	MPEGObjectTypeFLAC:              "MPEGObjectTypeFLAC",
	MPEGObjectTypeTSCC2:             "MPEGObjectTypeTSCC2",
	MPEGObjectTypeEVRC:              "MPEGObjectTypeEVRC",
	MPEGObjectTypeVORBIS:            "MPEGObjectTypeVORBIS",
	MPEGObjectTypeDVDSubtitle:       "MPEGObjectTypeDVDSubtitle",
	MPEGObjectTypeQCELP:             "MPEGObjectTypeQCELP",
	MPEGObjectTypeMPEG4SYSTEMS1:     "MPEGObjectTypeMPEG4SYSTEMS1",
	MPEGObjectTypeMPEG4SYSTEMS2:     "MPEGObjectTypeMPEG4SYSTEMS2",
	MPEGObjectTypeNONE:              "MPEGObjectTypeNONE",
}
View Source
var MpegObjectTypeStreamType = map[uint64]int{
	MPEGObjectTypeMOV_TEXT:          MPEGStreamTypeText,
	MPEGObjectTypeMPEG4:             MPEGStreamTypeVideo,
	MPEGObjectTypeH264:              MPEGStreamTypeVideo,
	MPEGObjectTypeHEVC:              MPEGStreamTypeVideo,
	MPEGObjectTypeAAC:               MPEGStreamTypeAudio,
	MPEGObjectTypeMPEG2VideoMain:    MPEGStreamTypeVideo,
	MPEGObjectTypeMPEG2VideoSimple:  MPEGStreamTypeVideo,
	MPEGObjectTypeMPEG2VideoSNR:     MPEGStreamTypeVideo,
	MPEGObjectTypeMPEG2VideoSpatial: MPEGStreamTypeVideo,
	MPEGObjectTypeMPEG2VideoHigh:    MPEGStreamTypeVideo,
	MPEGObjectTypeMPEG2Video422:     MPEGStreamTypeVideo,
	MPEGObjectTypeAACMain:           MPEGStreamTypeAudio,
	MPEGObjectTypeAACLow:            MPEGStreamTypeAudio,
	MPEGObjectTypeAACSSR:            MPEGStreamTypeAudio,
	MPEGObjectTypeMP32MP3:           MPEGStreamTypeAudio,
	MPEGObjectTypeMPEG1VIDEO:        MPEGStreamTypeVideo,
	MPEGObjectTypeMP3:               MPEGStreamTypeAudio,
	MPEGObjectTypeMJPEG:             MPEGStreamTypeVideo,
	MPEGObjectTypePNG:               MPEGStreamTypeVideo,
	MPEGObjectTypeJPEG2000:          MPEGStreamTypeVideo,
	MPEGObjectTypeVC1:               MPEGStreamTypeVideo,
	MPEGObjectTypeDIRAC:             MPEGStreamTypeVideo,
	MPEGObjectTypeAC3:               MPEGStreamTypeAudio,
	MPEGObjectTypeEAC3:              MPEGStreamTypeAudio,
	MPEGObjectTypeDTS:               MPEGStreamTypeAudio,
	MPEGObjectTypeOPUS:              MPEGStreamTypeAudio,
	MPEGObjectTypeVP9:               MPEGStreamTypeAudio,
	MPEGObjectTypeFLAC:              MPEGStreamTypeAudio,
	MPEGObjectTypeTSCC2:             MPEGStreamTypeVideo,
	MPEGObjectTypeEVRC:              MPEGStreamTypeAudio,
	MPEGObjectTypeVORBIS:            MPEGStreamTypeAudio,
	MPEGObjectTypeDVDSubtitle:       MPEGStreamTypeText,
	MPEGObjectTypeQCELP:             MPEGStreamTypeAudio,
	MPEGObjectTypeMPEG4SYSTEMS1:     MPEGStreamTypeUnknown,
	MPEGObjectTypeMPEG4SYSTEMS2:     MPEGStreamTypeUnknown,
	MPEGObjectTypeNONE:              MPEGStreamTypeUnknown,
}
View Source
var ProtoBufTypeNames = scalar.UToSymStr{
	ProtoBufTypeInt32:          "Int32",
	ProtoBufTypeInt64:          "Int64",
	ProtoBufTypeUInt32:         "UInt32",
	ProtoBufTypeUInt64:         "UInt64",
	ProtoBufTypeSInt32:         "SInt32",
	ProtoBufTypeSInt64:         "SInt64",
	ProtoBufTypeBool:           "Bool",
	ProtoBufTypeEnum:           "Enum",
	ProtoBufTypeFixed64:        "Fixed64",
	ProtoBufTypeSFixed64:       "SFixed64",
	ProtoBufTypeDouble:         "Double",
	ProtoBufTypeString:         "String",
	ProtoBufTypeBytes:          "Bytes",
	ProtoBufTypeMessage:        "Message",
	ProtoBufTypePackedRepeated: "PackedRepeated",
	ProtoBufTypeFixed32:        "Fixed32",
	ProtoBufTypeSFixed32:       "SFixed32",
	ProtoBufTypeFloat:          "Float",
}
View Source
var TCPPortMap = scalar.UToScalar{}/* 679 elements not displayed */
View Source
var UDPPortMap = scalar.UToScalar{}/* 679 elements not displayed */

Functions

This section is empty.

Types

type AACFrameIn

type AACFrameIn struct {
	ObjectType int
}

type AvcDcrOut

type AvcDcrOut struct {
	LengthSize uint64
}

type AvcIn

type AvcIn struct {
	LengthSize uint64
}

type FlacFrameIn

type FlacFrameIn struct {
	SamplesBuf []byte
	StreamInfo FlacStreamInfo
}

type FlacFrameOut

type FlacFrameOut struct {
	SamplesBuf    []byte
	Samples       uint64
	Channels      int
	BitsPerSample int
}

type FlacMetadatablockOut

type FlacMetadatablockOut struct {
	IsLastBlock   bool
	HasStreamInfo bool
	StreamInfo    FlacStreamInfo
}

type FlacMetadatablockStreamInfo

type FlacMetadatablockStreamInfo struct {
	SampleRate           uint64
	BitPerSample         uint64
	TotalSamplesInStream uint64
}

type FlacMetadatablocksOut

type FlacMetadatablocksOut struct {
	HasStreamInfo bool
	StreamInfo    FlacStreamInfo
}

type FlacStreamInfo

type FlacStreamInfo struct {
	SampleRate           uint64
	BitPerSample         uint64
	TotalSamplesInStream uint64
	MD5                  []byte
}

type FlacStreaminfoOut

type FlacStreaminfoOut struct {
	StreamInfo FlacStreamInfo
}

type HevcDcrOut

type HevcDcrOut struct {
	LengthSize uint64
}

type HevcIn

type HevcIn struct {
	LengthSize uint64
}

type MP3FrameOut

type MP3FrameOut struct {
	MPEGVersion      int
	ProtectionAbsent bool
	BitRate          int
	SampleRate       int
	ChannelsIndex    int
	ChannelModeIndex int
}

type MPEGASCOut

type MPEGASCOut struct {
	ObjectType int
}

type MpegDecoderConfig

type MpegDecoderConfig struct {
	ObjectType    int
	ASCObjectType int
}

type MpegEsOut

type MpegEsOut struct {
	DecoderConfigs []MpegDecoderConfig
}

type OggPageOut

type OggPageOut struct {
	IsLastPage         bool
	IsFirstPage        bool
	IsContinuedPacket  bool
	StreamSerialNumber uint32
	SequenceNo         uint32
	Segments           [][]byte
}

type ProtoBufField

type ProtoBufField struct {
	Type    int
	Name    string
	Message ProtoBufMessage
	Enums   map[uint64]string
}

type ProtoBufIn

type ProtoBufIn struct {
	Message ProtoBufMessage
}

type ProtoBufMessage

type ProtoBufMessage map[int]ProtoBufField

type TCPStreamIn

type TCPStreamIn struct {
	SourcePort      int
	DestinationPort int
}

type UDPDatagramIn

type UDPDatagramIn struct {
	SourcePort      int
	DestinationPort int
}

Directories

Path Synopsis
Package all registers all builtin formats with the default registry
Package all registers all builtin formats with the default registry
ebml_matroska
Code below generated from ebml_matroska.xml
Code below generated from ebml_matroska.xml

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL