I'm developing a plugin for OSMF (using the sprint 10 code) and I'm having some trouble getting access to embedded cue points.
The plugin is loaded at runtime by the way.
If I know the CuePoint.time I can access them through MediaElement.metadata.getValue( [cuePointNamespace] ).getValue( [seconds] ). The metadata is of type TimelineMetadata.
But since I don't know the times of the cue points, and metadata.keys seems to return nothing, I can't access the values.
My goal is to somehow get all the cue points embedded in the video as soon as possible after playback has started.
Any way to do this?
I'm not 100% sure what the Sprint 10 syntax is/was, but here's the latest way to do it:
var timelineMetadata:TimelineMetadata = mediaElement.getMetadata(CuePoint.EMBEDDED_CUE_POINTS_NAMESPACE) as TimelineMetadata;
for var (i:int = 0; i < timelineMetadata.numMarkers; i++)
var cuePoint:CuePoint = timelineMetadata.getMarkerAt(i) as CuePoint;
Thanks for helping out Brian!