示例#1
0
        public unsafe void InitialiseCodecYV12BuffersTest()
        {
            vpx_codec_alg_priv_t alg  = new vpx_codec_alg_priv_t();
            VP8D_CONFIG          oxcf = new VP8D_CONFIG();
            var res = onyxd.vp8_create_decoder_instances(alg.yv12_frame_buffers, oxcf);

            Assert.Equal(vpx_codec_err_t.VPX_CODEC_OK, res);

            onyxd.vp8_remove_decoder_instances(alg.yv12_frame_buffers);
        }
示例#2
0
        public unsafe void UpdateFragmentsTest()
        {
            vpx_codec_alg_priv_t alg = new vpx_codec_alg_priv_t();
            vpx_codec_err_t      err;
            ulong dataSz = 573;
            byte *data   = (byte *)vpx_mem.vpx_malloc(dataSz);
            int   res    = vp8_dx.update_fragments(alg, data, (uint)dataSz, out err);

            Assert.Equal(1, res);
            Assert.Equal(vpx_codec_err_t.VPX_CODEC_OK, err);

            vpx_mem.vpx_free(data);
        }