Examples of IMetaCue


Examples of org.red5.io.flv.meta.IMetaCue

   * @param reader
   * @param writer
   * @throws IOException
   */
  private void writeTagsWithInjection(ITagReader reader, ITagWriter writer) throws IOException {
    IMetaCue cp = new MetaCue<Object, Object>();
    cp.setName("cue_1");
    cp.setTime(0.01);
    cp.setType(ICueType.EVENT);

    IMetaCue cp1 = new MetaCue<Object, Object>();
    cp1.setName("cue_2");
    cp1.setTime(2.01);
    cp1.setType(ICueType.EVENT);

    // Place in TreeSet for sorting
    TreeSet<IMetaCue> ts = new TreeSet<IMetaCue>();
    ts.add(cp);
    ts.add(cp1);
View Full Code Here

Examples of org.red5.io.flv.meta.IMetaCue

   * @param writer
   * @param tag
   * @return ITag tag
   */
  private ITag injectCuePoint(Object cue, ITag tag) {
    IMetaCue cp = (MetaCue<?, ?>) cue;
    Output out = new Output(IoBuffer.allocate(1000));
    Serializer.serialize(out, "onCuePoint");
    Serializer.serialize(out, cp);

    IoBuffer tmpBody = out.buf().flip();
View Full Code Here

Examples of org.red5.io.flv.meta.IMetaCue

   *
   * @param object
   * @return int time
   */
  private int getTimeInMilliseconds(Object object) {
    IMetaCue cp = (MetaCue<?, ?>) object;
    return (int) (cp.getTime() * 1000.00);

  }
 
View Full Code Here

Examples of org.red5.io.flv.meta.IMetaCue

  /**
   * Test to see if TreeSet is sorting properly
   */
  public void testCuePointOrder() {
    IMetaCue cue = new MetaCue<Object, Object>();
    cue.setName("cue_1");
    cue.setTime(0.01);
    cue.setType(ICueType.EVENT);

    IMetaCue cue1 = new MetaCue<Object, Object>();
    cue1.setName("cue_3");
    cue1.setTime(2.01);
    cue1.setType(ICueType.EVENT);

    IMetaCue cue2 = new MetaCue<Object, Object>();
    cue2.setName("cue_2");
    cue2.setTime(1.01);
    cue2.setType(ICueType.EVENT);

    TreeSet<IMetaCue> ts = new TreeSet<IMetaCue>();
    ts.add(cue);
    ts.add(cue1);
    ts.add(cue2);
View Full Code Here

Examples of org.red5.io.flv.meta.IMetaCue

   * @param writer
   * @throws IOException
   */
  private void writeTagsWithInjection(ITagReader reader, ITagWriter writer) throws IOException {

    IMetaCue cp = new MetaCue<Object, Object>();
    cp.setName("cue_1");
    cp.setTime(0.01);
    cp.setType(ICueType.EVENT);

    IMetaCue cp1 = new MetaCue<Object, Object>();
    cp1.setName("cue_1");
    cp1.setTime(2.01);
    cp1.setType(ICueType.EVENT);

    // Place in TreeSet for sorting
    TreeSet<IMetaCue> ts = new TreeSet<IMetaCue>();
    ts.add(cp);
    ts.add(cp1);
View Full Code Here

Examples of org.red5.io.flv.meta.IMetaCue

   * @param tag
   * @return ITag tag
   */
  private ITag injectMetaData(Object cue, ITag tag) {

    IMetaCue cp = (MetaCue<?, ?>) cue;
    Output out = new Output(IoBuffer.allocate(1000));
    Serializer.serialize(out, "onCuePoint");
    Serializer.serialize(out, cp);

    IoBuffer tmpBody = out.buf().flip();
View Full Code Here

Examples of org.red5.io.flv.meta.IMetaCue

   * Returns a timestamp in milliseconds
   * @param object
   * @return int time
   */
  private int getTimeInMilliseconds(Object object) {
    IMetaCue cp = (MetaCue<?, ?>) object;
    return (int) (cp.getTime() * 1000.00);
  }
 
View Full Code Here

Examples of org.red5.io.flv.meta.IMetaCue

   * Create some test Metadata for insertion.
   *
   * @return MetaData meta
   */
  private MetaData<?, ?> createMeta() {
    IMetaCue metaCue[] = new MetaCue[2];

      IMetaCue cp = new MetaCue<Object, Object>();
    cp.setName("cue_1");
    cp.setTime(0.01);
    cp.setType(ICueType.EVENT);

    IMetaCue cp1 = new MetaCue<Object, Object>();
    cp1.setName("cue_2");
    cp1.setTime(0.03);
    cp1.setType(ICueType.EVENT);

    // add cuepoints to array
    metaCue[0] = cp;
    metaCue[1] = cp1;

View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.