Yes, I already recognized this possibility in case of and prior to video recode.
As for your answer to my question, there's some things I don't understand:
First off, to my knowledge BD3D2MK3D creates 3D subtitles according to already retrieved depth information from the offset planes. So why not directly read the depths from those? The answer probably has to do with me not fully understanding what exact info there is in a 3D-plane.
I gather BD3D2MK3D uses these XML/PNG-files only internally for creating the proper offsets between left- and right-eye subtitle images.
But I am curious how in a 3D-plane the different subtitle offsets are "assigned" to the target SUP images. Where I can only make an educated guess that it is done by lead of timings-information.
Thanks for the link. I will definitely read on it.
Try StreamFab Downloader and download from Netflix, Amazon, Youtube! Or Try DVDFab and copy Blu-rays! or rip iTunes movies!
+ Reply to Thread
Results 451 to 464 of 464
Thread
-
-
The XML/PNG file is an intermediate step, that 's right. I need the PNG to convert the PNGs to 3D. But I've decided to write the <depth> tags in the XML for two reasons.
1. The user may want to modify the PNG images, for example to change their contrast or luminosity. Of course, the PNG/XML must be the source of the new conversion, and it is easier for the user if he doesn't need to specify again the 3D-plane to use.
2. But the main reason is that it is easy to edit the depth values in the XML to fix some wrong depth values. And in that case, the 3D-plane cannot be used, or it will overwrite the depths modified by the user. Therefore, the depth values must be stored in the XML.
I agree that it is not obvious that the depths can be modified, as usually, the whole conversion is made in one step, during the preparation of the project. But the XML/PNG stream is not deleted at the end of the conversion, to let the user edit it and convert it again to the final subtitle stream, and remux the final MKV. It's a possibility for a power user, like many other features of BD3D2MK3D. BTW, it's also why there are many comments in the text files of the projects generated by BD3D2MK3D.
Not exactly. The MVC video stream is made of GOPs (groups of pictures), just like the AVC stream. The 3D-planes are stored as SEI messages, within the MVC stream. It is divided in as many small parts as they are GOPs in the video, and stored in the message of the corresponding GOP, so that the player can receive the information just when it needs it, to display the frames of the GOP and the 3D subtitle (if any) correctly. So, in each of these parts, there is one depth value per video frame. For example, if a GOP is made of, say, 40 frames, there will be 40 depth values stored in the corresponding part of the 3D-plane. Note that it's always the case, even if there is no subtle to display during the GOP (but in that case, the depth values can be undefined).
My explanation above takes only one 3D-plane into account, but the BD specs specifies that there can be up to 32 3D-planes, for 32 different subtitle streams (although the same 3D-plane can be assigned to several subtitle streams.) And usually, all 32 3D-planes are specified, but most of them are totally undefined, or contain always the same depth value, and are therefore useless.
So, what BD3D2MK3D does is just extract the 3D-planes from the MVC (and concatenate the different parts to obtain complete 3D-planes with as many depth values as there are frames in the whole movie), then it analyses the XML of the subtltle stream to know when each subtitle starts and ends, then it converts that timings to frame numbers, and it retrieves the depth values for that frames. The final depth is then selected among the different depth values corresponding to the subtitle (because, often, the depth of the subtitle changes during its display, for example because there is a cut in the video, possibly with an important change of depth of the whole scene). The final depth value is then written in the XML, and finally, the conversion of the XML/PNG to 3D can really begin!
In the explanation above, I have used the usual term "3D-plane" instead of the correct term "offset sequence". Similarly, "depth" is used instead of "3D offset" or "offset value". But the processing doesn't depend on the terminology!r0lZ - PgcEdit homepage Hosted by VideoHelp (Thanks Baldrick)
- BD3D2MK3D A tool to convert 3D BD to 3D SBS/T&B/FS MKV -
Hi
I need a way to output the left eye and right eye separately then put them back together again. I'm hoping there is something I can modify in the encode_3D script. -
What type of frame do you need ? Full-size, or halved for HSBS or HTAB ? And why do you need to save the two views alone ? How would you like to recombine them ? To do what type of 3D video ?
r0lZ - PgcEdit homepage Hosted by VideoHelp (Thanks Baldrick)
- BD3D2MK3D A tool to convert 3D BD to 3D SBS/T&B/FS MKV -
Full sized TAB. I have a movie with one eye that has raised black levels. I would like to fix that then recombine them. I found a way to split the two eyes after encoding and maybe that's the best option. Although I'm not quite sure how I would re-combine them. I suppose I couldn't just replace:
left = SelectEven(interleaved)
right = SelectOdd(interleaved)
with
left = left.mkv
right = right.mkv
I think I will have to use ffmpeg to recombine them or hopefully I can just use mkvtoolnix. -
You can use the two MKV as input, that's right (although the command is not correct) but the problem is that you will need te encode the video three times: the first time to create the two MKV, the second to fix the luminosity, and the third time to join the two parts. That means a significant quality loss! It's because, unfortunately, you cannot use ffmpeg or mkvtoolnix to recombine the two views. They must be re-encoded.
IMO, the best method would be to edit the original avisynth script to add the command necessary to fix the bad eye, and then encode the full movie directly from the BD3D2MK3D project. You will need only one encoding. You should add a command like this in the script:
right = Levels (right, parameters)
(This is just an example. You may need another command, or several commands).
The difficulty with avisynth is that it is not easy to see the result. Luckilly, AvsPmod comes to the rescue. You can load the two views in two tabs, and add the command(s) necessary to fix the problem in the tab with the bad eye. Then, you can modify the parameters of the command freely, and compare the result with the good view by switching from one tab to the other one. When you have a good result, simply copy the command in the avs script in the project, and encode it normally.
Note that to load a MKV in an avisynth script, you will need to install the ffmpegsource avisynth plugin and use this command:
FFMpegSource2("path/to/movie.mkv")
This will create the default stream called "last". If you need to name it differently, use this:
left = FFMpegSource2("path/to/movie.mkv")
There are probably other plugins or commands that can load a MKV, but I know and use only this one.
I agree that learning how to use avisynth is not easy and requires some time, but you will certainly get a much better result than if you re-encode the movie several times. And there is a lot of knowledgeable peoples able to help you in the avisynth dedicated forums here or at doom9.
Good luck!Last edited by r0lZ; 5th Oct 2023 at 07:52.
r0lZ - PgcEdit homepage Hosted by VideoHelp (Thanks Baldrick)
- BD3D2MK3D A tool to convert 3D BD to 3D SBS/T&B/FS MKV -
Thanks. I was hoping for a simple solution but the more I read, the more I realized it wasn't going to be so. In the end I used ffmpeg for almost everything. I split the BD3D2MK3D encoded movie into two mkv files, then I changed the levels on the problem eye. I think both of these were effectively lossless because the file sizes were almost identical. Then I used ffmpeg to join and re-encode the two mkv files. Finally I used mkvtoolnix to fix the resolution and re-add the original audio.
If I have to do this again I might add extra ffmpeg commands to deal with the audio at the same time, or maybe I will remove the audio first then re-combine later. It would have been nice to be able to use the raw files created by BD3D2MK3D so that when complete it could mux them back together but I can't see any obvious way to do that. Thanks againLast edited by cdx47; 5th Oct 2023 at 08:00.
-
If you know already ffmpeg, you can probably use a ffmpeg plugin to insert the ffmpeg command in the avisynth script instead of the Levels () command, like explained in my previous post. That may be easier for you.
And honestly, I don't think that ffmpeg is able to split the two views without re-encoding them, but I may be wrong. It's possible for JPEG images (with some limitations), but MPEG videos are much more complex.
If you want to redo (almost) the same processing without using ffmpeg to split the two views, you can simply edit the avs script in the folder, like this:
Code:interleaved = FRIMSource("mvc", "00009.track_4113.264", "00009.track_4114.mvc", layout = "alt", num_frames = 18668, cache = 2, platform = "") right = SelectEven(interleaved) left = SelectOdd(interleaved) return(left) __END__ (the rest of the script is ignored)
r0lZ - PgcEdit homepage Hosted by VideoHelp (Thanks Baldrick)
- BD3D2MK3D A tool to convert 3D BD to 3D SBS/T&B/FS MKV -
Excellent! This might form the basis of being able to semi-automate it in future. I know very little about ffmpeg lol, but I used the "FFMPEG Filters Document" reference site to work out what the commands I found were doing. Then I modified them for my needs.
BTW looking at the bit-rates they are definitely lower in the ffmpeg re-encoded movie even though visually it looks pretty much identical on a large screen. But I agree with you about the potential for quality loss. So it occurs to me that if I do need to do anything like this in the future I will try to use the ripped disc as the source with ffmpeg all the way. At least that way I'm starting from the original source.Last edited by cdx47; 5th Oct 2023 at 08:26.
-
I had another look and yes the file is encoded 3 times. The results are fine and looks about the same as the original, but the completist in me is not happy. So I tested creating the left/right eyes from a frame-packed rip using CRF16 which is identical to the version I created with your tool and that works. So I can use that option to at least remove one generation of potential quality loss. But I'm going to try the AVS method to create the left and right eyes and maybe even try to modify the brightness of one eye.
Edit: I created a test file using the Tweak command in the avs file for the left eye without having to separately export left and right eye files. Seems to work which means everything gets done in one go using a modified version of your script. If you don't hear from me again then it worksLast edited by cdx47; 13th Oct 2023 at 17:25.
-
Perfect.
Have you used AvsPmod to fine-tune the effect?r0lZ - PgcEdit homepage Hosted by VideoHelp (Thanks Baldrick)
- BD3D2MK3D A tool to convert 3D BD to 3D SBS/T&B/FS MKV -
Nope, never heard of it but I wish I did lol. I just used a previous example you gave me to create very short output files then modded the mux file to only mux the picture. I will download AvsPmod because it could be very useful. I can imagine that I want transform an image or a particular eye in the future.
I've learned a lot over the last few years looking at your batch and avisynth scripts as well as the json filesLast edited by cdx47; 5th Oct 2023 at 17:49.
-
r0lZ - PgcEdit homepage Hosted by VideoHelp (Thanks Baldrick)
- BD3D2MK3D A tool to convert 3D BD to 3D SBS/T&B/FS MKV -
Hi r0lZ,
A short thanks for your crystal clear explanations. The SEI messaging for each GOP took a lot of clouds away.
I am now reading up on the "h264Offset3D.exe" tool which indeed seems the thing right up my street.
Will keep it short as I don't intend on further pollution of this thread.
Similar Threads
-
bd3d2mk3d and half-SBS or half-tab issue
By Scarredjoker in forum Blu-ray RippingReplies: 81Last Post: 30th Nov 2019, 07:23 -
How do I convert 3D SBS MKV H265 to 3D SBS MKV H264?
By vidhenry in forum Video ConversionReplies: 5Last Post: 21st Jan 2018, 18:13 -
Extract/convert/ripp/copy u name it 3D blueray iso to mkv sbs
By dannydevito in forum Blu-ray RippingReplies: 0Last Post: 19th Jan 2016, 04:47 -
3D Bluray to SBS MKV on OS X
By ddregs in forum Blu-ray RippingReplies: 1Last Post: 7th Jan 2016, 16:10 -
How to convert a Top-Bottom mkv-file to SBS
By ErwinForum in forum Video ConversionReplies: 0Last Post: 17th Feb 2015, 07:18