• Home
  • Raw
  • Download

Lines Matching refs:thiz

30 static SLuint32 getAssociatedState(IAndroidBufferQueue *thiz)  in getAssociatedState()  argument
33 switch (InterfaceToObjectID(thiz)) { in getAssociatedState()
35 state = ((CMediaPlayer *) thiz->mThis)->mPlay.mState; in getAssociatedState()
38 state = ((CAudioPlayer *) thiz->mThis)->mPlay.mState; in getAssociatedState()
240 IAndroidBufferQueue *thiz = (IAndroidBufferQueue *) self; in IAndroidBufferQueue_RegisterCallback() local
242 interface_lock_exclusive(thiz); in IAndroidBufferQueue_RegisterCallback()
245 if (SL_PLAYSTATE_STOPPED == getAssociatedState(thiz)) { in IAndroidBufferQueue_RegisterCallback()
246 thiz->mCallback = callback; in IAndroidBufferQueue_RegisterCallback()
247 thiz->mContext = pContext; in IAndroidBufferQueue_RegisterCallback()
254 interface_unlock_exclusive(thiz); in IAndroidBufferQueue_RegisterCallback()
265 IAndroidBufferQueue *thiz = (IAndroidBufferQueue *) self; in IAndroidBufferQueue_Clear() local
267 interface_lock_exclusive(thiz); in IAndroidBufferQueue_Clear()
270 thiz->mFront = &thiz->mBufferArray[0]; in IAndroidBufferQueue_Clear()
271 thiz->mRear = &thiz->mBufferArray[0]; in IAndroidBufferQueue_Clear()
273 thiz->mState.count = 0; in IAndroidBufferQueue_Clear()
274 thiz->mState.index = 0; in IAndroidBufferQueue_Clear()
277 switch (InterfaceToObjectID(thiz)) { in IAndroidBufferQueue_Clear()
279 android_audioPlayer_androidBufferQueue_clear_l((CAudioPlayer*) thiz->mThis); in IAndroidBufferQueue_Clear()
282 android_Player_androidBufferQueue_clear_l((CMediaPlayer*) thiz->mThis); in IAndroidBufferQueue_Clear()
288 interface_unlock_exclusive(thiz); in IAndroidBufferQueue_Clear()
319 IAndroidBufferQueue *thiz = (IAndroidBufferQueue *) self; in IAndroidBufferQueue_Enqueue() local
322 switch (thiz->mBufferType) { in IAndroidBufferQueue_Enqueue()
358 interface_lock_exclusive(thiz); in IAndroidBufferQueue_Enqueue()
360 AdvancedBufferHeader *oldRear = thiz->mRear, *newRear; in IAndroidBufferQueue_Enqueue()
361 if ((newRear = oldRear + 1) == &thiz->mBufferArray[thiz->mNumBuffers + 1]) { in IAndroidBufferQueue_Enqueue()
362 newRear = thiz->mBufferArray; in IAndroidBufferQueue_Enqueue()
364 if (thiz->mEOS) { in IAndroidBufferQueue_Enqueue()
367 } else if (newRear == thiz->mFront) { in IAndroidBufferQueue_Enqueue()
371 result = setItems(dataLength, pItems, itemsLength, thiz->mBufferType, oldRear, in IAndroidBufferQueue_Enqueue()
372 &thiz->mEOS); in IAndroidBufferQueue_Enqueue()
379 thiz->mRear = newRear; in IAndroidBufferQueue_Enqueue()
380 ++thiz->mState.count; in IAndroidBufferQueue_Enqueue()
384 interface_unlock_exclusive_attributes(thiz, ((SL_RESULT_SUCCESS == result) && in IAndroidBufferQueue_Enqueue()
385 (1 == thiz->mState.count) && (SL_PLAYSTATE_PLAYING == getAssociatedState(thiz))) ? in IAndroidBufferQueue_Enqueue()
403 IAndroidBufferQueue *thiz = (IAndroidBufferQueue *) self; in IAndroidBufferQueue_GetState() local
405 interface_lock_shared(thiz); in IAndroidBufferQueue_GetState()
407 pState->count = thiz->mState.count; in IAndroidBufferQueue_GetState()
408 pState->index = thiz->mState.index; in IAndroidBufferQueue_GetState()
410 interface_unlock_shared(thiz); in IAndroidBufferQueue_GetState()
424 IAndroidBufferQueue *thiz = (IAndroidBufferQueue *) self; in IAndroidBufferQueue_SetCallbackEventsMask() local
425 interface_lock_exclusive(thiz); in IAndroidBufferQueue_SetCallbackEventsMask()
428 thiz->mCallbackEventsMask = eventFlags; in IAndroidBufferQueue_SetCallbackEventsMask()
433 interface_unlock_exclusive(thiz); in IAndroidBufferQueue_SetCallbackEventsMask()
447 IAndroidBufferQueue *thiz = (IAndroidBufferQueue *) self; in IAndroidBufferQueue_GetCallbackEventsMask() local
448 interface_lock_shared(thiz); in IAndroidBufferQueue_GetCallbackEventsMask()
449 SLuint32 callbackEventsMask = thiz->mCallbackEventsMask; in IAndroidBufferQueue_GetCallbackEventsMask()
450 interface_unlock_shared(thiz); in IAndroidBufferQueue_GetCallbackEventsMask()
471 IAndroidBufferQueue *thiz = (IAndroidBufferQueue *) self; in IAndroidBufferQueue_init() local
472 thiz->mItf = &IAndroidBufferQueue_Itf; in IAndroidBufferQueue_init()
474 thiz->mState.count = 0; in IAndroidBufferQueue_init()
475 thiz->mState.index = 0; in IAndroidBufferQueue_init()
477 thiz->mCallback = NULL; in IAndroidBufferQueue_init()
478 thiz->mContext = NULL; in IAndroidBufferQueue_init()
479 thiz->mCallbackEventsMask = SL_ANDROIDBUFFERQUEUEEVENT_PROCESSED; in IAndroidBufferQueue_init()
481 thiz->mBufferType = kAndroidBufferTypeInvalid; in IAndroidBufferQueue_init()
482 thiz->mBufferArray = NULL; in IAndroidBufferQueue_init()
483 thiz->mFront = NULL; in IAndroidBufferQueue_init()
484 thiz->mRear = NULL; in IAndroidBufferQueue_init()
485 thiz->mEOS = false; in IAndroidBufferQueue_init()
491 IAndroidBufferQueue *thiz = (IAndroidBufferQueue *) self; in IAndroidBufferQueue_deinit() local
492 if (NULL != thiz->mBufferArray) { in IAndroidBufferQueue_deinit()
493 free(thiz->mBufferArray); in IAndroidBufferQueue_deinit()
494 thiz->mBufferArray = NULL; in IAndroidBufferQueue_deinit()
504 void IAndroidBufferQueue_log(IAndroidBufferQueue *thiz)
506 interface_lock_shared(thiz);
507 SL_LOGI("IAndroidBufferQueue %p:", thiz);
509 thiz->mState.count, thiz->mState.index, thiz->mCallback, thiz->mContext);
511 switch (thiz->mBufferType) {
526 thiz->mCallbackEventsMask,
527 thiz->mBufferType, bufferTypeString,
528 thiz->mEOS ? "true" : "false");
530 thiz->mBufferArray,
531 thiz->mFront, thiz->mFront - thiz->mBufferArray,
532 thiz->mRear, thiz->mRear - thiz->mBufferArray);
535 for (hdr = thiz->mFront; hdr != thiz->mRear; ) {
536 SLuint32 i = hdr - thiz->mBufferArray;
538 switch (thiz->mBufferType) {
584 if (++hdr == &thiz->mBufferArray[thiz->mNumBuffers + 1]) {
585 hdr = thiz->mBufferArray;
588 interface_unlock_shared(thiz);