Re: Clarification for ObjectReferenceVariabl

Andreas Kraft (kraft@fokus.gmd.de)
Thu, 12 Mar 1998 14:50:35 +0100 (MET)

Emmanuel,

On Tue, 10 Mar 1998, Emmanuel BEUQUE wrote:

> À (At) 17:37 +0100 10/03/98, Andreas Kraft écrivait (wrote) :
>
> I based my opinion on reading 5.3, 50.1, and 51.

Please, see my previous mail.

> To me, it seems difficult for an engine to build a reference to an object
> that is not prepared. That's the aim of so many provisions of use of MHEG
> actions.

No, that is not a problem. At least in our implementation an ObjectRef is just
a string/integer value combination. It some kind of late binding mechanism.
Otherwise, an action like "TransitionTo" would not be possible to implement...

> I assume that the problem is the same when giving a value to an
> ObjectRefVar, either by OrigValue or by SetVariable. I know that 25 doesn't
> specify that the new variable value shall reference an available object but
> I always prefered to consider this.

Yes, consistency is always a good idea.

> What if the ingredient do not exist ?
> And if some think that it is not allowed, what do they do when a shared
> ObjectRefVar reference an ingredient in a scene and the scene is destroyed ?

Very good question.
I can't think for a reason not to allow this. A variable is just a container
in the first place. The value in the variable need not to be valid at every
time. This depends on the usage. It should be handled as always: if the target
is not valid then disregard the action.

After thinking about it, I would like to suggest to explicitly allow
Applications to have ObjectRefVariables pointing to Ingredients in a Scene.

One example: I want to activate a specific bitmap in a scene during the startup
of the scene. Which bitmap is activated depends on some other things done
before in another scene. I can store the calculated ObjectReference in a shared
variable in the application which is used in the started scene to activate
the bitmap.
Here, I need a variable in the Application which points to an Ingredient in
a Scene.

What do think? Is there really a reason to disallow this?

Andreas

--
  o  _     Andreas Kraft
 (\_|_)      GMD FOKUS, kraft@fokus.gmd.de, +49 30 3463-7232
 T> ] [        The sky is the limit