Using imagecanvas on video screen but controls disappeared?

Hey
I am trying to implement image canvas on video screen.Every things works fine expect that the controls of video screen are not visible.Help me with this issue.


Sub main()

	port = CreateObject("roMessagePort")
    screen = CreateObject("roVideoScreen") 
   
   episode=CreateObject("roAssociativeArray")
   episode.HDBranded = false
   episode.IsHD = false 
  
 
episode.Stream = { url:"http://download.wavetlan.com/SVV/Media/HTTP/H264/Other_Media/H264_test5_voice_mp4_480x360.mp4",
bitrate:2000
quality:false
contentid:"mycontent-2000"
}
episode.StreamFormat= "mp4"
canvasItems = [
      
        { 
            Text:"The Server will go down"
            TextAttrs:{Color:"#0000000", Font:"Medium",
            HAlign:"HCenter", VAlign:"VCenter",
            Direction:"LeftToRight"}
            TargetRect:{x:390,y:357,w:500,h:60}
        }
    ] 
    canvasItems1 = [
      
        { 
            Text:"Hello ImageCanvas"
            TextAttrs:{Color:"#0000000", Font:"Medium",
            HAlign:"HCenter", VAlign:"VCenter",
            Direction:"LeftToRight"}
            TargetRect:{x:390,y:357,w:500,h:60}
        }
    ] 
 
   canvas = CreateObject("roImageCanvas")
   'port = CreateObject("roMessagePort")
   canvas.SetMessagePort(port)
   'Set opaque background
  ' canvas.SetLayer(0, {Color:"#FF000000", CompositionMode:"Source"}) 
   'canvas.SetRequireAllImagesToDraw(true)
   
    
    screen.SetContent(episode)
    screen.SetMessagePort(port)
    screen.Show() 
'   ' canvas.SetLayer(0, { Color: "#80000000", CompositionMode: "Source" })
    canvas.SetLayer(0, canvasItems)
    canvas.Show() 
   
   
    while true
       msg = wait(0, port)
         index = msg.GetIndex()
       if type(msg) = "roVideoScreenEvent" then
           print "showVideoScreen | Playback position = "; msg.isPlaybackPosition() " | index = "; msg.GetIndex()
           if msg.isScreenClosed()
               print "Screen closed"
               exit while
            else if msg.isStatusMessage()
                  print "status message: "; msg.GetMessage()
            else if msg.isPlaybackPosition()
                  print "playback position: "; msg.GetIndex()
            
					
            else if msg.isStreamSegmentInfo()
                  print "playback info"
                  print msg.GetMessage()
                  exit while
            else if msg.isPartialResult()
                  print "playback interrupted"
                  exit while
            else if msg.isRequestFailed()
                  print "request failed – error: "; msg.GetIndex();" – "; msg.GetMessage()
                  exit while
             
            end if
       end if
    end while 
    
    
   

End Sub

The imagecanvas is layered. If you want something on top generally you would put it at a higher layer. Layer 0 is generally for background, < 0 is to hide layers and >0 for items that ride over everything else. So instead of putting everything in layer 0 define what goes where and then setlayer accordingly

You can’t use roImageCanvas with roVideoScreen. You need to use it with roVideoPlayer, and you’ll need to implement all of the video controls yourself. Unfortunately, there is no way to customize the video player without implementing all functionality in code.

Thanks TheEndless did not pick up that he was using rovideoscreen