Jump to content


Photo

3D mode broken

3d mpv

  • Please log in to reply
21 replies to this topic

#1 serpi OFFLINE  

serpi

    Advanced Member

  • Members
  • 210 posts
  • Local time: 06:41 PM

Posted 29 March 2018 - 12:08 PM

Hi,

 

it seems the settings for the 3d conversation mode are not working anymore in ET 3.0?! (I think it already didn't work in 2.9.9)

 

I had it set to mono (convert to 2d), but now all 3d videos are played with the setting none (no conversation).

I tried it on two different installations, both with the same result.

 

I tried different settings, all are ignored.

 

Does ET use the video-stereo-mode setting of mpv?

 

In the documentation it is mentioned:

"Set the stereo 3D output mode (default: mono). This is mostly broken and thus deprecated."

 

So, maybe ET sets it but it doesn't work anymore in mpv?

 

As I understand, instead of this setting, a video filter should be used?

So, based on ffmpeg, mpv should be able to support this 3d output filters?

 

This would be intresting, as there is an hdmi mode, which should be the sae as the hardware based mode in Kodi, which works pretty well for me (and is one of the main reasons, I'm using Kodi besides ET.

 

Is there any chance to fix the 3d mode in ET?

 

Thanks & Ciao, Alfred



#2 Doofus ONLINE  

Doofus

    Advanced Member

  • Members
  • 12054 posts
  • Local time: 10:41 AM

Posted 29 March 2018 - 12:11 PM

MPV seem to have removed the filter.

https://mpv.srsfckn....ges/2017-12-25/

Edited by Doofus, 29 March 2018 - 12:18 PM.


#3 Doofus ONLINE  

Doofus

    Advanced Member

  • Members
  • 12054 posts
  • Local time: 10:41 AM

Posted 29 March 2018 - 12:24 PM

The filter might still be accessible with the lavfi wrapper. I think randomevents was going to look into that, but I haven't seen any follow up.

#4 serpi OFFLINE  

serpi

    Advanced Member

  • Members
  • 210 posts
  • Local time: 06:41 PM

Posted 29 March 2018 - 12:54 PM

The filter might still be accessible with the lavfi wrapper. I think randomevents was going to look into that, but I haven't seen any follow up.

 

I tried it in the shell with the mpv version of ET, the --video-stereo-mode option seems to be gone, but the videofilter stereo3d does work.

 

So, for example, to output an HSBS video to mono (left eye), you have to add --vf=stereo3d=sbs2l:ml to the commandline (or config).

 

The problem seems to be, that there is no auto detection of the input format anymore, so setting the filter would be a little bit more complicated in ET.

 

I would suggest, that it should still be possible to set the output format in ET, the input format should be read from the metadata 3D format:

 

SBS -> sbsl

HSBS -> sbs2l

TAB -> abl

HTAB -> ab2l

MVC -> ? (maybe al)

 

Maybe with an option, to set right first in input data (which, I think, i not used very often), which would lead to the input formats sbsr/sbs2r/abr/ab2r(/ar).

 

Or is it still possible in mpv, to have an automatic format detection based on the video stereo mode in the mkv file?

 

Ciao, Alfred



#5 Doofus ONLINE  

Doofus

    Advanced Member

  • Members
  • 12054 posts
  • Local time: 10:41 AM

Posted 29 March 2018 - 12:59 PM

Well, they say they've removed it.

Removed
af: remove deprecated audio filters (channels, equalizer, pan, volume; replacements in lavfi)
vf: remove most GPL video filters (crop, dsize, expand, flip, gradfun, mirror, noformat, pullup, rotate, scale, stereo3d, yadif; replacements in lavfi)
vf_buffer: remove this filter
video: remove automatic stereo3d filter insertion
vo_opengl: refactor into vo_gpu
vo_wayland: remove

The mpv version in 3.0 is a shinchiro build. I guess it's possible that they haven't removed it in theirs.

#6 serpi OFFLINE  

serpi

    Advanced Member

  • Members
  • 210 posts
  • Local time: 06:41 PM

Posted 29 March 2018 - 01:05 PM

The filter might still be accessible with the lavfi wrapper. I think randomevents was going to look into that, but I haven't seen any follow up.

 

How would I test/use this with mpv?

 

Thanks & Ciao, Alfred



#7 Doofus ONLINE  

Doofus

    Advanced Member

  • Members
  • 12054 posts
  • Local time: 10:41 AM

Posted 29 March 2018 - 01:08 PM

The easiest way would be to add the filter the mpv.conf, double click on the mpv.exe in the Theater install folder, and drag your movie onto it. I've got a portable version of mpv that I use to test with.

#8 serpi OFFLINE  

serpi

    Advanced Member

  • Members
  • 210 posts
  • Local time: 06:41 PM

Posted 29 March 2018 - 01:11 PM

The easiest way would be to add the filter the mpv.conf, double click on the mpv.exe in the Theater install folder, and drag your movie onto it. I've got a portable version of mpv that I use to test with.

 

I prefer the commandline for this.

 

But my problem ist, how do I access this lavfi wrapper?

Using the video filter in mpv, I wrote this example: --vf=stereo3d=sbs2l:ml

How would I set this using lavfi wrapper?

 

Thanks & Ciao, Alfred



#9 Luke OFFLINE  

Luke

    System Architect

  • Administrators
  • 135840 posts
  • Local time: 01:41 PM

Posted 29 March 2018 - 01:12 PM

So i guess rather than auto-detect, we will have to know the 3d mode and pass it to mpv. is that correct?



#10 Doofus ONLINE  

Doofus

    Advanced Member

  • Members
  • 12054 posts
  • Local time: 10:41 AM

Posted 29 March 2018 - 01:18 PM

But the filter has been removed from mpv. You'll need a workaround, like we did with the audio upmix.

#11 Doofus ONLINE  

Doofus

    Advanced Member

  • Members
  • 12054 posts
  • Local time: 10:41 AM

Posted 29 March 2018 - 01:21 PM

Do a search for lavfi by randomevents in mpv test thread. And you'll find it. We talked about this. He said he was going to look into it. I can't get there on my phone.

#12 serpi OFFLINE  

serpi

    Advanced Member

  • Members
  • 210 posts
  • Local time: 06:41 PM

Posted 29 March 2018 - 01:21 PM

The mpv version in 3.0 is a shinchiro build. I guess it's possible that they haven't removed it in theirs.

 

I just found this in the mpv documentation:

"Also, keep in mind that most actual filters are available via the lavfi wrapper, which gives you access to most of libavfilter's filters. This includes all filters that have been ported from MPlayer to libavfilter. Most builtin filters are deprecated in some ways, unless they're only available in mpv (such as filters which deal with mpv specifics, or which are implemented in mpv only). If a filter is not builtin, the lavfi-bridge will be automatically tried. This bridge does not support help output, and does not verify parameters before the filter is actually used. Although the mpv syntax is rather similar to libavfilter's, it's not the same. (Which means not everything accepted by vf_lavfi's graph option will be accepted by --vf.)"

 

So, it seems, the stereo3d filter is automatically passed to the wrapper now and has the same parameters there?!

How can I see, if the wrapper is used or the filter is builtin (I even don't know, what the wrapper is doing  ;) )?

 

Ciao, Alfred



#13 Doofus ONLINE  

Doofus

    Advanced Member

  • Members
  • 12054 posts
  • Local time: 10:41 AM

Posted 29 March 2018 - 01:29 PM

You'll have to check the filter chain in the mpv log, to see what's happening.

https://emby.media/c...r/?fromsearch=1

#14 serpi OFFLINE  

serpi

    Advanced Member

  • Members
  • 210 posts
  • Local time: 06:41 PM

Posted 29 March 2018 - 01:33 PM

So i guess rather than auto-detect, we will have to know the 3d mode and pass it to mpv. is that correct?

 

Well, it seems so, yes. As Doofus wrote, the automatic filter insertion now seems to be removed.

 

I think, for emby it would be best, to use the format3d tag from the metadata to map to the input format, as I wrote before.

 

So, either emby has tagged this when creating the metadata or the user has set this when manually creating/editing the metadata or setting it in the web interface.

 

I think, it should be enough for ET, to get an input mode, the output mode can still be set in the options.

 

It would also be nice to have an description for the output modes in the settings page besides the abbreviation.

 

But I don't know, if all the output modes from the ffmpeg page are supported with the wrapper.

 

Ciao, Alfred



#15 Doofus ONLINE  

Doofus

    Advanced Member

  • Members
  • 12054 posts
  • Local time: 10:41 AM

Posted 29 March 2018 - 01:40 PM

As I understand it, the wrapper directly uses the filters that are present in the version of ffmpeg they are currently using. The lavfi wrapper works perfectly for the audio filters. But you'd need to manually choose the settings.

#16 serpi OFFLINE  

serpi

    Advanced Member

  • Members
  • 210 posts
  • Local time: 06:41 PM

Posted 29 March 2018 - 01:47 PM

You'll have to check the filter chain in the mpv log, to see what's happening.

https://emby.media/c...r/?fromsearch=1

 

It seems, ET mpv still uses the builtin stereo3d filter:

 

[   0.187][v][vf] User filter list:
[   0.187][v][vf]   stereo3d (stereo3d.00)
[...]
[   0.198][v][vf] [stereo3d] 1920x540 [1:2] yuv420p bt.709/bt.709/bt.1886/limited/display SP=1.000000 CL=mpeg2/4/h264 stereo=ab2l/mono
[   0.198][v][vf] [autorotate] 1920x540 [1:2] yuv420p bt.709/bt.709/bt.1886/limited/display SP=1.000000 CL=mpeg2/4/h264 stereo=ab2l/mono
[   0.198][v][vf] [convert] 1920x540 [1:2] yuv420p bt.709/bt.709/bt.1886/limited/display SP=1.000000 CL=mpeg2/4/h264 stereo=ab2l/mono
 
But using lavfi-stereo3d instead of stereo3d as filtername gives a similar output:
 
[   0.192][v][vf] User filter list:
[   0.192][v][vf]   lavfi-stereo3d (lavfi-stereo3d.00)
[...]
[   0.205][v][vf] [lavfi-stereo3d] 1920x540 [1:2] yuv420p bt.709/bt.709/bt.1886/limited/display SP=1.000000 CL=mpeg2/4/h264 stereo=ab2l/mono
[   0.205][v][vf] [autorotate] 1920x540 [1:2] yuv420p bt.709/bt.709/bt.1886/limited/display SP=1.000000 CL=mpeg2/4/h264 stereo=ab2l/mono
[   0.205][v][vf] [convert] 1920x540 [1:2] yuv420p bt.709/bt.709/bt.1886/limited/display SP=1.000000 CL=mpeg2/4/h264 stereo=ab2l/mono
 
mpv documentation says this:
You can also prefix the filter name with lavfi- to force the wrapper. This is helpful if the filter name collides with a deprecated mpv builtin filter
 
So, now I'm confused. Is it using the wrapper or not?
 
Ciao, Alfred

Edited by serpi, 29 March 2018 - 01:49 PM.


#17 Doofus ONLINE  

Doofus

    Advanced Member

  • Members
  • 12054 posts
  • Local time: 10:41 AM

Posted 29 March 2018 - 02:00 PM

Do a search in your log, for filter chain. It'll likely be long. It should tell you what the output is. Which version of mpv are you using. Make sure you don't confuse the builds.

#18 Doofus ONLINE  

Doofus

    Advanced Member

  • Members
  • 12054 posts
  • Local time: 10:41 AM

Posted 29 March 2018 - 02:21 PM

It may also just report it as vf and not lavfi. There are a few instances where it doesn't report, accurately. I think the key here, is that the auto selection is probably not present.

Edited by Doofus, 29 March 2018 - 02:52 PM.


#19 serpi OFFLINE  

serpi

    Advanced Member

  • Members
  • 210 posts
  • Local time: 06:41 PM

Posted 29 March 2018 - 02:59 PM

It may also just report it as vf and not lavfi. There are few instances where it doesn't report, accurately. I think the key here, is that the auto selection is probably not present.

 

Yep, I think that's the main problem.

 

I'm using the mpv.exe from the 3.0.0 ET install (64 bit).

 

Searching for chain in the log file just gives me this line:

[   0.194][v][af] format changed, draining filter chain
 

But after reading the mpv documentation, that the lavfi- prefix would force the lavfi wrapper I think, mpv just uses automatically the wrapper with the vf=stereo3d option.

 

So, it seems everything is alright and the wrapper is already used, now all has to be done is implementing the call in ET  ;)

 

Ciao, Alfred



#20 Doofus ONLINE  

Doofus

    Advanced Member

  • Members
  • 12054 posts
  • Local time: 10:41 AM

Posted 29 March 2018 - 03:26 PM

It's a bit unpredictable as to whether it will successfully use the wrapper, automatically. I'd suggest using lavfi, directly. That way, it's always going to work. As for choosing which stereo3d to use, it'll either be a manual selection, or Luke will have to work some magic.

What you're finding on the log, might be down to how shinchiro builds their releases.





Also tagged with one or more of these keywords: 3d, mpv

0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users