XilinxProcessorIPLib/drivers/dp14txss/examples/src/pt_only/xdptxss_dp14_pt.c
int ConfigFrmbuf_rd(u32 StrideInBytes,
						XVidC_ColorFormat Cfmt,
						XVidC_VideoStream *StreamPtr)
	{
#if XPAR_XV_FRMBUFRD_NUM_INSTANCES
	int Status;

	XVFRMBUFRD_BUFFER_BASEADDR = frame_array[frame_pointer];
	XVFRMBUFRD_BUFFER_BASEADDR_Y = frame_array_y[frame_pointer];

	/* Configure  Frame Buffers */
	Status = XVFrmbufRd_SetMemFormat(&frmbufrd, StrideInBytes, Cfmt, StreamPtr);
	if(Status != XST_SUCCESS) {
		xil_printf("ERROR:: Unable to configure Frame Buffer Read\r\n");
		return(XST_FAILURE);
	}

	if (!supports_adaptive || !ADAPTIVE_TYPE) {
		Status = XVFrmbufRd_SetBufferAddr(&frmbufrd, XVFRMBUFRD_BUFFER_BASEADDR);
		Status |= XVFrmbufRd_SetChromaBufferAddr(&frmbufrd, XVFRMBUFRD_BUFFER_BASEADDR_Y);
		if(Status != XST_SUCCESS) {
			xil_printf("ERROR:: Unable to configure Frame Buffer "
					"Read buffer address\r\n");
			return(XST_FAILURE);
		}
	}

	/* Enable Interrupt */
	XVFrmbufRd_InterruptEnable(&frmbufrd,
			XVFRMBUFRD_HANDLER_DONE);

	/* When Adaptive mode is 0 or Monitor does not support Adaptive Sync
	 * the FB read is configured in AutoEnableRestart mode
	 */
	if (!supports_adaptive || !ADAPTIVE_TYPE) {
		XV_frmbufrd_EnableAutoRestart(&frmbufrd.FrmbufRd);
		/* Start Frame Buffers */
		XVFrmbufRd_Start(&frmbufrd);
	}
	//xil_printf("INFO: FRMBUFrd configured\r\n");
	return(Status);
#endif
}
/*****************************************************************************/
/**
 * This function configures Frame Buffer for defined mode
 * The FrramBuffer is put in Autorestart mode for non-Adaptive Sync mode
 * When Adaptive Sync mode is enabled the FrameBuffer is put in manual mode
 *
 * @return XST_SUCCESS if init is OK else XST_FAILURE
 *
 *****************************************************************************/
This function configures Frame Buffer for defined mode
The FrramBuffer is put in Autorestart mode for non-Adaptive Sync mode
When Adaptive Sync mode is enabled the FrameBuffer is put in manual mode

@return XST_SUCCESS if init is OK else XST_FAILURE
This function configures Frame Buffer for defined mode The FrramBuffer is put in Autorestart mode for non - Adaptive Sync mode When Adaptive Sync mode is enabled the FrameBuffer is put in manual mode @return XST_SUCCESS if init is OK else XST_FAILURE
int ConfigFrmbuf_rd(u32 StrideInBytes,
						XVidC_ColorFormat Cfmt,
						XVidC_VideoStream *StreamPtr)
	{
#if XPAR_XV_FRMBUFRD_NUM_INSTANCES
	int Status;
	XVFRMBUFRD_BUFFER_BASEADDR = frame_array[frame_pointer];
	XVFRMBUFRD_BUFFER_BASEADDR_Y = frame_array_y[frame_pointer];
	Status = XVFrmbufRd_SetMemFormat(&frmbufrd, StrideInBytes, Cfmt, StreamPtr);
	if(Status != XST_SUCCESS) {
		xil_printf("ERROR:: Unable to configure Frame Buffer Read\r\n");
		return(XST_FAILURE);
	}
	if (!supports_adaptive || !ADAPTIVE_TYPE) {
		Status = XVFrmbufRd_SetBufferAddr(&frmbufrd, XVFRMBUFRD_BUFFER_BASEADDR);
		Status |= XVFrmbufRd_SetChromaBufferAddr(&frmbufrd, XVFRMBUFRD_BUFFER_BASEADDR_Y);
		if(Status != XST_SUCCESS) {
			xil_printf("ERROR:: Unable to configure Frame Buffer "
					"Read buffer address\r\n");
			return(XST_FAILURE);
		}
	}
	XVFrmbufRd_InterruptEnable(&frmbufrd,
			XVFRMBUFRD_HANDLER_DONE);
	if (!supports_adaptive || !ADAPTIVE_TYPE) {
		XV_frmbufrd_EnableAutoRestart(&frmbufrd.FrmbufRd);
		XVFrmbufRd_Start(&frmbufrd);
	}
	return(Status);
#endif
}
int ConfigFrmbuf_rd ( u32 StrideInBytes , XVidC_ColorFormat Cfmt , XVidC_VideoStream * StreamPtr ) { #if XPAR_XV_FRMBUFRD_NUM_INSTANCES int Status ; XVFRMBUFRD_BUFFER_BASEADDR = frame_array [ frame_pointer ] ; XVFRMBUFRD_BUFFER_BASEADDR_Y = frame_array_y [ frame_pointer ] ; Status = XVFrmbufRd_SetMemFormat ( & frmbufrd , StrideInBytes , Cfmt , StreamPtr ) ; if ( Status != XST_SUCCESS ) { xil_printf ( " \r \n " ) ; return ( XST_FAILURE ) ; } if ( ! supports_adaptive || ! ADAPTIVE_TYPE ) { Status = XVFrmbufRd_SetBufferAddr ( & frmbufrd , XVFRMBUFRD_BUFFER_BASEADDR ) ; Status |= XVFrmbufRd_SetChromaBufferAddr ( & frmbufrd , XVFRMBUFRD_BUFFER_BASEADDR_Y ) ; if ( Status != XST_SUCCESS ) { xil_printf ( " " " \r \n " ) ; return ( XST_FAILURE ) ; } } XVFrmbufRd_InterruptEnable ( & frmbufrd , XVFRMBUFRD_HANDLER_DONE ) ; if ( ! supports_adaptive || ! ADAPTIVE_TYPE ) { XV_frmbufrd_EnableAutoRestart ( & frmbufrd . FrmbufRd ) ; XVFrmbufRd_Start ( & frmbufrd ) ; } return ( Status ) ; #endif }
This function configures Frame Buffer for defined mode
 The FrramBuffer is put in Autorestart mode for non-Adaptive Sync mode
 When Adaptive Sync mode is enabled the FrameBuffer is put in manual mode
This function configures Frame Buffer for defined mode The FrramBuffer is put in Autorestart mode for non - Adaptive Sync mode When Adaptive Sync mode is enabled the FrameBuffer is put in manual mode
/* Configure  Frame Buffers */ /* Enable Interrupt */ /* When Adaptive mode is 0 or Monitor does not support Adaptive Sync
	 * the FB read is configured in AutoEnableRestart mode
	 */ /* Start Frame Buffers */ //xil_printf("INFO: FRMBUFrd configured\r\n");