...
 
Commits (603)
CacheEnable : 1
CacheLineSize : 256
NumCacheLine : 64
NumWay : 4
CacheAddrMode : 0
FrameReport :
CacheEnable : 1
CacheLineSize : 256
NumCacheLine : 64
NumWay : 4
CacheAddrMode : 1
BlkWidth : 16
BlkHeight : 16
FrameReport : 0
......@@ -9,11 +9,6 @@ Profile : next
MaxCUWidth : 64 # Maximum coding unit width in pixel
MaxCUHeight : 64 # Maximum coding unit height in pixel
MaxPartitionDepth : 4 # Maximum coding unit depth
# obsoleted by TULog2MaxSize
#QuadtreeTULog2MinSize : 2 # Log2 of minimum transform size for
# # quadtree-based TU coding (2...6)
QuadtreeTUMaxDepthInter : 3
QuadtreeTUMaxDepthIntra : 3
#======== Coding Structure =============
IntraPeriod : 1 # Period of I-Frame ( -1 = only first)
......@@ -31,7 +26,7 @@ FDM : 1 # Fast Decision for Merge RD cost
#======== Quantization =============
QP : 32 # Quantization parameter(0-51)
MaxDeltaQP : 0 # CU-based multi-QP optimization
MaxCuDQPDepth : 0 # Max depth of a minimum CuDQP for sub-LCU-level delta QP
MaxCuDQPSubdiv : 0 # Maximum subdiv for CU luma Qp adjustment
DeltaQpRD : 0 # Slice-based multi-QP optimization
RDOQ : 1 # RDOQ
RDOQTS : 1 # RDOQ for transform skip
......@@ -84,13 +79,12 @@ CbQpOffset : 1
CrQpOffset : 1
TemporalSubsampleRatio : 8
ReWriteParamSets : 1
#============ NEXT ====================
# General
LargeCTU : 1 # Large CTU
CTUSize : 128
LCTUFast : 1
QuadtreeTULog2MaxSize : 6
DualITree : 1 # separate partitioning of luma and chroma channels for I-slices
MinQTLumaISlice : 8
......@@ -99,28 +93,33 @@ MinQTNonISlice : 8
MaxBTDepth : 3
MaxBTDepthISliceL : 3
MaxBTDepthISliceC : 3
MTT : 1
MTS : 1
MTSIntraMaxCand : 3
MTSInterMaxCand : 4
SBT : 1
LFNST : 1
ISP : 1
Affine : 1
SubPuMvp : 1
MaxNumMergeCand : 6
LMChroma : 1 # use CCLM only
DepQuant : 1
IMV : 2
IMV : 1
ALF : 1
IBC : 0 # turned off in CTC
AllowDisFracMMVD : 1
AffineAmvr : 0
LumaReshapeEnable : 1 # luma reshaping. 0: disable 1:enable
MIP : 1
# Fast tools
PBIntraFast : 1
ISPFast : 1
FastMrg : 1
AMaxBT : 1
FastMIP : 1
FastLFNST : 1
# Encoder optimization tools
AffineAmvrEncOpt : 0
......
......@@ -9,11 +9,6 @@ Profile : next
MaxCUWidth : 64 # Maximum coding unit width in pixel
MaxCUHeight : 64 # Maximum coding unit height in pixel
MaxPartitionDepth : 4 # Maximum coding unit depth
# obsoleted by TULog2MaxSize
#QuadtreeTULog2MinSize : 2 # Log2 of minimum transform size for
# # quadtree-based TU coding (2...6)
QuadtreeTUMaxDepthInter : 3
QuadtreeTUMaxDepthIntra : 3
#======== Coding Structure =============
IntraPeriod : -1 # Period of I-Frame ( -1 = only first)
......@@ -39,7 +34,7 @@ FDM : 1 # Fast Decision for Merge RD cost
#======== Quantization =============
QP : 32 # Quantization parameter(0-51)
MaxDeltaQP : 0 # CU-based multi-QP optimization
MaxCuDQPDepth : 0 # Max depth of a minimum CuDQP for sub-LCU-level delta QP
MaxCuDQPSubdiv : 0 # Maximum subdiv for CU luma Qp adjustment
DeltaQpRD : 0 # Slice-based multi-QP optimization
RDOQ : 1 # RDOQ
RDOQTS : 1 # RDOQ for transform skip
......@@ -100,13 +95,12 @@ SEIDecodedPictureHash : 0
CbQpOffset : 1
CrQpOffset : 1
ReWriteParamSets : 1
#============ NEXT ====================
# General
LargeCTU : 1 # Large CTU
CTUSize : 128
LCTUFast : 1
QuadtreeTULog2MaxSize : 6
DualITree : 1 # separate partitioning of luma and chroma channels for I-slices
MinQTLumaISlice : 8
......@@ -115,34 +109,38 @@ MinQTNonISlice : 8
MaxBTDepth : 3
MaxBTDepthISliceL : 3
MaxBTDepthISliceC : 3
MTT : 1
MTS : 1
MTSIntraMaxCand : 3
MTSInterMaxCand : 4
SBT : 1
ISP : 1
Affine : 1
SubPuMvp : 1
MaxNumMergeCand : 6
LMChroma : 1 # use CCLM only
DepQuant : 1
IMV : 2
IMV : 1
ALF : 1
MHIntra : 1
IBC : 0 # turned off in CTC
AllowDisFracMMVD : 1
AffineAmvr : 0
LumaReshapeEnable : 1 # luma reshaping. 0: disable 1:enable
MIP : 1
# Fast tools
PBIntraFast : 1
ISPFast : 1
FastMrg : 1
AMaxBT : 1
FastMIP : 0
# Encoder optimization tools
AffineAmvrEncOpt : 0
MmvdDisNum : 6
### DO NOT ADD ANYTHING BELOW THIS LINE ###
### DO NOT DELETE THE EMPTY LINE BELOW ###
......@@ -9,11 +9,6 @@ Profile : next
MaxCUWidth : 64 # Maximum coding unit width in pixel
MaxCUHeight : 64 # Maximum coding unit height in pixel
MaxPartitionDepth : 4 # Maximum coding unit depth
# obsoleted by TULog2MaxSize
#QuadtreeTULog2MinSize : 2 # Log2 of minimum transform size for
# # quadtree-based TU coding (2...6)
QuadtreeTUMaxDepthInter : 3
QuadtreeTUMaxDepthIntra : 3
#======== Coding Structure =============
IntraPeriod : -1 # Period of I-Frame ( -1 = only first)
......@@ -39,7 +34,7 @@ FDM : 1 # Fast Decision for Merge RD cost
#======== Quantization =============
QP : 32 # Quantization parameter(0-51)
MaxDeltaQP : 0 # CU-based multi-QP optimization
MaxCuDQPDepth : 0 # Max depth of a minimum CuDQP for sub-LCU-level delta QP
MaxCuDQPSubdiv : 0 # Maximum subdiv for CU luma Qp adjustment
DeltaQpRD : 0 # Slice-based multi-QP optimization
RDOQ : 1 # RDOQ
RDOQTS : 1 # RDOQ for transform skip
......@@ -100,13 +95,12 @@ SEIDecodedPictureHash : 0
CbQpOffset : 1
CrQpOffset : 1
ReWriteParamSets : 1
#============ NEXT ====================
# General
LargeCTU : 1 # Large CTU
CTUSize : 128
LCTUFast : 1
QuadtreeTULog2MaxSize : 6
DualITree : 1 # separate partitioning of luma and chroma channels for I-slices
MinQTLumaISlice : 8
......@@ -115,18 +109,19 @@ MinQTNonISlice : 8
MaxBTDepth : 3
MaxBTDepthISliceL : 3
MaxBTDepthISliceC : 3
MTT : 1
MTS : 1
MTSIntraMaxCand : 3
MTSInterMaxCand : 4
SBT : 1
ISP : 1
MMVD : 1
Affine : 1
SubPuMvp : 1
MaxNumMergeCand : 6
LMChroma : 1 # use CCLM only
DepQuant : 1
IMV : 2
IMV : 1
ALF : 1
GBi : 1
GBiFast : 1
......@@ -136,16 +131,20 @@ IBC : 0 # turned off in CTC
AllowDisFracMMVD : 1
AffineAmvr : 0
LumaReshapeEnable : 1 # luma reshaping. 0: disable 1:enable
MIP : 1
# Fast tools
PBIntraFast : 1
ISPFast : 1
FastMrg : 1
AMaxBT : 1
FastMIP : 0
# Encoder optimization tools
AffineAmvrEncOpt : 0
MmvdDisNum : 6
### DO NOT ADD ANYTHING BELOW THIS LINE ###
### DO NOT DELETE THE EMPTY LINE BELOW ###
......@@ -9,11 +9,6 @@ Profile : next
MaxCUWidth : 64 # Maximum coding unit width in pixel
MaxCUHeight : 64 # Maximum coding unit height in pixel
MaxPartitionDepth : 4 # Maximum coding unit depth
# obsoleted by TULog2MaxSize
#QuadtreeTULog2MinSize : 2 # Log2 of minimum transform size for
# # quadtree-based TU coding (2...6)
QuadtreeTUMaxDepthInter : 3
QuadtreeTUMaxDepthIntra : 3
#======== Coding Structure =============
IntraPeriod : 32 # Period of I-Frame ( -1 = only first)
......@@ -53,7 +48,7 @@ FDM : 1 # Fast Decision for Merge RD cost
#======== Quantization =============
QP : 32 # Quantization parameter(0-51)
MaxDeltaQP : 0 # CU-based multi-QP optimization
MaxCuDQPDepth : 0 # Max depth of a minimum CuDQP for sub-LCU-level delta QP
MaxCuDQPSubdiv : 0 # Maximum subdiv for CU luma Qp adjustment
DeltaQpRD : 0 # Slice-based multi-QP optimization
RDOQ : 1 # RDOQ
RDOQTS : 1 # RDOQ for transform skip
......@@ -114,13 +109,12 @@ SEIDecodedPictureHash : 0
CbQpOffset : 1
CrQpOffset : 1
ReWriteParamSets : 1
#============ NEXT ====================
# General
LargeCTU : 1 # Large CTU
CTUSize : 128
LCTUFast : 1
QuadtreeTULog2MaxSize : 6
DualITree : 1 # separate partitioning of luma and chroma channels for I-slices
MinQTLumaISlice : 8
......@@ -129,18 +123,20 @@ MinQTNonISlice : 8
MaxBTDepth : 3
MaxBTDepthISliceL : 3
MaxBTDepthISliceC : 3
MTT : 1
MTS : 1
MTSIntraMaxCand : 3
MTSInterMaxCand : 4
SBT : 1
LFNST : 1
ISP : 1
MMVD : 1
Affine : 1
SubPuMvp : 1
MaxNumMergeCand : 6
LMChroma : 1 # use CCLM only
DepQuant : 1
IMV : 2
IMV : 1
ALF : 1
GBi : 1
GBiFast : 1
......@@ -151,17 +147,23 @@ IBC : 0 # turned off in CTC
AllowDisFracMMVD : 1
AffineAmvr : 1
LumaReshapeEnable : 1 # luma reshaping. 0: disable 1:enable
MIP : 1
DMVR : 1
SMVD : 1
# Fast tools
PBIntraFast : 1
ISPFast : 1
FastMrg : 1
AMaxBT : 1
FastMIP : 0
FastLFNST : 0
# Encoder optimization tools
AffineAmvrEncOpt : 1
MmvdDisNum : 6
### DO NOT ADD ANYTHING BELOW THIS LINE ###
### DO NOT DELETE THE EMPTY LINE BELOW ###
# ======== Luma adaptive QP ==========
LumaLevelToDeltaQPMode : 1 # Change luma delta QP based on average luma
isSDR : 0 # 1: SDR in PQ container, 0: HDR
# ======= LMCS =======================
LumaReshapeEnable : 0 # turned off in HDR CTC
#======== Chroma QP scale ============
WCGPPSEnable : 1 # enable WCG Chroma scale
WCGPPSChromaQpScale : -0.46 # Linear chroma QP offset mapping (scale) based on QP
WCGPPSChromaQpOffset : 9.26 # Linear chroma QP offset mapping (offset) based on QP
WCGPPSCbQpScale : 1.14 # Scale factor depending on capture and representation color space
WCGPPSCrQpScale : 1.79 # Scale factor depending on capture and representation color space
# ======== Luma adaptive QP ========
LumaLevelToDeltaQPMode : 0 # Change luma delta QP based on average luma
# ======= LMCS =======================
LumaReshapeEnable : 0 # turned off in HDR CTC
ReshapeSignalType : 2 # set signal type to HLG if enabled
#======== Chroma QP scale ============
WCGPPSEnable : 0 # enable WCG Chroma scale
......@@ -9,15 +9,3 @@ SourceHeight : 1080 # Input frame height
FramesToBeEncoded : 240 # Number of frames to be coded
Level : 4.1
#======== Chroma QP scale =============
WCGPPSEnable : 1 # enable WCG Chroma scale
WCGPPSEnable : 1 # enable WCG Chroma scale
WCGPPSChromaQpScale : -0.46 # Linear chroma QP offset mapping (scale) based on QP
WCGPPSChromaQpOffset : 9.26 # Linear chroma QP offset mapping (offset) based on QP
WCGPPSCbQpScale : 1.14 # Scale factor depending on capture and representation color space
WCGPPSCrQpScale : 1.79 # Scale factor depending on capture and representation color space
# ======== Luma adaptive QP ========
LumaLevelToDeltaQPMode : 1 # Change luma delta QP based on average luma
isSDR : 0 # 1: SDR in PQ container, 0: HDR
......@@ -11,12 +11,5 @@ FramesToBeEncoded : 240 # Number of frames to be coded
Level : 4.1
#======== Chroma QP scale =============
WCGPPSEnable : 1 # enable WCG Chroma scale
WCGPPSChromaQpScale : -0.46 # Linear chroma QP offset mapping (scale) based on QP
WCGPPSChromaQpOffset : 9.26 # Linear chroma QP offset mapping (offset) based on QP
WCGPPSCbQpScale : 1.04 # Scale factor depending on capture and representation color space
WCGPPSCrQpScale : 1.39 # Scale factor depending on capture and representation color space
# ======== Luma adaptive QP ========
LumaLevelToDeltaQPMode : 1 # Change luma delta QP based on average luma
isSDR : 0 # 1: SDR in PQ container, 0: HDR
......@@ -9,14 +9,3 @@ SourceHeight : 1080 # Input frame height
FramesToBeEncoded : 500 # Number of frames to be coded
Level : 4.1
#======== Chroma QP scale =============
WCGPPSEnable : 1 # enable WCG Chroma scale
WCGPPSChromaQpScale : -0.46 # Linear chroma QP offset mapping (scale) based on QP
WCGPPSChromaQpOffset : 9.26 # Linear chroma QP offset mapping (offset) based on QP
WCGPPSCbQpScale : 1.14 # Scale factor depending on capture and representation color space
WCGPPSCrQpScale : 1.79 # Scale factor depending on capture and representation color space
# ======== Luma adaptive QP ========
LumaLevelToDeltaQPMode : 1 # Change luma delta QP based on average luma
isSDR : 0 # 1: SDR in PQ container, 0: HDR
......@@ -9,14 +9,3 @@ SourceHeight : 1080 # Input frame height
FramesToBeEncoded : 500 # Number of frames to be coded
Level : 4.1
#======== Chroma QP scale =============
WCGPPSEnable : 1 # enable WCG Chroma scale
WCGPPSChromaQpScale : -0.46 # Linear chroma QP offset mapping (scale) based on QP
WCGPPSChromaQpOffset : 9.26 # Linear chroma QP offset mapping (offset) based on QP
WCGPPSCbQpScale : 1.14 # Scale factor depending on capture and representation color space
WCGPPSCrQpScale : 1.79 # Scale factor depending on capture and representation color space
# ======== Luma adaptive QP ========
LumaLevelToDeltaQPMode : 1 # Change luma delta QP based on average luma
isSDR : 0 # 1: SDR in PQ container, 0: HDR
......@@ -9,14 +9,3 @@ SourceHeight : 1080 # Input frame height
FramesToBeEncoded : 400 # Number of frames to be coded
Level : 4.1
#======== Chroma QP scale =============
WCGPPSEnable : 1 # enable WCG Chroma scale
WCGPPSChromaQpScale : -0.46 # Linear chroma QP offset mapping (scale) based on QP
WCGPPSChromaQpOffset : 9.26 # Linear chroma QP offset mapping (offset) based on QP
WCGPPSCbQpScale : 1.14 # Scale factor depending on capture and representation color space
WCGPPSCrQpScale : 1.79 # Scale factor depending on capture and representation color space
# ======== Luma adaptive QP ========
LumaLevelToDeltaQPMode : 1 # Change luma delta QP based on average luma
isSDR : 0 # 1: SDR in PQ container, 0: HDR
......@@ -11,12 +11,5 @@ FramesToBeEncoded : 339 # Number of frames to be coded
Level : 4.1
#======== Chroma QP scale =============
WCGPPSEnable : 1 # enable WCG Chroma scale
WCGPPSChromaQpScale : -0.46 # Linear chroma QP offset mapping (scale) based on QP
WCGPPSChromaQpOffset : 9.26 # Linear chroma QP offset mapping (offset) based on QP
WCGPPSCbQpScale : 1.04 # Scale factor depending on capture and representation color space
WCGPPSCrQpScale : 1.39 # Scale factor depending on capture and representation color space
# ======== Luma adaptive QP ========
LumaLevelToDeltaQPMode : 1 # Change luma delta QP based on average luma
isSDR : 0 # 1: SDR in PQ container, 0: HDR
......@@ -9,14 +9,3 @@ SourceHeight : 1080 # Input frame height
FramesToBeEncoded : 200 # Number of frames to be coded
Level : 4.1
#======== Chroma QP scale =============
WCGPPSEnable : 1 # enable WCG Chroma scale
WCGPPSChromaQpScale : -0.46 # Linear chroma QP offset mapping (scale) based on QP
WCGPPSChromaQpOffset : 9.26 # Linear chroma QP offset mapping (offset) based on QP
WCGPPSCbQpScale : 1.14 # Scale factor depending on capture and representation color space
WCGPPSCrQpScale : 1.79 # Scale factor depending on capture and representation color space
# ======== Luma adaptive QP ========
LumaLevelToDeltaQPMode : 1 # Change luma delta QP based on average luma
isSDR : 0 # 1: SDR in PQ container, 0: HDR
......@@ -9,10 +9,3 @@ SourceHeight : 2160 # Input frame height
FramesToBeEncoded : 300 # Number of frames to be coded
Level : 5.1
#======== Chroma QP scale =============
WCGPPSEnable : 0 # enable WCG Chroma scale
# ======== Luma adaptive QP ========
LumaLevelToDeltaQPMode : 0 # Change luma delta QP based on average luma
#======== File I/O ===============
InputFile : DayStreet_3840x2160_60p_10bit_420_hlg.yuv
InputBitDepth : 10 # Input bitdepth
InputChromaFormat : 420 # Ratio of luminance to chrominance samples
FrameRate : 60 # Frame Rate per second
FrameSkip : 0 # Number of frames to be skipped in input
SourceWidth : 3840 # Input frame width
SourceHeight : 2160 # Input frame height
FramesToBeEncoded : 600 # Number of frames to be coded
Level : 5.1
#======== Chroma QP scale =============
WCGPPSEnable : 0 # enable WCG Chroma scale
# ======== Luma adaptive QP ========
LumaLevelToDeltaQPMode : 0 # Change luma delta QP based on average luma
......@@ -9,10 +9,3 @@ SourceHeight : 2160 # Input frame height
FramesToBeEncoded : 300 # Number of frames to be coded
Level : 5.1
#======== Chroma QP scale =============
WCGPPSEnable : 0 # enable WCG Chroma scale
# ======== Luma adaptive QP ========
LumaLevelToDeltaQPMode : 0 # Change luma delta QP based on average luma
......@@ -9,10 +9,3 @@ SourceHeight : 2160 # Input frame height
FramesToBeEncoded : 300 # Number of frames to be coded
Level : 5.1
#======== Chroma QP scale =============
WCGPPSEnable : 0 # enable WCG Chroma scale
# ======== Luma adaptive QP ========
LumaLevelToDeltaQPMode : 0 # Change luma delta QP based on average luma
#======== File I/O ===============
InputFile : PeopleInShoppingCenter_3840x2160_60p_10bit_420_hlg.yuv
InputBitDepth : 10 # Input bitdepth
InputChromaFormat : 420 # Ratio of luminance to chrominance samples
FrameRate : 60 # Frame Rate per second
FrameSkip : 0 # Number of frames to be skipped in input
SourceWidth : 3840 # Input frame width
SourceHeight : 2160 # Input frame height
FramesToBeEncoded : 600 # Number of frames to be coded
Level : 5.1
#======== Chroma QP scale =============
WCGPPSEnable : 0 # enable WCG Chroma scale
# ======== Luma adaptive QP ========
LumaLevelToDeltaQPMode : 0 # Change luma delta QP based on average luma
......@@ -9,9 +9,3 @@ SourceHeight : 2160 # Input frame height
FramesToBeEncoded : 300 # Number of frames to be coded
Level : 5.1
#======== Chroma QP scale =============
WCGPPSEnable : 0 # enable WCG Chroma scale
# ======== Luma adaptive QP ========
LumaLevelToDeltaQPMode : 0 # Change luma delta QP based on average luma
\ No newline at end of file
#======== File I/O ===============
InputFile : SunsetBeach2_3840x2160p_60_10b_HLG_420.yuv
InputBitDepth : 10 # Input bitdepth
InputChromaFormat : 420 # Ratio of luminance to chrominance samples
FrameRate : 60 # Frame Rate per second
FrameSkip : 0 # Number of frames to be skipped in input
SourceWidth : 3840 # Input frame width
SourceHeight : 2160 # Input frame height
FramesToBeEncoded : 600 # Number of frames to be coded
Level : 5.1
#======== Chroma QP scale =============
WCGPPSEnable : 0 # enable WCG Chroma scale
# ======== Luma adaptive QP ========
LumaLevelToDeltaQPMode : 0 # Change luma delta QP based on average luma
......@@ -312,6 +312,9 @@ class CMakeLauncher(object):
self._add_common_cmake_build_options(cmake_argv, params)
self._add_cmake_build_jobs_option(cmake_argv, params.cmk_generator_alias, params.cmk_build_jobs)
self._add_cmake_build_verbosity_option(cmake_argv, params.cmk_generator_alias, params.cmk_build_verbosity)
if params.cmk_generator_alias.startswith('vs'):
# msbuild option to disable node reuse -> jenkins build seems to idle at the end.
self._add_cmake_build_tool_options(cmake_argv, ['/nr:false'])
if cmake_argv_optional:
self._add_cmake_build_tool_options(cmake_argv, cmake_argv_optional)
retv = self.launch_cmake(cmake_argv)
......
......@@ -1137,8 +1137,15 @@ elements.
\par
See section~\ref{sec:gop-structure} for further details.
\\
\Option{ReWriteParamSets} &
%\ShortOption{-ip} &
\Default{$0$} &
Enable writing of parameter sets (SPS, PPS, etc.) before every (intra) random access point to enable true random access.
\\
\end{OptionTableNoShorthand}
%%
%% Motion estimation parameters
%%
......@@ -1222,12 +1229,29 @@ $}
Specifies the maximum number of merge candidates to use.
\\
\Option{MaxNumTriangleCand} &
%\ShortOption{\None} &
\Default{5} &
Specifies the maximum number of triangle merge candidates to use.
\\
\Option{DisableIntraInInter} &
%\ShortOption{\None} &
\Default{0} &
Flag to disable intra PUs in inter slices.
\\
\Option{MMVD} &
%\ShortOption{\None} &
\Default{1} &
Enables or disables the merge mode with motion vector difference (MMVD).
\\
\Option{MmvdDisNum} &
%\ShortOption{\None} &
\Default{6} &
Specifies the number of MMVD distance entries used from the distance table at encoder.
\\
\end{OptionTableNoShorthand}
......@@ -1392,6 +1416,20 @@ and cr_qp_offset, that are transmitted in the PPS. Valid values are in
the range $[-12, 12]$.
\\
\Option{CbCrQpOffset (-cbcrqpofs)} &
\Default{-1} &
Global offset to apply to the luma QP to derive the QP for joint Cb-Cr
residual coding mode. This option corresponds to the value of cb_cr_qp_offset
transmitted in the PPS. Valid values are in the range $[-12, 12]$.
\\
\Option{CbCrQpOffsetDualTree} &
\Default{0} &
Tile group QP offset for joint Cb-Cr residual coding mode when separate luma and
chroma trees are used. This option corresponds to the value of tile_group_cb_cr_qp_offset
transmitted in the tile group header. Valid values are in the range $[-12, 12]$.
\\
\Option{LumaLevelToDeltaQPMode} &
\Default{0} &
Luma-level based Delta QP modulation.
......@@ -1739,12 +1777,32 @@ Enables or disables the use of a deblocking across tile boundaries.
\begin{OptionTableNoShorthand}{Coding tools parameters}{tab:coding-tools}
\Option{MIP} &
%\ShortOption{\None} &
\Default{true} &
Enables or disables the use of matrix-based intra prediction (MIP).
\\
\Option{AMP} &
%\ShortOption{\None} &
\Default{true} &
Enables or disables the use of asymmetric motion partitions.
\\
\Option{ISP} &
%\ShortOption{\None} &
\Default{false} &
Enables or disables the Intra Sub-Partitions coding mode.
\\
\Option{ISPFast} &
%\ShortOption{\None} &
\Default{false} &
Enables or disables reduced testing of non-DCT-II transforms if ISP is likely to become the best mode for a given CU.
\par
This option has no effect if either ISP or MTS are disabled.
\\
\Option{SAO} &
%\ShortOption{\None} &
\Default{true} &
......@@ -1957,6 +2015,43 @@ luma TUs are also skipped.
\par
This option has no effect if TransformSkip is disabled.
\\
\Option{UseNonLinearAlfLuma} &
%\ShortOption{\None} &
\Default{true} &
Enables optimization of non-linear filters for ALF on Luma channel.
\\
\Option{UseNonLinearAlfChroma} &
%\ShortOption{\None} &
\Default{true} &
Enables optimization of non-linear filters for ALF on Chroma channels.
\\
\Option{SMVD} &
%\ShortOption{\None} &
\Default{false} &
Enables or disables symmetric MVD mode.
\\
\Option{RDPCM} &
%\ShortOption{\None} &
\Default{false} &
Enables or disables RDPCM coding mode.
\\
\Option{LFNST} &
%\ShortOption{\None} &
\Default{false} &
Enables or disables the use of low frequency non-separable transform (LFNST).
\\
\Option{FastLFNST} &
%\ShortOption{\None} &
\Default{false} &
Enables or disables the fast encoding of low frequency non-separable transform (LFNST).
\\
\end{OptionTableNoShorthand}
%%
......
......@@ -233,11 +233,16 @@ uint32_t DecApp::decode()
m_cDecLib.setNoOutputPriorPicsFlag (false);
}
if ( bNewPicture &&
#if !JVET_M0101_HLS
( nalu.m_nalUnitType == NAL_UNIT_CODED_SLICE_IDR_W_RADL
|| nalu.m_nalUnitType == NAL_UNIT_CODED_SLICE_IDR_N_LP
|| nalu.m_nalUnitType == NAL_UNIT_CODED_SLICE_BLA_N_LP
|| nalu.m_nalUnitType == NAL_UNIT_CODED_SLICE_BLA_W_RADL
|| nalu.m_nalUnitType == NAL_UNIT_CODED_SLICE_BLA_W_LP ) )
#else
( nalu.m_nalUnitType == NAL_UNIT_CODED_SLICE_IDR_W_RADL
|| nalu.m_nalUnitType == NAL_UNIT_CODED_SLICE_IDR_N_LP) )
#endif
{
xFlushOutput( pcListPic );
}
......@@ -247,7 +252,11 @@ uint32_t DecApp::decode()
m_cDecLib.setFirstSliceInPicture (false);
}
// write reconstruction to file -- for additional bumping as defined in C.5.2.3
#if !JVET_M0101_HLS
if(!bNewPicture && nalu.m_nalUnitType >= NAL_UNIT_CODED_SLICE_TRAIL_N && nalu.m_nalUnitType <= NAL_UNIT_RESERVED_VCL31)
#else
if (!bNewPicture && nalu.m_nalUnitType >= NAL_UNIT_CODED_SLICE_TRAIL && nalu.m_nalUnitType <= NAL_UNIT_RESERVED_VCL15)
#endif
{
xWriteOutput( pcListPic, nalu.m_temporalId );
}
......
......@@ -112,6 +112,7 @@ bool DecAppCfg::parseCfg( int argc, char* argv[] )
"\t2: enable tool statistic\n"
"\t3: enable bit and tool statistic\n")
#endif
("MCTSCheck", m_mctsCheck, false, "If enabled, the decoder checks for violations of mc_exact_sample_value_match_flag in Temporal MCTS ")
;
po::setDefaults(opts);
......@@ -148,6 +149,7 @@ bool DecAppCfg::parseCfg( int argc, char* argv[] )
}
#endif
g_mctsDecCheckEnabled = m_mctsCheck;
// Chroma output bit-depth
if( m_outputBitDepth[CHANNEL_TYPE_LUMA] != 0 && m_outputBitDepth[CHANNEL_TYPE_CHROMA] == 0 )
{
......@@ -230,6 +232,7 @@ DecAppCfg::DecAppCfg()
, m_bClipOutputVideoToRec709Range(false)
, m_packedYUVMode(false)
, m_statMode(0)
, m_mctsCheck(false)
{
for (uint32_t channelTypeIndex = 0; channelTypeIndex < MAX_NUM_CHANNEL_TYPE; channelTypeIndex++)
{
......
......@@ -73,6 +73,7 @@ protected:
bool m_packedYUVMode; ///< If true, output 10-bit and 12-bit YUV data as 5-byte and 3-byte (respectively) packed YUV data
std::string m_cacheCfgFile; ///< Config file of cache model
int m_statMode; ///< Config statistic mode (0 - bit stat, 1 - tool stat, 3 - both)
bool m_mctsCheck;
public:
DecAppCfg();
......
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
......@@ -15,6 +15,8 @@ target_link_libraries( ${EXE_NAME} Threads::Threads ${ADDITIONAL_LIBS} )
# include the output directory, where the svnrevision.h file is generated
include_directories(${CMAKE_CURRENT_BINARY_DIR})
include_directories(${CMAKE_SOURCE_DIR}/source/Lib/CommonLib)
if( CMAKE_SYSTEM_NAME STREQUAL "Linux" )
add_custom_command( TARGET ${EXE_NAME} POST_BUILD COMMAND ${CMAKE_COMMAND} -E copy
$<$<CONFIG:Debug>:${CMAKE_RUNTIME_OUTPUT_DIRECTORY_DEBUG}/parcat>
......
......@@ -36,90 +36,10 @@
#include <cstdlib>
#include <cstdio>
#include <cassert>
#include "CommonDef.h"
#define PRINT_NALUS 0
enum NalUnitType
{
TRAIL_N = 0, // 0
TRAIL_R, // 1
TSA_N, // 2
TSA_R, // 3
STSA_N, // 4
STSA_R, // 5
RADL_N, // 6
RADL_R, // 7
RASL_N, // 8
RASL_R, // 9
RESERVED_VCL_N10,
RESERVED_VCL_R11,
RESERVED_VCL_N12,
RESERVED_VCL_R13,
RESERVED_VCL_N14,
RESERVED_VCL_R15,
BLA_W_LP, // 16
BLA_W_RADL, // 17
BLA_N_LP, // 18
IDR_W_RADL, // 19
IDR_N_LP, // 20
CRA, // 21
RESERVED_IRAP_VCL22,
RESERVED_IRAP_VCL23,
RESERVED_VCL24,
RESERVED_VCL25,
RESERVED_VCL26,
RESERVED_VCL27,
RESERVED_VCL28,
RESERVED_VCL29,
RESERVED_VCL30,
RESERVED_VCL31,
#if HEVC_VPS
VPS, // 32
#else
RESERVED_32,
#endif
SPS, // 33
PPS, // 34
ACCESS_UNIT_DELIMITER, // 35
EOS, // 36
EOB, // 37
FILLER_DATA, // 38
PREFIX_SEI, // 39
SUFFIX_SEI, // 40
RESERVED_NVCL41,
RESERVED_NVCL42,
RESERVED_NVCL43,
RESERVED_NVCL44,
RESERVED_NVCL45,
RESERVED_NVCL46,
RESERVED_NVCL47,
UNSPECIFIED_48,
UNSPECIFIED_49,
UNSPECIFIED_50,
UNSPECIFIED_51,
UNSPECIFIED_52,
UNSPECIFIED_53,
UNSPECIFIED_54,
UNSPECIFIED_55,
UNSPECIFIED_56,
UNSPECIFIED_57,
UNSPECIFIED_58,
UNSPECIFIED_59,
UNSPECIFIED_60,
UNSPECIFIED_61,
UNSPECIFIED_62,
UNSPECIFIED_63,
INVALID,
};
/**
Find the beginning and end of a NAL (Network Abstraction Layer) unit in a byte buffer containing H264 bitstream data.
......@@ -182,6 +102,7 @@ const bool verbose = false;
const char * NALU_TYPE[] =
{
#if !JVET_M0101_HLS
"TRAIL_N",
"TRAIL_R",
"TSA_N",
......@@ -221,12 +142,60 @@ const char * NALU_TYPE[] =
#endif
"SPS_NUT",
"PPS_NUT",
#if JVET_M0132
"APS_NUT",
#endif
"AUD_NUT",
"EOS_NUT",
"EOB_NUT",
"FD_NUT",
"PREFIX_SEI_NUT",
"SUFFIX_SEI_NUT",
#else
"NAL_UNIT_CODED_SLICE_TRAIL",
"NAL_UNIT_CODED_SLICE_STSA",
"NAL_UNIT_CODED_SLICE_RADL",
"NAL_UNIT_CODED_SLICE_RASL",
"NAL_UNIT_RESERVED_VCL_4",
"NAL_UNIT_RESERVED_VCL_5",
"NAL_UNIT_RESERVED_VCL_6",
"NAL_UNIT_RESERVED_VCL_7",
"NAL_UNIT_CODED_SLICE_IDR_W_RADL",
"NAL_UNIT_CODED_SLICE_IDR_N_LP",
"NAL_UNIT_CODED_SLICE_CRA",
"NAL_UNIT_RESERVED_IRAP_VCL11",
"NAL_UNIT_RESERVED_IRAP_VCL12",
"NAL_UNIT_RESERVED_IRAP_VCL13",
"NAL_UNIT_RESERVED_VCL14",
#if HEVC_VPS
"NAL_UNIT_VPS",
#else
"NAL_UNIT_RESERVED_VCL15",
#endif
"NAL_UNIT_RESERVED_NVCL16",
"NAL_UNIT_SPS",
"NAL_UNIT_PPS",
"NAL_UNIT_APS",
"NAL_UNIT_ACCESS_UNIT_DELIMITER",
"NAL_UNIT_EOS",
"NAL_UNIT_EOB",
"NAL_UNIT_PREFIX_SEI",
"NAL_UNIT_SUFFIX_SEI",
"NAL_UNIT_FILLER_DATA",
"NAL_UNIT_RESERVED_NVCL26",
"NAL_UNIT_RESERVED_NVCL27",
"NAL_UNIT_UNSPECIFIED_28",
"NAL_UNIT_UNSPECIFIED_29",
"NAL_UNIT_UNSPECIFIED_30",
"NAL_UNIT_UNSPECIFIED_31"
#endif
};
int calc_poc(int iPOClsb, int prevTid0POC, int getBitsForPOC, int nalu_type)
......@@ -248,13 +217,15 @@ int calc_poc(int iPOClsb, int prevTid0POC, int getBitsForPOC, int nalu_type)
{
iPOCmsb = iPrevPOCmsb;
}
if ( nalu_type == BLA_W_LP
|| nalu_type == BLA_W_RADL
|| nalu_type == BLA_N_LP )
#if !JVET_M0101_HLS
if ( nalu_type == NAL_UNIT_CODED_SLICE_BLA_W_LP
|| nalu_type == NAL_UNIT_CODED_SLICE_BLA_W_RADL
|| nalu_type == NAL_UNIT_CODED_SLICE_BLA_N_LP )
{
// For BLA picture types, POCmsb is set to 0.
iPOCmsb = 0;
}
#endif
return iPOCmsb + iPOClsb;
}
......@@ -293,19 +264,27 @@ std::vector<uint8_t> filter_segment(const std::vector<uint8_t> & v, int idx, int
int poc = -1;
int poc_lsb = -1;
int new_poc = -1;
if(nalu_type == IDR_W_RADL || nalu_type == IDR_N_LP)
if(nalu_type == NAL_UNIT_CODED_SLICE_IDR_W_RADL || nalu_type == NAL_UNIT_CODED_SLICE_IDR_N_LP)
{
poc = 0;
new_poc = *poc_base + poc;
}
if(nalu_type < 32 && nalu_type != IDR_W_RADL && nalu_type != IDR_N_LP)
#if !JVET_M0101_HLS
if(nalu_type < 32 && nalu_type != NAL_UNIT_CODED_SLICE_IDR_W_RADL && nalu_type != NAL_UNIT_CODED_SLICE_IDR_N_LP)
#else
if(nalu_type < 15 && nalu_type != NAL_UNIT_CODED_SLICE_IDR_W_RADL && nalu_type != NAL_UNIT_CODED_SLICE_IDR_N_LP)
#endif
{
int offset = 16;
offset += 1; //first_slice_segment_in_pic_flag
if (nalu_type >= BLA_W_LP && nalu_type <= RESERVED_IRAP_VCL23)
#if !JVET_M0101_HLS
if (nalu_type >= NAL_UNIT_CODED_SLICE_BLA_W_LP && nalu_type <= NAL_UNIT_RESERVED_IRAP_VCL23)
#else
if (nalu_type >= NAL_UNIT_CODED_SLICE_IDR_W_RADL && nalu_type <= NAL_UNIT_RESERVED_IRAP_VCL13)
#endif
{
offset += 1; //no_output_of_prior_pics_flag
}
......@@ -321,7 +300,7 @@ std::vector<uint8_t> filter_segment(const std::vector<uint8_t> & v, int idx, int
offset += 3; // PPSId=1
offset += 1; // slice_type TODO: ue(v)
// separate_colour_plane_flag is not supported in JEM1.0
if (nalu_type == CRA)
if (nalu_type == NAL_UNIT_CODED_SLICE_CRA)
{
offset += 2;
}
......@@ -346,18 +325,18 @@ std::vector<uint8_t> filter_segment(const std::vector<uint8_t> & v, int idx, int
++cnt;
}
if(idx > 1 && (nalu_type == IDR_W_RADL || nalu_type == IDR_N_LP))
if(idx > 1 && (nalu_type == NAL_UNIT_CODED_SLICE_IDR_W_RADL || nalu_type == NAL_UNIT_CODED_SLICE_IDR_N_LP))
{
skip_next_sei = true;
idr_found = true;
}
#if HEVC_VPS
if((idx > 1 && (nalu_type == IDR_W_RADL || nalu_type == IDR_N_LP )) || ((idx>1 && !idr_found) && ( nalu_type == VPS || nalu_type == SPS || nalu_type == PPS))
if((idx > 1 && (nalu_type == NAL_UNIT_CODED_SLICE_IDR_W_RADL || nalu_type == NAL_UNIT_CODED_SLICE_IDR_N_LP )) || ((idx>1 && !idr_found) && ( nalu_type == NAL_UNIT_VPS || nalu_type == NAL_UNIT_SPS || nalu_type == NAL_UNIT_PPS))
#else
if((idx > 1 && (nalu_type == IDR_W_RADL || nalu_type == IDR_N_LP)) || ((idx > 1 && !idr_found) && (nalu_type == SPS || nalu_type == PPS))
if((idx > 1 && (nalu_type == NAL_UNIT_CODED_SLICE_IDR_W_RADL || nalu_type == NAL_UNIT_CODED_SLICE_IDR_N_LP)) || ((idx > 1 && !idr_found) && (nalu_type == NAL_UNIT_SPS || nalu_type == NAL_UNIT_PPS || nalu_type == NAL_UNIT_APS))
#endif
|| (nalu_type == SUFFIX_SEI && skip_next_sei))
|| (nalu_type == NAL_UNIT_SUFFIX_SEI && skip_next_sei))
{
}
else
......@@ -366,7 +345,7 @@ std::vector<uint8_t> filter_segment(const std::vector<uint8_t> & v, int idx, int
out.insert(out.end(), nalu.begin(), nalu.end());
}
if(nalu_type == SUFFIX_SEI && skip_next_sei)
if(nalu_type == NAL_UNIT_SUFFIX_SEI && skip_next_sei)
{
skip_next_sei = false;
}
......@@ -412,6 +391,7 @@ int main(int argc, char * argv[])
{
if(argc < 3)
{
printf("parcat version VTM %s\n", VTM_VERSION);
printf("usage: %s <bitstream1> [<bitstream2> ...] <outfile>\n", argv[0]);
return -1;
}
......
......@@ -129,7 +129,7 @@ uint32_t SEIRemovalApp::decode()
// just kick out all suffix SEIS
bWrite &= (( !m_discardSuffixSEIs || nalu.m_nalUnitType != NAL_UNIT_SUFFIX_SEI ) && ( !m_discardPrefixSEIs || nalu.m_nalUnitType != NAL_UNIT_PREFIX_SEI ));
bWrite &= unitCnt >= m_numNALUnitsToSkip;
bWrite &= m_numNALUnitsToWrite > 0 && unitCnt <= m_numNALUnitsToWrite;
bWrite &= m_numNALUnitsToWrite < 0 || unitCnt <= m_numNALUnitsToWrite;
if( bWrite )
{
......
This diff is collapsed.
......@@ -41,6 +41,7 @@
#include "CommonDef.h"
#include "Unit.h"
#include "UnitTools.h"
struct AlfClassifier
{
......@@ -66,29 +67,82 @@ enum Direction
class AdaptiveLoopFilter
{
public:
#if JVET_N0242_NON_LINEAR_ALF
static inline int clipALF(const int clip, const short ref, const short val0, const short val1)
{
return Clip3<int>(-clip, +clip, val0-ref) + Clip3<int>(-clip, +clip, val1-ref);
}
static constexpr int AlfNumClippingValues[MAX_NUM_CHANNEL_TYPE] = { 4, 4 };
static constexpr int MaxAlfNumClippingValues = 4;
#endif
static constexpr int m_NUM_BITS = 8;
static constexpr int m_CLASSIFICATION_BLK_SIZE = 32; //non-normative, local buffer size
static constexpr int m_ALF_UNUSED_CLASSIDX = 255;
static constexpr int m_ALF_UNUSED_TRANSPOSIDX = 255;
AdaptiveLoopFilter();
virtual ~AdaptiveLoopFilter() {}
#if JVET_N0415_CTB_ALF
void reconstructCoeffAPSs(CodingStructure& cs, bool luma, bool chroma, bool isRdo);
void reconstructCoeff(AlfSliceParam& alfSliceParam, ChannelType channel, const bool isRdo, const bool isRedo = false);
void ALFProcess(CodingStructure& cs);
#else
void reconstructCoeff(AlfSliceParam& alfSliceParam, ChannelType channel, const bool isRedo = false);
void ALFProcess( CodingStructure& cs, AlfSliceParam& alfSliceParam );
void reconstructCoeff( AlfSliceParam& alfSliceParam, ChannelType channel, const bool bRedo = false );
#endif
void create( const int picWidth, const int picHeight, const ChromaFormat format, const int maxCUWidth, const int maxCUHeight, const int maxCUDepth, const int inputBitDepth[MAX_NUM_CHANNEL_TYPE] );
void destroy();
static void deriveClassificationBlk( AlfClassifier** classifier, int** laplacian[NUM_DIRECTIONS], const CPelBuf& srcLuma, const Area& blk, const int shift );
#if JVET_N0180_ALF_LINE_BUFFER_REDUCTION
static void deriveClassificationBlk(AlfClassifier** classifier, int** laplacian[NUM_DIRECTIONS], const CPelBuf& srcLuma, const Area& blk, const int shift, int vbCTUHeight, int vbPos);
#else
static void deriveClassificationBlk(AlfClassifier** classifier, int** laplacian[NUM_DIRECTIONS], const CPelBuf& srcLuma, const Area& blk, const int shift);
#endif
void deriveClassification( AlfClassifier** classifier, const CPelBuf& srcLuma, const Area& blk );
void resetPCMBlkClassInfo(CodingStructure & cs, AlfClassifier** classifier, const CPelBuf& srcLuma, const Area& blk);
template<AlfFilterType filtType>
static void filterBlk( AlfClassifier** classifier, const PelUnitBuf &recDst, const CPelUnitBuf& recSrc, const Area& blk, const ComponentID compId, short* filterSet, const ClpRng& clpRng );
#if JVET_N0180_ALF_LINE_BUFFER_REDUCTION
#if JVET_N0242_NON_LINEAR_ALF
static void filterBlk(AlfClassifier** classifier, const PelUnitBuf &recDst, const CPelUnitBuf& recSrc, const Area& blk, const ComponentID compId, short* filterSet, short* fClipSet, const ClpRng& clpRng, CodingStructure& cs, int vbCTUHeight, int vbPos);
#else
static void filterBlk(AlfClassifier** classifier, const PelUnitBuf &recDst, const CPelUnitBuf& recSrc, const Area& blk, const ComponentID compId, short* filterSet, const ClpRng& clpRng, CodingStructure& cs, int vbCTUHeight, int vbPos);
#endif
#else
#if JVET_N0242_NON_LINEAR_ALF
static void filterBlk(AlfClassifier** classifier, const PelUnitBuf &recDst, const CPelUnitBuf& recSrc, const Area& blk, const ComponentID compId, short* filterSet, short* fClipSet, const ClpRng& clpRng, CodingStructure& cs);
#else
static void filterBlk(AlfClassifier** classifier, const PelUnitBuf &recDst, const CPelUnitBuf& recSrc, const Area& blk, const ComponentID compId, short* filterSet, const ClpRng& clpRng, CodingStructure& cs);
#endif
#endif
inline static int getMaxGolombIdx( AlfFilterType filterType )
{
return filterType == ALF_FILTER_5 ? 2 : 3;
}
void( *m_deriveClassificationBlk )( AlfClassifier** classifier, int** laplacian[NUM_DIRECTIONS], const CPelBuf& srcLuma, const Area& blk, const int shift );
void( *m_filter5x5Blk )( AlfClassifier** classifier, const PelUnitBuf &recDst, const CPelUnitBuf& recSrc, const Area& blk, const ComponentID compId, short* filterSet, const ClpRng& clpRng );
void( *m_filter7x7Blk )( AlfClassifier** classifier, const PelUnitBuf &recDst, const CPelUnitBuf& recSrc, const Area& blk, const ComponentID compId, short* filterSet, const ClpRng& clpRng );
#if JVET_N0180_ALF_LINE_BUFFER_REDUCTION
void(*m_deriveClassificationBlk)(AlfClassifier** classifier, int** laplacian[NUM_DIRECTIONS], const CPelBuf& srcLuma, const Area& blk, const int shift, int vbCTUHeight, int vbPos);
#else
void(*m_deriveClassificationBlk)(AlfClassifier** classifier, int** laplacian[NUM_DIRECTIONS], const CPelBuf& srcLuma, const Area& blk, const int shift);
#endif
#if JVET_N0180_ALF_LINE_BUFFER_REDUCTION
#if JVET_N0242_NON_LINEAR_ALF
void(*m_filter5x5Blk)(AlfClassifier** classifier, const PelUnitBuf &recDst, const CPelUnitBuf& recSrc, const Area& blk, const ComponentID compId, short* filterSet, short* fClipSet, const ClpRng& clpRng, CodingStructure& cs, int vbCTUHeight, int vbPos);
void(*m_filter7x7Blk)(AlfClassifier** classifier, const PelUnitBuf &recDst, const CPelUnitBuf& recSrc, const Area& blk, const ComponentID compId, short* filterSet, short* fClipSet, const ClpRng& clpRng, CodingStructure& cs, int vbCTUHeight, int vbPos);
#else
void(*m_filter5x5Blk)(AlfClassifier** classifier, const PelUnitBuf &recDst, const CPelUnitBuf& recSrc, const Area& blk, const ComponentID compId, short* filterSet, const ClpRng& clpRng, CodingStructure& cs, int vbCTUHeight, int vbPos);
void(*m_filter7x7Blk)(AlfClassifier** classifier, const PelUnitBuf &recDst, const CPelUnitBuf& recSrc, const Area& blk, const ComponentID compId, short* filterSet, const ClpRng& clpRng, CodingStructure& cs, int vbCTUHeight, int vbPos);
#endif
#else
#if JVET_N0242_NON_LINEAR_ALF
void(*m_filter5x5Blk)(AlfClassifier** classifier, const PelUnitBuf &recDst, const CPelUnitBuf& recSrc, const Area& blk, const ComponentID compId, short* filterSet, short* fClipSet, const ClpRng& clpRng, CodingStructure& cs);
void(*m_filter7x7Blk)(AlfClassifier** classifier, const PelUnitBuf &recDst, const CPelUnitBuf& recSrc, const Area& blk, const ComponentID compId, short* filterSet, short* fClipSet, const ClpRng& clpRng, CodingStructure& cs);
#else
void(*m_filter5x5Blk)(AlfClassifier** classifier, const PelUnitBuf &recDst, const CPelUnitBuf& recSrc, const Area& blk, const ComponentID compId, short* filterSet, const ClpRng& clpRng, CodingStructure& cs);
void(*m_filter7x7Blk)(AlfClassifier** classifier, const PelUnitBuf &recDst, const CPelUnitBuf& recSrc, const Area& blk, const ComponentID compId, short* filterSet, const ClpRng& clpRng, CodingStructure& cs);
#endif
#endif
#ifdef TARGET_SIMD_X86
void initAdaptiveLoopFilterX86();
......@@ -97,11 +151,30 @@ public:
#endif
protected:
#if JVET_N0415_CTB_ALF
static const int m_classToFilterMapping[NUM_FIXED_FILTER_SETS][MAX_NUM_ALF_CLASSES];
static const int m_fixedFilterSetCoeff[ALF_FIXED_FILTER_NUM][MAX_NUM_ALF_LUMA_COEFF];
short m_fixedFilterSetCoeffDec[NUM_FIXED_FILTER_SETS][MAX_NUM_ALF_CLASSES * MAX_NUM_ALF_LUMA_COEFF];
short m_coeffApsLuma[6][MAX_NUM_ALF_LUMA_COEFF * MAX_NUM_ALF_CLASSES];
#if JVET_N0242_NON_LINEAR_ALF
short m_clippApsLuma[6][MAX_NUM_ALF_LUMA_COEFF * MAX_NUM_ALF_CLASSES];
short m_clipDefault[MAX_NUM_ALF_CLASSES * MAX_NUM_ALF_LUMA_COEFF];
#endif
bool m_created = false;
short m_chromaCoeffFinal[MAX_NUM_ALF_LUMA_COEFF];
#endif
#if JVET_N0242_NON_LINEAR_ALF
Pel m_alfClippingValues[MAX_NUM_CHANNEL_TYPE][MaxAlfNumClippingValues];
#endif
std::vector<AlfFilterShape> m_filterShapes[MAX_NUM_CHANNEL_TYPE];
AlfClassifier** m_classifier;
short m_coeffFinal[MAX_NUM_ALF_CLASSES * MAX_NUM_ALF_LUMA_COEFF];
#if JVET_N0242_NON_LINEAR_ALF
short m_clippFinal[MAX_NUM_ALF_CLASSES * MAX_NUM_ALF_LUMA_COEFF];
short m_chromaClippFinal[MAX_NUM_ALF_LUMA_COEFF];
#endif
int** m_laplacian[NUM_DIRECTIONS];
uint8_t* m_ctuEnableFlag[MAX_NUM_COMPONENT];
uint8_t* m_ctuEnableFlag[MAX_NUM_COMPONENT];
PelStorage m_tempBuf;
int m_inputBitDepth[MAX_NUM_CHANNEL_TYPE];
int m_picWidth;
......@@ -112,6 +185,12 @@ protected:
int m_numCTUsInWidth;
int m_numCTUsInHeight;
int m_numCTUsInPic;
#if JVET_N0180_ALF_LINE_BUFFER_REDUCTION
int m_alfVBLumaPos;
int m_alfVBChmaPos;
int m_alfVBLumaCTUHeight;
int m_alfVBChmaCTUHeight;
#endif
ChromaFormat m_chromaFormat;
ClpRngs m_clpRngs;
};
......
......@@ -42,11 +42,6 @@
#include "Buffer.h"
#include "InterpolationFilter.h"
#if ENABLE_SIMD_OPT_BUFFER
#ifdef TARGET_SIMD_X86
#include "CommonDefX86.h"
template< typename T >
void addAvgCore( const T* src1, int src1Stride, const T* src2, int src2Stride, T* dest, int dstStride, int width, int height, int rshift, int offset, const ClpRng& clpRng )
{
......@@ -91,16 +86,14 @@ void addBIOAvgCore(const Pel* src0, int src0Stride, const Pel* src1, int src1Str
}
}
#if JVET_M0063_BDOF_FIX
void gradFilterCore(Pel* pSrc, int srcStride, int width, int height, int gradStride, Pel* gradX, Pel* gradY, const int bitDepth)
#else
void gradFilterCore(Pel* pSrc, int srcStride, int width, int height, int gradStride, Pel* gradX, Pel* gradY)
#endif
{
Pel* srcTmp = pSrc + srcStride + 1;
Pel* gradXTmp = gradX + gradStride + 1;
Pel* gradYTmp = gradY + gradStride + 1;
#if JVET_M0063_BDOF_FIX
#if JVET_N0325_BDOF
int shift1 = std::max<int>(6, (bitDepth - 6));
#else
int shift1 = std::max<int>(2, (IF_INTERNAL_PREC - bitDepth));
#endif
......@@ -108,13 +101,8 @@ void gradFilterCore(Pel* pSrc, int srcStride, int width, int height, int gradStr
{
for (int x = 0; x < (width - 2 * BIO_EXTEND_SIZE); x++)
{
#if JVET_M0063_BDOF_FIX
gradYTmp[x] = (srcTmp[x + srcStride] - srcTmp[x - srcStride]) >> shift1;
gradXTmp[x] = (srcTmp[x + 1] - srcTmp[x - 1]) >> shift1;
#else
gradYTmp[x] = (srcTmp[x + srcStride] - srcTmp[x - srcStride]) >> 4;
gradXTmp[x] = (srcTmp[x + 1] - srcTmp[x - 1]) >> 4;
#endif
}
gradXTmp += gradStride;
gradYTmp += gradStride;
......@@ -142,13 +130,12 @@ void gradFilterCore(Pel* pSrc, int srcStride, int width, int height, int gradStr
::memcpy(gradYTmp + (height - 2 * BIO_EXTEND_SIZE)*gradStride, gradYTmp + (height - 2 * BIO_EXTEND_SIZE - 1)*gradStride, sizeof(Pel)*(width));
}
#if JVET_M0063_BDOF_FIX
void calcBIOParCore(const Pel* srcY0Temp, const Pel* srcY1Temp, const Pel* gradX0, const Pel* gradX1, const Pel* gradY0, const Pel* gradY1, int* dotProductTemp1, int* dotProductTemp2, int* dotProductTemp3, int* dotProductTemp5, int* dotProductTemp6, const int src0Stride, const int src1Stride, const int gradStride, const int widthG, const int heightG, const int bitDepth)
#else
void calcBIOParCore(const Pel* srcY0Temp, const Pel* srcY1Temp, const Pel* gradX0, const Pel* gradX1, const Pel* gradY0, const Pel* gradY1, int* dotProductTemp1, int* dotProductTemp2, int* dotProductTemp3, int* dotProductTemp5, int* dotProductTemp6, const int src0Stride, const int src1Stride, const int gradStride, const int widthG, const int heightG)
#endif
{
#if JVET_M0063_BDOF_FIX
#if JVET_N0325_BDOF
int shift4 = std::max<int>(4, (bitDepth - 8));
int shift5 = std::max<int>(1, (bitDepth - 11));
#else
int shift4 = std::min<int>(8, (bitDepth - 4));
int shift5 = std::min<int>(5, (bitDepth - 7));
#endif
......@@ -156,15 +143,9 @@ void calcBIOParCore(const Pel* srcY0Temp, const Pel* srcY1Temp, const Pel* gradX
{
for (int x = 0; x < widthG; x++)
{
#if JVET_M0063_BDOF_FIX
int temp = (srcY0Temp[x] >> shift4) - (srcY1Temp[x] >> shift4);
int tempX = (gradX0[x] + gradX1[x]) >> shift5;
int tempY = (gradY0[x] + gradY1[x]) >> shift5;
#else
int temp = (srcY0Temp[x] >> 6) - (srcY1Temp[x] >> 6);
int tempX = (gradX0[x] + gradX1[x]) >> 3;
int tempY = (gradY0[x] + gradY1[x]) >> 3;
#endif
dotProductTemp1[x] = tempX * tempX;
dotProductTemp2[x] = tempX * tempY;
dotProductTemp3[x] = -tempX * temp;
......@@ -299,10 +280,8 @@ PelBufferOps::PelBufferOps()
calcBIOPar = calcBIOParCore;
calcBlkGradient = calcBlkGradientCore;
#if JVET_M0147_DMVR
copyBuffer = copyBufferCore;
padding = paddingCore;
#endif
#if ENABLE_SIMD_OPT_GBI
removeWeightHighFreq8 = removeWeightHighFreq;
removeWeightHighFreq4 = removeWeightHighFreq;
......@@ -314,10 +293,6 @@ PelBufferOps::PelBufferOps()
PelBufferOps g_pelBufOP = PelBufferOps();
#endif
#endif
#if JVET_M0147_DMVR
void copyBufferCore(Pel *src, int srcStride, Pel *dst, int dstStride, int width, int height)
{
int numBytes = width * sizeof(Pel);
......@@ -352,7 +327,6 @@ void paddingCore(Pel *ptr, int stride, int width, int height, int padSize)
memcpy(ptrTemp2 + (i * stride), (ptrTemp2), numBytes);
}
}
#endif
template<>
void AreaBuf<Pel>::addWeightedAvg(const AreaBuf<const Pel> &other1, const AreaBuf<const Pel> &other2, const ClpRng& clpRng, const int8_t gbiIdx)
{
......@@ -383,20 +357,11 @@ void AreaBuf<Pel>::addWeightedAvg(const AreaBuf<const Pel> &other1, const AreaBu