View Single Post
Old 25th October 2016, 11:44   #1094  |  Link
r0lZ
PgcEdit daemon
 
r0lZ's Avatar
 
Join Date: Jul 2003
Posts: 7,469
I have verified point 2 and you're right. The \pos(x,y) version is always correct, but the right view of the margin version is off by one pixel in a specific case. The bug is due to a discrepancy in the way my code rounds the values when the X coordinates are divided by 2 (for Half-SBS). It happens therefore only in Half-SBS mode and when the 3D depth value is odd.

To test the problem, I have created a single SRT subtitle, and converted it without a 3D-Plane, but with the additional depth set to 30 (the maximum). For technical reasons, the additional depth is always divided by two, so the real additional depth is 15, an odd number. In Half-SBS, the subtitle of the left view must therefore be placed at the middle of the left view + half the 3D offset (rounded to the inferior integer): 1920/4+7 = 487. Similarly, the subtitle of the right view must be shifted to the left by half the 3D offset, but this time rounded to the upper integer: 1920/4*3-8 = 1432. That values are correct in the /pos version. For the margin version, the left view is correct. The margins are 28 and 974, and this simple calculation gives the correct result: (1920-28-974)/2+28 = 487. But for the right view, the same margins are used (but of course inverted): 974 and 28. The final position is therefore (1920-974-28)/2+960-28 = 1433, as you can see in the example below. It should be 1432.
Code:
Dialogue: 0,0:00:05.00,0:00:35.00,3D,,28,974,40,,!
Dialogue: 0,0:00:05.00,0:00:35.00,3D,,974,28,40,,!
Dialogue: 0,0:00:35.01,0:01:10.00,3D,,8,968,8,,{\pos(487,1040)}!
Dialogue: 0,0:00:35.01,0:01:10.00,3D,,968,8,8,,{\pos(1432,1040)}!
The right margin values should be 973,29 instead of 974,28 in red above.

I will fix that bug immediately, although it should not be noticeable in normal circumstances. [EDIT: Done.]
Quote:
Originally Posted by konikpolny View Post
I am inclined to use the Margins version anyway.
To avoid the bug, you should use the \pos version instead!
__________________
r0lZ
PgcEdit homepage (hosted by VideoHelp)
BD3D2MK3D A tool to convert 3D blu-rays to SBS, T&B or FS MKV

Last edited by r0lZ; 25th October 2016 at 12:34.
r0lZ is offline