当前位置: 首页>>代码示例>>Golang>>正文


Golang TLibCommon.TComDataCU类代码示例

本文整理汇总了Golang中gohm/TLibCommon.TComDataCU的典型用法代码示例。如果您正苦于以下问题:Golang TComDataCU类的具体用法?Golang TComDataCU怎么用?Golang TComDataCU使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。


在下文中一共展示了TComDataCU类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Golang代码示例。

示例1: encodeMVPIdxPU

func (this *TEncEntropy) encodeMVPIdxPU(pcCU *TLibCommon.TComDataCU, uiAbsPartIdx uint, eRefList TLibCommon.RefPicList) {
	if (pcCU.GetInterDir1(uiAbsPartIdx) & (1 << eRefList)) != 0 {
		this.m_pcEntropyCoderIf.codeMVPIdx(pcCU, uiAbsPartIdx, eRefList)
	}

	return
}
开发者ID:hanjinze,项目名称:GoHM,代码行数:7,代码来源:TEncEntropy.go

示例2: encodeInterDirPU

func (this *TEncEntropy) encodeInterDirPU(pcCU *TLibCommon.TComDataCU, uiAbsPartIdx uint) {
	if !pcCU.GetSlice().IsInterB() {
		return
	}

	this.m_pcEntropyCoderIf.codeInterDir(pcCU, uiAbsPartIdx)
	return
}
开发者ID:hanjinze,项目名称:GoHM,代码行数:8,代码来源:TEncEntropy.go

示例3: DecodePredInfo

func (this *TDecEntropy) DecodePredInfo(pcCU *TLibCommon.TComDataCU, uiAbsPartIdx, uiDepth uint, pcSubCU *TLibCommon.TComDataCU) {
	if pcCU.IsIntra(uiAbsPartIdx) {
		this.DecodeIntraDirModeLuma(pcCU, uiAbsPartIdx, uiDepth)
		this.DecodeIntraDirModeChroma(pcCU, uiAbsPartIdx, uiDepth)
	} else {
		this.DecodePUWise(pcCU, uiAbsPartIdx, uiDepth, pcSubCU)
	}
}
开发者ID:hanjinze,项目名称:GoHM,代码行数:8,代码来源:TDecEntropy.go

示例4: encodeQP

func (this *TEncEntropy) encodeQP(pcCU *TLibCommon.TComDataCU, uiAbsPartIdx uint, bRD bool) { //= false );
	if bRD {
		uiAbsPartIdx = 0
	}

	if pcCU.GetSlice().GetPPS().GetUseDQP() {
		this.m_pcEntropyCoderIf.codeDeltaQP(pcCU, uiAbsPartIdx)
	}
}
开发者ID:hanjinze,项目名称:GoHM,代码行数:9,代码来源:TEncEntropy.go

示例5: encodeSkipFlag

func (this *TEncEntropy) encodeSkipFlag(pcCU *TLibCommon.TComDataCU, uiAbsPartIdx uint, bRD bool) { //= false );
	if pcCU.GetSlice().IsIntra() {
		return
	}
	if bRD {
		uiAbsPartIdx = 0
	}

	this.m_pcEntropyCoderIf.codeSkipFlag(pcCU, uiAbsPartIdx)
}
开发者ID:hanjinze,项目名称:GoHM,代码行数:10,代码来源:TEncEntropy.go

示例6: encodeRefFrmIdxPU

func (this *TEncEntropy) encodeRefFrmIdxPU(pcCU *TLibCommon.TComDataCU, uiAbsPartIdx uint, eRefList TLibCommon.RefPicList) {
	if pcCU.GetSlice().GetNumRefIdx(eRefList) == 1 {
		return
	}

	if pcCU.GetInterDir1(uiAbsPartIdx)&(1<<eRefList) != 0 {
		this.m_pcEntropyCoderIf.codeRefFrmIdx(pcCU, uiAbsPartIdx, eRefList)
	}

	return
}
开发者ID:hanjinze,项目名称:GoHM,代码行数:11,代码来源:TEncEntropy.go

示例7: encodePredInfo

func (this *TEncEntropy) encodePredInfo(pcCU *TLibCommon.TComDataCU, uiAbsPartIdx uint, bRD bool) { // = false );
	if bRD {
		uiAbsPartIdx = 0
	}
	//fmt.Printf("uiAbsPartIdx=%d\n", uiAbsPartIdx);
	if pcCU.IsIntra(uiAbsPartIdx) { // If it is Intra mode, encode intra prediction mode.
		this.encodeIntraDirModeLuma(pcCU, uiAbsPartIdx, true)
		this.encodeIntraDirModeChroma(pcCU, uiAbsPartIdx, bRD)
	} else {
		this.encodePUWise(pcCU, uiAbsPartIdx, bRD)
	}
}
开发者ID:hanjinze,项目名称:GoHM,代码行数:12,代码来源:TEncEntropy.go

示例8: DecodeInterDirPU

func (this *TDecEntropy) DecodeInterDirPU(pcCU *TLibCommon.TComDataCU, uiAbsPartIdx, uiDepth, uiPartIdx uint) {
	var uiInterDir uint

	if pcCU.GetSlice().IsInterP() {
		uiInterDir = 1
	} else {
		this.m_pcEntropyDecoderIf.ParseInterDir(pcCU, &uiInterDir, uiAbsPartIdx)
	}

	pcCU.SetInterDirSubParts(uiInterDir, uiAbsPartIdx, uiPartIdx, uiDepth)

}
开发者ID:hanjinze,项目名称:GoHM,代码行数:12,代码来源:TDecEntropy.go

示例9: encodePUWise

func (this *TEncEntropy) encodePUWise(pcCU *TLibCommon.TComDataCU, uiAbsPartIdx uint, bRD bool) { //= false );
	if bRD {
		uiAbsPartIdx = 0
	}

	ePartSize := pcCU.GetPartitionSize1(uiAbsPartIdx)
	var uiNumPU uint
	if ePartSize == TLibCommon.SIZE_2Nx2N {
		uiNumPU = 1
	} else if ePartSize == TLibCommon.SIZE_NxN {
		uiNumPU = 4
	} else {
		uiNumPU = 2
	}
	uiDepth := uint(pcCU.GetDepth1(uiAbsPartIdx))
	//fmt.Printf("ePartSize=%d\n",ePartSize);
	uiPUOffset := (TLibCommon.G_auiPUOffset[uint(ePartSize)] << ((pcCU.GetSlice().GetSPS().GetMaxCUDepth() - uiDepth) << 1)) >> 4

	uiSubPartIdx := uiAbsPartIdx
	for uiPartIdx := uint(0); uiPartIdx < uiNumPU; uiPartIdx++ {
		this.encodeMergeFlag(pcCU, uiSubPartIdx)
		if pcCU.GetMergeFlag1(uiSubPartIdx) {
			this.encodeMergeIndex(pcCU, uiSubPartIdx, false)
		} else {
			this.encodeInterDirPU(pcCU, uiSubPartIdx)
			for uiRefListIdx := 0; uiRefListIdx < 2; uiRefListIdx++ {
				if pcCU.GetSlice().GetNumRefIdx(TLibCommon.RefPicList(uiRefListIdx)) > 0 {
					this.encodeRefFrmIdxPU(pcCU, uiSubPartIdx, TLibCommon.RefPicList(uiRefListIdx))
					this.encodeMvdPU(pcCU, uiSubPartIdx, TLibCommon.RefPicList(uiRefListIdx))
					this.encodeMVPIdxPU(pcCU, uiSubPartIdx, TLibCommon.RefPicList(uiRefListIdx))
				}
			}
		}
		uiSubPartIdx += uiPUOffset
	}

	return
}
开发者ID:hanjinze,项目名称:GoHM,代码行数:38,代码来源:TEncEntropy.go

示例10: DecodeIPCMInfo

func (this *TDecEntropy) DecodeIPCMInfo(pcCU *TLibCommon.TComDataCU, uiAbsPartIdx, uiDepth uint) {
	if !pcCU.GetSlice().GetSPS().GetUsePCM() ||
		pcCU.GetWidth1(uiAbsPartIdx) > (1<<pcCU.GetSlice().GetSPS().GetPCMLog2MaxSize()) ||
		pcCU.GetWidth1(uiAbsPartIdx) < (1<<pcCU.GetSlice().GetSPS().GetPCMLog2MinSize()) {
		return
	}

	this.m_pcEntropyDecoderIf.ParseIPCMInfo(pcCU, uiAbsPartIdx, uiDepth)
}
开发者ID:hanjinze,项目名称:GoHM,代码行数:9,代码来源:TDecEntropy.go

示例11: DecodeRefFrmIdxPU

func (this *TDecEntropy) DecodeRefFrmIdxPU(pcCU *TLibCommon.TComDataCU, uiAbsPartIdx, uiDepth, uiPartIdx uint, eRefList TLibCommon.RefPicList) {
	iRefFrmIdx := 0
	iParseRefFrmIdx := pcCU.GetInterDir1(uiAbsPartIdx) & (1 << uint(eRefList))
	//fmt.Printf("iParseRefFrmIdx=%d\n", iParseRefFrmIdx);

	if pcCU.GetSlice().GetNumRefIdx(eRefList) > 1 && iParseRefFrmIdx != 0 {
		this.m_pcEntropyDecoderIf.ParseRefFrmIdx(pcCU, &iRefFrmIdx, eRefList)
		//fmt.Printf("0iRefFrmIdx=%d\n", iRefFrmIdx);
	} else if iParseRefFrmIdx == 0 {
		iRefFrmIdx = TLibCommon.NOT_VALID
		//fmt.Printf("1iRefFrmIdx=%d\n", iRefFrmIdx);
	} else {
		iRefFrmIdx = 0
		//fmt.Printf("2iRefFrmIdx=%d\n", iRefFrmIdx);
	}

	ePartSize := pcCU.GetPartitionSize1(uiAbsPartIdx)
	pcCU.GetCUMvField(eRefList).SetAllRefIdx(int8(iRefFrmIdx), ePartSize, int(uiAbsPartIdx), uiDepth, int(uiPartIdx))
}
开发者ID:hanjinze,项目名称:GoHM,代码行数:19,代码来源:TDecEntropy.go

示例12: encodeIPCMInfo

func (this *TEncEntropy) encodeIPCMInfo(pcCU *TLibCommon.TComDataCU, uiAbsPartIdx uint, bRD bool) { // = false );
	if !pcCU.GetSlice().GetSPS().GetUsePCM() ||
		pcCU.GetWidth1(uiAbsPartIdx) > (1<<pcCU.GetSlice().GetSPS().GetPCMLog2MaxSize()) ||
		pcCU.GetWidth1(uiAbsPartIdx) < (1<<pcCU.GetSlice().GetSPS().GetPCMLog2MinSize()) {
		return
	}

	if bRD {
		uiAbsPartIdx = 0
	}

	this.m_pcEntropyCoderIf.codeIPCMInfo(pcCU, uiAbsPartIdx)
}
开发者ID:hanjinze,项目名称:GoHM,代码行数:13,代码来源:TEncEntropy.go

示例13: encodeCoeff

func (this *TEncEntropy) encodeCoeff(pcCU *TLibCommon.TComDataCU, uiAbsPartIdx, uiDepth, uiWidth, uiHeight uint, bCodeDQP *bool) {
	uiMinCoeffSize := pcCU.GetPic().GetMinCUWidth() * pcCU.GetPic().GetMinCUHeight()
	uiLumaOffset := uiMinCoeffSize * uiAbsPartIdx
	uiChromaOffset := uiLumaOffset >> 2

	if pcCU.IsIntra(uiAbsPartIdx) {
		/*DTRACE_CABAC_VL( g_nSymbolCounter++ )*/
		this.m_pcEntropyCoderIf.DTRACE_CABAC_T("\tdecodeTransformIdx()\tCUDepth=")
		this.m_pcEntropyCoderIf.DTRACE_CABAC_V(uiDepth)
		this.m_pcEntropyCoderIf.DTRACE_CABAC_T("\n")
	} else {
		if !(pcCU.GetMergeFlag1(uiAbsPartIdx) && pcCU.GetPartitionSize1(uiAbsPartIdx) == TLibCommon.SIZE_2Nx2N) {
			this.m_pcEntropyCoderIf.codeQtRootCbf(pcCU, uiAbsPartIdx)
		}
		if !pcCU.GetQtRootCbf(uiAbsPartIdx) {
			return
		}
	}

	this.xEncodeTransform(pcCU, uiLumaOffset, uiChromaOffset, uiAbsPartIdx, uiDepth, uiWidth, uiHeight, 0, bCodeDQP)
}
开发者ID:hanjinze,项目名称:GoHM,代码行数:21,代码来源:TEncEntropy.go

示例14: DecodeMergeIndex

func (this *TDecEntropy) DecodeMergeIndex(pcCU *TLibCommon.TComDataCU, uiPartIdx, uiAbsPartIdx uint, uiDepth uint) {
	uiMergeIndex := uint(0)
	this.m_pcEntropyDecoderIf.ParseMergeIndex(pcCU, &uiMergeIndex)
	pcCU.SetMergeIndexSubParts(uiMergeIndex, uiAbsPartIdx, uiPartIdx, uiDepth)

}
开发者ID:hanjinze,项目名称:GoHM,代码行数:6,代码来源:TDecEntropy.go

示例15: DecodeMVPIdxPU

func (this *TDecEntropy) DecodeMVPIdxPU(pcSubCU *TLibCommon.TComDataCU, uiPartAddr, uiDepth, uiPartIdx uint, eRefList TLibCommon.RefPicList) {
	iMVPIdx := -1

	cZeroMv := TLibCommon.NewTComMv(0, 0)
	cMv := cZeroMv
	iRefIdx := -1

	pcSubCUMvField := pcSubCU.GetCUMvField(eRefList)
	pAMVPInfo := pcSubCUMvField.GetAMVPInfo()

	iRefIdx = int(pcSubCUMvField.GetRefIdx(int(uiPartAddr)))
	cMv = cZeroMv

	if (pcSubCU.GetInterDir1(uiPartAddr) & (1 << eRefList)) != 0 {
		this.m_pcEntropyDecoderIf.ParseMVPIdx(&iMVPIdx)
	}
	pcSubCU.FillMvpCand(uiPartIdx, uiPartAddr, eRefList, iRefIdx, pAMVPInfo)
	pcSubCU.SetMVPNumSubParts(pAMVPInfo.IN, eRefList, uiPartAddr, uiPartIdx, uiDepth)
	pcSubCU.SetMVPIdxSubParts(iMVPIdx, eRefList, uiPartAddr, uiPartIdx, uiDepth)
	if iRefIdx >= 0 {
		cMv = this.m_pcPrediction.GetMvPredAMVP(pcSubCU, uiPartIdx, uiPartAddr, eRefList)
		cMvd := pcSubCUMvField.GetMvd(int(uiPartAddr))
		//fmt.Printf("%d=(%d,%d)=(%d,%d)\n", iRefIdx, cMv.GetHor(), cMv.GetVer(), cMvd.GetHor(), cMvd.GetVer());
		cMv.Set(cMv.GetHor()+cMvd.GetHor(), cMv.GetVer()+cMvd.GetVer())
	}

	ePartSize := pcSubCU.GetPartitionSize1(uiPartAddr)
	pcSubCU.GetCUMvField(eRefList).SetAllMv(*cMv, ePartSize, int(uiPartAddr), 0, int(uiPartIdx))
	//fmt.Printf("%d(%d,%d)=%d,%d,%d",eRefList,cMv.GetHor(), cMv.GetVer(),ePartSize, uiPartAddr, uiPartIdx);
}
开发者ID:hanjinze,项目名称:GoHM,代码行数:30,代码来源:TDecEntropy.go


注:本文中的gohm/TLibCommon.TComDataCU类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。