Académique Documents
Professionnel Documents
Culture Documents
Purpose This lesson will walk through a simple example of determining which
button the user picked from an interactive menu that contains several
buttons. We will also demonstrate how to use the branching object and
virtual machine commands to only play those chapters of interest in two
different video title sets.
Definitions
DLP DVD Lab Pro
VTS Video Title Set
GPMR General Purpose Memory Registers
SPMR System Memory Registers
Empty PGC Program chain that does not contain
any cells but only VM commands.
Sometimes referred to as a pass-
thru PGC.
VM Virtual Machine (instructions)
PTT Part of Title User Defined Chapter
in a movie
We renamed it to clarify
it’s purposed in this design.
DVD Lab Pro
Button Processing Programming in VM
Lesson #2
Page 6 of 8
• (lines 1,2) The player will put into SPRM8 the last highlited button in multiples of 1024
decimal. Thus button one is stored as 1024decimal and button two = 2048decimal, etc. . We
will need to compare the same way. Note that you can enter in the decimal value and DLP
will convert to hex.
• (lines3-17) The VM command JumpTT only allows comparison by ‘indirect’, meaning, you
can only compare one GPRM to another GPRM. You cannot compare to a ‘direct value’ like
1024 or 2048 etc. So what we will do is used GPRM1 and change its value before doing a
compare. So, having eight buttons we will need to do eight comparisons.
• (line 18) As a default, we will link back to the VMG menu. Just in case we hosed ourself
and forget to check for a certain button.
• The ‘quicklink’ button is essential for VM programming in DLP. To successfully jump to a
PGCN, you must know the number assigned to it by DLP. It is not necessary the sequential
number displayed with the object. Use the ‘quicklink’ button to ensure you will call the
correct PGCN. DLP will fill in the VM code whereever the cursor is located in the edit
window.
Completed VM command:
DVD Lab Pro
Button Processing Programming in VM
Lesson #2
Page 8 of 8
There are always pitfalls whenever hardcoding in VM. In this example, if you add or take away
titles (movies) in the VTS’, chances are the PGCNs will need to be updated in the VMG VM
object. The JumpTT’s are hard-code using a snapshot of the network at the time of creation. If
you make changes (awl-sheets ☺ ) you must go back and examine your JumpTTs.
You could have just as easily used the button linking tool to link each button to the appropriate
branching object and accomplished the same thing. And in someways, it is much easier to do and
manage down the road. Everything is graphical and easy to understand 6 months down the road.
In this example I purposely left out the return links for all the branching objects in VTS1. What
will occur if you left them out? Will the player lock up or do something else? (hint: IFOedit will
help you find the answer!)
Also, I would like to acknowledge ‘markham’ and ‘moonman’ from the mmbforums with their
VM programming expertise and mentoring. What they shared with me is documented in this
lesson. Thanks guys!