summaryrefslogtreecommitdiffstats
path: root/media
diff options
context:
space:
mode:
Diffstat (limited to 'media')
-rw-r--r--media/libmedia/AudioSystem.cpp2
-rw-r--r--media/libmedia/AudioTrack.cpp30
-rw-r--r--media/libmedia/IAudioFlinger.cpp4
-rw-r--r--media/libmedia/IAudioPolicyService.cpp6
-rw-r--r--media/libmedia/JetPlayer.cpp2
-rw-r--r--media/libmedia/SoundPool.cpp4
-rw-r--r--media/libmedia/ToneGenerator.cpp2
-rw-r--r--media/libmediaplayerservice/MediaPlayerService.cpp4
-rw-r--r--media/libstagefright/AudioPlayer.cpp2
9 files changed, 28 insertions, 28 deletions
diff --git a/media/libmedia/AudioSystem.cpp b/media/libmedia/AudioSystem.cpp
index 2596f07..4c41ba5 100644
--- a/media/libmedia/AudioSystem.cpp
+++ b/media/libmedia/AudioSystem.cpp
@@ -589,7 +589,7 @@ audio_io_handle_t AudioSystem::getOutput(audio_stream_type_t stream,
uint32_t samplingRate,
audio_format_t format,
uint32_t channels,
- audio_policy_output_flags_t flags)
+ audio_output_flags_t flags)
{
const sp<IAudioPolicyService>& aps = AudioSystem::get_audio_policy_service();
if (aps == 0) return 0;
diff --git a/media/libmedia/AudioTrack.cpp b/media/libmedia/AudioTrack.cpp
index 6dc6c41..092b516 100644
--- a/media/libmedia/AudioTrack.cpp
+++ b/media/libmedia/AudioTrack.cpp
@@ -92,7 +92,7 @@ AudioTrack::AudioTrack(
audio_format_t format,
int channelMask,
int frameCount,
- audio_policy_output_flags_t flags,
+ audio_output_flags_t flags,
callback_t cbf,
void* user,
int notificationFrames,
@@ -124,7 +124,7 @@ AudioTrack::AudioTrack(
mPreviousPriority(ANDROID_PRIORITY_NORMAL), mPreviousSchedulingGroup(ANDROID_TGROUP_DEFAULT)
{
mStatus = set((audio_stream_type_t)streamType, sampleRate, (audio_format_t)format, channelMask,
- frameCount, (audio_policy_output_flags_t)flags, cbf, user, notificationFrames,
+ frameCount, (audio_output_flags_t)flags, cbf, user, notificationFrames,
0 /*sharedBuffer*/, false /*threadCanCallJava*/, sessionId);
}
@@ -134,7 +134,7 @@ AudioTrack::AudioTrack(
audio_format_t format,
int channelMask,
const sp<IMemory>& sharedBuffer,
- audio_policy_output_flags_t flags,
+ audio_output_flags_t flags,
callback_t cbf,
void* user,
int notificationFrames,
@@ -174,7 +174,7 @@ status_t AudioTrack::set(
audio_format_t format,
int channelMask,
int frameCount,
- audio_policy_output_flags_t flags,
+ audio_output_flags_t flags,
callback_t cbf,
void* user,
int notificationFrames,
@@ -222,8 +222,8 @@ status_t AudioTrack::set(
// force direct flag if format is not linear PCM
if (!audio_is_linear_pcm(format)) {
- flags = (audio_policy_output_flags_t)
- ((flags | AUDIO_POLICY_OUTPUT_FLAG_DIRECT) & ~AUDIO_POLICY_OUTPUT_FLAG_FAST);
+ flags = (audio_output_flags_t)
+ ((flags | AUDIO_OUTPUT_FLAG_DIRECT) & ~AUDIO_OUTPUT_FLAG_FAST);
}
if (!audio_is_output_channel(channelMask)) {
@@ -735,7 +735,7 @@ status_t AudioTrack::createTrack_l(
audio_format_t format,
uint32_t channelMask,
int frameCount,
- audio_policy_output_flags_t flags,
+ audio_output_flags_t flags,
const sp<IMemory>& sharedBuffer,
audio_io_handle_t output)
{
@@ -761,14 +761,14 @@ status_t AudioTrack::createTrack_l(
// Client decides whether the track is TIMED (see below), but can only express a preference
// for FAST. Server will perform additional tests.
- if ((flags & AUDIO_POLICY_OUTPUT_FLAG_FAST) && !(
+ if ((flags & AUDIO_OUTPUT_FLAG_FAST) && !(
// either of these use cases:
// use case 1: shared buffer
(sharedBuffer != 0) ||
// use case 2: callback handler
(mCbf != NULL))) {
- ALOGW("AUDIO_POLICY_OUTPUT_FLAG_FAST denied");
- flags = (audio_policy_output_flags_t) (flags & ~AUDIO_POLICY_OUTPUT_FLAG_FAST);
+ ALOGW("AUDIO_OUTPUT_FLAG_FAST denied");
+ flags = (audio_output_flags_t) (flags & ~AUDIO_OUTPUT_FLAG_FAST);
}
ALOGV("createTrack_l() output %d afFrameCount %d afLatency %d", output, afFrameCount, afLatency);
@@ -796,7 +796,7 @@ status_t AudioTrack::createTrack_l(
if (mNotificationFramesAct > (uint32_t)frameCount/2) {
mNotificationFramesAct = frameCount/2;
}
- if (frameCount < minFrameCount && !(flags & AUDIO_POLICY_OUTPUT_FLAG_FAST)) {
+ if (frameCount < minFrameCount && !(flags & AUDIO_OUTPUT_FLAG_FAST)) {
// not ALOGW because it happens all the time when playing key clicks over A2DP
ALOGV("Minimum buffer size corrected from %d to %d",
frameCount, minFrameCount);
@@ -817,7 +817,7 @@ status_t AudioTrack::createTrack_l(
if (mIsTimed) {
trackFlags |= IAudioFlinger::TRACK_TIMED;
}
- if (flags & AUDIO_POLICY_OUTPUT_FLAG_FAST) {
+ if (flags & AUDIO_OUTPUT_FLAG_FAST) {
trackFlags |= IAudioFlinger::TRACK_FAST;
}
@@ -1033,7 +1033,7 @@ ssize_t AudioTrack::write(const void* buffer, size_t userSize)
size_t toWrite;
- if (mFormat == AUDIO_FORMAT_PCM_8_BIT && !(mFlags & AUDIO_POLICY_OUTPUT_FLAG_DIRECT)) {
+ if (mFormat == AUDIO_FORMAT_PCM_8_BIT && !(mFlags & AUDIO_OUTPUT_FLAG_DIRECT)) {
// Divide capacity by 2 to take expansion into account
toWrite = audioBuffer.size>>1;
memcpy_to_i16_from_u8(audioBuffer.i16, (const uint8_t *) src, toWrite);
@@ -1190,7 +1190,7 @@ bool AudioTrack::processAudioBuffer(const sp<AudioTrackThread>& thread)
// Divide buffer size by 2 to take into account the expansion
// due to 8 to 16 bit conversion: the callback must fill only half
// of the destination buffer
- if (mFormat == AUDIO_FORMAT_PCM_8_BIT && !(mFlags & AUDIO_POLICY_OUTPUT_FLAG_DIRECT)) {
+ if (mFormat == AUDIO_FORMAT_PCM_8_BIT && !(mFlags & AUDIO_OUTPUT_FLAG_DIRECT)) {
audioBuffer.size >>= 1;
}
@@ -1209,7 +1209,7 @@ bool AudioTrack::processAudioBuffer(const sp<AudioTrackThread>& thread)
}
if (writtenSize > reqSize) writtenSize = reqSize;
- if (mFormat == AUDIO_FORMAT_PCM_8_BIT && !(mFlags & AUDIO_POLICY_OUTPUT_FLAG_DIRECT)) {
+ if (mFormat == AUDIO_FORMAT_PCM_8_BIT && !(mFlags & AUDIO_OUTPUT_FLAG_DIRECT)) {
// 8 to 16 bit conversion, note that source and destination are the same address
memcpy_to_i16_from_u8(audioBuffer.i16, (const uint8_t *) audioBuffer.i8, writtenSize);
writtenSize <<= 1;
diff --git a/media/libmedia/IAudioFlinger.cpp b/media/libmedia/IAudioFlinger.cpp
index 81e259a..2b5126f 100644
--- a/media/libmedia/IAudioFlinger.cpp
+++ b/media/libmedia/IAudioFlinger.cpp
@@ -362,7 +362,7 @@ public:
audio_format_t *pFormat,
audio_channel_mask_t *pChannelMask,
uint32_t *pLatencyMs,
- audio_policy_output_flags_t flags)
+ audio_output_flags_t flags)
{
Parcel data, reply;
audio_devices_t devices = pDevices ? *pDevices : (audio_devices_t)0;
@@ -855,7 +855,7 @@ status_t BnAudioFlinger::onTransact(
audio_format_t format = (audio_format_t) data.readInt32();
audio_channel_mask_t channelMask = (audio_channel_mask_t)data.readInt32();
uint32_t latency = data.readInt32();
- audio_policy_output_flags_t flags = (audio_policy_output_flags_t) data.readInt32();
+ audio_output_flags_t flags = (audio_output_flags_t) data.readInt32();
audio_io_handle_t output = openOutput(module,
&devices,
&samplingRate,
diff --git a/media/libmedia/IAudioPolicyService.cpp b/media/libmedia/IAudioPolicyService.cpp
index 5040bd9..7aab8d6 100644
--- a/media/libmedia/IAudioPolicyService.cpp
+++ b/media/libmedia/IAudioPolicyService.cpp
@@ -124,7 +124,7 @@ public:
uint32_t samplingRate,
audio_format_t format,
uint32_t channels,
- audio_policy_output_flags_t flags)
+ audio_output_flags_t flags)
{
Parcel data, reply;
data.writeInterfaceToken(IAudioPolicyService::getInterfaceDescriptor());
@@ -418,8 +418,8 @@ status_t BnAudioPolicyService::onTransact(
uint32_t samplingRate = data.readInt32();
audio_format_t format = (audio_format_t) data.readInt32();
uint32_t channels = data.readInt32();
- audio_policy_output_flags_t flags =
- static_cast <audio_policy_output_flags_t>(data.readInt32());
+ audio_output_flags_t flags =
+ static_cast <audio_output_flags_t>(data.readInt32());
audio_io_handle_t output = getOutput(stream,
samplingRate,
diff --git a/media/libmedia/JetPlayer.cpp b/media/libmedia/JetPlayer.cpp
index 52aee49..59e538f 100644
--- a/media/libmedia/JetPlayer.cpp
+++ b/media/libmedia/JetPlayer.cpp
@@ -94,7 +94,7 @@ int JetPlayer::init()
AUDIO_FORMAT_PCM_16_BIT,
audio_channel_out_mask_from_count(pLibConfig->numChannels),
mTrackBufferSize,
- AUDIO_POLICY_OUTPUT_FLAG_NONE);
+ AUDIO_OUTPUT_FLAG_NONE);
// create render and playback thread
{
diff --git a/media/libmedia/SoundPool.cpp b/media/libmedia/SoundPool.cpp
index 3b7b96a..4b318ed 100644
--- a/media/libmedia/SoundPool.cpp
+++ b/media/libmedia/SoundPool.cpp
@@ -608,10 +608,10 @@ void SoundChannel::play(const sp<Sample>& sample, int nextChannelID, float leftV
// do not create a new audio track if current track is compatible with sample parameters
#ifdef USE_SHARED_MEM_BUFFER
newTrack = new AudioTrack(streamType, sampleRate, sample->format(),
- channels, sample->getIMemory(), AUDIO_POLICY_OUTPUT_FLAG_NONE, callback, userData);
+ channels, sample->getIMemory(), AUDIO_OUTPUT_FLAG_NONE, callback, userData);
#else
newTrack = new AudioTrack(streamType, sampleRate, sample->format(),
- channels, frameCount, AUDIO_POLICY_OUTPUT_FLAG_NONE, callback, userData,
+ channels, frameCount, AUDIO_OUTPUT_FLAG_NONE, callback, userData,
bufferFrames);
#endif
oldTrack = mAudioTrack;
diff --git a/media/libmedia/ToneGenerator.cpp b/media/libmedia/ToneGenerator.cpp
index c93b6fd..253602d 100644
--- a/media/libmedia/ToneGenerator.cpp
+++ b/media/libmedia/ToneGenerator.cpp
@@ -1024,7 +1024,7 @@ bool ToneGenerator::initAudioTrack() {
AUDIO_FORMAT_PCM_16_BIT,
AUDIO_CHANNEL_OUT_MONO,
0, // frameCount
- AUDIO_POLICY_OUTPUT_FLAG_FAST,
+ AUDIO_OUTPUT_FLAG_FAST,
audioCallback,
this, // user
0, // notificationFrames
diff --git a/media/libmediaplayerservice/MediaPlayerService.cpp b/media/libmediaplayerservice/MediaPlayerService.cpp
index 8bde8f1..7254599 100644
--- a/media/libmediaplayerservice/MediaPlayerService.cpp
+++ b/media/libmediaplayerservice/MediaPlayerService.cpp
@@ -1587,7 +1587,7 @@ status_t MediaPlayerService::AudioOutput::open(
format,
channelMask,
frameCount,
- AUDIO_POLICY_OUTPUT_FLAG_NONE,
+ AUDIO_OUTPUT_FLAG_NONE,
CallbackWrapper,
mCallbackData,
0, // notification frames
@@ -1599,7 +1599,7 @@ status_t MediaPlayerService::AudioOutput::open(
format,
channelMask,
frameCount,
- AUDIO_POLICY_OUTPUT_FLAG_NONE,
+ AUDIO_OUTPUT_FLAG_NONE,
NULL,
NULL,
0,
diff --git a/media/libstagefright/AudioPlayer.cpp b/media/libstagefright/AudioPlayer.cpp
index 0f816e7..468fe2c 100644
--- a/media/libstagefright/AudioPlayer.cpp
+++ b/media/libstagefright/AudioPlayer.cpp
@@ -151,7 +151,7 @@ status_t AudioPlayer::start(bool sourceAlreadyStarted) {
mAudioTrack = new AudioTrack(
AUDIO_STREAM_MUSIC, mSampleRate, AUDIO_FORMAT_PCM_16_BIT, audioMask,
- 0, AUDIO_POLICY_OUTPUT_FLAG_NONE, &AudioCallback, this, 0);
+ 0, AUDIO_OUTPUT_FLAG_NONE, &AudioCallback, this, 0);
if ((err = mAudioTrack->initCheck()) != OK) {
delete mAudioTrack;