History

Partly add arm asm code to encoder.

Licai Guo committed 12 years ago

Commit bb244d71 parent 7150adc28 files · +7914 −1Browse files

Showing the changes to codec/encoder/core/src/deblocking.cpp (1 of 28 files). Show all

Unified · Split

codec/encoder/core/src/deblocking.cpp+37−3
@@ -605,6 +605,23 @@ void DeblockingMbAvcbase (SWelsFuncPtrList* pFunc, SMB* pCurMb, SDeblockingFilte · 604 unmodified lines
605605 DeblockingIntraMb (&pFunc->pfDeblocking, pCurMb, pFilter);
606606 break;
607607 default:
608+#if (defined(HAVE_NEON) && defined(SINGLE_REF_FRAME))
609+ DeblockingBSCalcEnc_neon(pCurMb->pNonZeroCount, pCurMb->sMv, pCurMb->uiNeighborAvail, iMbStride, uiBS);
610+ if (iLeftFlag){
611+ if (IS_INTRA((pCurMb-1)->uiMbType)) {
612+ *(uint32_t*)uiBS[0][0] = 0x04040404;
613+ }
614+ } else {
615+ *(uint32_t*)uiBS[0][0] = 0;
616+ }
617+ if (iTopFlag) {
618+ if (IS_INTRA((pCurMb-iMbStride)->uiMbType)) {
619+ *(uint32_t*)uiBS[1][0] = 0x04040404;
620+ }
621+ } else {
622+ *(uint32_t*)uiBS[1][0] = 0;
623+ }
624+#else
608625 if (iLeftFlag) {
609626 * (uint32_t*)uiBS[0][0] = IS_INTRA ((pCurMb - 1)->uiMbType) ? 0x04040404 : DeblockingBSMarginalMBAvcbase (pCurMb,
610627 pCurMb - 1, 0);
@@ -630,7 +647,7 @@ void DeblockingMbAvcbase (SWelsFuncPtrList* pFunc, SMB* pCurMb, SDeblockingFilte · 19 unmodified lines
630647 * (uint32_t*)uiBS[0][1] = * (uint32_t*)uiBS[0][2] = * (uint32_t*)uiBS[0][3] =
631648 * (uint32_t*)uiBS[1][1] = * (uint32_t*)uiBS[1][2] = * (uint32_t*)uiBS[1][3] = 0;
632649 }
633−
650+#endif
634651 DeblockingInterMb (&pFunc->pfDeblocking, pCurMb, pFilter, uiBS);
635652 break;
636653 }
@@ -768,10 +785,13 @@ void WelsNonZeroCount_c (int8_t* pNonZeroCount) { · 131 unmodified lines
768785 }
769786 void WelsBlockFuncInit (PSetNoneZeroCountZeroFunc* pfSetNZCZero, int32_t iCpu) {
770787 *pfSetNZCZero = WelsNonZeroCount_c;
788+#ifdef HAVE_NEON
789+ if( iCpu & WELS_CPU_NEON ) {
790+ *pfSetNZCZero = WelsNonZeroCount_neon;
791+ }
792+#endif
771793 }
772794
773−
774−
775795 void DeblockingInit (DeblockingFunc* pFunc, int32_t iCpu) {
776796 pFunc->pfLumaDeblockingLT4Ver = DeblockLumaLt4V_c;
777797 pFunc->pfLumaDeblockingEQ4Ver = DeblockLumaEq4V_c;
@@ -796,6 +816,20 @@ void DeblockingInit (DeblockingFunc* pFunc, int32_t iCpu) { · 18 unmodified lines
796816 pFunc->pfChromaDeblockingEQ4Hor = DeblockChromaEq4H_ssse3;
797817 }
798818 #endif
819+
820+#if defined(HAVE_NEON)
821+ if (iCpu & WELS_CPU_NEON ) {
822+ pFunc->pfLumaDeblockingLT4Ver = DeblockLumaLt4V_neon;
823+ pFunc->pfLumaDeblockingEQ4Ver = DeblockLumaEq4V_neon;
824+ pFunc->pfLumaDeblockingLT4Hor = DeblockLumaLt4H_neon;
825+ pFunc->pfLumaDeblockingEQ4Hor = DeblockLumaEq4H_neon;
826+
827+ pFunc->pfChromaDeblockingLT4Ver = DeblockChromaLt4V_neon;
828+ pFunc->pfChromaDeblockingEQ4Ver = DeblockChromaEq4V_neon;
829+ pFunc->pfChromaDeblockingLT4Hor = DeblockChromaLt4H_neon;
830+ pFunc->pfChromaDeblockingEQ4Hor = DeblockChromaEq4H_neon;
831+ }
832+#endif
799833 }
800834
801835

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t