Log in

View Full Version : subtitle question


M!ro
10th November 2004, 01:02
just a quick one. if i have
[71 00 00 0E 00 45 00 00] Set gprm(14) =(mov) 69
and then
[41 00 00 00 8E 00 00 00] (SetSTN) Set Sub-picture stream = gprm(14)

what exactly do i get in the end? i mean, which subtitle number this selects? according to dvd shrink list, this would select subtitle #6. so when using SetSTN with gprm, gprms are starting from 64 for first subtitle stream? can someone confirm this?

2COOL
10th November 2004, 01:20
Originally posted by M!ro

[71 00 00 0E 00 45 00 00] Set gprm(14) =(mov) 69
gprm(14) will be assigned the decimal value of 69


[41 00 00 00 8E 00 00 00] (SetSTN) Set Sub-picture stream = gprm(14)sprm(2) will now be assigned the decimal value of grpm(14) so sprm(2) = 69

what exactly do i get in the end? i mean, which subtitle number this selects?Subtitle #6

according to dvd shrink list, this would select subtitle #6. so when using SetSTN with gprm, gprms are starting from 64 for first subtitle stream?DVD Shrink is correct and you are also too for the starting 64 value. Also if sprm(2) = 0 then no subtitles will display.

can someone confirm this? OK. confirmed. ;)

blutach
10th November 2004, 01:37
@2COOL - Bit confused here.

I thought SPRM(2) has to be 62 (and then add 128) (ie 0xBE) to be off?

2COOL
10th November 2004, 01:46
Originally posted by blutach
@2COOL - Bit confused here.

I thought SPRM(2) has to be 62 (and then add 128) (ie 0xBE) to be off? I was working on a DVD earlier with a subtitle menu with 4 options

Subp 1: English
[51 04 00 00 C0 00 00 09] (SetSTN) Set Sub-picture stream = 0, on ; LinkPGCN PGC 9

Subp 2: French
[51 04 00 00 C1 00 00 09] (SetSTN) Set Sub-picture stream = 1, on ; LinkPGCN PGC 9

Subp 3: Espanol
[51 04 00 00 C2 00 00 09] (SetSTN) Set Sub-picture stream = 2, on ; LinkPGCN PGC 9

None

Upon viewing the sprm(2) after selection...

English > sprm(2)= 64
French > sprm(2) = 65
Espanol > sprm(2) = 66
None > sprm(2) = 0

I tested other DVDs other and yielded the same results.

blutach
10th November 2004, 02:03
So why is this the command to turn all subbies off?

[51 00 00 00 BE 00 00 00] 7 (SetSTN) Set Sub-picture stream = 62:none
Regards

2COOL
10th November 2004, 02:14
Originally posted by blutach
So why is this the command to turn all subbies off?

[51 00 00 00 BE 00 00 00] 7 (SetSTN) Set Sub-picture stream = 62:none
Regards You are right. sprm(2)=62 can also turn off subtitles. I found in my testings that if no selection is made in the subtitle menu, sprm(2) will hold a value of 0 during Title play. By default, sprm(2) should be 0 upon DVD insert.

Edit: hmmm...let me get back to you on sprm(2). I'll see if I can get a reference.

Update: Default sprm(2) is 62.

blutach
10th November 2004, 02:21
My reference is 2COOL's guide on turning off subbies (hosted by rolz)

r0lZ
10th November 2004, 02:45
In SetSTN, the value you use is the number of the subtitle (ie 0 to 31, or 62 for none selected, or 63 for forced) + 0x40 to turn the subtitle ON.
You MUST also set the bit 7 (0x80) to instruct SetSTN to change the subtitle assignment.
Valid values are therefore:
128 to 159: Select subtitle 0-31 but don't turn it on.
192 to 223: Select subtitle 0-31, and turn it on.
190: Don't select any subtitle (leave the player decide)
255: Set forced subtitle

When playing, the SPRM 2 will hold the same value ORed with 0x7F (ie, bit 7 is turned off):
0 to 31: Subtitle 0-31 selected but not displayed.
64 to 95: Subtitle 0-31 displayed.
62: Player decide.
127: Forced subtitle.

The value 69 is therefore: Subtitle 5 displayed.

2COOL
10th November 2004, 03:01
[edit]

blutach
10th November 2004, 03:04
Here were mpucoder's thoughts:

Stream 31 is not "off", it is just very unlikely that it will be present. There can be as many as 32 subpicture streams, numbered from 0 to 31 (0x00 to 0x1f, or substream numbers 0x20 to 0x3f). The designation for "off" is stream 62 (ox3e, combined with the required flag to cause the new value to be stored is 0xbe).
I know IfoEdit is messed up in its interpretation, and we had a long thread about the values. Since that was awhile ago, it bears repeating.
value meaning
00-7f will do nothing, bit 7 must be set to cause any change
80-9f stream 0 to 31 selected, but off
a0-bd meaningless
be no subpicture
bf stream 0 forced, but off - ie, invalid
c0-df stream 0 to 31 selected and displayed
e0-fe meaningless
ff stream 0 forced and displayed.

r0lZ
10th November 2004, 03:13
Exactly what I said, but in hexadecimal! ;)

blutach
10th November 2004, 03:15
Yes, except for 62. You have said "let the player decide" while mpucoder has said "no subbie".

:confused:

r0lZ
10th November 2004, 03:20
He is right... and wrong. When 'not set', the player may take the decision to select and turn on a subpic, based on the user's preferences. This is why it is best to use a stream explicitely turned off (values 128 to 159) to be sure the player won't select one.

2COOL
10th November 2004, 03:30
Originally posted by r0lZ
The value 69 is therefore: Subtitle 5 displayed. I stand corrected.

SPRM(2)'s Value When Setting SubPictures (SetSTN)

Selected but OFF (not displayed)

[51 00 00 00 80 00 00 00] (SetSTN) Set Sub-picture stream = 0, off sprm(2) = 0
[51 00 00 00 81 00 00 00] (SetSTN) Set Sub-picture stream = 1, off sprm(2) = 1
[51 00 00 00 82 00 00 00] (SetSTN) Set Sub-picture stream = 2, off sprm(2) = 2
[51 00 00 00 83 00 00 00] (SetSTN) Set Sub-picture stream = 3, off sprm(2) = 3
[51 00 00 00 84 00 00 00] (SetSTN) Set Sub-picture stream = 4, off sprm(2) = 4
[51 00 00 00 85 00 00 00] (SetSTN) Set Sub-picture stream = 5, off sprm(2) = 5
[51 00 00 00 86 00 00 00] (SetSTN) Set Sub-picture stream = 6, off sprm(2) = 6
[51 00 00 00 87 00 00 00] (SetSTN) Set Sub-picture stream = 7, off sprm(2) = 7
[51 00 00 00 88 00 00 00] (SetSTN) Set Sub-picture stream = 8, off sprm(2) = 8
[51 00 00 00 89 00 00 00] (SetSTN) Set Sub-picture stream = 9, off sprm(2) = 9
[51 00 00 00 8A 00 00 00] (SetSTN) Set Sub-picture stream = 10, off sprm(2) = 10
[51 00 00 00 8B 00 00 00] (SetSTN) Set Sub-picture stream = 11, off sprm(2) = 11
[51 00 00 00 8C 00 00 00] (SetSTN) Set Sub-picture stream = 12, off sprm(2) = 12
[51 00 00 00 8D 00 00 00] (SetSTN) Set Sub-picture stream = 13, off sprm(2) = 13
[51 00 00 00 8E 00 00 00] (SetSTN) Set Sub-picture stream = 14, off sprm(2) = 14
[51 00 00 00 8F 00 00 00] (SetSTN) Set Sub-picture stream = 15, off sprm(2) = 15
[51 00 00 00 90 00 00 00] (SetSTN) Set Sub-picture stream = 16, off sprm(2) = 16
[51 00 00 00 91 00 00 00] (SetSTN) Set Sub-picture stream = 17, off sprm(2) = 17
[51 00 00 00 92 00 00 00] (SetSTN) Set Sub-picture stream = 18, off sprm(2) = 18
[51 00 00 00 93 00 00 00] (SetSTN) Set Sub-picture stream = 19, off sprm(2) = 19
[51 00 00 00 94 00 00 00] (SetSTN) Set Sub-picture stream = 20, off sprm(2) = 20
[51 00 00 00 95 00 00 00] (SetSTN) Set Sub-picture stream = 21, off sprm(2) = 21
[51 00 00 00 96 00 00 00] (SetSTN) Set Sub-picture stream = 22, off sprm(2) = 22
[51 00 00 00 97 00 00 00] (SetSTN) Set Sub-picture stream = 23, off sprm(2) = 23
[51 00 00 00 98 00 00 00] (SetSTN) Set Sub-picture stream = 24, off sprm(2) = 24
[51 00 00 00 99 00 00 00] (SetSTN) Set Sub-picture stream = 25, off sprm(2) = 25
[51 00 00 00 9A 00 00 00] (SetSTN) Set Sub-picture stream = 26, off sprm(2) = 26
[51 00 00 00 9B 00 00 00] (SetSTN) Set Sub-picture stream = 27, off sprm(2) = 27
[51 00 00 00 9C 00 00 00] (SetSTN) Set Sub-picture stream = 28, off sprm(2) = 28
[51 00 00 00 9D 00 00 00] (SetSTN) Set Sub-picture stream = 29, off sprm(2) = 29
[51 00 00 00 9E 00 00 00] (SetSTN) Set Sub-picture stream = 30, off sprm(2) = 30
[51 00 00 00 9F 00 00 00] (SetSTN) Set Sub-picture stream = 31, off sprm(2) = 31

Subpictures OFF (Not displayed)(Default setting)

[51 00 00 00 BE 00 00 00] (SetSTN) Set Sub-picture stream = 62:none sprm(2) = 62


Selected and ON (displayed)

[51 00 00 00 C0 00 00 00] (SetSTN) Set Sub-picture stream = 0, on sprm(2) = 64
[51 00 00 00 C1 00 00 00] (SetSTN) Set Sub-picture stream = 1, on sprm(2) = 65
[51 00 00 00 C2 00 00 00] (SetSTN) Set Sub-picture stream = 2, on sprm(2) = 66
[51 00 00 00 C3 00 00 00] (SetSTN) Set Sub-picture stream = 3, on sprm(2) = 67
[51 00 00 00 C4 00 00 00] (SetSTN) Set Sub-picture stream = 4, on sprm(2) = 68
[51 00 00 00 C5 00 00 00] (SetSTN) Set Sub-picture stream = 5, on sprm(2) = 69
[51 00 00 00 C6 00 00 00] (SetSTN) Set Sub-picture stream = 6, on sprm(2) = 70
[51 00 00 00 C7 00 00 00] (SetSTN) Set Sub-picture stream = 7, on sprm(2) = 71
[51 00 00 00 C8 00 00 00] (SetSTN) Set Sub-picture stream = 8, on sprm(2) = 72
[51 00 00 00 C9 00 00 00] (SetSTN) Set Sub-picture stream = 9, on sprm(2) = 73
[51 00 00 00 CA 00 00 00] (SetSTN) Set Sub-picture stream = 10, on sprm(2) = 74
[51 00 00 00 CB 00 00 00] (SetSTN) Set Sub-picture stream = 11, on sprm(2) = 75
[51 00 00 00 CC 00 00 00] (SetSTN) Set Sub-picture stream = 12, on sprm(2) = 76
[51 00 00 00 CD 00 00 00] (SetSTN) Set Sub-picture stream = 13, on sprm(2) = 77
[51 00 00 00 CE 00 00 00] (SetSTN) Set Sub-picture stream = 14, on sprm(2) = 78
[51 00 00 00 CF 00 00 00] (SetSTN) Set Sub-picture stream = 15, on sprm(2) = 79
[51 00 00 00 D0 00 00 00] (SetSTN) Set Sub-picture stream = 16, on sprm(2) = 80
[51 00 00 00 D1 00 00 00] (SetSTN) Set Sub-picture stream = 17, on sprm(2) = 81
[51 00 00 00 D2 00 00 00] (SetSTN) Set Sub-picture stream = 18, on sprm(2) = 82
[51 00 00 00 D3 00 00 00] (SetSTN) Set Sub-picture stream = 19, on sprm(2) = 83
[51 00 00 00 D4 00 00 00] (SetSTN) Set Sub-picture stream = 20, on sprm(2) = 84
[51 00 00 00 D5 00 00 00] (SetSTN) Set Sub-picture stream = 21, on sprm(2) = 85
[51 00 00 00 D6 00 00 00] (SetSTN) Set Sub-picture stream = 22, on sprm(2) = 86
[51 00 00 00 D7 00 00 00] (SetSTN) Set Sub-picture stream = 23, on sprm(2) = 87
[51 00 00 00 D8 00 00 00] (SetSTN) Set Sub-picture stream = 24, on sprm(2) = 88
[51 00 00 00 D9 00 00 00] (SetSTN) Set Sub-picture stream = 25, on sprm(2) = 89
[51 00 00 00 DA 00 00 00] (SetSTN) Set Sub-picture stream = 26, on sprm(2) = 90
[51 00 00 00 DB 00 00 00] (SetSTN) Set Sub-picture stream = 27, on sprm(2) = 91
[51 00 00 00 DC 00 00 00] (SetSTN) Set Sub-picture stream = 28, on sprm(2) = 92
[51 00 00 00 DD 00 00 00] (SetSTN) Set Sub-picture stream = 29, on sprm(2) = 93
[51 00 00 00 DE 00 00 00] (SetSTN) Set Sub-picture stream = 30, on sprm(2) = 94
[51 00 00 00 DF 00 00 00] (SetSTN) Set Sub-picture stream = 31, on sprm(2) = 95

Subpicture 0 is forced to display. The value of 63 is called a Dummy Stream value.

[51 00 00 00 FF 00 00 00] (SetSTN) Set Sub-picture stream = 63:forced sprm(2) = 127

blutach
10th November 2004, 03:35
Really confused now :confused: :confused: :confused: :confused: :confused:

r0lZ
10th November 2004, 03:36
You must turn the forced subpic ON, so last line should be:

[51 00 00 00 FF 00 00 00] (SetSTN) Set Sub-picture stream = 63:forced sprm(2) = 127

r0lZ
10th November 2004, 03:38
Originally posted by blutach
Really confused now :confused: :confused: :confused: :confused: :confused: Just play with the SetSTN GUI in PgcEdit: you'll understand...

2COOL
10th November 2004, 03:42
Originally posted by r0lZ
You must turn the forced subpic ON, so last line should be:

[51 00 00 00 FF 00 00 00] (SetSTN) Set Sub-picture stream = 63:forced sprm(2) = 127 Ooop!:o. Everything is correct now and can be used as a solid reference. thanks again r0lZ! ;) I was meaning to document that for a long time now. It just keeps getting bump down my TODO list. :(

blutach
10th November 2004, 03:43
@rolz

Does this mean that we want the forced stream on in every instance?

By forced stream, I understand this to mean, the occasional subtitles that display (such as the Japanese subbies in Kill Bill 1?) as opposed to the full dialogue. Is this correct?

Regards

2COOL
10th November 2004, 03:50
Originally posted by blutach
Does this mean that we want the forced stream on in every instance?

By forced stream, I understand this to mean, the occasional subtitles that display (such as the Japanese subbies in Kill Bill 1?) as opposed to the full dialogue. Is this correct? I feel like I'm 0-2 now but here is goes.

[51 00 00 00 FF 00 00 00] (SetSTN) Set Sub-picture stream = 63:forced sprm(2) = 127

This will only force subpicture 0. It's actually the first subpicture. Can't confirm with Kill Bill 1 but the Japanese subs aren't Subp 0, then it won't show them. I hope I read your question right.

blutach
10th November 2004, 04:00
Sorry 2COOL - By Japanese subbies, I meant, the English subbies shown when the Japanese folks are talking in Japanese. Obviously, this isn't throughout the whole flick. The main English subbies would be what we would select if we wanted to see the whole dialogue.

I just wanted to confirm (or otherwise) my understanding, that these occasional subbies are the "forced stream". I also wonder whether we will need to identify them (maybe they are the 3rd English stream after normal English and English for Hearing Impaired) and turn them on or whether using the code in your last post does the trick?

I thought I knew this stuff re subbies :(

2COOL
10th November 2004, 04:14
Originally posted by blutach
I also wonder whether we will need to identify them (maybe they are the 3rd English stream after normal English and English for Hearing Impaired) and turn them on or whether using the code in your last post does the trick?:( With the tools we have now, it's hard to figure which one is the "forced" stream with the English translation only. You would have to trial and error like I usually done with toggling the subs in IfoEdit and seeing what displays. When the trace function is out, you'll really get to see what gprm(2)'s value is showing and it will definitely tell you what sub stream is playing according to my reference.

blutach
10th November 2004, 04:25
Subrip is a pretty useful prog in finding out what's what in the zoo - particularly for small streams that could be candidates for those "overlay (forced?)" subbies.

Regards and thnx 2 all

2COOL
10th November 2004, 04:45
Originally posted by blutach
Subrip is a pretty useful prog in finding out what's what in the zoo - particularly for small streams that could be candidates for those "overlay (forced?)" subbies. IMHO, you're doing extra work just to find out which subs is the one you need. The way r0lZ has been spewing put new versions in quick time, you'll see his trace function in awe soon!

M!ro
10th November 2004, 08:51
2COOL, r0lZ, thx a lot for clearing this up to me! I got little confused with those numbers but now i got it :)

r0lZ
10th November 2004, 09:43
I still wonder if the 'forced' subpic has to be subpic 0. In the subtitle attributes, there is a special coding called 'forced caption'. If you define, for example, subpic 2 to be the forced caption, it seems logical to use subpic 2 whenever a "(SetSTN) Set Sub-picture stream = 63:forced" command is encountered.

@blutach
Yes, the 'forced' caption is the one used, for example, when you watch a movie with audio translated in your native language, but things like text appearing at some places in the movie must be translated with subtitles.

blutach
11th November 2004, 07:30
@rolz - thanks for that. In that case, you'd always want the forced stream to be on, yes?

r0lZ
11th November 2004, 11:49
Originally posted by blutach
@rolz - thanks for that. In that case, you'd always want the forced stream to be on, yes? I suppose so. But of course it's up to you.

IMHO, when I watch an american movie translated in french, I don't like to see a forced subtitle each time the image includes some text somewhere. But I need the forced subtitle when watching a japanese anime!

Also, as you said, forced subtitles are often used to translate audio that has not been translated in your native language.

blutach
11th November 2004, 13:27
@rolz

Looks like it's one of those - "play to test" things.

But in movies like Kill Bill 1 and Last Samurai where there is lots of forign languages sub-titles (and any other DVD, I suppose), I suspect the forced stream needs to be set.

Regards

Anime
23rd November 2007, 07:19
hello i'm wondering...
how am i possible to do DVD(w/o)sub + few custom subtitle to below ex: english, chinese S, chinese T
__________________________________
automatic setstn = 0 if just acess to DVD >> i know
"BUT" if the user switch subtitle inside video to =1
if he return to menu and select the video again do not setstn=0 if he already have "cookie" >> i don't know

errrrrr, sorry for my misuse of terms =D

~thanks
Rick