Log in

View Full Version : Media Player .NET (MPDN) - D3D HQ GPU Video Renderer [v2.49.0/v1.31.0 27 Dec 2018]


Pages : 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 [23] 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96

Zachs
28th January 2015, 23:28
Found a guy who has similar problems of Optimus + nVidia 880M system, which was also related to texture usage.
http://us.battle.net/heroes/en/forum/topic/13733923564

It seems that it's the drivers fault, am I right? We will just have to wait until nVidia give us a 'perfect' driver version.

I will test if debanding has any affect on rendering time later today. From my experience, the new debanding code is much more faster than previous version.

You could also add a few Resizers that resizes to different sizes in the chain to see if it worsens the problem as that forces the chain to create more textures (you'll probably get garbage output but image quality is not the purpose of the test).

Would be good if more people with Optimus could try to replicate the issue as well.

Zachs
28th January 2015, 23:29
I wouldn't just wait. Have you posted your issue in the nVidia forums or provided feedback? (http://www.nvidia.com/object/driverqualityassurance.html)

You have access to an Optimus setup haven't you? Perhaps you could help test and see if you could replicate the problem before reporting the bug to nvidia collectively.

ryrynz
28th January 2015, 23:39
You have access to an Optimus setup haven't you? Perhaps you could help test and see if you could replicate the problem before reporting the bug to nvidia collectively.

Yeah, I'll have a play on it see what happens.

Zachs
28th January 2015, 23:52
Yeah, I'll have a play on it see what happens.

Great! :)

I think the settings to replicate the issue were as follows.

SuperChromaRes -> SuperRes with NEDI + 5 passes
Optionally:
Add deband
Resize to 150%
ImageProcessor - LumaSharpen
Resize to 200%
ImageProcessor - LumaSharpen
Resize to 50%
ImageProcessor - LumaSharpen
...
Resize to 100%

@Anima123 is that right?

Anima123
29th January 2015, 00:12
It's quite easy to trigger the problem now, you just use the new SuperRes and playback a video file with lower resolution like 720x404 toward a target 1080p resolution.

Zachs
29th January 2015, 03:29
Starting v2.20, MPDN's extensions (PlayerExtensions, RenderScripts and CustomLinearScalers) will be merged into one repository and one folder called "Extensions".

Within it, you will still have the three separate extension folders but they are no longer loaded independently - and all scripts will be recursively loaded from the "Extensions" folder. This change is necessary seeing as how much code duplicates are starting to occur between PlayerExtensions and RenderScripts. With that, we can now move the common code into a subfolder, reduce code duplicates, and generally have better synergy between the various scripts.

The interfaces (IPlayerExtension, IRenderScript, ICustomLinearScaler) remain mostly the same with some minor changes.

Also note that we have merged RenderScripts and PlayerExtensions repositories into MPDN_Extensions (https://github.com/zachsaw/MPDN_Extensions) on GitHub. Please make sure you switch to this repository for any further works.


Cheers,
Zachs

Blackfyre
29th January 2015, 05:00
Thanks for the heads up. Really appreciate the hard work. Well done mate. Hopefully it's a smooth transition to version 2.20 (whenever it's released).

Edit: It's released, we'll test soon.

Zachs
29th January 2015, 05:07
v2.20.0 released.

Note for all users.

All scripts have now been combined into one zip file (link in OP) and from now on that is the link to use to download the latest scripts. Note that the scripts will be updated from time to time that is outside of MPDN's release cycle, so to get the latest updates, make sure you download the scripts whenever there's an announcement from the developers.

To find out when the extension scripts was last updated, see MPDN_Extensions page on GitHub (https://github.com/zachsaw/MPDN_Extensions/) (e.g. "... authored X minutes/hours/days ago").

Anime Viewer
29th January 2015, 07:36
v2.20.0 released.

All scripts have now been combined into one zip file (link in OP) and from now on that is the link to use to download the latest scripts. Note that the scripts will be updated from time to time that is outside of MPDN's release cycle, so to get the latest updates, make sure you download the scripts whenever there's an announcement from the developers.


I've only tested a handful of files so far, but so far 2.20 (and the extensions) seems to extract and work fine.

Zachs
29th January 2015, 11:54
All developers,

I've just cleaned up the merged repository. I'd appreciate it if you could all do a merge from the latest revision.

Cheers!

DeadlyEmbrace
29th January 2015, 17:58
Ok, I've switched to the new repository and fixed the Remote Control extension. It seems the old one sneaked in somehow.

Anima123
29th January 2015, 20:24
Shiandow,

I have get through your algorithm of CalculateSize() and found it doesn't work as expected. For 576p -> 1080p upscaling, there's no intermediate resizing steps, the first pass just push the currentSize direct to 1080p. No wonder it does not suffer from rendering time increasing for 576p video, and that might also explain why the NEDI might not working if MaxScale set >= 2.0.

Another question, does SuperRes shader do upscaling of diff itself with bilinear, if useBilinear is 'true'?

Shiandow
29th January 2015, 21:04
Shiandow,

I have get through your algorithm of CalculateSize() and found it doesn't work as expected. For 576p -> 1080p upscaling, there's no intermediate resizing steps, the first pass just push the currentSize direct to 1080p. No wonder it does not suffer from rendering time increasing for 576p video, and that might also explain why the NEDI might not working if MaxScale set >= 2.0.

That is expected behaviour, doing 576 -> 1080p in more than 1 step would require at least one step with a scaling factor less than or equal to sqrt(1.875) which is slightly lower than the minimum allowed scaling factor sqrt(1.9). Also that comment about NEDI not working no longer applies, that bug was fixed recently. For technical reasons NEDI had problems with scaling factors of exactly 2.0.


Another question, does SuperRes shader do upscaling of diff itself with bilinear, if useBilinear is 'true'?

Yes it simply turn hardware bilinear interpolation for the SuperRes shader on, that way the input is automatically interpolated. This costs less memory and seems to be at least as fast as doing it manually.

Anima123
30th January 2015, 00:19
Siandow,

Read from http://forum.doom9.org/showthread.php?p=1703811#post1703811, you mentioned that in MPDN, the new texture is used to avoid unnecessary computing of NEDI. I wonder if you can add an option for the user to choose if new texture be used.

Since current Optimus drivers have bug in terms of texture, I wonder if this bug can be avoided somehow by invoke NEDI in a 'traditional, unoptimized' way.

Another simple quick question: Scaler.Bicubic(1.0f, false) or Scaler.Bicubic(0.0f, false), which one is equivalent to Catmull-Rom?

Anime Viewer
30th January 2015, 02:48
Since current Optimus drivers have bug in terms of texture, I wonder if this bug can be avoided somehow by invoke NEDI in a 'traditional, unoptimized' way.


What bug are you referring to (is it a 800/900 series bug)? I haven't noticed any texture problem(s) with my 680m GTX Optimus system.

Anima123
30th January 2015, 02:52
What bug are you referring to (is it a 800/900 series bug)? I haven't noticed any texture problem(s) with my 680m GTX Optimus system.

Mine is 880M. As I reported in this thread, it will cause rendering time increase gradually when using SuperRes with NEDI enabled.

Zachs
30th January 2015, 05:15
*Devs only*

I've added support for .resx (XML) and .resources (compiled resource) file. Here's the guideline to use them correctly with MPDN.

Resource files needs an identifier allocated for it to be accessible in your code and this identifier is generally created automatically when the IDE invokes the compiler, based on the information it gathers from csproj file.

Since there's no csproj file requirement for MPDN's scripts to function, this identifier cannot be automatically generated. As such, you'll need to rename the .resx / .resources file such that the name itself is the identifier.

For example, PlaylistForm.resx would be dependent upon PlaylistForm.cs. Since the PlaylistForm class has a full type name of Mpdn.PlayerExtensions.GitHub.PlaylistForm, you'll need to name the resx file to Mpdn.PlayerExtensions.GitHub.PlaylistForm.resx (or if you pre-ResGen the .resx file, you'll need to name it Mpdn.PlayerExtensions.GitHub.PlaylistForm.resources). As you could see in the following code which is inserted by the designer (in PlaylistForm.Designer.cs), typeof(PlaylistForm) is the reason for naming our resource files the way that was described.


System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(PlaylistForm));


I've updated the PlaylistForm to use an external .resx file to serve as an example.

In conclusion, this change should make it easier for devs who need to embed icons/images in a resource file - all you need to do is rename the file from the IDE generated name to the type's full name (+.resx) before pushing it to GitHub; or you could simply add a postbuild event that ResGen a .resources file with the type's full name, whichever way you feel is easier.

nekromantik
30th January 2015, 07:58
I reported before on my 860M there is no bug with render time increases.
Watched a 45 min video with SuperRES NNDI enabled and no bug present. Might be a Keplar bug as my 860M is Maxwell.

Garteal
30th January 2015, 10:52
Awesome Zachs, thanks for the quick responses and implementation. Will start updating things here in a bit.

poorplayer
30th January 2015, 20:08
No streaming support - No plans for MPDN to support streaming at the moment either. Not even sure if LAV splitter does streaming...

Not sure if it counts as streaming, but MPDN doesn't work for me with SVPtube. It does work with MPC-HC using LAV.

ryrynz
31st January 2015, 00:29
I reported before on my 860M there is no bug with render time increases.
Watched a 45 min video with SuperRES NNDI enabled and no bug present. Might be a Keplar bug as my 860M is Maxwell.
Same here. Can't duplicate any render time increases both full screen and windowed. Nvidia 850 gtx gpu confirmed used in an hp optimus notebook. NNEDI3 5 pass on 640 video latest drivers win 8.1

Zachs
31st January 2015, 04:47
@Anima123
Maybe you should upload the clip so we could all test with the same settings and media, as no one else seems to be able to replicate the problem.

Anima123
31st January 2015, 07:07
Do you guys has some video clips that has a scale factor more than 2.0 when playing in the native resolution, such as 720 x 404 to 1920 x 1080? The latest SuperRes suffers from that by introducing 'slowly increasing the size each pass' feature, which is easier to trigger.

For 720p to 1080p, I can playback it very fluently with no rendering time increase if NEDI not enabled, and the quality is quite nice to me.

Zachs
31st January 2015, 07:22
So with NEDI enabled even 720p to 1080p will trigger the problem?
In that case, all the other people with Optimus have tested and found no such problem...

Anima123
31st January 2015, 07:38
So with NEDI enabled even 720p to 1080p will trigger the problem?
In that case, all the other people with Optimus have tested and found no such problem...

Actually I took ryrynz's advice via PM and tried the 'high performance' status of my 880M, and the rendering time increase still there with 720p -> 1080p, SuperRes with NEDI enabled. The increase is gradually and slowly though.

Now the only way using SuperRes and didn't suffer this is plain SuperRes.

And I also found, for low-resolution videos, SuperChromRes + SuperRes will suffer the creepy rendering time increase, while the same configuration for 720p videos not.

ryrynz
31st January 2015, 07:55
Upload your video to a file sharing site and send me a PM, I'll test it with SuperChromaRes enabled as well with and without NEDI.
What are your rendering times like at start? and as it creeps up, what does it stop at if anything? I was running latest drivers for the GTX 850m, make sure you are also.

Shiandow
1st February 2015, 03:34
The latest extensions now have a renderscript called "Preset Group" which makes it possible define several different configurations and then switch between them using a hotkey. It's also possible to use such a Preset Group as part of another Preset Group or a Script Chain, that way you can have multiple hotkeys to control different parts of the processing.

Edit: Oh and I made a small change to the debanding script, it should now preserve colours a bit better.

Zachs
1st February 2015, 03:41
The latest extensions now have a renderscript called "Preset Group" which makes it possible define several different configurations and then switch between them using a hotkey. It's also possible to use such a Preset Group as part of another Preset Group or a Script Chain, that way you can have multiple hotkeys to control different parts of the processing.

Edit: Oh and I made a small change to the debanding script, it should now preserve colours a bit better.
Great stuff!!

Those who've requested switching between multiple render chains via shortcut keys, your wish has come true!

Thank you do much Shiandow!

Blackfyre
1st February 2015, 05:28
Shiandow & Zachs

Thanks guys. Glad my request for switching between multiple render chains via shortcuts was added :) I shall do some testing.

Edit: I probably need instructions, because I can't see how to configure it.

nekromantik
1st February 2015, 17:49
How do I know if NNDI is actually working?
Also is SuperChromaRes meant to go first then SuperRes?

Shiandow
1st February 2015, 18:46
Shiandow & Zachs
Edit: I probably need instructions, because I can't see how to configure it.

You can add renderscripts to a Preset Group by selecting a renderscript type at the bottom, and then clicking add. You can then configure this renderscript by double clicking it, or selecting it and clicking configure. You can give a Preset Group it's own name by filling in a name at the top left, and you can give it a hotkey by typing in a hotkey in the top right.

How do I know if NNDI is actually working?
Also is SuperChromaRes meant to go first then SuperRes?

Well if NEDI is working then the corners of the image should move slightly, although if that's the only way you can notice a difference then it might not be worth it. It might be easier to see if you configure a Preset Group, adding one preset with NEDI and another one without, then you can turn NEDI on or off with a hotkey.
And yes, SuperChromaRes should be used before SuperRes. In almost all cases it should be the very first in the script chain.

nekromantik
1st February 2015, 19:09
You can add renderscripts to a Preset Group by selecting a renderscript type at the bottom, and then clicking add. You can then configure this renderscript by double clicking it, or selecting it and clicking configure. You can give a Preset Group it's own name by filling in a name at the top left, and you can give it a hotkey by typing in a hotkey in the top right.



Well if NEDI is working then the corners of the image should move slightly, although if that's the only way you can notice a difference then it might not be worth it. It might be easier to see if you configure a Preset Group, adding one preset with NEDI and another one without, then you can turn NEDI on or off with a hotkey.
And yes, SuperChromaRes should be used before SuperRes. In almost all cases it should be the very first in the script chain.

Thanks

Reason I asked was my render times was only 23 with 3 runs of NEDI and super res. Im on a optimus laptop so should be higher.

Shiandow
1st February 2015, 21:13
Thanks

Reason I asked was my render times was only 23 with 3 runs of NEDI and super res. Im on a optimus laptop so should be higher.

Does it increase when you enable NEDI?

nekromantik
1st February 2015, 21:39
Does it increase when you enable NEDI?

Nope no render time difference but if I change the SuperRes passes from 3 to 6 there is a small 5 - 8 ms difference.
Looks like NEDI is not being applied as off and on no difference.

Shiandow
1st February 2015, 22:05
Nope no render time difference but if I change the SuperRes passes from 3 to 6 there is a small 5 - 8 ms difference.
Looks like NEDI is not being applied as off and on no difference.

Just to be sure, you're actually enabling NEDI in the SuperRes settings, not just adding copies of the NEDI script after the SuperRes script?

nekromantik
1st February 2015, 22:09
Just to be sure, you're actually enabling NEDI in the SuperRes settings, not just adding copies of the NEDI script after the SuperRes script?

I just installed the latest version of player and scripts and now it works.
I get increased render time a bit when NEDI is ticked in SuperRes.
And Yes I was using it in SuperRes.
Thanks for help.

One more thing, the resize script, do you still need it if you watching on 4k tv? Or will SuperRes upscale auto to output res?

Shiandow
1st February 2015, 22:12
I just installed the latest version of player and scripts and now it works.
I get increased render time a bit when NEDI is ticked in SuperRes.
And Yes I was using it in SuperRes.
Thanks for help.

One more thing, the resize script, do you still need it if you watching on 4k tv? Or will SuperRes upscale auto to output res?

SuperRes will scale directly to the output resolution, but even if it didn't MDPN always resizes the final output to the correct size.

nekromantik
1st February 2015, 22:22
SuperRes will scale directly to the output resolution, but even if it didn't MDPN always resizes the final output to the correct size.

Thanks
I will probably make a script chain group for anything less then 4k with SuperChroma and SuperRes and then for 4k no chain.

Zachs
1st February 2015, 22:59
Nope no render time difference but if I change the SuperRes passes from 3 to 6 there is a small 5 - 8 ms difference.
Looks like NEDI is not being applied as off and on no difference.

Just another thing to add. Render time isn't a true indication of the amount of work the GPU was doing - it's merely the time it took to do the work it was given. This time could be lower even when it's working harder, simply because GPU clock rates have been increased (automatically by the driver/hardware).

The GPU load (via GPU-Z) is a better indicator. Render time is only useful for finding out if your GPU is fast enough to run an algo/render chain - it doesn't tell you how much headroom the GPU has.

Garteal
2nd February 2015, 00:27
I've been working on extending the playlist of Mpdn into something I've personally been looking for for a while. As a bonus I've also tried to make it look a little more attractive.
http://abload.de/img/mpdn-playlistekuol.png
This will probably be mostly useful for people who watch anime with chapters and want to watch a bunch in one seating.
Simply key in all the chapters you want to skip, where it should skip to the next video on the playlist, sit back on your chair/couch and enjoy the show.
Everything should be pretty straight-forward.

The new features added are:

skipping chapters you don't want to see
skip to the next video or end the video when it reaches a certain chapter

This allows you to skip the openings and end at the ending songs for example.

Seeing as I got some positive feedback on the idea and first implementation, I've decided to share it. Hope someone else finds it useful other than me.

nekromantik
2nd February 2015, 00:50
Just another thing to add. Render time isn't a true indication of the amount of work the GPU was doing - it's merely the time it took to do the work it was given. This time could be lower even when it's working harder, simply because GPU clock rates have been increased (automatically by the driver/hardware).

The GPU load (via GPU-Z) is a better indicator. Render time is only useful for finding out if your GPU is fast enough to run an algo/render chain - it doesn't tell you how much headroom the GPU has.

Makes sense :)

Zachs
2nd February 2015, 03:02
I've been working on extending the playlist of Mpdn into something I've personally been looking for for a while. As a bonus I've also tried to make it look a little more attractive.
http://abload.de/img/mpdn-playlistekuol.png
This will probably be mostly useful for people who watch anime with chapters and want to watch a bunch in one seating.
Simply key in all the chapters you want to skip, where it should skip to the next video on the playlist, sit back on your chair/couch and enjoy the show.
Everything should be pretty straight-forward.

The new features added are:

skipping chapters you don't want to see
skip to the next video or end the video when it reaches a certain chapter

This allows you to skip the openings and end at the ending songs for example.

Seeing as I got some positive feedback on the idea and first implementation, I've decided to share it. Hope someone else finds it useful other than me.

Thank you so much Gartael!

I've added files drag-drop back to playlist as well as auto-play on open play list. Only thing missing is reodering through drag-drop. :)
Also made the playlist form following MPDN main form when it gets moved around.

Dark Eiri
2nd February 2015, 07:00
Do you pretent to add filetype associations to MPDN in the future? If you'd like to, I'd be happy to give you this icon-set I made for personal use (I use them with MPC-HC at the moment).

http://i61.tinypic.com/2mdmkjr.png

ryrynz
2nd February 2015, 07:07
Do you pretent to add filetype associations to MPDN in the future? If you'd like to, I'd be happy to give you this icon-set I made for personal use (I use them with MPC-HC at the moment).


Fit's in with the "theme" of MPDN nicely I think, very clean.

Blackfyre
2nd February 2015, 07:28
Do you pretent to add filetype associations to MPDN in the future? If you'd like to, I'd be happy to give you this icon-set I made for personal use (I use them with MPC-HC at the moment).

http://i61.tinypic.com/2mdmkjr.png

Love this and love the idea! File association + those icons would be a great add-on.

Zachs
2nd February 2015, 07:35
Player extension for file association anyone?

Edit: thanks Dark Eiri!

Garteal
2nd February 2015, 16:41
Thank you so much Gartael!

I've added files drag-drop back to playlist as well as auto-play on open play list. Only thing missing is reodering through drag-drop. :)
Also made the playlist form following MPDN main form when it gets moved around.
I did some work on the drag and drop and reordering them, but it looks like you already did that so I'll rebase and add on to that later.
Saw your other commits on it as well. Thanks for the improvements!

Do you have an issue tracker for Mpdn? And if not, why not set up one? Might be handier.

Zachs
3rd February 2015, 01:58
Don't have an issue tracker yet but for the open source extensions, GitHub has one that we could use.

Zachs
3rd February 2015, 04:20
I've added some RenderScript examples in GitHub, so if anyone's interested to try them out, just copy the contents in Examples\RenderScripts into the Extensions\RenderScripts folder. These only serve as examples of how to do various things with render scripts, so you wouldn't want to use them in your daily video playback.

The examples are,

1) Shader Model 3.0 Script example (RenderScript (https://github.com/zachsaw/MPDN_Extensions/blob/master/Examples/RenderScripts/Example.Basic.cs) - hlsl (https://github.com/zachsaw/MPDN_Extensions/blob/master/Examples/RenderScripts/Examples/BlueTintSm3.hlsl))
A basic render script example using shader model 3.0 - this example simply adds a blue tint to your image and forms the basis of the next two examples.

2) Shader Model 5.0 script example (RenderScript (https://github.com/zachsaw/MPDN_Extensions/blob/master/Examples/RenderScripts/Example.Sm5.cs) - hlsl (https://github.com/zachsaw/MPDN_Extensions/blob/master/Examples/RenderScripts/Examples/BlueTintSm5.hlsl))
Instead of the usual constants, SM5.0 requires constant buffers - it is quite a minor change from SM3.0.

3) DirectCompute script example (RenderScript (https://github.com/zachsaw/MPDN_Extensions/blob/master/Examples/RenderScripts/Example.DirectCompute.cs) - hlsl (https://github.com/zachsaw/MPDN_Extensions/blob/master/Examples/RenderScripts/Examples/BlueTintDirectCompute.hlsl))
This example shows how the sample script above can be done in DirectCompute. It is way more powerful than basic pixel shaders as you can process any arbitrary pixels in any order (per thread group). Note that this script and the one above require Dx11 GPUs. If you don't have one, you'll get blank screen when these scripts are selected.

4) Custom Textures script example (RenderScript (https://github.com/zachsaw/MPDN_Extensions/blob/master/Examples/RenderScripts/Example.CustomTextures.cs) - hlsl (https://github.com/zachsaw/MPDN_Extensions/blob/master/Examples/RenderScripts/Examples/CustomTextures.hlsl))
So far this feature hasn't been used in any render scripts, so just thought it'd be a good idea to have an example for it in case anyone finds the need to say, draw fishes swimming on top of your video footage. Joking aside, this feature is very useful for implementing lookups (point and linearly filtered). Currently RenderScript only supports 2D textures - 3D texture support will be added in the future (this is the missing link for 3dlut implementation in RenderScript).

Cheers.

ryrynz
3rd February 2015, 09:31
Some playlist extension requests.

Ability to remove currently playing file from the playlist (stops the video)
Right click context menu for the playlist (nice but no big deal, we have buttons)
Docking between MPDN and playlist (Not required? visual thing really which brings me to it's right angled edges vs MPDN's rounded edges)
Remembering previous size & window position
On file open add that file to the playlist
Option to remember previous played file and display in playlist

Bout it for now, cheers.

Small cosmetic issue.

Resizing the playlist window I can have the 'End chapter' just say 'End' and I have to manually resize that field to display it all.

I think the playlist buttons loook quite nice, thoughts on having the MPDN icons that match them? The playlist could ditch the button look and go with a highlight like the video window.