コード例 #1
0
 public int Open(DecoderSetup setup)
 {
     _dx?.RemoveRef();
     _dx = setup.DirectXContext.AddRef();
     _uploader?.Dispose();
     _uploader = DirectXUploader.Create(_dx, setup.CodecProps.format, setup.CodecProps.width, setup.CodecProps.height);
     Config    = new DecoderConfig();
     return(0);
 }
コード例 #2
0
        public int Open(DecoderSetup setup)
        {
            DecoderConfig result     = new DecoderConfig();
            var           codecProps = setup.CodecProps;
            var           res        = DecoderContext_Open(_handle, ref codecProps, ref result.DecoderProperties, ref result.CodecProperties);

            _opened = res >= 0;
            Config  = result;
            return(res);
        }