Rename (IF_)LOGE(_IF) to (IF_)ALOGE(_IF) DO NOT MERGE
See https://android-git.corp.google.com/g/#/c/157220
Bug: 5449033
Change-Id: Ic9c19d30693bd56755f55906127cd6bd7126096c
diff --git a/media/libmedia/AudioEffect.cpp b/media/libmedia/AudioEffect.cpp
index d74389d..6639d06 100644
--- a/media/libmedia/AudioEffect.cpp
+++ b/media/libmedia/AudioEffect.cpp
@@ -107,7 +107,7 @@
const sp<IAudioFlinger>& audioFlinger = AudioSystem::get_audio_flinger();
if (audioFlinger == 0) {
- LOGE("set(): Could not get audioflinger");
+ ALOGE("set(): Could not get audioflinger");
return NO_INIT;
}
@@ -138,7 +138,7 @@
mIEffectClient, priority, io, mSessionId, &mStatus, &mId, &enabled);
if (iEffect == 0 || (mStatus != NO_ERROR && mStatus != ALREADY_EXISTS)) {
- LOGE("set(): AudioFlinger could not create effect, status: %d", mStatus);
+ ALOGE("set(): AudioFlinger could not create effect, status: %d", mStatus);
return mStatus;
}
@@ -148,7 +148,7 @@
cblk = iEffect->getCblk();
if (cblk == 0) {
mStatus = NO_INIT;
- LOGE("Could not get control block");
+ ALOGE("Could not get control block");
return mStatus;
}
diff --git a/media/libmedia/AudioRecord.cpp b/media/libmedia/AudioRecord.cpp
index c1591a4..2674070 100644
--- a/media/libmedia/AudioRecord.cpp
+++ b/media/libmedia/AudioRecord.cpp
@@ -54,12 +54,12 @@
size_t size = 0;
if (AudioSystem::getInputBufferSize(sampleRate, format, channelCount, &size)
!= NO_ERROR) {
- LOGE("AudioSystem could not query the input buffer size.");
+ ALOGE("AudioSystem could not query the input buffer size.");
return NO_INIT;
}
if (size == 0) {
- LOGE("Unsupported configuration: sampleRate %d, format %d, channelCount %d",
+ ALOGE("Unsupported configuration: sampleRate %d, format %d, channelCount %d",
sampleRate, format, channelCount);
return BAD_VALUE;
}
@@ -153,7 +153,7 @@
}
// validate parameters
if (!audio_is_valid_format(format)) {
- LOGE("Invalid format");
+ ALOGE("Invalid format");
return BAD_VALUE;
}
@@ -177,7 +177,7 @@
(audio_in_acoustics_t)flags,
mSessionId);
if (input == 0) {
- LOGE("Could not get audio input for record source %d", inputSource);
+ ALOGE("Could not get audio input for record source %d", inputSource);
return BAD_VALUE;
}
@@ -292,7 +292,7 @@
if (t != 0) {
if (t->exitPending()) {
if (t->requestExitAndWait() == WOULD_BLOCK) {
- LOGE("AudioRecord::start called from thread");
+ ALOGE("AudioRecord::start called from thread");
return WOULD_BLOCK;
}
}
@@ -472,12 +472,12 @@
&status);
if (record == 0) {
- LOGE("AudioFlinger could not create record track, status: %d", status);
+ ALOGE("AudioFlinger could not create record track, status: %d", status);
return status;
}
sp<IMemory> cblk = record->getCblk();
if (cblk == 0) {
- LOGE("Could not get control block");
+ ALOGE("Could not get control block");
return NO_INIT;
}
mAudioRecord.clear();
@@ -626,7 +626,7 @@
if (ssize_t(userSize) < 0) {
// sanity-check. user is most-likely passing an error code.
- LOGE("AudioRecord::read(buffer=%p, size=%u (%d)",
+ ALOGE("AudioRecord::read(buffer=%p, size=%u (%d)",
buffer, userSize, userSize);
return BAD_VALUE;
}
@@ -709,7 +709,7 @@
status_t err = obtainBuffer(&audioBuffer, 1);
if (err < NO_ERROR) {
if (err != TIMED_OUT) {
- LOGE_IF(err != status_t(NO_MORE_BUFFERS), "Error obtaining an audio buffer, giving up.");
+ ALOGE_IF(err != status_t(NO_MORE_BUFFERS), "Error obtaining an audio buffer, giving up.");
return false;
}
break;
diff --git a/media/libmedia/AudioSystem.cpp b/media/libmedia/AudioSystem.cpp
index 0ef1885..f7f129c 100644
--- a/media/libmedia/AudioSystem.cpp
+++ b/media/libmedia/AudioSystem.cpp
@@ -70,7 +70,7 @@
gAudioFlinger = interface_cast<IAudioFlinger>(binder);
gAudioFlinger->registerClient(gAudioFlingerClient);
}
- LOGE_IF(gAudioFlinger==0, "no AudioFlinger!?");
+ ALOGE_IF(gAudioFlinger==0, "no AudioFlinger!?");
return gAudioFlinger;
}
diff --git a/media/libmedia/AudioTrack.cpp b/media/libmedia/AudioTrack.cpp
index 891e331..d290cd1 100644
--- a/media/libmedia/AudioTrack.cpp
+++ b/media/libmedia/AudioTrack.cpp
@@ -158,7 +158,7 @@
AutoMutex lock(mLock);
if (mAudioTrack != 0) {
- LOGE("Track already in use");
+ ALOGE("Track already in use");
return INVALID_OPERATION;
}
@@ -188,7 +188,7 @@
// validate parameters
if (!audio_is_valid_format(format)) {
- LOGE("Invalid format");
+ ALOGE("Invalid format");
return BAD_VALUE;
}
@@ -198,7 +198,7 @@
}
if (!audio_is_output_channel(channelMask)) {
- LOGE("Invalid channel mask");
+ ALOGE("Invalid channel mask");
return BAD_VALUE;
}
uint32_t channelCount = popcount(channelMask);
@@ -209,7 +209,7 @@
(audio_policy_output_flags_t)flags);
if (output == 0) {
- LOGE("Could not get audio output for stream type %d", streamType);
+ ALOGE("Could not get audio output for stream type %d", streamType);
return BAD_VALUE;
}
@@ -239,7 +239,7 @@
if (cbf != 0) {
mAudioTrackThread = new AudioTrackThread(*this, threadCanCallJava);
if (mAudioTrackThread == 0) {
- LOGE("Could not create callback thread");
+ ALOGE("Could not create callback thread");
return NO_INIT;
}
}
@@ -324,7 +324,7 @@
if (t != 0) {
if (t->exitPending()) {
if (t->requestExitAndWait() == WOULD_BLOCK) {
- LOGE("AudioTrack::start called from thread");
+ ALOGE("AudioTrack::start called from thread");
return;
}
}
@@ -566,12 +566,12 @@
if (loopStart >= loopEnd ||
loopEnd - loopStart > cblk->frameCount ||
cblk->server > loopStart) {
- LOGE("setLoop invalid value: loopStart %d, loopEnd %d, loopCount %d, framecount %d, user %d", loopStart, loopEnd, loopCount, cblk->frameCount, cblk->user);
+ ALOGE("setLoop invalid value: loopStart %d, loopEnd %d, loopCount %d, framecount %d, user %d", loopStart, loopEnd, loopCount, cblk->frameCount, cblk->user);
return BAD_VALUE;
}
if ((mSharedBuffer != 0) && (loopEnd > cblk->frameCount)) {
- LOGE("setLoop invalid value: loop markers beyond data: loopStart %d, loopEnd %d, framecount %d",
+ ALOGE("setLoop invalid value: loop markers beyond data: loopStart %d, loopEnd %d, framecount %d",
loopStart, loopEnd, cblk->frameCount);
return BAD_VALUE;
}
@@ -726,7 +726,7 @@
status_t status;
const sp<IAudioFlinger>& audioFlinger = AudioSystem::get_audio_flinger();
if (audioFlinger == 0) {
- LOGE("Could not get audioflinger");
+ ALOGE("Could not get audioflinger");
return NO_INIT;
}
@@ -769,7 +769,7 @@
}
if (frameCount < minFrameCount) {
if (enforceFrameCount) {
- LOGE("Invalid buffer size: minFrameCount %d, frameCount %d", minFrameCount, frameCount);
+ ALOGE("Invalid buffer size: minFrameCount %d, frameCount %d", minFrameCount, frameCount);
return BAD_VALUE;
} else {
frameCount = minFrameCount;
@@ -779,7 +779,7 @@
// Ensure that buffer alignment matches channelcount
int channelCount = popcount(channelMask);
if (((uint32_t)sharedBuffer->pointer() & (channelCount | 1)) != 0) {
- LOGE("Invalid buffer alignement: address %p, channelCount %d", sharedBuffer->pointer(), channelCount);
+ ALOGE("Invalid buffer alignement: address %p, channelCount %d", sharedBuffer->pointer(), channelCount);
return BAD_VALUE;
}
frameCount = sharedBuffer->size()/channelCount/sizeof(int16_t);
@@ -799,12 +799,12 @@
&status);
if (track == 0) {
- LOGE("AudioFlinger could not create track, status: %d", status);
+ ALOGE("AudioFlinger could not create track, status: %d", status);
return status;
}
sp<IMemory> cblk = track->getCblk();
if (cblk == 0) {
- LOGE("Could not get control block");
+ ALOGE("Could not get control block");
return NO_INIT;
}
mAudioTrack = track;
@@ -964,7 +964,7 @@
if (ssize_t(userSize) < 0) {
// sanity-check. user is most-likely passing an error code.
- LOGE("AudioTrack::write(buffer=%p, size=%u (%d)",
+ ALOGE("AudioTrack::write(buffer=%p, size=%u (%d)",
buffer, userSize, userSize);
return BAD_VALUE;
}
@@ -1096,7 +1096,7 @@
status_t err = obtainBuffer(&audioBuffer, waitCount);
if (err < NO_ERROR) {
if (err != TIMED_OUT) {
- LOGE_IF(err != status_t(NO_MORE_BUFFERS), "Error obtaining an audio buffer, giving up.");
+ ALOGE_IF(err != status_t(NO_MORE_BUFFERS), "Error obtaining an audio buffer, giving up.");
return false;
}
break;
diff --git a/media/libmedia/IAudioFlinger.cpp b/media/libmedia/IAudioFlinger.cpp
index bedf8d3..abd491f 100644
--- a/media/libmedia/IAudioFlinger.cpp
+++ b/media/libmedia/IAudioFlinger.cpp
@@ -112,7 +112,7 @@
data.writeInt32(lSessionId);
status_t lStatus = remote()->transact(CREATE_TRACK, data, &reply);
if (lStatus != NO_ERROR) {
- LOGE("createTrack error: %s", strerror(-lStatus));
+ ALOGE("createTrack error: %s", strerror(-lStatus));
} else {
lSessionId = reply.readInt32();
if (sessionId != NULL) {
@@ -155,7 +155,7 @@
data.writeInt32(lSessionId);
status_t lStatus = remote()->transact(OPEN_RECORD, data, &reply);
if (lStatus != NO_ERROR) {
- LOGE("openRecord error: %s", strerror(-lStatus));
+ ALOGE("openRecord error: %s", strerror(-lStatus));
} else {
lSessionId = reply.readInt32();
if (sessionId != NULL) {
@@ -632,7 +632,7 @@
status_t lStatus = remote()->transact(CREATE_EFFECT, data, &reply);
if (lStatus != NO_ERROR) {
- LOGE("createEffect error: %s", strerror(-lStatus));
+ ALOGE("createEffect error: %s", strerror(-lStatus));
} else {
lStatus = reply.readInt32();
int tmp = reply.readInt32();
diff --git a/media/libmedia/IMediaDeathNotifier.cpp b/media/libmedia/IMediaDeathNotifier.cpp
index 08b2286..8525482 100644
--- a/media/libmedia/IMediaDeathNotifier.cpp
+++ b/media/libmedia/IMediaDeathNotifier.cpp
@@ -54,7 +54,7 @@
binder->linkToDeath(sDeathNotifier);
sMediaPlayerService = interface_cast<IMediaPlayerService>(binder);
}
- LOGE_IF(sMediaPlayerService == 0, "no media player service!?");
+ ALOGE_IF(sMediaPlayerService == 0, "no media player service!?");
return sMediaPlayerService;
}
diff --git a/media/libmedia/JetPlayer.cpp b/media/libmedia/JetPlayer.cpp
index afa84b7..188e582 100644
--- a/media/libmedia/JetPlayer.cpp
+++ b/media/libmedia/JetPlayer.cpp
@@ -68,21 +68,21 @@
if (pLibConfig == NULL)
pLibConfig = EAS_Config();
if (pLibConfig == NULL) {
- LOGE("JetPlayer::init(): EAS library configuration could not be retrieved, aborting.");
+ ALOGE("JetPlayer::init(): EAS library configuration could not be retrieved, aborting.");
return EAS_FAILURE;
}
// init the EAS library
result = EAS_Init(&mEasData);
if( result != EAS_SUCCESS) {
- LOGE("JetPlayer::init(): Error initializing Sonivox EAS library, aborting.");
+ ALOGE("JetPlayer::init(): Error initializing Sonivox EAS library, aborting.");
mState = EAS_STATE_ERROR;
return result;
}
// init the JET library with the default app event controller range
result = JET_Init(mEasData, NULL, sizeof(S_JET_CONFIG));
if( result != EAS_SUCCESS) {
- LOGE("JetPlayer::init(): Error initializing JET library, aborting.");
+ ALOGE("JetPlayer::init(): Error initializing JET library, aborting.");
mState = EAS_STATE_ERROR;
return result;
}
@@ -109,7 +109,7 @@
ALOGV("JetPlayer::init(): render thread(%d) successfully started.", mTid);
mState = EAS_STATE_READY;
} else {
- LOGE("JetPlayer::init(): failed to start render thread.");
+ ALOGE("JetPlayer::init(): failed to start render thread.");
mState = EAS_STATE_ERROR;
return EAS_FAILURE;
}
@@ -169,7 +169,7 @@
mAudioBuffer =
new EAS_PCM[pLibConfig->mixBufferSize * pLibConfig->numChannels * MIX_NUM_BUFFERS];
if (!mAudioBuffer) {
- LOGE("JetPlayer::render(): mAudioBuffer allocate failed");
+ ALOGE("JetPlayer::render(): mAudioBuffer allocate failed");
goto threadExit;
}
@@ -210,7 +210,7 @@
for (int i = 0; i < MIX_NUM_BUFFERS; i++) {
result = EAS_Render(mEasData, p, pLibConfig->mixBufferSize, &count);
if (result != EAS_SUCCESS) {
- LOGE("JetPlayer::render(): EAS_Render returned error %ld", result);
+ ALOGE("JetPlayer::render(): EAS_Render returned error %ld", result);
}
p += count * pLibConfig->numChannels;
num_output += count * pLibConfig->numChannels * sizeof(EAS_PCM);
@@ -229,14 +229,14 @@
// check audio output track
if (mAudioTrack == NULL) {
- LOGE("JetPlayer::render(): output AudioTrack was not created");
+ ALOGE("JetPlayer::render(): output AudioTrack was not created");
goto threadExit;
}
// Write data to the audio hardware
//ALOGV("JetPlayer::render(): writing to audio output");
if ((temp = mAudioTrack->write(mAudioBuffer, num_output)) < 0) {
- LOGE("JetPlayer::render(): Error in writing:%d",temp);
+ ALOGE("JetPlayer::render(): Error in writing:%d",temp);
return temp;
}
@@ -469,7 +469,7 @@
//-------------------------------------------------------------------------------------------------
void JetPlayer::dump()
{
- LOGE("JetPlayer dump: JET file=%s", mEasJetFileLoc->path);
+ ALOGE("JetPlayer dump: JET file=%s", mEasJetFileLoc->path);
}
void JetPlayer::dumpJetStatus(S_JET_STATUS* pJetStatus)
@@ -479,7 +479,7 @@
pJetStatus->currentUserID, pJetStatus->segmentRepeatCount,
pJetStatus->numQueuedSegments, pJetStatus->paused);
else
- LOGE(">> JET player status is NULL");
+ ALOGE(">> JET player status is NULL");
}
diff --git a/media/libmedia/MediaProfiles.cpp b/media/libmedia/MediaProfiles.cpp
index c9e8bc2..c905762 100644
--- a/media/libmedia/MediaProfiles.cpp
+++ b/media/libmedia/MediaProfiles.cpp
@@ -903,7 +903,7 @@
expat is not compiled with -DXML_DTD. We don't have DTD parsing support.
if (!::XML_SetParamEntityParsing(parser, XML_PARAM_ENTITY_PARSING_ALWAYS)) {
- LOGE("failed to enable DTD support in the xml file");
+ ALOGE("failed to enable DTD support in the xml file");
return UNKNOWN_ERROR;
}
@@ -913,7 +913,7 @@
for (;;) {
void *buff = ::XML_GetBuffer(parser, BUFF_SIZE);
if (buff == NULL) {
- LOGE("failed to in call to XML_GetBuffer()");
+ ALOGE("failed to in call to XML_GetBuffer()");
delete profiles;
profiles = NULL;
goto exit;
@@ -921,7 +921,7 @@
int bytes_read = ::fread(buff, 1, BUFF_SIZE, fp);
if (bytes_read < 0) {
- LOGE("failed in call to read");
+ ALOGE("failed in call to read");
delete profiles;
profiles = NULL;
goto exit;
@@ -963,7 +963,7 @@
}
}
if (index == -1) {
- LOGE("The given video encoder %d is not found", codec);
+ ALOGE("The given video encoder %d is not found", codec);
return -1;
}
@@ -976,7 +976,7 @@
if (!strcmp("enc.vid.fps.min", name)) return mVideoEncoders[index]->mMinFrameRate;
if (!strcmp("enc.vid.fps.max", name)) return mVideoEncoders[index]->mMaxFrameRate;
- LOGE("The given video encoder param name %s is not found", name);
+ ALOGE("The given video encoder param name %s is not found", name);
return -1;
}
int MediaProfiles::getVideoEditorExportParamByName(
@@ -993,7 +993,7 @@
}
}
if (index == -1) {
- LOGE("The given video decoder %d is not found", codec);
+ ALOGE("The given video decoder %d is not found", codec);
return -1;
}
if (!strcmp("videoeditor.export.profile", name))
@@ -1001,7 +1001,7 @@
if (!strcmp("videoeditor.export.level", name))
return exportProfile->mLevel;
- LOGE("The given video editor export param name %s is not found", name);
+ ALOGE("The given video editor export param name %s is not found", name);
return -1;
}
int MediaProfiles::getVideoEditorCapParamByName(const char *name) const
@@ -1009,7 +1009,7 @@
ALOGV("getVideoEditorCapParamByName: %s", name);
if (mVideoEditorCap == NULL) {
- LOGE("The mVideoEditorCap is not created, then create default cap.");
+ ALOGE("The mVideoEditorCap is not created, then create default cap.");
createDefaultVideoEditorCap(sInstance);
}
@@ -1024,7 +1024,7 @@
if (!strcmp("maxPrefetchYUVFrames", name))
return mVideoEditorCap->mMaxPrefetchYUVFrames;
- LOGE("The given video editor param name %s is not found", name);
+ ALOGE("The given video editor param name %s is not found", name);
return -1;
}
@@ -1048,7 +1048,7 @@
}
}
if (index == -1) {
- LOGE("The given audio encoder %d is not found", codec);
+ ALOGE("The given audio encoder %d is not found", codec);
return -1;
}
@@ -1059,7 +1059,7 @@
if (!strcmp("enc.aud.hz.min", name)) return mAudioEncoders[index]->mMinSampleRate;
if (!strcmp("enc.aud.hz.max", name)) return mAudioEncoders[index]->mMaxSampleRate;
- LOGE("The given audio encoder param name %s is not found", name);
+ ALOGE("The given audio encoder param name %s is not found", name);
return -1;
}
@@ -1103,7 +1103,7 @@
int index = getCamcorderProfileIndex(cameraId, quality);
if (index == -1) {
- LOGE("The given camcorder profile camera %d quality %d is not found",
+ ALOGE("The given camcorder profile camera %d quality %d is not found",
cameraId, quality);
return -1;
}
@@ -1120,7 +1120,7 @@
if (!strcmp("aud.ch", name)) return mCamcorderProfiles[index]->mAudioCodec->mChannels;
if (!strcmp("aud.hz", name)) return mCamcorderProfiles[index]->mAudioCodec->mSampleRate;
- LOGE("The given camcorder profile param id %d name %s is not found", cameraId, name);
+ ALOGE("The given camcorder profile param id %d name %s is not found", cameraId, name);
return -1;
}
diff --git a/media/libmedia/MediaScannerClient.cpp b/media/libmedia/MediaScannerClient.cpp
index 629b165..40b8188 100644
--- a/media/libmedia/MediaScannerClient.cpp
+++ b/media/libmedia/MediaScannerClient.cpp
@@ -142,12 +142,12 @@
UConverter *conv = ucnv_open(enc, &status);
if (U_FAILURE(status)) {
- LOGE("could not create UConverter for %s\n", enc);
+ ALOGE("could not create UConverter for %s\n", enc);
return;
}
UConverter *utf8Conv = ucnv_open("UTF-8", &status);
if (U_FAILURE(status)) {
- LOGE("could not create UConverter for UTF-8\n");
+ ALOGE("could not create UConverter for UTF-8\n");
ucnv_close(conv);
return;
}
@@ -180,7 +180,7 @@
ucnv_convertEx(utf8Conv, conv, &target, target + targetLength,
&source, (const char *)dest, NULL, NULL, NULL, NULL, TRUE, TRUE, &status);
if (U_FAILURE(status)) {
- LOGE("ucnv_convertEx failed: %d\n", status);
+ ALOGE("ucnv_convertEx failed: %d\n", status);
mValues->setEntry(i, "???");
} else {
// zero terminate
diff --git a/media/libmedia/Metadata.cpp b/media/libmedia/Metadata.cpp
index 8eeebbb..546a9b0 100644
--- a/media/libmedia/Metadata.cpp
+++ b/media/libmedia/Metadata.cpp
@@ -135,7 +135,7 @@
{
if (key < FIRST_SYSTEM_ID ||
(LAST_SYSTEM_ID < key && key < FIRST_CUSTOM_ID)) {
- LOGE("Bad key %d", key);
+ ALOGE("Bad key %d", key);
return false;
}
size_t curr = mData->dataPosition();
@@ -152,7 +152,7 @@
break;
}
if (mData->readInt32() == key) {
- LOGE("Key exists already %d", key);
+ ALOGE("Key exists already %d", key);
error = true;
break;
}
diff --git a/media/libmedia/ToneGenerator.cpp b/media/libmedia/ToneGenerator.cpp
index 6a38ff1..35dfbb8 100644
--- a/media/libmedia/ToneGenerator.cpp
+++ b/media/libmedia/ToneGenerator.cpp
@@ -805,7 +805,7 @@
mState = TONE_IDLE;
if (AudioSystem::getOutputSamplingRate(&mSamplingRate, streamType) != NO_ERROR) {
- LOGE("Unable to marshal AudioFlinger");
+ ALOGE("Unable to marshal AudioFlinger");
return;
}
mThreadCanCallJava = threadCanCallJava;
@@ -906,7 +906,7 @@
ALOGV("Start waiting for previous tone to stop");
lStatus = mWaitCbkCond.waitRelative(mLock, seconds(3));
if (lStatus != NO_ERROR) {
- LOGE("--- start wait for stop timed out, status %d", lStatus);
+ ALOGE("--- start wait for stop timed out, status %d", lStatus);
mState = TONE_IDLE;
mLock.unlock();
return lResult;
@@ -925,7 +925,7 @@
ALOGV("Wait for start callback");
lStatus = mWaitCbkCond.waitRelative(mLock, seconds(3));
if (lStatus != NO_ERROR) {
- LOGE("--- Immediate start timed out, status %d", lStatus);
+ ALOGE("--- Immediate start timed out, status %d", lStatus);
mState = TONE_IDLE;
lResult = false;
}
@@ -943,7 +943,7 @@
}
ALOGV("cond received");
} else {
- LOGE("--- Delayed start timed out, status %d", lStatus);
+ ALOGE("--- Delayed start timed out, status %d", lStatus);
mState = TONE_IDLE;
}
}
@@ -979,7 +979,7 @@
if (lStatus == NO_ERROR) {
ALOGV("track stop complete, time %d", (unsigned int)(systemTime()/1000000));
} else {
- LOGE("--- Stop timed out");
+ ALOGE("--- Stop timed out");
mState = TONE_IDLE;
mpAudioTrack->stop();
}
@@ -1018,7 +1018,7 @@
// Open audio track in mono, PCM 16bit, default sampling rate, default buffer size
mpAudioTrack = new AudioTrack();
if (mpAudioTrack == 0) {
- LOGE("AudioTrack allocation failed");
+ ALOGE("AudioTrack allocation failed");
goto initAudioTrack_exit;
}
ALOGV("Create Track: %p\n", mpAudioTrack);
@@ -1036,7 +1036,7 @@
mThreadCanCallJava);
if (mpAudioTrack->initCheck() != NO_ERROR) {
- LOGE("AudioTrack->initCheck failed");
+ ALOGE("AudioTrack->initCheck failed");
goto initAudioTrack_exit;
}
diff --git a/media/libmedia/Visualizer.cpp b/media/libmedia/Visualizer.cpp
index de40f98..d08ffa5 100644
--- a/media/libmedia/Visualizer.cpp
+++ b/media/libmedia/Visualizer.cpp
@@ -61,7 +61,7 @@
if (enabled) {
if (t->exitPending()) {
if (t->requestExitAndWait() == WOULD_BLOCK) {
- LOGE("Visualizer::enable() called from thread");
+ ALOGE("Visualizer::enable() called from thread");
return INVALID_OPERATION;
}
}
@@ -116,7 +116,7 @@
if (cbk != NULL) {
mCaptureThread = new CaptureThread(*this, rate, ((flags & CAPTURE_CALL_JAVA) != 0));
if (mCaptureThread == 0) {
- LOGE("Could not create callback thread");
+ ALOGE("Could not create callback thread");
return NO_INIT;
}
}
diff --git a/media/libmedia/mediametadataretriever.cpp b/media/libmedia/mediametadataretriever.cpp
index 1658f41..88e269f 100644
--- a/media/libmedia/mediametadataretriever.cpp
+++ b/media/libmedia/mediametadataretriever.cpp
@@ -52,7 +52,7 @@
binder->linkToDeath(sDeathNotifier);
sService = interface_cast<IMediaPlayerService>(binder);
}
- LOGE_IF(sService == 0, "no MediaPlayerService!?");
+ ALOGE_IF(sService == 0, "no MediaPlayerService!?");
return sService;
}
@@ -61,12 +61,12 @@
ALOGV("constructor");
const sp<IMediaPlayerService>& service(getService());
if (service == 0) {
- LOGE("failed to obtain MediaMetadataRetrieverService");
+ ALOGE("failed to obtain MediaMetadataRetrieverService");
return;
}
sp<IMediaMetadataRetriever> retriever(service->createMetadataRetriever(getpid()));
if (retriever == 0) {
- LOGE("failed to create IMediaMetadataRetriever object from server");
+ ALOGE("failed to create IMediaMetadataRetriever object from server");
}
mRetriever = retriever;
}
@@ -98,11 +98,11 @@
ALOGV("setDataSource");
Mutex::Autolock _l(mLock);
if (mRetriever == 0) {
- LOGE("retriever is not initialized");
+ ALOGE("retriever is not initialized");
return INVALID_OPERATION;
}
if (srcUrl == NULL) {
- LOGE("data source is a null pointer");
+ ALOGE("data source is a null pointer");
return UNKNOWN_ERROR;
}
ALOGV("data source (%s)", srcUrl);
@@ -114,11 +114,11 @@
ALOGV("setDataSource(%d, %lld, %lld)", fd, offset, length);
Mutex::Autolock _l(mLock);
if (mRetriever == 0) {
- LOGE("retriever is not initialized");
+ ALOGE("retriever is not initialized");
return INVALID_OPERATION;
}
if (fd < 0 || offset < 0 || length < 0) {
- LOGE("Invalid negative argument");
+ ALOGE("Invalid negative argument");
return UNKNOWN_ERROR;
}
return mRetriever->setDataSource(fd, offset, length);
@@ -129,7 +129,7 @@
ALOGV("getFrameAtTime: time(%lld us) option(%d)", timeUs, option);
Mutex::Autolock _l(mLock);
if (mRetriever == 0) {
- LOGE("retriever is not initialized");
+ ALOGE("retriever is not initialized");
return NULL;
}
return mRetriever->getFrameAtTime(timeUs, option);
@@ -140,7 +140,7 @@
ALOGV("extractMetadata(%d)", keyCode);
Mutex::Autolock _l(mLock);
if (mRetriever == 0) {
- LOGE("retriever is not initialized");
+ ALOGE("retriever is not initialized");
return NULL;
}
return mRetriever->extractMetadata(keyCode);
@@ -151,7 +151,7 @@
ALOGV("extractAlbumArt");
Mutex::Autolock _l(mLock);
if (mRetriever == 0) {
- LOGE("retriever is not initialized");
+ ALOGE("retriever is not initialized");
return NULL;
}
return mRetriever->extractAlbumArt();
diff --git a/media/libmedia/mediaplayer.cpp b/media/libmedia/mediaplayer.cpp
index 6054749..2284927 100644
--- a/media/libmedia/mediaplayer.cpp
+++ b/media/libmedia/mediaplayer.cpp
@@ -115,7 +115,7 @@
if ( !( (mCurrentState & MEDIA_PLAYER_IDLE) ||
(mCurrentState == MEDIA_PLAYER_STATE_ERROR ) ) ) {
- LOGE("attachNewPlayer called in state %d", mCurrentState);
+ ALOGE("attachNewPlayer called in state %d", mCurrentState);
return INVALID_OPERATION;
}
@@ -126,7 +126,7 @@
mCurrentState = MEDIA_PLAYER_INITIALIZED;
err = NO_ERROR;
} else {
- LOGE("Unable to to create media player");
+ ALOGE("Unable to to create media player");
}
}
@@ -195,7 +195,7 @@
ALOGV("invoke %d", request.dataSize());
return mPlayer->invoke(request, reply);
}
- LOGE("invoke failed: wrong state %X", mCurrentState);
+ ALOGE("invoke failed: wrong state %X", mCurrentState);
return INVALID_OPERATION;
}
@@ -236,7 +236,7 @@
mCurrentState = MEDIA_PLAYER_PREPARING;
return mPlayer->prepareAsync();
}
- LOGE("prepareAsync called in state %d", mCurrentState);
+ ALOGE("prepareAsync called in state %d", mCurrentState);
return INVALID_OPERATION;
}
@@ -298,7 +298,7 @@
}
return ret;
}
- LOGE("start called in state %d", mCurrentState);
+ ALOGE("start called in state %d", mCurrentState);
return INVALID_OPERATION;
}
@@ -317,7 +317,7 @@
}
return ret;
}
- LOGE("stop called in state %d", mCurrentState);
+ ALOGE("stop called in state %d", mCurrentState);
return INVALID_OPERATION;
}
@@ -336,7 +336,7 @@
}
return ret;
}
- LOGE("pause called in state %d", mCurrentState);
+ ALOGE("pause called in state %d", mCurrentState);
return INVALID_OPERATION;
}
@@ -348,7 +348,7 @@
mPlayer->isPlaying(&temp);
ALOGV("isPlaying: %d", temp);
if ((mCurrentState & MEDIA_PLAYER_STARTED) && ! temp) {
- LOGE("internal/external state mismatch corrected");
+ ALOGE("internal/external state mismatch corrected");
mCurrentState = MEDIA_PLAYER_PAUSED;
}
return temp;
@@ -402,7 +402,7 @@
*msec = mDuration;
return ret;
}
- LOGE("Attempt to call getDuration without a valid mediaplayer");
+ ALOGE("Attempt to call getDuration without a valid mediaplayer");
return INVALID_OPERATION;
}
@@ -435,7 +435,7 @@
return NO_ERROR;
}
}
- LOGE("Attempt to perform seekTo in wrong state: mPlayer=%p, mCurrentState=%u", mPlayer.get(), mCurrentState);
+ ALOGE("Attempt to perform seekTo in wrong state: mPlayer=%p, mCurrentState=%u", mPlayer.get(), mCurrentState);
return INVALID_OPERATION;
}
@@ -457,7 +457,7 @@
if (mPlayer != 0) {
status_t ret = mPlayer->reset();
if (ret != NO_ERROR) {
- LOGE("reset() failed with return code (%d)", ret);
+ ALOGE("reset() failed with return code (%d)", ret);
mCurrentState = MEDIA_PLAYER_STATE_ERROR;
} else {
mCurrentState = MEDIA_PLAYER_IDLE;
@@ -486,7 +486,7 @@
if (mCurrentState & ( MEDIA_PLAYER_PREPARED | MEDIA_PLAYER_STARTED |
MEDIA_PLAYER_PAUSED | MEDIA_PLAYER_PLAYBACK_COMPLETE ) ) {
// Can't change the stream type after prepare
- LOGE("setAudioStream called in state %d", mCurrentState);
+ ALOGE("setAudioStream called in state %d", mCurrentState);
return INVALID_OPERATION;
}
// cache
@@ -532,7 +532,7 @@
ALOGV("MediaPlayer::setAudioSessionId(%d)", sessionId);
Mutex::Autolock _l(mLock);
if (!(mCurrentState & MEDIA_PLAYER_IDLE)) {
- LOGE("setAudioSessionId called in state %d", mCurrentState);
+ ALOGE("setAudioSessionId called in state %d", mCurrentState);
return INVALID_OPERATION;
}
if (sessionId < 0) {
@@ -570,7 +570,7 @@
if (mPlayer == 0 ||
(mCurrentState & MEDIA_PLAYER_IDLE) ||
(mCurrentState == MEDIA_PLAYER_STATE_ERROR )) {
- LOGE("attachAuxEffect called in state %d", mCurrentState);
+ ALOGE("attachAuxEffect called in state %d", mCurrentState);
return INVALID_OPERATION;
}
@@ -641,7 +641,7 @@
case MEDIA_PLAYBACK_COMPLETE:
ALOGV("playback complete");
if (mCurrentState == MEDIA_PLAYER_IDLE) {
- LOGE("playback complete in idle state");
+ ALOGE("playback complete in idle state");
}
if (!mLoop) {
mCurrentState = MEDIA_PLAYER_PLAYBACK_COMPLETE;
@@ -651,7 +651,7 @@
// Always log errors.
// ext1: Media framework error code.
// ext2: Implementation dependant error code.
- LOGE("error (%d, %d)", ext1, ext2);
+ ALOGE("error (%d, %d)", ext1, ext2);
mCurrentState = MEDIA_PLAYER_STATE_ERROR;
if (mPrepareSync)
{
@@ -717,7 +717,7 @@
if (service != 0) {
p = service->decode(url, pSampleRate, pNumChannels, pFormat);
} else {
- LOGE("Unable to locate media service");
+ ALOGE("Unable to locate media service");
}
return p;
@@ -737,7 +737,7 @@
if (service != 0) {
p = service->decode(fd, offset, length, pSampleRate, pNumChannels, pFormat);
} else {
- LOGE("Unable to locate media service");
+ ALOGE("Unable to locate media service");
}
return p;
diff --git a/media/libmedia/mediarecorder.cpp b/media/libmedia/mediarecorder.cpp
index ec62978..8d947d8 100644
--- a/media/libmedia/mediarecorder.cpp
+++ b/media/libmedia/mediarecorder.cpp
@@ -33,11 +33,11 @@
{
ALOGV("setCamera(%p,%p)", camera.get(), proxy.get());
if(mMediaRecorder == NULL) {
- LOGE("media recorder is not initialized yet");
+ ALOGE("media recorder is not initialized yet");
return INVALID_OPERATION;
}
if (!(mCurrentState & MEDIA_RECORDER_IDLE)) {
- LOGE("setCamera called in an invalid state(%d)", mCurrentState);
+ ALOGE("setCamera called in an invalid state(%d)", mCurrentState);
return INVALID_OPERATION;
}
@@ -54,15 +54,15 @@
{
ALOGV("setPreviewSurface(%p)", surface.get());
if(mMediaRecorder == NULL) {
- LOGE("media recorder is not initialized yet");
+ ALOGE("media recorder is not initialized yet");
return INVALID_OPERATION;
}
if (!(mCurrentState & MEDIA_RECORDER_DATASOURCE_CONFIGURED)) {
- LOGE("setPreviewSurface called in an invalid state(%d)", mCurrentState);
+ ALOGE("setPreviewSurface called in an invalid state(%d)", mCurrentState);
return INVALID_OPERATION;
}
if (!mIsVideoSourceSet) {
- LOGE("try to set preview surface without setting the video source first");
+ ALOGE("try to set preview surface without setting the video source first");
return INVALID_OPERATION;
}
@@ -79,11 +79,11 @@
{
ALOGV("init");
if(mMediaRecorder == NULL) {
- LOGE("media recorder is not initialized yet");
+ ALOGE("media recorder is not initialized yet");
return INVALID_OPERATION;
}
if (!(mCurrentState & MEDIA_RECORDER_IDLE)) {
- LOGE("init called in an invalid state(%d)", mCurrentState);
+ ALOGE("init called in an invalid state(%d)", mCurrentState);
return INVALID_OPERATION;
}
@@ -109,11 +109,11 @@
{
ALOGV("setVideoSource(%d)", vs);
if(mMediaRecorder == NULL) {
- LOGE("media recorder is not initialized yet");
+ ALOGE("media recorder is not initialized yet");
return INVALID_OPERATION;
}
if (mIsVideoSourceSet) {
- LOGE("video source has already been set");
+ ALOGE("video source has already been set");
return INVALID_OPERATION;
}
if (mCurrentState & MEDIA_RECORDER_IDLE) {
@@ -124,7 +124,7 @@
}
}
if (!(mCurrentState & MEDIA_RECORDER_INITIALIZED)) {
- LOGE("setVideoSource called in an invalid state(%d)", mCurrentState);
+ ALOGE("setVideoSource called in an invalid state(%d)", mCurrentState);
return INVALID_OPERATION;
}
@@ -144,7 +144,7 @@
{
ALOGV("setAudioSource(%d)", as);
if(mMediaRecorder == NULL) {
- LOGE("media recorder is not initialized yet");
+ ALOGE("media recorder is not initialized yet");
return INVALID_OPERATION;
}
if (mCurrentState & MEDIA_RECORDER_IDLE) {
@@ -155,11 +155,11 @@
}
}
if (mIsAudioSourceSet) {
- LOGE("audio source has already been set");
+ ALOGE("audio source has already been set");
return INVALID_OPERATION;
}
if (!(mCurrentState & MEDIA_RECORDER_INITIALIZED)) {
- LOGE("setAudioSource called in an invalid state(%d)", mCurrentState);
+ ALOGE("setAudioSource called in an invalid state(%d)", mCurrentState);
return INVALID_OPERATION;
}
@@ -177,21 +177,21 @@
{
ALOGV("setOutputFormat(%d)", of);
if(mMediaRecorder == NULL) {
- LOGE("media recorder is not initialized yet");
+ ALOGE("media recorder is not initialized yet");
return INVALID_OPERATION;
}
if (!(mCurrentState & MEDIA_RECORDER_INITIALIZED)) {
- LOGE("setOutputFormat called in an invalid state: %d", mCurrentState);
+ ALOGE("setOutputFormat called in an invalid state: %d", mCurrentState);
return INVALID_OPERATION;
}
if (mIsVideoSourceSet && of >= OUTPUT_FORMAT_AUDIO_ONLY_START && of != OUTPUT_FORMAT_RTP_AVP && of != OUTPUT_FORMAT_MPEG2TS) { //first non-video output format
- LOGE("output format (%d) is meant for audio recording only and incompatible with video recording", of);
+ ALOGE("output format (%d) is meant for audio recording only and incompatible with video recording", of);
return INVALID_OPERATION;
}
status_t ret = mMediaRecorder->setOutputFormat(of);
if (OK != ret) {
- LOGE("setOutputFormat failed: %d", ret);
+ ALOGE("setOutputFormat failed: %d", ret);
mCurrentState = MEDIA_RECORDER_ERROR;
return ret;
}
@@ -203,19 +203,19 @@
{
ALOGV("setVideoEncoder(%d)", ve);
if(mMediaRecorder == NULL) {
- LOGE("media recorder is not initialized yet");
+ ALOGE("media recorder is not initialized yet");
return INVALID_OPERATION;
}
if (!mIsVideoSourceSet) {
- LOGE("try to set the video encoder without setting the video source first");
+ ALOGE("try to set the video encoder without setting the video source first");
return INVALID_OPERATION;
}
if (mIsVideoEncoderSet) {
- LOGE("video encoder has already been set");
+ ALOGE("video encoder has already been set");
return INVALID_OPERATION;
}
if (!(mCurrentState & MEDIA_RECORDER_DATASOURCE_CONFIGURED)) {
- LOGE("setVideoEncoder called in an invalid state(%d)", mCurrentState);
+ ALOGE("setVideoEncoder called in an invalid state(%d)", mCurrentState);
return INVALID_OPERATION;
}
@@ -233,19 +233,19 @@
{
ALOGV("setAudioEncoder(%d)", ae);
if(mMediaRecorder == NULL) {
- LOGE("media recorder is not initialized yet");
+ ALOGE("media recorder is not initialized yet");
return INVALID_OPERATION;
}
if (!mIsAudioSourceSet) {
- LOGE("try to set the audio encoder without setting the audio source first");
+ ALOGE("try to set the audio encoder without setting the audio source first");
return INVALID_OPERATION;
}
if (mIsAudioEncoderSet) {
- LOGE("audio encoder has already been set");
+ ALOGE("audio encoder has already been set");
return INVALID_OPERATION;
}
if (!(mCurrentState & MEDIA_RECORDER_DATASOURCE_CONFIGURED)) {
- LOGE("setAudioEncoder called in an invalid state(%d)", mCurrentState);
+ ALOGE("setAudioEncoder called in an invalid state(%d)", mCurrentState);
return INVALID_OPERATION;
}
@@ -263,15 +263,15 @@
{
ALOGV("setOutputFile(%s)", path);
if(mMediaRecorder == NULL) {
- LOGE("media recorder is not initialized yet");
+ ALOGE("media recorder is not initialized yet");
return INVALID_OPERATION;
}
if (mIsOutputFileSet) {
- LOGE("output file has already been set");
+ ALOGE("output file has already been set");
return INVALID_OPERATION;
}
if (!(mCurrentState & MEDIA_RECORDER_DATASOURCE_CONFIGURED)) {
- LOGE("setOutputFile called in an invalid state(%d)", mCurrentState);
+ ALOGE("setOutputFile called in an invalid state(%d)", mCurrentState);
return INVALID_OPERATION;
}
@@ -289,15 +289,15 @@
{
ALOGV("setOutputFile(%d, %lld, %lld)", fd, offset, length);
if(mMediaRecorder == NULL) {
- LOGE("media recorder is not initialized yet");
+ ALOGE("media recorder is not initialized yet");
return INVALID_OPERATION;
}
if (mIsOutputFileSet) {
- LOGE("output file has already been set");
+ ALOGE("output file has already been set");
return INVALID_OPERATION;
}
if (!(mCurrentState & MEDIA_RECORDER_DATASOURCE_CONFIGURED)) {
- LOGE("setOutputFile called in an invalid state(%d)", mCurrentState);
+ ALOGE("setOutputFile called in an invalid state(%d)", mCurrentState);
return INVALID_OPERATION;
}
@@ -308,7 +308,7 @@
// this issue by checking the file descriptor first before passing
// it through binder call.
if (fd < 0) {
- LOGE("Invalid file descriptor: %d", fd);
+ ALOGE("Invalid file descriptor: %d", fd);
return BAD_VALUE;
}
@@ -326,21 +326,21 @@
{
ALOGV("setVideoSize(%d, %d)", width, height);
if(mMediaRecorder == NULL) {
- LOGE("media recorder is not initialized yet");
+ ALOGE("media recorder is not initialized yet");
return INVALID_OPERATION;
}
if (!(mCurrentState & MEDIA_RECORDER_DATASOURCE_CONFIGURED)) {
- LOGE("setVideoSize called in an invalid state: %d", mCurrentState);
+ ALOGE("setVideoSize called in an invalid state: %d", mCurrentState);
return INVALID_OPERATION;
}
if (!mIsVideoSourceSet) {
- LOGE("Cannot set video size without setting video source first");
+ ALOGE("Cannot set video size without setting video source first");
return INVALID_OPERATION;
}
status_t ret = mMediaRecorder->setVideoSize(width, height);
if (OK != ret) {
- LOGE("setVideoSize failed: %d", ret);
+ ALOGE("setVideoSize failed: %d", ret);
mCurrentState = MEDIA_RECORDER_ERROR;
return ret;
}
@@ -358,7 +358,7 @@
mSurfaceMediaSource =
mMediaRecorder->querySurfaceMediaSource();
if (mSurfaceMediaSource == NULL) {
- LOGE("SurfaceMediaSource could not be initialized!");
+ ALOGE("SurfaceMediaSource could not be initialized!");
}
return mSurfaceMediaSource;
}
@@ -369,21 +369,21 @@
{
ALOGV("setVideoFrameRate(%d)", frames_per_second);
if(mMediaRecorder == NULL) {
- LOGE("media recorder is not initialized yet");
+ ALOGE("media recorder is not initialized yet");
return INVALID_OPERATION;
}
if (!(mCurrentState & MEDIA_RECORDER_DATASOURCE_CONFIGURED)) {
- LOGE("setVideoFrameRate called in an invalid state: %d", mCurrentState);
+ ALOGE("setVideoFrameRate called in an invalid state: %d", mCurrentState);
return INVALID_OPERATION;
}
if (!mIsVideoSourceSet) {
- LOGE("Cannot set video frame rate without setting video source first");
+ ALOGE("Cannot set video frame rate without setting video source first");
return INVALID_OPERATION;
}
status_t ret = mMediaRecorder->setVideoFrameRate(frames_per_second);
if (OK != ret) {
- LOGE("setVideoFrameRate failed: %d", ret);
+ ALOGE("setVideoFrameRate failed: %d", ret);
mCurrentState = MEDIA_RECORDER_ERROR;
return ret;
}
@@ -393,7 +393,7 @@
status_t MediaRecorder::setParameters(const String8& params) {
ALOGV("setParameters(%s)", params.string());
if(mMediaRecorder == NULL) {
- LOGE("media recorder is not initialized yet");
+ ALOGE("media recorder is not initialized yet");
return INVALID_OPERATION;
}
@@ -402,13 +402,13 @@
MEDIA_RECORDER_RECORDING |
MEDIA_RECORDER_ERROR));
if (isInvalidState) {
- LOGE("setParameters is called in an invalid state: %d", mCurrentState);
+ ALOGE("setParameters is called in an invalid state: %d", mCurrentState);
return INVALID_OPERATION;
}
status_t ret = mMediaRecorder->setParameters(params);
if (OK != ret) {
- LOGE("setParameters(%s) failed: %d", params.string(), ret);
+ ALOGE("setParameters(%s) failed: %d", params.string(), ret);
// Do not change our current state to MEDIA_RECORDER_ERROR, failures
// of the only currently supported parameters, "max-duration" and
// "max-filesize" are _not_ fatal.
@@ -421,34 +421,34 @@
{
ALOGV("prepare");
if(mMediaRecorder == NULL) {
- LOGE("media recorder is not initialized yet");
+ ALOGE("media recorder is not initialized yet");
return INVALID_OPERATION;
}
if (!(mCurrentState & MEDIA_RECORDER_DATASOURCE_CONFIGURED)) {
- LOGE("prepare called in an invalid state: %d", mCurrentState);
+ ALOGE("prepare called in an invalid state: %d", mCurrentState);
return INVALID_OPERATION;
}
if (mIsAudioSourceSet != mIsAudioEncoderSet) {
if (mIsAudioSourceSet) {
- LOGE("audio source is set, but audio encoder is not set");
+ ALOGE("audio source is set, but audio encoder is not set");
} else { // must not happen, since setAudioEncoder checks this already
- LOGE("audio encoder is set, but audio source is not set");
+ ALOGE("audio encoder is set, but audio source is not set");
}
return INVALID_OPERATION;
}
if (mIsVideoSourceSet != mIsVideoEncoderSet) {
if (mIsVideoSourceSet) {
- LOGE("video source is set, but video encoder is not set");
+ ALOGE("video source is set, but video encoder is not set");
} else { // must not happen, since setVideoEncoder checks this already
- LOGE("video encoder is set, but video source is not set");
+ ALOGE("video encoder is set, but video source is not set");
}
return INVALID_OPERATION;
}
status_t ret = mMediaRecorder->prepare();
if (OK != ret) {
- LOGE("prepare failed: %d", ret);
+ ALOGE("prepare failed: %d", ret);
mCurrentState = MEDIA_RECORDER_ERROR;
return ret;
}
@@ -460,17 +460,17 @@
{
ALOGV("getMaxAmplitude");
if(mMediaRecorder == NULL) {
- LOGE("media recorder is not initialized yet");
+ ALOGE("media recorder is not initialized yet");
return INVALID_OPERATION;
}
if (mCurrentState & MEDIA_RECORDER_ERROR) {
- LOGE("getMaxAmplitude called in an invalid state: %d", mCurrentState);
+ ALOGE("getMaxAmplitude called in an invalid state: %d", mCurrentState);
return INVALID_OPERATION;
}
status_t ret = mMediaRecorder->getMaxAmplitude(max);
if (OK != ret) {
- LOGE("getMaxAmplitude failed: %d", ret);
+ ALOGE("getMaxAmplitude failed: %d", ret);
mCurrentState = MEDIA_RECORDER_ERROR;
return ret;
}
@@ -481,17 +481,17 @@
{
ALOGV("start");
if (mMediaRecorder == NULL) {
- LOGE("media recorder is not initialized yet");
+ ALOGE("media recorder is not initialized yet");
return INVALID_OPERATION;
}
if (!(mCurrentState & MEDIA_RECORDER_PREPARED)) {
- LOGE("start called in an invalid state: %d", mCurrentState);
+ ALOGE("start called in an invalid state: %d", mCurrentState);
return INVALID_OPERATION;
}
status_t ret = mMediaRecorder->start();
if (OK != ret) {
- LOGE("start failed: %d", ret);
+ ALOGE("start failed: %d", ret);
mCurrentState = MEDIA_RECORDER_ERROR;
return ret;
}
@@ -503,17 +503,17 @@
{
ALOGV("stop");
if (mMediaRecorder == NULL) {
- LOGE("media recorder is not initialized yet");
+ ALOGE("media recorder is not initialized yet");
return INVALID_OPERATION;
}
if (!(mCurrentState & MEDIA_RECORDER_RECORDING)) {
- LOGE("stop called in an invalid state: %d", mCurrentState);
+ ALOGE("stop called in an invalid state: %d", mCurrentState);
return INVALID_OPERATION;
}
status_t ret = mMediaRecorder->stop();
if (OK != ret) {
- LOGE("stop failed: %d", ret);
+ ALOGE("stop failed: %d", ret);
mCurrentState = MEDIA_RECORDER_ERROR;
return ret;
}
@@ -531,7 +531,7 @@
{
ALOGV("reset");
if (mMediaRecorder == NULL) {
- LOGE("media recorder is not initialized yet");
+ ALOGE("media recorder is not initialized yet");
return INVALID_OPERATION;
}
@@ -556,7 +556,7 @@
break;
default: {
- LOGE("Unexpected non-existing state: %d", mCurrentState);
+ ALOGE("Unexpected non-existing state: %d", mCurrentState);
break;
}
}
@@ -567,12 +567,12 @@
{
ALOGV("close");
if (!(mCurrentState & MEDIA_RECORDER_INITIALIZED)) {
- LOGE("close called in an invalid state: %d", mCurrentState);
+ ALOGE("close called in an invalid state: %d", mCurrentState);
return INVALID_OPERATION;
}
status_t ret = mMediaRecorder->close();
if (OK != ret) {
- LOGE("close failed: %d", ret);
+ ALOGE("close failed: %d", ret);
mCurrentState = MEDIA_RECORDER_ERROR;
return UNKNOWN_ERROR;
} else {
@@ -586,7 +586,7 @@
ALOGV("doReset");
status_t ret = mMediaRecorder->reset();
if (OK != ret) {
- LOGE("doReset failed: %d", ret);
+ ALOGE("doReset failed: %d", ret);
mCurrentState = MEDIA_RECORDER_ERROR;
return ret;
} else {