Results 1 to 3 of 3

Thread: [RESOLVED] FilgraphManager

  1. #1

    Thread Starter
    Fanatic Member AccessShell's Avatar
    Join Date
    Oct 2013
    Posts
    790

    Resolved [RESOLVED] FilgraphManager

    I am using the Filgraph Manager to .mp3 files. I can easily execute .run, .stop.

    However when I execute .pause, the pause works fine. When I try to resume, I get the resume overlaid with the start from the beginning. This website https://docs.microsoft.com/en-us/pre...75652(v=vs.85) , in the last paragraph says if you have paused it, the use .run to resume. I must be missing something.

    This is the code I use to run a file
    Code:
         Set FilgraphManager = New QuartzTypeLib.FilgraphManager    Set IMediaEventEx = FilgraphManager
        IMediaEventEx.SetNotifyWindow cmdMediaEvents.hWnd, WM_MOUSEMOVE, 0
        With FilgraphManager
            '.RenderFile "https://dl.espressif.com/dl/audio/gs-16b-2c-44100hz.mp3"
            .RenderFile mstrSoundFile
            .Run
        End With
    This is the code I use to pause and then resume
    Code:
        IMediaEventEx.SetNotifyWindow cmdMediaEvents.hWnd, WM_MOUSEMOVE, 0
        If blnPaused = False Then
            With FilgraphManager
                '.RenderFile "https://dl.espressif.com/dl/audio/gs-16b-2c-44100hz.mp3"
                .RenderFile mstrSoundFile
                .Pause
                blnPaused = True
            End With
        Else
            With FilgraphManager
                '.RenderFile "https://dl.espressif.com/dl/audio/gs-16b-2c-44100hz.mp3"
                .RenderFile mstrSoundFile
                .Run
                blnPaused = False
            End With
        End If
    Any assistance would be appreciated

    Thanks

  2. #2
    PowerPoster
    Join Date
    Nov 2017
    Posts
    3,116

    Re: FilgraphManager

    Never used it myself, and can't test it right now.

    That being said, it seems highly unlikely to me just from a logical standpoint that it would be appropriate to continually call the .RenderFile method when pausing or resuming. I would think that method would only need to be called once when loading the file.

    Just a guess. Can't help more. Good luck.

  3. #3

    Thread Starter
    Fanatic Member AccessShell's Avatar
    Join Date
    Oct 2013
    Posts
    790

    Re: FilgraphManager

    Thank you OptionBase1, you are correct. I removed the .RenderFile method in the Pause routine and everything worked as it should.

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