NAME

FLV::MetaTag - Flash video file data structure

LICENSE

See FLV::Info

DESCRIPTION

As best I can tell, FLV meta tags are a pair of AMF data: one is the event name and one is the payload. I learned that from looking at sample FLV files and reading the FLVTool2 code.

I've seen no specification for the meta tag, so this is all empirical for me, unlike the other tags.

METHODS

This is a subclass of FLV::Base.

$self->parse($fileinst)

Takes a FLV::File instance and extracts an FLV meta tag from the file stream. This method throws exceptions if the stream is not a valid FLV v1.0 or v1.1 file.

There is no return value.

The majority of the work is done by FLV::AMFReader.

$self->serialize()

Returns a byte string representation of the tag data. Throws an exception via croak() on error.

$self->get_info()

Returns a hash of FLV metadata. See FLV::Info for more details.

$self->get_values();
$self->get_value($key);
$self->set_value($key, $value);

These are convenience functions for interacting with an onMetadata hash.

get_values() returns a hash of all metadata key-value pairs. get_value($key) returns a single value. set_value() has no return value.

AUTHOR

See FLV::Info