diff options
-rw-r--r-- | libhb/decavcodec.c | 2 | ||||
-rw-r--r-- | libhb/vadxva2.c | 24 |
2 files changed, 13 insertions, 13 deletions
diff --git a/libhb/decavcodec.c b/libhb/decavcodec.c index f1d0c3477..c68037a7a 100644 --- a/libhb/decavcodec.c +++ b/libhb/decavcodec.c @@ -860,7 +860,7 @@ static hb_buffer_t *copy_frame( hb_work_private_t *pv ) { pv->dst_frame = malloc( ww * hh * 3 / 2 ); } - if( hb_va_extract( pv->dxva2, pv->dst_frame, pv->frame, pv->job->geometry.width, pv->job->geometry.height, pv->job->title->crop, pv->opencl_scale, pv->job->use_opencl, pv->job->use_decomb, pv->job->use_detelecine ) == HB_WORK_ERROR ) + if( hb_va_extract( pv->dxva2, pv->dst_frame, pv->frame, pv->job->width, pv->job->height, pv->job->title->crop, pv->opencl_scale, pv->job->use_opencl, pv->job->use_decomb, pv->job->use_detelecine ) == HB_WORK_ERROR ) { hb_log( "hb_va_Extract failed!!!!!!" ); } diff --git a/libhb/vadxva2.c b/libhb/vadxva2.c index d5c2a2bfa..828bbb0b9 100644 --- a/libhb/vadxva2.c +++ b/libhb/vadxva2.c @@ -124,10 +124,10 @@ void hb_va_close( hb_va_dxva2_t *dxva2 ) */ static int hb_dx_create_video_decoder( hb_va_dxva2_t *dxva2, int codec_id, const hb_title_t* fmt ) { - dxva2->width = fmt->width; - dxva2->height = fmt->height; - dxva2->surface_width = (fmt->width + 15) & ~15; - dxva2->surface_height = (fmt->height + 15) & ~15; + dxva2->width = fmt->geometry.width; + dxva2->height = fmt->geometry.height; + dxva2->surface_width = (fmt->geometry.width + 15) & ~15; + dxva2->surface_height = (fmt->geometry.height + 15) & ~15; switch( codec_id ) { case AV_CODEC_ID_H264: @@ -162,17 +162,17 @@ static int hb_dx_create_video_decoder( hb_va_dxva2_t *dxva2, int codec_id, const surface->order = 0; } hb_log( "dxva2:CreateSurface succeed with %d, fmt (%dx%d) surfaces (%dx%d)", dxva2->surface_count, - fmt->width, fmt->height, dxva2->surface_width, dxva2->surface_height ); + fmt->geometry.width, fmt->geometry.height, dxva2->surface_width, dxva2->surface_height ); DXVA2_VideoDesc dsc; memset( &dsc, 0, sizeof(dsc)); - dsc.SampleWidth = fmt->width; - dsc.SampleHeight = fmt->height; + dsc.SampleWidth = fmt->geometry.width; + dsc.SampleHeight = fmt->geometry.height; dsc.Format = dxva2->render; - if( fmt->rate> 0 && fmt->rate_base> 0 ) + if( fmt->vrate.num > 0 && fmt->vrate.den > 0 ) { - dsc.InputSampleFreq.Numerator = fmt->rate; - dsc.InputSampleFreq.Denominator = fmt->rate_base; + dsc.InputSampleFreq.Numerator = fmt->vrate.num; + dsc.InputSampleFreq.Denominator = fmt->vrate.den; } else { @@ -489,8 +489,8 @@ static int hb_va_setup( hb_va_dxva2_t *dxva2, void **hw, int width, int height ) hb_title_t fmt; memset( &fmt, 0, sizeof(fmt)); - fmt.width = width; - fmt.height = height; + fmt.geometry.width = width; + fmt.geometry.height = height; if( hb_dx_create_video_decoder( dxva2, dxva2->codec_id, &fmt ) == HB_WORK_ERROR ) return HB_WORK_ERROR; |