summaryrefslogtreecommitdiffstats
path: root/opensles/libopensles/CAudioPlayer.c
diff options
context:
space:
mode:
Diffstat (limited to 'opensles/libopensles/CAudioPlayer.c')
-rw-r--r--opensles/libopensles/CAudioPlayer.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/opensles/libopensles/CAudioPlayer.c b/opensles/libopensles/CAudioPlayer.c
index d27f15b5..c70f204d 100644
--- a/opensles/libopensles/CAudioPlayer.c
+++ b/opensles/libopensles/CAudioPlayer.c
@@ -26,9 +26,6 @@ SLresult CAudioPlayer_Realize(void *self, SLboolean async)
CAudioPlayer *this = (CAudioPlayer *) self;
SLresult result = SL_RESULT_SUCCESS;
- // initialize cached data, to be overwritten by platform-specific initialization
- this->mNumChannels = 0;
-
#ifdef ANDROID
result = android_audioPlayer_realize(this, async);
#endif
@@ -37,6 +34,10 @@ SLresult CAudioPlayer_Realize(void *self, SLboolean async)
result = SndFile_Realize(this);
#endif
+ // At this point the channel count and sample rate might still be unknown,
+ // depending on the data source and the platform implementation.
+ // If they are unknown here, then they will be determined during prefetch.
+
return result;
}