diff --git a/source/Lib/EncoderLib/IntraSearch.cpp b/source/Lib/EncoderLib/IntraSearch.cpp
index b9047f9..f526589 100644
a
|
b
|
void IntraSearch::preCalcPLTIndex(CodingStructure& cs, Partitioner& partitioner, |
2030 | 2030 | } |
2031 | 2031 | |
2032 | 2032 | PelBuf curPLTIdx = tu.getcurPLTIdx(compBegin); |
2033 | | int errorLimit = numComp * g_paletteQuant[cu.qp]; |
| 2033 | int errorLimit = numComp * g_paletteQuant[cu.qp < 0 ? 0 : cu.qp]; |
2034 | 2034 | uint32_t bestIdx = 0; |
2035 | 2035 | uint32_t scaleX = getComponentScaleX(COMPONENT_Cb, cs.sps->getChromaFormatIdc()); |
2036 | 2036 | uint32_t scaleY = getComponentScaleY(COMPONENT_Cb, cs.sps->getChromaFormatIdc()); |
… |
… |
void IntraSearch::derivePLTLossy(CodingStructure& cs, Partitioner& partitioner, |
2167 | 2167 | } |
2168 | 2168 | } |
2169 | 2169 | |
2170 | | int errorLimit = g_paletteQuant[cu.qp]; |
| 2170 | int errorLimit = g_paletteQuant[cu.qp < 0 ? 0 : cu.qp]; |
2171 | 2171 | uint32_t totalSize = height*width; |
2172 | 2172 | SortingElement *pelList = new SortingElement[totalSize]; |
2173 | 2173 | SortingElement element; |