This signal is emitted by the InfiniteApiControllerInterface when the following occurs.
The 3djuump infinite API features an internal clock that sets the pace of the whole API : objects are updated at
fixed intervals (all at once).
The InfiniteApiControllerInterfaceSignal.Tick signal is sent at the end of the modification of the objects.
Beware, the DisplayDone signal is not sent just after the update of the objects, but when
the image content is displayed on the view (window.requestAnimationFrame).
If you want to synchronize a behavior when the objects are updated, then use Tick.
If you want to synchronize a behavior when the display is updated, then use DisplayDone.
/** * Sample to illustrate the use of signals in the InfiniteApiControllerInterface and InfiniteEngineInterface. */ import { InfiniteApiControllerInterfaceSignal, InfiniteEngineInterface, InfiniteApiControllerInterface, InfiniteFactory, InfiniteEngineInterfaceSignal } from'generated/documentation/appinfiniteapi';
// what to do when the display is updated ? constonDisplayUpdated = () : void=> { console.log('display has just been updated'); }
// what to do when the objects are updated ? constonObjectUpdated = () : void=> { console.log('infinite objects have just been updated'); }
// the InfiniteEngineInterface has been created previously letlInfiniteEngine : InfiniteEngineInterface;
// the api controller interface (no need to create it, it is available !) constlControllerInterface : InfiniteApiControllerInterface = InfiniteFactory.GetInfiniteApiController();
// register callbacks on Tick and DisplayDone lControllerInterface.addEventListener(InfiniteApiControllerInterfaceSignal.Tick, onObjectUpdated); lInfiniteEngine.addEventListener(InfiniteEngineInterfaceSignal.DisplayDone, onDisplayUpdated);
Please refer to [InfiniteApiControllerInterface](../interfaces/InfiniteApiControllerInterface.html) for more information.
The InfiniteApiControllerInterfaceSignal lists all the signals that may be sent by the InfiniteApiControllerInterface.
This signal is emitted by the InfiniteApiControllerInterface when the following occurs. The 3djuump infinite API features an internal clock that sets the pace of the whole API : objects are updated at fixed intervals (all at once). The InfiniteApiControllerInterfaceSignal.Tick signal is sent at the end of the modification of the objects.
Beware, the DisplayDone signal is not sent just after the update of the objects, but when the image content is displayed on the view (
window.requestAnimationFrame).If you want to synchronize a behavior when the objects are updated, then use Tick.
If you want to synchronize a behavior when the display is updated, then use DisplayDone.
Please refer to [InfiniteApiControllerInterface](../interfaces/InfiniteApiControllerInterface.html) for more information.
See