Attribute VB_Name = "Module1"
Function myVIDEOPROC(ByVal handle As Long, ByVal action As Long, _
              ByVal param1 As Long, ByVal param2 As Long, ByVal user As Long) As Long
Dim r As Rect
    Select Case action
        
        Case BassVideo_OpenDone
         Form1.List1.AddItem ("open done...")
        Case BassVideo_FoundVideo
          r.Left = 0
          r.top = 0
          r.Bottom = Form1.picVideo(0).ScaleHeight
          r.Right = Form1.picVideo(0).ScaleWidth
          Call BassVideo_SetVideoWindow(chan, Form1.picVideo(0).Hwnd, r, 0)
        Case BassVideo_EndStream
         Form1.List1.AddItem ("End of stream")
        Case BassVideo_DShow_Event
         Form1.List1.AddItem (BassVideo_EventToString(param1))
    End Select
    myVIDEOPROC = 0 ' do not handle event resize, ... if use auto
End Function

