View Full Version : Learning to play with GPRMs
Metallo
2nd January 2006, 16:58
Hi guys...
...happy New Year to all :)
I'm trying to understand how GPRMs work, therefore the first basic question I have is the following:
I created a simple DVD containing a Title Menu, 4 RootMenus and 1 title, just to play around.
I opened the VOB in PGCEdit, this is what appears when selecting the First-Play PGC:
********** pre commands:
1 Set gprm(11) =(mov) 0
2 Set gprm(13) =(mov) 65535
3 Set gprm(14) =(mov) 0
4 (JumpSS) Jump to VMGM PGC 2
********** post commands:
********** cell commands:
I know that GPRMs are 16, but what does every number correspond to?
I mean, 1 Set gprm(11) =(mov) 0 , why is gprm11, why gprm 13 etc?
I really want to understand, but I need to know the corresponding meaning of every of the 16 registers :mad:
I use the Unofficial DVD specs of DVD Replica, but cannot find the meaning in there either.
I guess I miss an important point, that's why I'm asking for your help.
Thank you!
Alex
goonix
2nd January 2006, 17:29
The GPRMs are "General Purpose Registers" so they don't have a special meaning.
They are simply variables you can store numbers in it.
To store a number in one of the GPRMs means nothing.
Only if the DVD program interpreter reads this GPRM later and makes a decision upon the content, it will have a function.
goonix
bigotti5
2nd January 2006, 17:45
mean, 1 Set gprm(11) =(mov) 0 , why is gprm11, why gprm 13 etc?
I guess you use DVDLab pro
DVDLab uses GPRM11-15 itself for its abstraction layer (Help-pdf page 253)
GPRM11 Node, used to link Movie to particular VTS menu and for Menu button highlighting
GPRM12 Used for temporary in−command sequence data storage
GPRM13 Used to identify currently playing play lists
GPRM14 Used as a counter in a Counter and Random list
GPRM15 Used for Return to last menu object
Metallo
2nd January 2006, 17:46
The GPRMs are "General Purpose Registers" so they don't have a special meaning.
They are simply variables you can store numbers in it.
To store a number in one of the GPRMs means nothing.
Only if the DVD program interpreter reads this GPRM later and makes a decision upon the content, it will have a function.
goonix
Goonix,
I agree with you, but if they are 16 registers, each of them must have a purpose, otherwise the instruction above could also be :
********** pre commands:
1 Set gprm(1) =(mov) 0
2 Set gprm(2) =(mov) 65535
3 Set gprm(3) =(mov) 0
4 (JumpSS) Jump to VMGM PGC 2
********** post commands:
********** cell commands:
...but I think there is a reason why the DVD opens with 11, 13 and 14...
Hope my question is clearer now :)
Cheers
Alex
Metallo
2nd January 2006, 18:13
I guess you use DVDLab pro
Correct.
Now I do understand better...
So this is program depending?
Alex
goonix
2nd January 2006, 18:31
Yes, DVDLab may have used GPRM1... 3 too. There is no difference.
These registers have been choosen by DVDLab without a special reason.
Maybe the only reason is, that you can use the lower GPRM numbers for your own programming.
Of course, if you change "Set gprm(13) =(mov) 65535" to "Set gprm(2) =(mov) 65535" you have also to change "If gprm(13) then..." to "If gprm(2) then..." in all places of the DVD.
goonix
lovelegend
3rd January 2006, 08:08
Goonix,
I agree with you, but if they are 16 registers, each of them must have a purpose, otherwise the instruction above could also be :
********** pre commands:
1 Set gprm(1) =(mov) 0
2 Set gprm(2) =(mov) 65535
3 Set gprm(3) =(mov) 0
4 (JumpSS) Jump to VMGM PGC 2
********** post commands:
********** cell commands:
your question sounds like asking why we would choose x, y and z for the axes of a graph... :P
Using your logic, there are 26 alphabets, and if we choose x-axis and y-axis instead of a-axis and b-axis, then x and y must have a special meaning isn't it? :D
gprm is just like a variable in any programming language, the only difference is for like a C program, you can declare 100 or more variables of any name, but in DVD we have only 16 gprm and they're numbered from 0 to 15.
vBulletin® v3.8.11, Copyright ©2000-2026, vBulletin Solutions Inc.