[M4IF Technotes] Directly Call Conditional

Christian Weigel christian.weigel epost.de
Sun Oct 27 11:11:10 EST 2002


Hi Nicholas,
Did you try this:
AT 2100 {
	REPLACE Media1GoSmall.activate BY TRUE
}
I tried it and it worked.
Regards 
Christian
Nicholas Smit wrote:
> Hi experts.
> 
> Is there any way to directly call a conditional?
> 
> What I would like to do is something like : 
> 
> AT 2100 { CALL Media1GoSmall.activate	}
> 
> But of course I know one can only REPLACE, INSERT AND DELETE. 
> 
> 
> 
> As a work around at the moment I have: 
> 
> DEF TS1 TouchSensor { 	enabled false 	} 	
> DEF Go ROUTE TS1.enabled_changed to TS1.Media1GoBig.activate
> 
> 
> #"call" first event....
> AT 1000 { 
> 	REPLACE TS1.enabled by true 
> } 
> 
> #insert next event....
> AT 2000 { 
> 	REPLACE Route Go by TS1.enabled_changed to 
> Media1GoSmall.Activate 
> 	Replace TS1.enabled by False
> } 
> 
> #trigger the event....
> AT 2100 { 	
> 	REPLACE TS1.enabled by True 		
> }
> 
> 
> But I've noticed there seems to be a latency introduced by 
> the event queue, hence the 2100.  Sometimes the triggering 
> event can be introduced as little as 10 milliseonds after the 
> new event has been introduced, but othertimes the player will 
> crash, or ignore it.  100ms seems to work fine though... But 
> that's not great. 
> 
> There must be a better means to directly call a conditional...?
> 
> Thanks!
> 
> Nik.
> 
> _______________________________________________
> Technotes mailing list
> Technotes   lists.m4if.org 
> http://lists.m4if.org/mailman/listinfo/technot> es
> 



More information about the Mp4-tech mailing list