Exclude code that don't work on android in voe_cmd_test

Description:
Ths cl makes voe_cmd_test work on android by excluding some code
that are availabel on android today, some highlights
1. change maxnumofchannles
2. disable audio device selection
3. disable set/get volume

BUG=
TEST=test on try bots
Review URL: https://webrtc-codereview.appspot.com/584009

git-svn-id: http://webrtc.googlecode.com/svn/trunk@2300 4adac7df-926f-26a2-2b94-8c16560cd09d
This commit is contained in:
leozwang@webrtc.org 2012-05-25 16:47:35 +00:00
parent 15cd04a314
commit 351fb6d3b4

View File

@ -358,7 +358,11 @@ void RunTest(std::string out_path) {
res = codec->SetSendCodec(chan, cinst);
VALIDATE;
#ifndef WEBRTC_ANDROID
const int kMaxNumChannels = 8;
#else
const int kMaxNumChannels = 1;
#endif
int channel_index = 0;
std::vector<int> channels(kMaxNumChannels);
for (i = 0; i < kMaxNumChannels; ++i) {
@ -376,7 +380,7 @@ void RunTest(std::string out_path) {
bool newcall = true;
while (newcall) {
#ifdef WEBRTC_LINUX
#if defined(WEBRTC_LINUX) && !defined(WEBRTC_ANDROID)
int rd(-1), pd(-1);
res = hardware->GetNumOfRecordingDevices(rd);
VALIDATE;
@ -452,6 +456,7 @@ void RunTest(std::string out_path) {
VALIDATE;
}
#ifndef WEBRTC_ANDROID
printf("Getting mic volume \n");
unsigned int vol = 999;
res = volume->GetMicVolume(vol);
@ -459,6 +464,7 @@ void RunTest(std::string out_path) {
if ((vol > 255) || (vol < 1)) {
printf("\n****ERROR in GetMicVolume");
}
#endif
int forever = 1;
while (forever) {