Subtitles and dxva (1 Viewer)

tourettes

Retired Team Member
  • Premium Supporter
  • January 7, 2005
    17,301
    4,800
    ? I'm not sure what you mean by that? I tried it in graphedit and the alpha thing did work, blending the subtitles over the movie.

    But did you try it with EVR or VMR9 (with YUV mixing mode enabled, not sure if this can be enabled in GraphEdit) as video renderers?

    I used the Video Mixing Renderer 9 to test this. Needed the mixing renderer to support input from multiple pins, one movie and one subtitles. That did work. To be honest I've not checked the complete graph pins to check output though. I do know the movie was YUV, I double checked the output of the VobSub filter and it's mediatype was ARGB32.

    YUV Mixing Mode

    # The other inputs pins can only accept per-pixel alpha YUV formats, such as AYUV, AI44 and IA44.
    # None of the VMR's input pins can accept any RGB formats.
     

    hoborg

    Portal Pro
    June 13, 2008
    4,413
    1,644
    Nový Jičín
    Home Country
    Czech Republic Czech Republic
    Hello.
    I am not coder, but what about such solution?
    1) Modify DirectVobSub to stream subtitles data instead to "place" them in to video (something like "null renderer")
    2) Create MP plugin which should detect such stream and display subtitles as OSD in MP (like volume bar)

    What do you think about this - is it possible?
     

    magnetism

    Portal Member
    October 3, 2007
    15
    0
    YUV Mixing Mode

    # The other inputs pins can only accept per-pixel alpha YUV formats, such as AYUV, AI44 and IA44.
    # None of the VMR's input pins can accept any RGB formats.

    I take it then that MediaPortal sets this mode? I must have missed that in the code... Anyway, I guess that means that using this will not be possible, unless I change the vobsub thing to render to AYUV...
     

    tourettes

    Retired Team Member
  • Premium Supporter
  • January 7, 2005
    17,301
    4,800
    YUV Mixing Mode

    # The other inputs pins can only accept per-pixel alpha YUV formats, such as AYUV, AI44 and IA44.
    # None of the VMR's input pins can accept any RGB formats.

    I take it then that MediaPortal sets this mode? I must have missed that in the code... Anyway, I guess that means that using this will not be possible, unless I change the vobsub thing to render to AYUV...

    Yes, its set by MP. Patching vobsub to render into AYUV should work (at least in theory). If it works, then its the smallest effort that is needed to make HW accell on subs for MP to work (and wont require changes, or only minor changes on MP side).
     

    magnetism

    Portal Member
    October 3, 2007
    15
    0
    You would need some changes in the MP code. The code that constructs the graph now does things with the vobsub filter that will make it impossible to support DXVA. But that would need to change regardless of the solution taken to render the subtitles I would guess.

    Then I guess we'd need to change MP to give the source filter some more info on the played media (FPS, resolution etc).

    I'll have a quick look tonight at AYUV rendering, we might get lucky and rendering is already supported by the filter..
     

    magnetism

    Portal Member
    October 3, 2007
    15
    0
    Right, I had a look at AYUV today and unfortunately it looks like it's not actually already in the plugin. The whole code base is a bit of a mess in the regard, there seem to be bits of code that do support the AYUV already and other bits where it's ignored or just handled differently.
    Anyway, it looks like a lot more work than I have time for at the moment. I'll keep it on the backburner for now. Pitty.
     

    Users who are viewing this thread

    Top Bottom