FLAC.ApplicationMetaData
— TypeApplication metadata
Not sure what this is for.
FLAC.CueSheetMetaData
— TypeCue sheet meta data.
An array of CueSheetTrack
s
FLAC.CueSheetMetaData
— MethodOpen the file, fnm
, check that it is a flac stream and return any cue sheets, closing the file.
FLAC.InfoMetaData
— TypeA block containing information on the stream including samplerate
, channels
, bitspersample
, totalsamples
, and mdsum
.
FLAC.InfoMetaData
— MethodOpen the file, fnm
, check that it is a flac stream and return the stream info, closing the file.
FLAC.PaddingMetaData
— Typelen
bytes of padding in the FLAC stream.
FLAC.SeekTableMetaData
— TypeAn array of SeekPoint
s
FLAC.StreamDecoderPtr
— TypeStreamDecoderPtr
A Julia type for a libflac stream decoder object.
This type primarily exists so that a finalizer to delete the decoder can be assigned.
FLAC.StreamEncoderPtr
— TypeStreamEncoderPtr
Flac stream encoder object.
All it contains is an opaque pointer. The zero-argument constructor creates a new stream decoder and wraps the pointer.
The type is not an immutable because it uses a finalizer.
FLAC.StreamMetaData
— TypeMetadata in a FLAC stream.
Used in both encoding and decoding of a stream. Each type of metadata object contains an indicator of its typ
, an indicator of whether this is the last metadata block and its length, in bytes.
FLAC.VorbisCommentMetaData
— TypeVorbis comment metadata. The vendor comment is always present.
FLAC.VorbisCommentMetaData
— MethodOpen the file, fnm
, check that it is a flac stream and return any Vorbis tags, closing the file.
Base.length
— Methodlength(f::FLACDecoder)
Return the total length of the FLAC file in samples
Base.read
— Methodread(f::FLACDecoder, num_samples::Integer)
Read up to the specified number of samples from the given FLACDecoder,
Base.seek
— Methodseek(f::FLACDecoder, offset::Int64)
Perform an absolute seek within the given FLAC stream. Throws an ArgumentError
if the requested seek is impossible. Will automatically flush()
the decoder stream if a seek error is encountered.
Base.size
— Methodsize(f::FLACDecoder)
Return the size tuple of the FLAC file (length in samples, number of channels)
FLAC.initfile!
— Methodinitfile!(dd::StreamDecoderPtr, fnm::String; wcallback=debug_wcallback_c,
mcallback=debug_mcallback_c, ecallback=debug_ecallback_c, client_data=nothing)
Initialize the StreamDecoderPtr
, dd
, to read the FLAC file fnm
.
This function allows the user to override any of the default callback functions.
FLAC.initfile!
— Methodinit_file
Initialize the StreamEncoder
object en
to write the file fnm
.
Note that setting stream characteristics (channels
, bits_per_sample
, etc.) must be done before initializing the encoder.
FLAC.CueSheetIndex
— TypeA single cue sheet index
FLAC.CueSheetTrack
— TypeA single track annotation in a CueSheet.
I'm not sure about the offsets here. In the C struct the typ
and pre_emphasis
fields are single bits.
FLAC.VorbisCommentEntry
— TypeA single Vorbis comment.
Comments are usually key/value pairs of the form ARTIST=Miles Davis
, YEAR=1965
, etc.
Base.convert
— MethodCreate a Ptr{StreamMetaData} from a Dict of key/value pairs.
Both the key and the value are converted to strings.
Base.unsafe_convert
— MethodAllows for passing the instance of the type in a ccall
.
FLAC.debug_ecallback
— Methoddebug_ecallback(d::Ptr{Cvoid}, status::Int32, client::Ptr{Cvoid})
Error callback function.
FLAC.debug_mcallback
— Methoddebug_mcallback(d::Ptr{Cvoid}, mp::Ptr{Cvoid}, client::Ptr{Cvoid})
Debugging metadata callback function. Prints a brief description of any Info
, Padding
, VorbisComment
, or SeekTable
metadata blocks in the stream.
FLAC.debug_wcallback
— Methoddebug_wcallback(dd::Ptr{Cvoid}, hdr::Ptr{FrameHeader},
buffer::Ptr{Ptr{Int32}}, client::Ptr{Cvoid})
Debugging write callback. Prints information about every frame written. Very verbose. Use with caution.
FLAC.get_state
— Methodget_state(dd:StreamDecoderPtr)
Returns the decoder state as a StreamDecoderState
enum value.
FLAC.get_state_string
— Methodget_state_string(dd::StreamDecoderPtr)
Returns a character string describing the current state of the decoder
FLAC.load
— Methodload(filename::File{format"FLAC"})
Opens and reads the given filename, returning an array of samples and as well as the samplerate of the samples stored within the file. This method is part of the FileIO integration, do not call directly but instead import the FileIO bindings and call load()
with a filename ending in .flac
to invoke this method through the FileIO machinery.
FLAC.metadata
— MethodFactory to construct a subtype of StreamMetaData from an opaque pointer.
Typically this is used in a callback function that is passed a Ptr{Cvoid}
.
FLAC.pcallback
— Methodstandard progress callback function
FLAC.save
— Methodsave(filename, data, samplerate; bits_per_sample = 24, compression_level = 3)
Encodes and writes an array of values out to a file, using the given bitdepth and compression level. This method is part of the FileIO integration, do not call directly but instead import the FileIO bindings and call save()
with a filename ending in .flac
to invoke this method through the FileIO machinery.
FLAC.set_metadata_ignore_all
— Methodset_metadata_ignore_all(dd::StreamDecoderPtr)
Set the stream decoder to ignore all metadata blocks.
Must be called before the decoder is initialized.
FLAC.set_metadata_respond_all
— Methodset_metadata_respond_all(dd::StreamDecoderPtr)
Set the stream decoder to respond to all metadata blocks.
Must be called before the decoder is initialized.
FLAC.silent_mcallback
— Methodsilent_mcallback(d::Ptr{Cvoid}, mp::Ptr{Cvoid}, client::Ptr{Cvoid})
Silent metadata callback function. Ignores all metadata blocks.