Example #1
0
static void vdp_instance_destroy(vdp_instance_t *vi)
{
    vdp_device_destroy(vi->vdp, vi->device);
    vdp_destroy_x11(vi->vdp);
    XCloseDisplay(vi->display);
    free(vi);
}
Example #2
0
void CVDPAU::FiniVDPAUProcs()
{
  if (vdp_device == VDP_INVALID_HANDLE) return;

  VdpStatus vdp_st;
  vdp_st = vdp_device_destroy(vdp_device);
  CheckStatus(vdp_st, __LINE__);
  vdp_device = VDP_INVALID_HANDLE;
  vdpauConfigured = false;
}
Example #3
0
File: vdpau.c Project: aib/mlt
static void vdpau_fini( producer_avformat self )
{
	if ( !self->vdpau )
		return;
	mlt_log_debug( NULL, "vdpau_fini (%x)\n", self->vdpau->device );
	if ( self->vdpau->decoder != VDP_INVALID_HANDLE )
		vdp_decoder_destroy( self->vdpau->decoder );
	if ( self->vdpau->device != VDP_INVALID_HANDLE )
		vdp_device_destroy( self->vdpau->device );
	free( self->vdpau );
	self->vdpau = NULL;
}
Example #4
0
void CVDPAU::FiniVDPAUProcs()
{
  while (!m_videoSurfaces.empty())
  {
    vdpau_render_state *render = m_videoSurfaces.back();
    m_videoSurfaces.pop_back();
    if (render->bitstream_buffers_allocated)
      m_dllAvUtil.av_freep(&render->bitstream_buffers);
    render->bitstream_buffers_allocated = 0;
    free(render);
  }

  if (vdp_device == VDP_INVALID_HANDLE) return;

  VdpStatus vdp_st;
  vdp_st = vdp_device_destroy(vdp_device);
  CheckStatus(vdp_st, __LINE__);
  vdp_device = VDP_INVALID_HANDLE;
  vdpauConfigured = false;
}