frame.bend checks
raw source on the hub · import 0xd6fc55bf65b187fec4175f80d08c165a/frame.bend as Frame
What a session gives a program: frames, and what they are frames of.
1 import
import Base
Types
type Frame source · line 9 · raw
Data
Video: one picture's access unit, its NAL units in Annex B form (each after 00 00 00 01); key says a decoder can start at it. Audio: what the description's audio says it is: AAC frames, each after its ADTS header, or G.711 samples, a byte each. pts is the time to show or play it, in 90 kHz ticks since the stream's first frame of that kind.
Video@pts:U32 -> @key:Bool -> @data:List<&2, U32> -> Frame
Audio@pts:U32 -> @data:List<&2, U32> -> Frame
type Info source · line 33 · raw
Data
A stream's description: the video's codec ("H264" or "H265") and its parameter sets in Annex B form, as the server announced them (they may also come in the stream); the audio's codec ("AAC", "PCMA" or "PCMU" for G.711's A-law and mu-law; "" when there is none this client reads), its sample rate and channels.
Info@codec:String -> @sets:List<&2, U32> -> @audio:String -> @rate:U32 -> @chans:U32 -> Info
Definitions
def Frame.pts source · line 13 · raw
@f:Frame -> U32
def Frame.later source · line 21 · raw
@f:Frame -> @d:U32 -> Frame
The frame d ticks later: for a stream that goes on after another.
def Info.codec source · line 36 · raw
@i:Info -> String
def Info.sets source · line 40 · raw
@i:Info -> List<&2, U32>
def Info.audio source · line 44 · raw
@i:Info -> String
def Info.rate source · line 48 · raw
@i:Info -> U32
def Info.chans source · line 52 · raw
@i:Info -> U32
def Info.h265 source · line 56 · raw
@i:Info -> Bool