1 Reply Latest reply on Oct 29, 2010 5:14 PM by bringrags

    image overlaying video problems


      Hey everyone,


      I am trying to add an image to be displayed during video play back in the bottom right corner of the video, and i've done so using the following code,


      var watermark:ImageElement = new ImageElement(new URLResource(watermarkSrc));

      var watermarkLayout:LayoutMetadata = new LayoutMetadata();

      watermarkLayout.bottom = watermark_Yoffset;

      watermarkLayout.right = watermark_Xoffset;

      watermark.addMetadata(LayoutMetadata.LAYOUT_NAMESPACE, watermarkLayout);             


      var dynamicVideoElement:VideoElement = new VideoElement(dsr, new RTMPDynamicStreamingNetLoader());


      var parallelElement:ParallelElement = new ParallelElement();




      mediaSprite.media = parallelElement;



      What seems to be happening is that the watermark image gets put on the screen first and then the video gets placed ontop of the image, thus covering it and the image is never shown.


      I'd like for the image to show for as long as the video is playing, hence the reason why I used a parallel Element.


      Is there a way to control the order on which the elements are added to the view such that the logo is always added so that it is visible during video playback?


      Thanks for the help.