Lines Matching refs:channel

101 void SoundPool::addToRestartList(SoundChannel* channel)
105 mRestart.push_back(channel);
110 void SoundPool::addToStopList(SoundChannel* channel)
114 mStop.push_back(channel);
134 SoundChannel* channel;
135 ALOGV("Getting channel from stop list");
137 channel = *iter;
140 if (channel != 0) {
142 channel->stop();
149 SoundChannel* channel;
150 ALOGV("Getting channel from list");
152 channel = *iter;
155 if (channel != 0) {
157 channel->nextEvent();
241 SoundChannel* channel;
258 // allocate a channel
259 channel = allocateChannel_l(priority, sampleID);
261 // no channel allocated - return 0
262 if (!channel) {
263 ALOGV("No channel allocated");
269 ALOGV("play channel %p state = %d", channel, channel->state());
270 channel->play(sample, channelID, leftVolume, rightVolume, priority, loop, rate);
277 SoundChannel* channel = NULL;
279 // check if channel for given sampleID still available
283 channel = *iter;
285 ALOGV("Allocated recycled channel for same sampleID");
291 // allocate any channel
292 if (!channel && !mChannels.empty()) {
295 channel = *iter;
297 ALOGV("Allocated active channel");
302 if (channel) {
303 channel->setPriority(priority);
309 mChannels.insert(iter, channel);
311 return channel;
314 // move a channel from its current position to the front of the list
315 void SoundPool::moveToFront_l(SoundChannel* channel)
318 if (*iter == channel) {
320 mChannels.push_front(channel);
330 SoundChannel* channel = findChannel(channelID);
331 if (channel) {
332 channel->pause();
341 SoundChannel* channel = &mChannelPool[i];
342 channel->autoPause();
350 SoundChannel* channel = findChannel(channelID);
351 if (channel) {
352 channel->resume();
361 SoundChannel* channel = &mChannelPool[i];
362 channel->autoResume();
370 SoundChannel* channel = findChannel(channelID);
371 if (channel) {
372 channel->stop();
374 channel = findNextChannel(channelID);
375 if (channel)
376 channel->clearNextEvent();
383 SoundChannel* channel = findChannel(channelID);
384 if (channel) {
385 channel->setVolume(leftVolume, rightVolume);
393 SoundChannel* channel = findChannel(channelID);
394 if (channel) {
395 channel->setPriority(priority);
403 SoundChannel* channel = findChannel(channelID);
404 if (channel) {
405 channel->setLoop(loop);
413 SoundChannel* channel = findChannel(channelID);
414 if (channel) {
415 channel->setRate(rate);
420 void SoundPool::done_l(SoundChannel* channel)
422 ALOGV("done_l(%d)", channel->channelID());
424 if (channel->nextChannelID() != 0) {
426 addToRestartList(channel);
432 moveToFront_l(channel);
643 ALOGE("Sample channel count (%d) out of range", numChannels);
685 ALOGV("channel %d stolen - event queued for channel %d", channelID(), nextChannelID);
729 // mToggle toggles each time a track is started on a given channel.
803 ALOGV("stolen channel has no event");
815 ALOGV("Starting stolen channel %d -> %d", channelID(), nextChannelID);
821 SoundChannel* channel = static_cast<SoundChannel*>((void *)((unsigned long)user & ~1));
823 channel->process(event, info, (unsigned long)user & 1);
838 ALOGV("process wrong toggle %p channel %d", this, mChannelID);
887 ALOGV("process %p channel %d event %s",
892 ALOGV("End loop %p channel %d", this, mChannelID);
894 ALOGV("process %p channel %d NEW_IAUDIOTRACK", this, mChannelID);