Results 1 to 2 of 2

Thread: [RESOLVED] Directx 9.0 w/VB.NET video mpeg in window

  1. #1

    Thread Starter
    Member
    Join Date
    Jun 2005
    Location
    palo alto california
    Posts
    45

    Resolved [RESOLVED] Directx 9.0 w/VB.NET video mpeg in window

    Hi

    I want to use DirectX 9.0c with VB.net 2006 to load a video mpeg and have it displayed in a regular window.

    I have code that will play any mp3. And it does play the sound from a video mpeg. But I haven't figured out how to create (?) a video window to display the video.

    VB Code:
    1. Imports microsoft.directx.AudioVideoPlayback
    2. Imports Microsoft.DirectX
    3. Public Class Form1
    4.   Dim carrot As Audio = Nothing
    5.  
    6.   Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
    7.     carrot = Audio.FromFile("c:\funny.mpeg")
    8.  carrot.play()
    9.   End Sub  
    10. End Class

    The newest version claims to have integrated directx.directshow.dll into the platform. But I have to have the AudioVideoPlayback.dll referenced.

    I suspect that I need to do something like

    Dim display as IVideoWindow

    But I am not using it correctly...

  2. #2

    Thread Starter
    Member
    Join Date
    Jun 2005
    Location
    palo alto california
    Posts
    45

    Directx 9.0 w/VB.NET video mpeg in window [RESOLVED]

    Sorry you could have had easy points.

    I missed the obvious. The documentation is just about zero. In fact it lead me to believe that the audio method was correct as its help talked of opening a video window. But I should have looked more clearly. USE VIDEO
    VB Code:
    1. Imports microsoft.directx.AudioVideoPlayback
    2. Imports Microsoft.DirectX
    3. Public Class Form1
    4.   Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
    5.     Dim carrot As Video
    6.     carrot = Video.FromFile("c:\funny.mpeg")
    7.     carrot.Owner = Me
    8.     carrot.Play()
    9.   End Sub
    10.  
    11.  
    12. End Class

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width