Hi,

On Sat, Dec 24, 2011 at 8:23 AM, Kostya Shishkov
<[email protected]> wrote:
> +#if IVI4_STREAM_ANALYSER
> +static uint8_t has_b_frames = 0;
> +static uint8_t has_transp   = 0;
> +static uint8_t uses_tiling  = 0;
> +static uint8_t uses_haar    = 0;
> +static uint8_t uses_fullpel = 0;
> +#endif

Can those (under ifdef is fine) go in the IVI4DecContext please?

> +struct {
> +    InvTransformPtr *inv_trans;
> +    DCTransformPtr  *dc_trans;
> +    int             is_2d_trans;
> +} transforms[18] = {
> +    { ff_ivi_inverse_haar_8x8,  ff_ivi_dc_haar_2d,       1 },
> +    { NULL, NULL, 0 }, /* inverse Haar 8x1 */
> +    { NULL, NULL, 0 }, /* inverse Haar 1x8 */
> +    { ff_ivi_put_pixels_8x8,    ff_ivi_put_dc_pixel_8x8, 1 },
> +    { ff_ivi_inverse_slant_8x8, ff_ivi_dc_slant_2d,      1 },
> +    { ff_ivi_row_slant8,        ff_ivi_dc_row_slant,     1 },
> +    { ff_ivi_col_slant8,        ff_ivi_dc_col_slant,     1 },
> +    { NULL, NULL, 0 }, /* inverse DCT 8x8 */
> +    { NULL, NULL, 0 }, /* inverse DCT 8x1 */
> +    { NULL, NULL, 0 }, /* inverse DCT 1x8 */
> +    { NULL, NULL, 0 }, /* inverse Haar 4x4 */
> +    { ff_ivi_inverse_slant_4x4, ff_ivi_dc_slant_2d,      1 },
> +    { NULL, NULL, 0 }, /* no transform 4x4 */

Later on, you use != NULL as an indicator that it's implemented. No
transform suggests that no IDCT is needed, and that NULL is a correct
value. Which is correct?

> +    /* Decode chroma subsampling. We support only 4:4 aka YVU9. */
> +    if (get_bits(&ctx->gb, 2)) {
> +        av_log(avctx, AV_LOG_ERROR, "Only YVU9 picture format is 
> supported!\n");
> +        return AVERROR_INVALIDDATA;
> +    }

Do we know the meaning of the other combinations? If they're valid,
maybe ask for samples?

> +            scan_indx = get_bits(&ctx->gb, 4);
> +            if (scan_indx == 15) {
> +                av_log(avctx, AV_LOG_ERROR, "Custom scan pattern 
> encountered!\n");
> +                return AVERROR_INVALIDDATA;
> +            }
> +            band->scan = scan_index_to_tab[scan_indx];
> +
> +            band->quant_mat = get_bits(&ctx->gb, 5);
> +            if (band->quant_mat == 31) {
> +                av_log(avctx, AV_LOG_ERROR, "Custom quant matrix 
> encountered!\n");
> +                return AVERROR_INVALIDDATA;
> +            }

Ask for samples x2?

Ronald
_______________________________________________
libav-devel mailing list
[email protected]
https://lists.libav.org/mailman/listinfo/libav-devel

Reply via email to