I had to do this for a 3D channel - so it was years ago - here's the draw code - note, that everything is doubled horizontally as it's intended for a 3D TV. So you'd need to edit this to get it back to single screen/2D.
Sub DrawPauseScreen(Episode As Object)
m.canvas.Clear(&h000000FF)
If m.ThumbsExist=TRUE
If INT(m.position/(m.TimestampMultiplier/1000))>0
m.Frames[0]=INT(m.position/(m.TimestampMultiplier/1000))-1
Else
m.Frames[0]=-1
End If
m.Frames[1]=INT(m.position/(m.TimestampMultiplier/1000))
If INT(m.position/(m.TimestampMultiplier/1000))<m.TotalFrameCount-1
m.Frames[2]=m.Frames[1]+1
Else
m.Frames[2]=-1
End If
FrameBorderSides=CreateObject("roBitmap","pkg:/assets/square.png")
FrameMask=CreateObject("roBitmap",{width:180,height:200,alphaenable:false})
FrameMask.Clear(&hFFFFFF00)
'DRAW SCREEN
If m.Frames[0]>-1
m.dataset.WriteFile("tmp:/frame"+itostr(m.Frames[0])+".png",m.OffsetTable[m.Frames[0]],m.OffsetTable[m.Frames[0]+1]-m.OffsetTable[m.Frames[0]])
FBMP0=CreateObject("roBitmap","tmp:/frame"+itostr(m.Frames[0])+".png")
SourceBMP0Left=CreateObject("roRegion",FBMP0,0,0,160,180)
SourceBMP0Right=CreateObject("roRegion",FBMP0,160,0,160,180)
m.canvas.DrawObject(26,270,SourceBMP0Left)
m.canvas.DrawObject(16,260,FrameBorderSides)
m.canvas.DrawObject(666,270,SourceBMP0Right)
m.canvas.DrawObject(656,260,FrameBorderSides)
Else
m.canvas.DrawObject(16,260,FrameMask)
m.canvas.DrawObject(656,260,FrameMask)
End If
If m.Frames[2]>-1
If m.Frames[2]<m.TotalFrameCount-1
m.dataset.WriteFile("tmp:/frame"+itostr(m.Frames[1])+".png",m.OffsetTable[m.Frames[1]],m.OffsetTable[m.Frames[1]+1]-m.OffsetTable[m.Frames[1]])
FBMP1=CreateObject("roBitmap","tmp:/frame"+itostr(m.Frames[1])+".png")
SourceBMP1Left=CreateObject("roRegion",FBMP1,0,0,160,180)
SourceBMP1Right=CreateObject("roRegion",FBMP1,160,0,160,180)
m.canvas.DrawScaledObject(218,252,1.25,1.25,SourceBMP1Left)
m.canvas.DrawScaledObject(206,240,1.24,1.24,FrameBorderSides)
m.canvas.DrawScaledObject(858,252,1.25,1.25,SourceBMP1Right)
m.canvas.DrawScaledObject(846,240,1.24,1.24,FrameBorderSides)
m.dataset.WriteFile("tmp:/frame"+itostr(m.Frames[2])+".png",m.OffsetTable[m.Frames[2]],m.OffsetTable[m.Frames[2]+1]-m.OffsetTable[m.Frames[2]])
FBMP2=CreateObject("roBitmap","tmp:/frame"+itostr(m.Frames[2])+".png")
SourceBMP2Left=CreateObject("roRegion",FBMP2,0,0,160,180)
SourceBMP2Right=CreateObject("roRegion",FBMP2,160,0,160,180)
m.canvas.DrawObject(450,270,SourceBMP2Left)
m.canvas.DrawObject(440,260,FrameBorderSides)
m.canvas.DrawObject(1090,270,SourceBMP2Right)
m.canvas.DrawObject(1080,260,FrameBorderSides)
Else
m.dataset.WriteFile("tmp:/frame"+itostr(m.Frames[1])+".png",m.OffsetTable[m.Frames[1]],m.OffsetTable[m.Frames[1]+1]-m.OffsetTable[m.Frames[1]])
FBMP1=CreateObject("roBitmap","tmp:/frame"+itostr(m.Frames[1])+".png")
SourceBMP1Left=CreateObject("roRegion",FBMP1,0,0,160,180)
SourceBMP1Right=CreateObject("roRegion",FBMP1,160,0,160,180)
m.canvas.DrawScaledObject(218,252,1.24,1.24,SourceBMP1Left)
m.canvas.DrawScaledObject(206,240,1.24,1.24,FrameBorderSides)
m.canvas.DrawScaledObject(858,252,1.24,1.24,SourceBMP1Right)
m.canvas.DrawScaledObject(846,240,1.24,1.24,FrameBorderSides)
m.dataset.WriteFile("tmp:/frame"+itostr(m.Frames[2])+".png",m.OffsetTable[m.Frames[2]],m.EndOfFileMarker+1-m.OffsetTable[m.Frames[2]])
FBMP2=CreateObject("roBitmap","tmp:/frame"+itostr(m.Frames[2])+".png")
SourceBMP2Left=CreateObject("roRegion",FBMP2,0,0,160,180)
SourceBMP2Right=CreateObject("roRegion",FBMP2,160,0,160,180)
m.canvas.DrawObject(450,270,SourceBMP2Left)
m.canvas.DrawObject(440,260,FrameBorderSides)
m.canvas.DrawObject(1090,270,SourceBMP2Right)
m.canvas.DrawObject(1080,260,FrameBorderSides)
End If
Else
m.canvas.DrawObject(440,260,FrameMask)
m.canvas.DrawObject(1080,260,FrameMask)
m.dataset.WriteFile("tmp:/frame"+itostr(m.Frames[1])+".png",m.OffsetTable[m.Frames[1]],m.EndOfFileMarker+1-m.OffsetTable[m.Frames[1]])
FBMP1=CreateObject("roBitmap","tmp:/frame"+itostr(m.Frames[1])+".png")
SourceBMP1Left=CreateObject("roRegion",FBMP1,0,0,160,180)
SourceBMP1Right=CreateObject("roRegion",FBMP1,160,0,160,180)
m.canvas.DrawScaledObject(218,252,1.25,1.25,SourceBMP1Left)
m.canvas.DrawScaledObject(206,240,1.24,1.24,FrameBorderSides)
m.canvas.DrawScaledObject(858,252,1.25,1.25,SourceBMP1Right)
m.canvas.DrawScaledObject(846,240,1.24,1.24,FrameBorderSides)
End If
End If
'END OF THUMBS IF THEY EXISTED - now draw progress bar and button indicator graphic/speed
ProgressBar=CreateObject("roBitmap","pkg:/assets/playerprogressbar.png")
ProgressMarker=CreateObject("roBitmap","pkg:/assets/playerprogressmarker.png")
ProgressMarkerArrow=CreateObject("roBitmap","pkg:/assets/playerprogressmarkerbottom.png") '************************** needs to be utilized - X is the same as progressmarker, y is +62
PauseIcon=CreateObject("roBitmap","pkg:/assets/playerpaused.png")
FSlowIcon=CreateObject("roBitmap","pkg:/assets/playerfslow.png")
RSlowIcon=CreateObject("roBitmap","pkg:/assets/playerrslow.png")
FFastIcon1=CreateObject("roBitmap","pkg:/assets/playerffast1.png")
FFastIcon2=CreateObject("roBitmap","pkg:/assets/playerffast2.png")
FFastIcon3=CreateObject("roBitmap","pkg:/assets/playerffast3.png")
RFastIcon1=CreateObject("roBitmap","pkg:/assets/playerrfast1.png")
RFastIcon2=CreateObject("roBitmap","pkg:/assets/playerrfast2.png")
RFastIcon3=CreateObject("roBitmap","pkg:/assets/playerrfast3.png")
If m.stepspeed=-6
m.canvas.DrawObject(291,520,RFastIcon3) '509 to center between the top of the progress indicator and the bottom of the center thumbnail frame
m.canvas.DrawObject(931,520,RFastIcon3) '520 to center between the top of the horizontal progress bar itself and the bottom of the center thumbnail frame
End If
If m.stepspeed=-4
m.canvas.DrawObject(291,520,RFastIcon2) '509 to center between the top of the progress indicator and the bottom of the center thumbnail frame
m.canvas.DrawObject(931,520,RFastIcon2) '520 to center between the top of the horizontal progress bar itself and the bottom of the center thumbnail frame
End If
If m.stepspeed=-2
m.canvas.DrawObject(291,520,RFastIcon1) '509 to center between the top of the progress indicator and the bottom of the center thumbnail frame
m.canvas.DrawObject(931,520,RFastIcon1) '520 to center between the top of the horizontal progress bar itself and the bottom of the center thumbnail frame
End If
If m.stepspeed=-1
m.canvas.DrawObject(291,520,RSlowIcon) '509 to center between the top of the progress indicator and the bottom of the center thumbnail frame
m.canvas.DrawObject(931,520,RSlowIcon) '520 to center between the top of the horizontal progress bar itself and the bottom of the center thumbnail frame
End If
If m.stepspeed=0
m.canvas.DrawObject(291,520,PauseIcon) '509 to center between the top of the progress indicator and the bottom of the center thumbnail frame
m.canvas.DrawObject(931,520,PauseIcon) '520 to center between the top of the horizontal progress bar itself and the bottom of the center thumbnail frame
End If
If m.stepspeed=1
m.canvas.DrawObject(291,520,FSlowIcon) '509 to center between the top of the progress indicator and the bottom of the center thumbnail frame
m.canvas.DrawObject(931,520,FSlowIcon) '520 to center between the top of the horizontal progress bar itself and the bottom of the center thumbnail frame
End If
If m.stepspeed=2
m.canvas.DrawObject(291,520,FFastIcon1) '509 to center between the top of the progress indicator and the bottom of the center thumbnail frame
m.canvas.DrawObject(931,520,FFastIcon1) '520 to center between the top of the horizontal progress bar itself and the bottom of the center thumbnail frame
End If
If m.stepspeed=4
m.canvas.DrawObject(291,520,FFastIcon2) '509 to center between the top of the progress indicator and the bottom of the center thumbnail frame
m.canvas.DrawObject(931,520,FFastIcon2) '520 to center between the top of the horizontal progress bar itself and the bottom of the center thumbnail frame
End If
If m.stepspeed=6
m.canvas.DrawObject(291,520,FFastIcon3) '509 to center between the top of the progress indicator and the bottom of the center thumbnail frame
m.canvas.DrawObject(931,520,FFastIcon3) '520 to center between the top of the horizontal progress bar itself and the bottom of the center thumbnail frame
End If
m.canvas.DrawObject(80,574,ProgressBar)
m.canvas.DrawObject(720,574,ProgressBar)
'Draw initial position information graphical data
m.canvas.DrawObject(152+INT(300*(m.initialposition/episode.Runtime)),574+62,ProgressMarkerArrow) 'offset +62 Y location from main marker
m.canvas.DrawObject(792+INT(300*(m.initialposition/episode.Runtime)),574+62,ProgressMarkerArrow) 'offset +62 Y location from main marker
'Draw initial position SHADED/COLORED PROGRESS BAR
temporarywidth=INT(300*(m.initialposition/episode.Runtime))
If temporarywidth>0
ShadedBar=CreateObject("roBitmap",{width:temporarywidth,height:18,alphaenable:false})
ShadedBar.Clear(&hFFFF) 'Blue
m.canvas.DrawObject(172,605,ShadedBar)
m.canvas.DrawObject(812,605,ShadedBar)
End If
m.canvas.DrawObject(152+INT(300*(m.Position/episode.Runtime)),574,ProgressMarker) 'progress marker is drawn on top
m.canvas.DrawObject(792+INT(300*(m.Position/episode.Runtime)),574,ProgressMarker)
P1=""
P2=""
'Draw Right side total runtime length of episode
If episode.hours>0 P1=itostr(episode.hours)+"h "
If episode.minutes<10
P2="0"+itostr(episode.minutes)+"m"
Else
P2=itostr(episode.minutes)+"m"
End If
m.canvas.DrawText(P1+P2,486,598,&h0000FFFF,m.Font)
m.canvas.DrawText(P1+P2,1126,598,&h0000FFFF,m.Font)
'Draw Left side current position as hours and minutes
CHours=0
CMinutes=0
CSeconds=m.Position
CHours=INT(CSeconds/3600) '60seconds*60minutes
CMinutes=INT((CSeconds-CHours*3600)/60)
P3=""
P4=""
If CHours>0 P3=itostr(CHours)+"h "
If CMinutes<10
P4="0"+itostr(CMinutes)+"m"
Else
P4=itostr(CMinutes)+"m"
End If
m.SizeResult=m.FontMetrics.Size(P3+P4) 'determine size of string
m.canvas.DrawText(P3+P4,140-m.SizeResult.W,598,&hFF0000FF,m.Font) 'right-justify text string
m.canvas.DrawText(P3+P4,140-m.SizeResult.W+640,598,&hFF0000FF,m.Font)
m.canvas.SwapBuffers()
End Sub