VideoHelp Forum
+ Reply to Thread
Page 2 of 2
FirstFirst 1 2
Results 31 to 38 of 38
Thread
  1. Member Budman1's Avatar
    Join Date
    Jul 2012
    Location
    NORTHWEST ILLINOIS, USA
    Search Comp PM
    Around Win7 Microsoft decided they want you to use built in Windows codecs. Players such as Potplayer (https://www.videohelp.com/software/PotPlayer) are free to use their internal decoders, but ask Potplayer to use a system codec and for some types it'll always use the Windows codec even if you have another installed and enabled.
    If you have K-Lite or Windows Codec Tweaker installed you can disable this Windows Media Foundation function but it really should not be necessary. Again, if you don't know what Media Foundation is... DON'T mess with it.
    Quote Quote  
  2. Originally Posted by Budman1 View Post
    Around Win7 Microsoft decided they want you to use built in Windows codecs. Players such as Potplayer (https://www.videohelp.com/software/PotPlayer) are free to use their internal decoders, but ask Potplayer to use a system codec and for some types it'll always use the Windows codec even if you have another installed and enabled.
    If you have K-Lite or Windows Codec Tweaker installed you can disable this Windows Media Foundation function but it really should not be necessary. Again, if you don't know what Media Foundation is... DON'T mess with it.
    I did mention Media Foundation later in my post, but the part you quoted wasn't referring to it. Only DirectShow. This is my understanding. If I'm wrong I'm happy for someone to correct me and I'll edit my previous post.

    Prior to Win7, DirectShow only used the merit system for determining which codec would decode a particular format when more than one applicable codec was installed. https://msdn.microsoft.com/en-us/library/dd390674%28v=VS.85%29.aspx
    It's partly the reason why installing codec packs could get messy. Players such as Potplayer or MPC-HC can register filters themselves and set their own priority rather than use the Windows merit system, although mostly these days they'd just use their internal codecs anyway.

    For Windows 7 a system was introduced whereby certain codecs are registered as default, and for those types the merit system isn't used. The way I understand it, that effects any player using DirectShow codecs (unless it can set it's own merits) so a tool such as the Preferred Filter Tweaker can be used to change the preferred codecs.
    Chances are K-Lite does that for you when you install it. It'd probably have to, otherwise it'd be installing DirectShow codecs that wouldn't work.

    https://msdn.microsoft.com/en-us/library/dd390342%28VS.85%29.aspx
    4. Starting in Windows 7, DirectShow has a list of preferred filters for certain media subtypes. If there is a preferred filter for the media type that is being rendered, the Filter Graph Manager tries that filter next.

    Then there's Media Foundation which is supposed to eventually replace DirectShow, and no doubt DirectShow's lack of support for Microsoft's Protected Media Path is some of the reason for that. The way I understand it that has nothing to do with players such as MPC-HC using DirectShow codecs but Microsoft toys such as Windows Media Player use Media Foundation instead of DirectShow. If you want ffdshow to decode for WMP, you need to disable Media Foundation for the file type in question. Or disable it completely. If you're not using built-in Windows programs, you probably wouldn't need to.
    K-Lite might automatically disable Media Foundation when you install it. Chances are it does because people would expect LAV Filters or ffdshow to work all the time, even for WMP. Whether it does or not I don't know as I don't use K-Lite or Win7.
    Last edited by hello_hello; 13th Apr 2016 at 04:09.
    Quote Quote  
  3. pixeldroid,
    If you're still around.....

    I had it in the back of my mind you could run ffdshow with only it's filters. No codecs to enable. The penny dropped today. It's obvious now. It should have been then. I'm going to smack myself in the head again later.

    The process for adding ffdshow to Potplayer is exactly the same as before, except rather than add the ffdshow video decoder from the registered filters list, you add the ffdshow RAW Video Filter instead (smacks self in head again). Set it's merit to "prefer", and when you click on the "filter information" button on the right, ffdshow's configuration opens with a choice of the following codecs:

    Click image for larger version

Name:	ffdshow raw decoder.gif
Views:	409
Size:	19.2 KB
ID:	36539

    You can enable filters as before and use ffdshow's on-screen-display, but now you're free to re-enable codecs in the standard ffdshow decoder configuration, disable the raw video decoder there if you prefer, configure it's filters differently and use it as you normally would.

    As a side note..... because I thought I was going silly at first..... if you open the RAW Video Filter via Potplayer's filter setup the configuration window opens with the title "RAW Video Filter". When you open it via the icon in the system tray, it's title changes to "RAW Video Decoder". Any changes you make to the "RAW Video Filter" configuration don't take effect until you reload the video. Changes to settings via the system tray icon are immediate. Settings are common for both as I assume they're the same filter.

    Anyway..... you could use both the standard video decoder and the raw video filter if you were so inclined, for a stereo on-screen-display.

    Click image for larger version

Name:	potplayer.gif
Views:	359
Size:	73.1 KB
ID:	36540
    Last edited by hello_hello; 13th Apr 2016 at 05:57.
    Quote Quote  
  4. Member
    Join Date
    Apr 2016
    Location
    Madison, WI USA
    Search Comp PM
    Okay. Progress.
    You were correct about the 32 bit install issue. Colorbars() and other scripts work.
    However, now that I'm out of that infinite loop, it appears that, as others have indicated, the frame numbers from avisynth are not the absolute frame numbers of the video. The numbers start at 2000 and any time I move the playback head, the counting restarts at 2000.

    I truly appreciate all the help, it looks like ffdshow is the way to go.
    Regarding the thumbnails, they made it much easier to identify who was in the videos, else I don't need them.
    Quote Quote  
  5. The frame number thing seems to be expected behaviour for ffdshow's Avisynth filter, and any program with bits borrowed from ffdshow, I guess.

    I thought I'd worked it out and much of it was explained in detail here, but maybe I dreamt both those things....

    It's probably related to the buffering, but it's probably also to do with Avisynth expecting to open the video and able to navigate to any frame, so ffdshow just tells it "something". If you play a video while the "buffer" is enabled, the frame count jumps by 2000 when navigating. When it's disabled the frame count jumps by zero when navigating. I'm not sure how ffdshow chooses the frame number initially, that seems like it can be anything.

    Whatever the technical reason, ffdshow's OSD has an "Avisynth Info" option and it displays the same frame number as Avisynth, no matter how wrong it is relative to the actual video, so it seems it's meant to work that way.

    Click image for larger version

Name:	osd.jpg
Views:	299
Size:	17.6 KB
ID:	36680
    Quote Quote  
  6. Member Budman1's Avatar
    Join Date
    Jul 2012
    Location
    NORTHWEST ILLINOIS, USA
    Search Comp PM
    Using post #3 as a reference, and using the generic AVIsynth (32 bit) and the Potplayer (32 bit)I have never had a problem getting correct frame number and use it to trim and splice with a program I wrote.

    Code:
    DirectShowSource(("C:\Users\Bud\Desktop\Various test Formats\Commercial HD.flv"), Pixel_Type="yuy2").Crop(0,0,-0,-0)
    ShowFrameNumber(scroll=true, x=10, y=27, font="Arial", size=24, text_color=$ff0000)
    # ShowTime(x=72, y=44, font="Arial", size=24, text_color=$ff0000)
    # Subtitle("Frame Rate '' Invalid for SMPTE", font="Arial", size=24, text_color=$ff0000, align=2)
    The scroll=true is necessary to display one only frame number. I have not had much luck with ffdshow avisynth and think maybe it is not updated as often. Tinestamps can also be shown by removing the pound sign comment

    Click image for larger version

Name:	ScreenHunter_190 Apr. 20 11.24.jpg
Views:	327
Size:	91.3 KB
ID:	36681

    Click image for larger version

Name:	ScreenHunter_190 Apr. 20 11.23.jpg
Views:	301
Size:	56.7 KB
ID:	36682

    Click image for larger version

Name:	ScreenHunter_190 Apr. 20 11.22.jpg
Views:	293
Size:	73.9 KB
ID:	36683
    Quote Quote  
  7. DirectShow is notoriously not frame accurate.

    MPC-HC opening a video directly, frame 39468 according to ffdshow.

    Click image for larger version

Name:	1.jpg
Views:	284
Size:	22.9 KB
ID:	36697

    Potplayer opening a video directly, frame 39468 according to ffdshow.

    Click image for larger version

Name:	2.jpg
Views:	285
Size:	21.5 KB
ID:	36698

    Same video opened in Potplayer via a DirectShowSource script.
    Frame 39468 according to ffdshow.
    Frame 39473 according to Avisynth via ShowFrameNumber() in the script.
    Frame 02373 according to ShowFrameNumber() in Potplayer's Avisynth filter section.

    Click image for larger version

Name:	3.jpg
Views:	291
Size:	24.9 KB
ID:	36699

    MPC-HC opening the DirectShowSource script.
    Frame number 39468 according to lower ffdshow, decoding the video for Avisynth
    Frame 39473 according to upper ffdshow, processing the raw Avisynth output.
    Frame 39473 according to ShowFrameNumber() in the script.

    Click image for larger version

Name:	5.jpg
Views:	303
Size:	47.8 KB
ID:	36700

    LWLibavVideoSource script for opening the video.
    Frame 39468 according to MeGUI
    Frame 39468 according to ShowFrameNumber() in the script.
    Frame 39468 according to ffdshow's OSD after adding ffdshow(preset="default") to the LWLibavVideoSource script.

    Click image for larger version

Name:	4.jpg
Views:	262
Size:	28.8 KB
ID:	36701

    I was mainly referring to using ShowFrameNumber() in Potplayer's Avisynth filter section rather than in a script opening the video, as added to Potplayer's Avisynth section the frame numbers don't display correctly as they don't when adding ShowFrameNumber() to ffdshow's Avisynth filter. Opening a video via a DirectShow script and adding ShowFrameNumber() is possibly accurate, although DirectShow wasn't in a frame accurate mood today. Sometimes it's pretty good, sometimes, not.
    Quote Quote  
  8. Member
    Join Date
    Aug 2014
    Location
    New Delhi, India
    Search PM
    Originally Posted by Budman1 View Post
    Right out of the box defaults, just hit the tab key to display on screen information and then hit 'F' key for forward and 'D' key for backward when near your target

    Image
    [Attachment 31698 - Click to enlarge]
    Thanks a lot for this info!
    Quote Quote  



Similar Threads

Visit our sponsor! Try DVDFab and backup Blu-rays!