Performance Considerations for the StylusInput APIs
Performance Considerations for the StylusInput APIs |
Description of ways to enhance performance when using the StylusInput application programming interfaces (APIs).
The following list describes some ways in which to improve the performance of applications that use the StylusInput APIs.
- Use the IStylusSyncPlugin.DataInterest or IStylusAsyncPlugin.DataInterest property to subscribe only to the data that is relevant to your plug-in. This reduces the overall number of method calls the RealTimeStylus object makes and also reduces the complexity of your plug-in.
- Minimize the complexity of synchronous plug-ins. Synchronous plug-ins generally run on the RealTimeStylus object's thread and may contribute to delays in ink collection.
- Consider making your plug-in asynchronous. If your plug-in is complex and needs to add custom data to the RealTimeStylus object's queue, consider using a cascaded RealTimeStylus model and adding the plug-in to the secondary RealTimeStylus object's synchronous plug-in collection. For more information about the cascaded RealTimeStylus model, see The Cascaded RealTimeStylus Model.