If a block quantizer is zero, it should use the DCT_DCT transform
Rather than reading the transform type from the bitstream. See section 5.11.47 of the spec.
Rather than reading the transform type from the bitstream. See section 5.11.47 of the spec.
mentioned in merge request !361 (closed)
Looking at the header reading we have:
const int delta_lossless = !hdr->quant.ydc_delta && !hdr->quant.udc_delta &&
!hdr->quant.uac_delta && !hdr->quant.vdc_delta && !hdr->quant.vac_delta;
hdr->all_lossless = 1;
for (int i = 0; i < NUM_SEGMENTS; i++) {
hdr->segmentation.qidx[i] = hdr->segmentation.enabled ?
iclip_u8(hdr->quant.yac + hdr->segmentation.seg_data.d[i].delta_q) :
hdr->quant.yac;
hdr->segmentation.lossless[i] =
!hdr->segmentation.qidx[i] && delta_lossless;
hdr->all_lossless &= hdr->segmentation.lossless[i];
}
This is supposed to equal the following condition in libaom:
for (int i = 0; i < MAX_SEGMENTS; ++i) {
const int qindex = cm->seg.enabled
? av1_get_qindex(&cm->seg, i, cm->base_qindex)
: cm->base_qindex;
xd->lossless[i] = qindex == 0 && cm->y_dc_delta_q == 0 &&
cm->u_dc_delta_q == 0 && cm->u_ac_delta_q == 0 &&
cm->v_dc_delta_q == 0 && cm->v_ac_delta_q == 0;
xd->qindex[i] = qindex;
}
cm->coded_lossless = is_coded_lossless(cm, xd);
However, coefficient reading uses:
const int qindex =
cm->seg.enabled ? xd->qindex[mbmi->segment_id] : cm->base_qindex;
if (qindex <= 0) return;
I.e. they only check qindex (Y/AC), not the full lossless state.
mentioned in merge request !377 (merged)
closed via merge request !377 (merged)
closed via commit 242c35f3
VideoLAN code repository instance