/*
* @author Valentin Simonov / http://va.lent.in/
*/
using TouchScript.Core;
using TouchScript.Pointers;
namespace TouchScript.InputSources
{
///
/// An object which represents an input source.
///
///
/// In TouchScript all pointer points () come from input sources.
/// If you want to feed pointers to the library the best way to do it is to create a custom input source.
///
public interface IInputSource : INTERNAL_IInputSource
{
///
/// Gets or sets current coordinates remapper.
///
/// An object used to change coordinates of pointer points coming from this input source.
ICoordinatesRemapper CoordinatesRemapper { get; set; }
///
/// This method is called by to synchronously update the input.
///
bool UpdateInput();
///
/// Forces the input to update its state when resolution changes.
///
void UpdateResolution();
///
/// Cancels the pointer.
///
/// The pointer.
/// if set to true returns the pointer back to the system with different id.
/// True if the pointer belongs to this Input and was successfully cancelled; false otherwise.
bool CancelPointer(Pointer pointer, bool shouldReturn);
}
///
/// Internal methods for . DO NOT USE ANY OF THEM!
///
public interface INTERNAL_IInputSource
{
///
/// Used by to return a pointer to input source.
/// DO NOT CALL IT DIRECTLY FROM YOUR CODE!
///
/// The pointer.
void INTERNAL_DiscardPointer(Pointer pointer);
}
}