cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
Highlighted
Contributor
Contributor
3,171 Views
Registered: ‎09-30-2015

VPSS - Full Fledged deinterlace driver problem

Hello,

I found problem in VPSS driver. In configuration:

Input((768x288-Interlaced)Deintrelacer ->((768x576)Scaler -> Output(800x600).

Video stream after Deinterlacing have doubled lines count (288 lines to 576) and this stream is going to scaler. But is not possible set scaler Zoom windows to this size. Problem is in function static XVprocSs_ScaleMode GetScalingMode(XVprocSs *XVprocSsPtr) when function test validateWindowSize validity. This problem code:

 

  if(XVprocSs_IsZoomModeOn(XVprocSsPtr))
  {
    /* Read PIP window setting - set elsewhere */
    XVprocSs_GetZoomPipWindow(XVprocSsPtr, XVPROCSS_ZOOM_WIN, &win);
    /* validate window */
    status = validateWindowSize(&win,
	                            StrmInPtr->Timing.HActive,
	                            StrmInPtr->Timing.VActive);
    if(status != XST_SUCCESS)
    {
      XVprocSs_LogWrite(XVprocSsPtr, XVPROCSS_EVT_CFG_MAX, XVPROCSS_EDAT_MAX_RDWINBAD);
	  return(XVPROCSS_SCALE_NOT_SUPPORTED);
    }
    else
    {
      XVprocSs_LogWrite(XVprocSsPtr, XVPROCSS_EVT_CFG_MAX, XVPROCSS_EDAT_MAX_SCALEUP);
      return (XVPROCSS_SCALE_UP);
    }
  }

I changed to this:

 

 

  if(XVprocSs_IsZoomModeOn(XVprocSsPtr))
  {
    /* Read PIP window setting - set elsewhere */
    XVprocSs_GetZoomPipWindow(XVprocSsPtr, XVPROCSS_ZOOM_WIN, &win);
    /* validate window */
    // TODO - Report
    u16 VActive;
    if( XVprocSs_GetSubsystemTopology(XVprocSsPtr) == XVPROCSS_TOPOLOGY_FULL_FLEDGED ){
    	if( StrmInPtr->IsInterlaced )
    		VActive = 2*StrmInPtr->Timing.VActive;
    	else
    		VActive = StrmInPtr->Timing.VActive;
    } else {
    	VActive = StrmInPtr->Timing.VActive;
    }

    if(status != XST_SUCCESS)
    {
      XVprocSs_LogWrite(XVprocSsPtr, XVPROCSS_EVT_CFG_MAX, XVPROCSS_EDAT_MAX_RDWINBAD);
	  return(XVPROCSS_SCALE_NOT_SUPPORTED);
    }
    else
    {
      XVprocSs_LogWrite(XVprocSsPtr, XVPROCSS_EVT_CFG_MAX, XVPROCSS_EDAT_MAX_SCALEUP);
      return (XVPROCSS_SCALE_UP);
    }
  }

 

This is working correctly

Regards

Kulich

0 Kudos
2 Replies
Highlighted
Contributor
Contributor
3,137 Views
Registered: ‎09-30-2015

Little correction. In previous post is a mistake (missing calling function validateWindowSize). This is better and working (tested) code:

 

// TODO - Report
    u16 VActive;
    if( XVprocSs_GetSubsystemTopology(XVprocSsPtr) == XVPROCSS_TOPOLOGY_FULL_FLEDGED ){
    	if( StrmInPtr->IsInterlaced )
    		VActive = 2*StrmInPtr->Timing.VActive;
    	else
    		VActive = StrmInPtr->Timing.VActive;
    } else {
    	VActive = StrmInPtr->Timing.VActive;
    }
    status = validateWindowSize(&win,
	                            StrmInPtr->Timing.HActive
VActive);

 

0 Kudos
Highlighted
Xilinx Employee
Xilinx Employee
3,031 Views
Registered: ‎05-07-2015

HI @kulich

 

 

yes you are right valid window size check of interlaced video seems incorrect. I will check on this. and report this to development if need be, and get back to you.

Thanks
Bharath
--------------------------------------------------​--------------------------------------------
Please mark the Answer as "Accept as solution" if information provided addresses your query/concern.
Give Kudos to a post which you think is helpful.
--------------------------------------------------​-------------------------------------------
0 Kudos