Home | History | Annotate | Download | only in input

Lines Matching refs:batch

418                         ALOGD("channel '%s' consumer ~ consumed batch event, seq=%u",
446 Batch& batch = mBatches.editItemAt(batchIndex);
447 if (canAddSample(batch, &mMsg)) {
448 batch.samples.push(mMsg);
450 ALOGD("channel '%s' consumer ~ appended to batch event",
455 // We cannot append to the batch in progress, so we need to consume
456 // the previous batch right now and defer the new message until later.
459 batch, batch.samples.size(), outSeq, outEvent);
465 ALOGD("channel '%s' consumer ~ consumed batch event and "
473 // Start a new batch if needed.
477 Batch& batch = mBatches.editTop();
478 batch.samples.push(mMsg);
480 ALOGD("channel '%s' consumer ~ started batch event",
513 Batch& batch = mBatches.editItemAt(i);
515 result = consumeSamples(factory, batch, batch.samples.size(),
525 ssize_t split = findSampleNoLaterThan(batch, sampleTime);
530 result = consumeSamples(factory, batch, split + 1, outSeq, outEvent);
532 if (batch.samples.isEmpty()) {
536 next = &batch.samples.itemAt(0);
548 Batch& batch, size_t count, uint32_t* outSeq, InputEvent** outEvent) {
554 InputMessage& msg = batch.samples.editItemAt(i);
567 batch.samples.removeItemsAt(0, count);
811 // Send finished signals for the batch sequence chain first.
841 // Send finished signal for the last message in the batch.
863 const Batch& batch = mBatches.itemAt(i);
864 const InputMessage& head = batch.samples.itemAt(0);
935 bool InputConsumer::canAddSample(const Batch& batch, const InputMessage *msg) {
936 const InputMessage& head = batch.samples.itemAt(0);
951 ssize_t InputConsumer::findSampleNoLaterThan(const Batch& batch, nsecs_t time) {
952 size_t numSamples = batch.samples.size();
955 && batch.samples.itemAt(index).body.motion.eventTime <= time) {