View Full Version : Guide to convert BD 3D to 3D Left+Right Stereoscopic and Anaglyph
r0lZ
16th March 2014, 11:40
On "Monster Inc. 3D" (not "Monsters University"), you'll find "Partysorus Rex" (a short from the Toy Story Toons series), with subtitles in several languages, including French. The collection of howlers ("Bêtisier" in French) that was included in the credits of the original 2D main movie has been removed from the 3D version, but has been added as a bonus on the 3DBD. It has also several subtitle streams. "For the Birds" ("Drôles d'oiseaux sur une ligne à haute tension"), on the same BD, has only a few English subtitles. So, on that 3DBD, you have 3 shorts with subtitles. That should be sufficient for your tests. :-)
Nico8583
16th March 2014, 19:31
Thanks ;-)
b0mb
18th March 2014, 15:17
That's not credible. The resolution of the video is not at all related to the depth effect. I can admit that the video may be a bit less sharp (since its resolution is divided by 2), and perhaps that there is less "detail" in the depth, but certainly not that the depth is reduced.
There have been long discussions of a French forum on the supposed superiority of half-T&B over Half-SBS, because the parallax depends of the horizontal direction and therefore is more precise when the X resolution is not divided by 2. Theoretically, it's true. But the parallax plays only a small role in the perception of the relief. The brain is much more important. And the conclusion of the experts on the forum is that half-SBS gives excellent results, not less good than half-T&B (or full-SBS). Of course, if you really think that full-SBS is superior, you will perhaps see a difference. But it's pure religion. And anyway, if there is a small difference, it's in the precise position of the "planes", not at all in the global depth of the scene, simply because the parallax do not change when the resolution is reduced. It is only somewhat blurred, exactly like the precision of the pixels.
after weeks of testing different formats i came to the conclusion that you were right with what you´ve said ;)
r0lZ
18th March 2014, 16:22
Thanks for your long tests and for letting us know. :-)
Nico8583
19th March 2014, 18:26
I'm going to try to make (thanks to r0lZ to advise me ;) ) a soft to convert BD sup to SBS/TAB 3D sup/xml/sub (like Neisklar Suppe3D with other functionnality).
If you use Suppe3D and have suggestions, don't hesitate to tell me.
Nico8583
20th March 2014, 19:27
after weeks of testing different formats i came to the conclusion that you were right with what you´ve said ;)
What is your conclusion ? Do you mind Full SBS is superior to Half SBS even on first minutes of Avatar ? :)
jbuszkie
20th March 2014, 19:51
Yes, the method has evolved greatly, and currently, you can do it with a GUI and much more rapid MVC decoders. BD3D2MK3D converts a BD3D to Half-SBS (or T&B) MKV, with chapters and as many audio and subtitles streams as you want. You can also hardcode the subtitle stream on the video if you wish. The download link is in my signature. You have to install Avisynth if you haven't it already. See the help menu.
There are other GUIs as well, but I prefer to leave their authors present them.
I do like the tool.. Is there something similar for non 3D movies?
I need recode the ones I've watched into something smaller. sometimes there are multiple playlist and it's tough to figure out which one is the correct one. You tool kinda showed the similarities and difference in the playlist and could be useful to figure out the correct play list and turn it into a MKV.
Or is makemkv the way to go then handbrake to shrink?
I was looking for a sticky that had a list of guides!
Now if I could just get the subtitles to work with my player for SBS! (works in VLC so probably an issue with my player!)
Thanks,
Jim
r0lZ
20th March 2014, 20:44
Well, I haven't made an equivalent GUI for 2D BDs, but when I have to recode a movie, usually I use eac3to or tsMuxeR to examine the MPLS files and their associated M2TS parts. When I know what file I want to grab, I use either tsMuxeR or MakeMKV to build an intermediate M2TS or MKV file. I re-encode it with Simple X264 Launcher (http://forum.doom9.org/showthread.php?t=144140), and I remux the intermediate M2TS or MKV with MkvMerge (and, of course, I replace the video stream with the re-encoded one).
I don't like the MakeMKV GUI much, because it has no preview, and it is often extremely slow. So, perhaps I'll do something similar to BD3D2MK3D for 2D movies later, but honestly, I'm not sure. It is somewhat difficult and long to figure out all steps to encode a 3D movie to SBS or T&B, but it is much more simple to re-encode a 2D movies, and I'm not sure it is really necessary to develop a new GUI to do it.
BTW, I suppose that you have noticed that BD3D2MK3D generates also a batch file to mux the 2D movie to MKV (without re-encoding). Of course, that works only with the 2D version of a 3D movie, but it's a good starting point to re-encode it with x264 if you wish.
(Sidenote: I have also developed a plugin for PgcEdit to re-encode any PGC with x264. That plugin has not been released yet, and anyway, it cannot handle BD discs. I should release it soon...)
jbuszkie
20th March 2014, 22:30
Separate question...
These 3d SBS mkvs..
What hardware player are people using to play them?
Do you guys have experience with the mede8er?
Sorry if this is off topic..
Jim
r0lZ
21st March 2014, 10:01
All Smart TVs from Samsung, LG, Panasonic, Philips and probably all other major brands can display 3D SBS MKVs. Some have limitations (like my Samsung that cannot display the embedded subtitles). You can also use a Smart BD player, that will convert the SBS file to regular 3D images, and send them at 48fps to the TV, exactly like for any 3D BD. Anyway, your TV must be 3D to handle that images properly.
I have no experience with 3D "hardware boxes", as I have only an old Lacie LaCinema multimedia HDD, that cannot handle 3D files. I can use it to sent the SBS images to the TV, and let the TV separate them, but it's not a good solution, because the OSD of the Lacie is also "decoded" and is of course impossible to read. Anyway, your TV must be 3D, and if you have a 3D TV, you don't need an external multimedia box. The mede8er can be an excellent multimedia player, but it's the TV that will display the 3D movies in 3D anyway.
Nico8583
25th March 2014, 21:55
A little question : I'm on Windows 7 x64 and I don't have any codec pack installed on a PC. This PC is only use to encode movies, not for playing. Is it necessary, recommended or totaly useless to install a codec pack (like ffdshow, klite or other) in order to encode from AVS (VC-1, MPEG2 or H264 sources) to x264 ?
frencher
25th March 2014, 21:59
All Smart TVs from Samsung, LG, Panasonic, Philips and probably all other major brands can display 3D SBS MKVs. Some have limitations (like my Samsung that cannot display the embedded subtitles). You can also use a Smart BD player, that will convert the SBS file to regular 3D images, and send them at 48fps to the TV, exactly like for any 3D BD. Anyway, your TV must be 3D to handle that images properly.
I have no experience with 3D "hardware boxes", as I have only an old Lacie LaCinema multimedia HDD, that cannot handle 3D files. I can use it to sent the SBS images to the TV, and let the TV separate them, but it's not a good solution, because the OSD of the Lacie is also "decoded" and is of course impossible to read. Anyway, your TV must be 3D, and if you have a 3D TV, you don't need an external multimedia box. The mede8er can be an excellent multimedia player, but it's the TV that will display the 3D movies in 3D anyway.
Hi r0lZ,
Try in same folder Film.mkv and Film.srt works with my Samsung 6500D ;)
frencher
25th March 2014, 22:00
A little question : I'm on Windows 7 x64 and I don't have any codec pack installed on a PC. This PC is only use to encode movies, not for playing. Is it necessary, recommended or totaly useless to install a codec pack (like ffdshow, klite or other) in order to encode from AVS (VC-1, MPEG2 or H264 sources) to x264 ?
Hi Nico8583,
Avisynth, Matroska splitter and FFdshow are necessary ;)
Nico8583
25th March 2014, 22:29
Thanks ;)
I can encode without Matroska and FFDShow, so do you know why is it necessary ?
frencher
26th March 2014, 00:13
Thanks ;)
I can encode without Matroska and FFDShow, so do you know why is it necessary ?
For MVC DirectShowMVCSource.dll and other 3D filters use Embedded codecs.
Now for playing standard video you need FFdshow and Splitter ;)
Nico8583
26th March 2014, 07:42
For MVC DirectShowMVCSource.dll and other 3D filters use Embedded codecs.
Now for playing standard video you need FFdshow and Splitter ;)
Thanks, it's not for playing so I don't need its :)
r0lZ
26th March 2014, 11:25
Right. The codecs are necessary only to play the BD files, and therefore they are required for the preview. But if you can figure out what MPLS must be encoded without the preview, you don't need them.
Hi r0lZ,
Try in same folder Film.mkv and Film.srt works with my Samsung 6500D ;)
I know that my TV supports external SRT files, but I want to use external (or, if possible, internal) SUB/IDX files, and that's not possible. I don't want to have to convert the original SUP to SRT using OCR. Too much work and risks of errors.
Furthermore, the TV shows the SRT in 2D, without any depth effect, and it's not suitable at all for a 3D movie. And, when the subtitle is very long, the TV splits it at random positions, and shows it on 3, 4 or even 5 lines of text! It is not rare to see subtitles occupying the whole bottom half of the screen! Samsung has made a very bad job with the subtitles support. It's my biggest deception with my TV. :-(
slavanap
8th April 2014, 23:17
Recently I actively use ssifSource4, so I'd like to share new version with minor bugfixes that I've found.
http://sendfile.su/965540
Also, there is a new tool filmtester.exe to verify ssifSource output readiness.
This tool reads all the avs-file output and checks for frame duplication sequences longer than 2 (by default) frames. As you know ssifSource (if decoding fails) copies the last successfully decoded frame till the end of the sequence, thus with this tool you can check, whether or not x264 encoding will be successful without wasting processor time for the encoding.
I think, this tool might be useful for testing other plugins' output as well.
pjvader
9th April 2014, 00:39
i have looked everywhere but i'm not having any luck!
is it possible to use multiavchd to create a full frame sequential/frame packing (sorry its late it's whichever one is used for 3d bd!) 3d clip (i.e. add the playlist then use cut start to edit it) im trying to create a demo disc of 2d and 3d clips with the dts-HD sound intact but i'm getting stuck when it comes to full HD 3d:o and scenarist seems a bit :eek: thanks
r0lZ
9th April 2014, 09:38
Thanks slavanap.
Can you confirm that your filmtester.exe needs to decode the whole movie to verify the duplicated frames? In that case, I suppose it takes a long time anyway. It's not as long as encoding the movie, but it's a waste of time anyway. Right?
@pjvader:
Wrong thread. Here, we are doing exactly the opposite. Anyway, to create a 3D BD, the first step is to encode your video in MVC. Maybe the FRIM encoder (http://forum.doom9.org/showthread.php?t=169651) can help. Then, try the new 3D tsMuxeR (http://forum.doom9.org/showthread.php?t=168539) to create the BD structure.
I don't know multiavchd enough to reply to your question.
slavanap
9th April 2014, 14:10
r0lZ,
yes, it's a wasting a time somehow, but I wasted much more time with encoding badly dumped blu-ray with x264 with all the plugins (ssifSource2, ssifSource4-ldecod, ssifSource4-intel).
So, yes, it decodes whole movie, but for me it's more faster than failed encoding with x264. And I can decode simultaneously with different plugins, because decoding process uses few threads.
And, btw, this tool shows its statistics during the decoding in real-time.
First parameter is avs-file, just try out.)
r0lZ
9th April 2014, 14:15
OK, thanks. Note that I haven't written that your tool is useless. I was just wondering if you have found a way to detect problems without having to decode the whole movie. I'll try it later. Currently, I'm working with Nico on a tool to generate real 3D subtitles, with the depth of each individual subtitle retrieved from the MVC stream.
slavanap
9th April 2014, 14:23
I see. Actually, if you need a depth of the place in a frame to where the subtitle should be placed, it simply might be extracted via motion estimation, for instance. I'm familiar with it.
r0lZ
9th April 2014, 15:00
Good to know. Currently, we are only using the 3D-planes embedded in the MVC stream. They contain exactly what we need. But a tool to generate the depth values automatically without relying on an existing 3D-plane could be useful. We'll let you know if we need that...
slavanap
9th April 2014, 15:29
Also, this tool that's already available, might be useful for you (try to find motion between the views):
http://compression.ru/video/motion_estimation/index_en.html
P.S. It might be useful to set max vertical motion to ~4% of frame height, and max horizontal motion to ~12% of frame width.
moamoa
13th April 2014, 18:27
Hi
I am able to rip my 3D blurays to SBS fine.
Two questions though.
1. Current it converts to 1920x1080 SBS. Can it do 3840x1080 SBS? If so, what do I do to get that.
2. Audio. If the sound is 7.1 HD DTS. Can I mix it down to 5.1 DTS, so my AMP can handle it?
Thanks :)
r0lZ
13th April 2014, 20:01
1. Currently, Full-SBS is not supported. However, you can modify the AVS script yourself and remove the two "HorizontalReduceBy2" commands. The original line:
StackHorizontal(HorizontalReduceBy2(Left), HorizontalReduceBy2(Right))
should be replaced with:
StackHorizontal(Left, Right)
However, I do not recommend to encode in full-SBS (or full T&B) because that format is not supported by most TVs and by many software 3D players. Furthermore, it is not possible to convert the subtitles to 3D when the output format is full-SBS or full-T&B. Therefore, you will have to remove the subtitles or use only the 2D subs. (See the subtitle option in tab 2.)
2. Yes. Tick the DTS-HD core option in tab 2.
moamoa
14th April 2014, 12:27
1. Currently, Full-SBS is not supported. However, you can modify the AVS script yourself and remove the two "HorizontalReduceBy2" commands. The original line:
StackHorizontal(HorizontalReduceBy2(Left), HorizontalReduceBy2(Right))
should be replaced with:
StackHorizontal(Left, Right)
However, I do not recommend to encode in full-SBS (or full T&B) because that format is not supported by most TVs and by many software 3D players. Furthermore, it is not possible to convert the subtitles to 3D when the output format is full-SBS or full-T&B. Therefore, you will have to remove the subtitles or use only the 2D subs. (See the subtitle option in tab 2.)
2. Yes. Tick the DTS-HD core option in tab 2.
Thanks you.
Re the 3D, that worked good. I will be using the files with a Pivos XS media player which will take 3840 SBS and convert that to framepacked output to projector, so I think for me, it will be perfect.
Re the DTS-HD, does ticking the box not just add the DTS-HD 7.1 track (from the ISO) to the file? My amp will not handle that, so need it converted to DTS 5.1 (older format). Are you saying tick the box, converts it it 5.1? This is what I need.
Nico8583
14th April 2014, 16:41
DTS-HD tracks are composed with a DTS Core (older format like you say) and a lot of data to make the track HD. So when you tick the box, you tell to the soft to extract and keep only DTS core, so there is no conversion but you get DTS 5.1 track ;)
r0lZ
14th April 2014, 17:20
Yes, Nico is right. Just tick the box, and the stream should be compatible with your hardware.
(But afaik, a DTS HD track is read by the old players that do not understand the HD format as the "older format", and they should see only the 5.1 core. DTS-HD is supposed to be backward compatible, so I don't understand why you need to convert it to 5.1. That option is mainly there for peoples who do not want to include a very heavy HD track and prefer the lighter 5.1 core, but IMO it should never be necessary to tick it for compatibility reasons. I guess the problem comes from your media player that "knows" DTS-HD and sends the 7.1 channels to your projector in decoded form. Probably the projector cannot handle 7.1 channels and fails. IMO, the media player should have an option to use only the core, and send the 5.1 channels to the output. Can you confirm that?)
Nico8583
14th April 2014, 18:34
After read and discuss a lot with some people and experts, I think DTS is the best choice for most of users. DTS-HD is necessary only if you have a huge and expensive HC installation with a dedicated room. DTS-HD costs useless disk space, IMO...
r0lZ
14th April 2014, 19:49
I fully agree. My point is that DTS-HD should be playable with a "normal" DTS decoder, but of course, in that case, the HD part of the stream is totally useless, and the 5.1 core is largely sufficient.
Nico8583
14th April 2014, 20:20
Yes, DTS-HD should be playable on any player with a DTS decoder ;)
moamoa
14th April 2014, 21:37
Yes, Nico is right. Just tick the box, and the stream should be compatible with your hardware.
(But afaik, a DTS HD track is read by the old players that do not understand the HD format as the "older format", and they should see only the 5.1 core. DTS-HD is supposed to be backward compatible, so I don't understand why you need to convert it to 5.1. That option is mainly there for peoples who do not want to include a very heavy HD track and prefer the lighter 5.1 core, but IMO it should never be necessary to tick it for compatibility reasons. I guess the problem comes from your media player that "knows" DTS-HD and sends the 7.1 channels to your projector in decoded form. Probably the projector cannot handle 7.1 channels and fails. IMO, the media player should have an option to use only the core, and send the 5.1 channels to the output. Can you confirm that?)
I can confirm this works fine. Don't know what I did wrong :/ first time.
One little issue, which is easy to work around. When you make the backup with MakeMKV the files is puts in the the directory;
ISO\Movie Name\BDMV\STREAM\SSIF
Are named like;
00021.ssif.smap
I need to manually go into these and rename them;
00021.ssif
Before the tool will pick up the ISO directory as valid. Be handy if it recognised these... oh, and the option so keep 3840 for SBS in the GUI.. But both these are easy to workaround. So thank you! excellent tool !!! :)
r0lZ
14th April 2014, 23:23
For the smap extension, I don't think I can do something. The external tools called by my program need a standard BDMV structure, and I have no way to force them to consider the smap files. I don't know why MakeMKV creates that non-standard files, but the workaround should be a fix in MakeMKV, not in my program. However, if you wish, I can perhaps write a little tool to rename all files from a specific BDMV\STREAM\SSIF folder to automatically remove the .smap extension. Then, you should be able to open the BD folder without problem. But you will not be able to easily restore the .smap extension, if that's necessary for any reason.
For the Full-SBS/T&B, it's not so simple. As I wrote above, the 3D subtitles are incompatible with that format (due to a limitation in the SUB/IDX file format) and I will have to modify the GUI to take the new format into account, and prohibit to include 3D subtitles when Full-SBS or T&B has been selected. I'm not sure it's a good idea. But I will see what I can do...
slavanap
14th April 2014, 23:58
moamoa, r0lZ,
Just a tip:
rem This .bat file creates hardlinks for smap files. pls, check whether it works on your Windows version.
cd BDMV\STREAM\SSIF\
for %%f in (*.smap) do mklink /H %%~nf %%f
pause
r0lZ
15th April 2014, 08:07
Nice idea! MkLink should work with Windows 7 or greater. And since BD3D2MK3D requires at least Win7, I'll implement that trick.
Of course, it won't work if the source directory is a mounted ISO. Someone can confirm that the .smap files are illegal in a real BD and therefore that a working ISO must have regular ssif files?
Nico8583
15th April 2014, 08:12
I have tried MakeMKV and .smap, and rename files to ssif seems to not be sufficient. .smap files are about few kilobytes, not like real ssif files. On MakeMKV forum, there is a (Linux ?) script to rebuild SSIF files from .smap and it's not a simple rename, AFAIK...
r0lZ
15th April 2014, 08:17
(But afaik, a DTS HD track is read by the old players that do not understand the HD format as the "older format", and they should see only the 5.1 core. DTS-HD is supposed to be backward compatible, so I don't understand why you need to convert it to 5.1. That option is mainly there for peoples who do not want to include a very heavy HD track and prefer the lighter 5.1 core, but IMO it should never be necessary to tick it for compatibility reasons. I guess the problem comes from your media player that "knows" DTS-HD and sends the 7.1 channels to your projector in decoded form. Probably the projector cannot handle 7.1 channels and fails. IMO, the media player should have an option to use only the core, and send the 5.1 channels to the output. Can you confirm that?)
Someone pointed me to this explanation about TrueHD and AC3 (https://trac.bunkus.org/wiki/FAQ%3ATrueHDAndAC3). I guess a similar explanation apply to DTS-HD and DTS. And if it's the case, that explains why the "HD core" option must be ticked in BD3D2MK3D if you want to mux an audio file compatible with the old DTS decoders (and similarly for the AC3 core). It's a pity that MKV has such a limitation, but unfortunately it's a fact.
I wonder if I should remove that option and apply the extraction of the core anyway, since when the option is unticked, the final MKV file may contain DTS-HD or TrueHD streams that are incompatible with most players. Someone has a good reason to keep that option?
Nico8583
15th April 2014, 08:18
Not for me, I make all my MKV with core only, I don't have sufficient installation to keep HD audio
r0lZ
15th April 2014, 08:27
OK. I think I'll leave that option, but I'll add a warning when the user unticks it to explain that the resulting track will be incompatible with most players.
Thalyn
9th May 2014, 08:05
So it's been a little while since I've gone through my 3D collection, but a thought occurred to me the other night while correcting a subtitle issue: instead of a normal bilinear resize, would a weighted resize or even straight-up discarding scanlines work out better?
Essentially I had a play with full-size 3D frames. PotPlayer (my software of choice), however, renders these such that they look identical to half-OU as it applies a resize filter before interleaving the rows for each eye. The results are fine, but I can't help wondering if they could be better - particularly on angles very near horizontal. In essence I would attempt to retain different detail with each eye, rather than the same detail, in an effort to produce a "better" result.
The idea is to either A) de-interlace both eyes, then weave the even lines of the left (remembering video starts at row 0) and odd lines of the right, thus relying on the human brain to "fill in" the missing lines (I suspect this is how PowerDVD and its ilk work anyway when using a passive display), or B) apply some kind of offset reduction that gives preference to every second line (25/50/25 weighting) instead of equal preference to pairs (50/50 weighting). The scripts, just off the top of my head (modifications welcome) would be something like the following (keeping in mind these assume that you've already decided whether AVC is Left or Right):
#Method A
Left = SeparateFields (Left)
Left = SelectEven (Left)
Right = SeparateFields (Right)
Right = SelectOdd (Right)
Return StackVertical (Left, Right)
#Method B (I suspect I have the wrong syntax here, but hopefully enough of the idea is apparent to get what I'm on about)
Left = Left.BilinearRezise (Left.Width, Left.Height / 2, 0, -0.5)
Right = Right.BilinearResize (Right.Width, Right.Height / 2, 0, 0.5)
Return StackVertical (Left, Right)
Obviously, Method A would give the best results when displayed on a passive 1080p screen if that's indeed the way PowerDVD and the like work on the same display. However it's effectively throwing away half the available detail and I question whether this is actually going to be noticeable in the event a display with sufficient resolution is used to view it - either a 2160p passive or any 1080p+ active. Method B, on the other hand, attempts to retain that detail in the same way as a basic resize does in such a way that the two eyes still see slightly different results without wasting anything, theoretically giving better "effective" resolution regardless of the display in use.
Some quick testing suggests (to me) that Method B is viable but I only have a passive screen to test it on (and haven't performed thorough analysis of the results as yet). But for others who might have considered and/or tried it, is this something worth looking into or am I just trying to find a solution where there isn't a problem to begin with?
I'm not sure I understand your point. I don't know PotPlayer, and therefore I don't know what it does with 3D videos, but it should display the 2 views in such a way that the 3D rendering hardware can display them correctly. Apparently, your hardware requires interleaved scanlines. Right? And, if I understand correctly, you suggest that instead of doing a standard resize to divide the height of the 2 views by 2, it could be better to discriminate one every 2 scanlines, and keep only the even scanlines for the left eye and the odd ones for the right eye. Still correct? IMO, there are two problems with that idea.
The left and right views are different (except when the objects are exactly "on the surface of the screen"). Therefore, with your method, the left eye will see only the even scanlines, and the right eye only the odd scanlines. IMO, that may create a flickering effect, that can be very unpleasant.
The second problem is that removing the scanlines can, in some cases (such as during the end credits), remove some very important information, such as thin horizontal lines. If the same thin line is kept on the other view, that will also create obvious differences in the left and right views, and that differences are difficult to "understand" by your brain. That may be also an unpleasant effect.
But I agree that your idea is not bad, and I encourage you to test it. (Unfortunately, I have only a 3D active Samsung TV, and I can't test it myself.) Take in mind, however, that that method is only suitable for a very specific hardware, and will probably give extremely bad results if the movie is displayed on hardware that is not suitable, such as an active 3D TV. You may have to throw away all your encodes when you will buy a new TV!
Note also that in the past, before the 3D blu-ray technology, there has been some 3D-DVDs using a technique similar to your idea. I have some of them, and I have converted them to T&B. The idea was to store the left view in the even scanlines and the right view in the odd ones. Since DVDs are in standard PAL or NTSC format, they are interlaced by nature, and therefore the left and right views are displayed alternately, at 50 or 59.94 fields per seconds. It is therefore sufficient to synchronize the active shutter glasses with the AC power to hide the right field for each eye. Of course, the quality of these 3D-DVDs was not good, because the remaining vertical resolution is extremely limited (240 scanlines per field in NTSC!) But that worked!
Final tech note: I haven't verified, but you may have to add the AssumeFieldBased() instruction at the beginning of your script for method A. And the BilinearResize() used in script B does NOT simply remove scanlines. BilinearResize() is a fast resize, but it merges the scanlines together, and you cannot obtain what you want. Perhaps it's possible with PointResize, but I don't know how to force it to select the right scanlines.
Thalyn
9th May 2014, 14:07
Yeah, I use a 1080p passive screen with row-based separation. Somehow I forgot to mention that.
The fine lines you mention was something I had considered but not specifically with Method A. The prospect of detail which exists on one eye but not the other, especially with a slow "crawl" that causes it to alternate could be quite horrid. I'd have to experiment with it, but I can see that being a dealbreaker with how it could potentially interact with active 3D (not that I have any intention of ever using it, but you never know for certain).
Method B wasn't so much to discard every second line but rather to merge them in with lower weighting. So instead of having lines A, B, C, and D become A + B, C + D for both eyes, you'd get A + 50% B, 50% B + C + 50% D for the left and 50% A + B + 50% C, 50% C + D + 50% E and so forth for the right. This would still potentially have "crawl" but it would be significantly reduced.
I guess all I can really do is experiment, but I need to figure out how exactly to do the weighted resize properly; assuming I haven't accidentally gotten it right.
*update*
Testing with The Immortals:
Discarding scanlines entirely is off the table. The results had even more noticeable edges than using a traditional resize, along with fairly pronounced crawl on moving horizontal edges. While perfectly watchable it was clearly worse than the easier alternative. Not only that but it was slower (approximately 85% of the speed) and created a larger file (42% larger) making it worse in pretty much every way.
Attempting to use a weighted merge, however, was very nearly the same speed (97% as fast as a straight reduction) and produced a file only slightly bigger (roughly 4%). As to whether it's worth it? Hard to tell. Those are small enough increases that it's worth further experimentation, but I'll need to figure out a better way to evaluate it than "Yeah, that doesn't look terrible" when ultimately I can say the same of either reduction technique. Some light crawling was evident on credits (to be fair, this is also evident with normal vertical reduction) but nothing during the movie seemed to show anything.
The reduction I applied used the following code, based on the description of the "ReduceBy2" command:
Left = MergeChroma (Left.BilinearResize (Left.Width, Left.Height / 2, 0, 0.5), \
Left.BilinearResize (Left.Width, Left.Height / 2, 0, 1))
Right = MergeChroma (Right.BilinearResize (Right.Width, Right.Height / 2, 0, -0.5), \
Right.BilinearResize (Right.Width, Right.Height / 2, 0, -1))
I'm only assuming that's providing me with the 25%/50%/25% weighting I'm after, with the left and right using offsets 1 pixel apart for the 50% lines, but that's purely a guess and I could use some input from someone more knowledgeable on how BilinearResize works.
*Update 2*
Found a work-around for not being able to pick my resizing kernel, by way of the following:
Left = Blur (Left, 0, 1)
Left = SeparateRows (Left, 2)
Left = SelectEven (Left)
Right = Blur (Right, 0, 1)
Right = SeparateRows (Right, 2)
Right = SelectOdd (Right)
Ultimately that applies a 25/50/25 blur to the entire frame, then picks out alternating scanlines for the left and right eye, which theoretically gives exactly the same results as what I'm after. In fact, the Left view there should be identical to using the VerticalReduceBy2 command. I have no idea whether that's the most efficient way to do it or not but quick testing suggests that it's still within spitting distance (less than 4% difference) of a traditional resize. I'll have to run a more extensive test to compare filesizes but that's a 2 hour job and I want to do stuff with my system right now.
As for the results? Still very, very hard to tell. Comparing a 2D frame this method gives better output (less soft) than a more traditional bilinear resize (even one using a 25/50/25 kernel), especially when subtitles are concerned, though obviously still inferior to the source image. But when comparing in 3D? The results are definitely very good but I can't definitively say that they're better; though I can't say that they're any worse, either.
*Final update*
Well, I've had an opportunity to do a full run and... I'm still not convinced that I'm looking at a solution to a problem that even exists. Does it work? Yes. Is it any better? Well... I know I like the results and plan on using this method going forward, but without the ability to see a live comparison between the two I can't say it's actually worthwhile. I'm not prepared to call it a bust but I think anyone who's been following my experiment can be safe in the knowledge that I haven't completely changed the playing field.
Final results for this particular stream (Immortals) put the filesize at roughly 105% of a standard bilinear resize, however the speed was only around 91% of normal; though I may have skewed that slightly with multitasking at the time. The speed difference isn't entirely unexpected but I have no way of determining whether the increased filesize is from more detail retention or simply worse compression due to the frame packing not optimising as well with the variations I've introduced.
pommesmatte
12th May 2014, 13:20
r0lz, you said you are working on a method for the real depth in 3D subtitles?
How soon do you think you may be successful?
I will then postpone some of my encodings. :)
Very soon. I have already successfully encoded 3 BDs with the subtitles at the right depth. However, I don't want to release the new version immediately, because there are still some bugs to fix, and I need more time to verify that everything works as expected.
In fact, I'm working on that part with Nico8583. He has already almost finished an exe to extract the 3D-planes from the MVC streams, but I've just discovered a bug that must be fixed. Since Nico is currently doing a little trip, that cannot be fixed before the middle of this week.
Nico is also working on the exe to convert the PNG images of the subtitle stream (previously converted to XML/PNG format) to 3D, but there is a big problem with the transparency of the background, and he is still searching for a solution. On my side, I did the same work with ImageMagick, and that works perfectly well, but it's very slow. I still don't know if I will release the new version of BD3D2MK3D with my method, or if I will wait for a solution for Nico's method. I may release my method soon, and replace it with Nico's exe when it will be ready.
Anyway, I can't release it before Wednesday or Thursday. Please be patient...
Nico8583
13th May 2014, 22:05
I'm here :) I'm going to fix bugs now ;)
As promised, here is v0.35 of BD3D2MK3D (http://download.videohelp.com/r0lZ/BD3D2AVS/BD3D2MK3D.7z).
# v0.35 (May 14, 2014)
# - The subtitles are now converted to 3D using the depth information from the 3D-planes of the MVC stream.
# - Added a tool to extract the 3D-planes from the MVC demuxed stream. Thanks Nico8583!
# - Added a tool to convert subtitles to 3D using the individual depths from the 3D-plane.
# - It is now possible to include both 2D and 3D versions of the subtitles in the final MKV file.
# - Added a tool and an option to convert the DTS and WAV files to AC3
# - Uses now mpls_dump.exe to list and filter the MPLS files when the BD is opened.
# - Fix for the missing SSIF files when processing a BD folder created by MakeMKV.
# - The program now remembers the last directory used when loading or saving the tags from tab 3.
# - Updated MkvMerge and x264 to their latest versions.
The main improvement is the conversion of the subtitles to 3D using now the "real depth" extracted from the 3D-planes of the original BD. As a consequence, the previous "Subtitle Depth" setting has been removed and is now replaced with a new "Additional Depth" setting. Normally, that setting can be left to 0, but sometimes the 3D subtitles are too close to the objects of the 3D image and it might be necessary to "unstick" them somewhat. You can set the additional depth to a small value such as 1 or 2 to do exactly that.
If you have an existing BD3D2MK3D project (with the original MVC and SUP files), you can convert the SUP file to real 3D using the two new tools available in the Tools menu. Just be sure to overwrite the 3D IDX/SUB files with the new conversion, and mux the MKV file again (with _MUX_3D.cmd).
The quality and precision of the depth of the 3D subtitles converted with the new method depend greatly of the 3D-plane of the original BD. Some planes are not very well defined, and may give relatively bad results. However, usually, the result is much better than when an arbitrary fixed depth is used, like with the previous versions.
Note that currently, the conversion of each individual 2D subtitle is made using ImageMagick (convert.exe) and is somewhat slow. I hope Nico will find a solution for the opaque background bug of his tool. If it's possible, the conversion should take much less time with his exe.
Huge thanks to Nico8583 for MVCPlanes.exe. As far as I know, that exe is now bug free, and can extract the 3D-Planes from the MVC stream much faster than the original tool that I wrote some time ago in Tcl/Tk. Thanks Nico! :-)
As usual, the latest version of BD3D2MK3D can be downloaded here: BD3D2MK3D.7z (http://download.videohelp.com/r0lZ/BD3D2AVS/BD3D2MK3D.7z)
Please report any bug or problem you may encounter with the new 3D subtitle conversion method. Thanks in advance.
Nico8583
14th May 2014, 14:13
You're welcome, and thanks r0lZ for your help and your good software ;)
mini-moose
15th May 2014, 11:55
that new 3D subs feature sounds nice!
I was wondering - what happens if you just use the .sup extracted from the blu-ray instead of converting it to vobsub? Does the sup file contain the depth info needed or that comes from the 3d structure.
Many players have no issues playing the sup files as is, as long as they are muxed in. mkvmerge also applies a compression on them, so they only take about 1/2 their actual size.
vBulletin® v3.8.11, Copyright ©2000-2026, vBulletin Solutions Inc.