Merge "Sensor: Add batch support for native applications" into nyc-dev

am: 9c2e644

* commit '9c2e6448b1c7c9d0a28bb6ac47b44bc6c8797ffe':
  Sensor: Add batch support for native applications
This commit is contained in:
Aniroop Mathur
2016-03-17 18:29:39 +00:00
committed by android-build-merger

View File

@@ -105,6 +105,14 @@ int ASensorManager_destroyEventQueue(ASensorManager* manager,
/*****************************************************************************/
int ASensorEventQueue_registerSensor(ASensorEventQueue* queue, ASensor const* sensor,
int32_t samplingPeriodUs, int maxBatchReportLatencyUs)
{
return static_cast<SensorEventQueue*>(queue)->enableSensor(
static_cast<Sensor const*>(sensor)->getHandle(), samplingPeriodUs,
maxBatchReportLatencyUs, 0);
}
int ASensorEventQueue_enableSensor(ASensorEventQueue* queue, ASensor const* sensor)
{
return static_cast<SensorEventQueue*>(queue)->enableSensor(