📄 rprocrtc.h
字号:
//
// Copyright (c) Microsoft Corporation. All rights reserved.
//
//
// Use of this source code is subject to the terms of the Microsoft end-user
// license agreement (EULA) under which you licensed this SOFTWARE PRODUCT.
// If you did not accept the terms of the EULA, you are not authorized to use
// this source code. For a copy of the EULA, please see the LICENSE.RTF on your
// install media.
//
/*****************************************************************************\
*
* Module Name RPROCRTC.H
* ASIC 3D RAGE PRO/LT PRO WindowsNT
*
* Description Header files for the Crtcpro.c
*
* (c) 1998 ATI Technologies Inc. (unpublished)
*
* All rights reserved. This notice is intended as a precaution against
* inadvertent publication and does not imply publication or any waiver
* of confidentiality. The year included in the foregoing notice is the
* year of creation of the work.
*
* LOG OF CHANGES :
*
* 1.0 05/04/98 [SAH] Initial revision
*
*
*
\*****************************************************************************/
#ifndef _RPROCRTC_H_
#define _RPROCRTC_H_
#include "dal.h"
#pragma pack(1)
#define MAX_NO_OF_LCD_RES_TIMING 20
typedef struct _BIOS_GENERAL_LCD_CRTC_TIMING // Structures used for setting and querying CRTC timings.
{
USHORT usCRTC_H_TOTAL; // Horizontal total (pixels * 8)
UCHAR ucCRTC_H_DISP; // Horizontal display end (pixels * 8)
UCHAR ucCRTC_H_SYNC_START; // Horizontal sync start (pixels * 8)
UCHAR ucCRTC_H_SYNC_DLY;
UCHAR ucCRTC_H_SYNC_WID; // Horizontal sync width (pixels * 8)
USHORT usCRTC_V_TOTAL; // Vertical tatal
USHORT usCRTC_V_DISP; // Vertical display end
USHORT usCRTC_V_SYNC_START; // Vertical sync start
UCHAR ucCRTC_V_SYNC_WID; // Vertical sync width
USHORT usPixelClock; // Pixel clock frequency to use
UCHAR ucOVR_WID_LEFT; // Left overscan width (pixels * 8)
UCHAR ucOVR_WID_RIGHT; // Right overscan width (pixels * 8)
USHORT usOVR_WID_TOP; // Top overscan width (in scan lines)
USHORT usOVR_WID_BOTTOM; // Bottom overscan width (in scan lines)
UCHAR ucOVR_CLR_8; // Overscan color INDEX, output on feature connector in
// in 4 and 8 bpp modes
UCHAR ucOVR_CLR_B; // Blue overscan color, to internal DAC
UCHAR ucOVR_CLR_G; // Green overscan color, to internal DAC
UCHAR ucOVR_CLR_R; // Red overscan color, to internal DAC
//LCD related fields needed for center mode
USHORT usFP_POS; // Defines the position of the frame pulse for the
// LCD panel (Needed for DSTN panels)
UCHAR ucHSYNC_DELAY; // Hsync delay for the LCD Panel { 0x0 = no delay
// 0xF = 15 vclks delay } 4 bit field
//LCD related fields needed for expansion mode
USHORT usHORZ_BLEND_RATIO; // Actually HORZ_STRETCH_RATIO (but we only
// currently support blending no pixel
// replication
USHORT usVERT_STRETCH_RATIO0; // Vertical Stretch ratio for coprocessor mode
UCHAR ucTVO_H_TOT_PIX; // TVO_CNTL Fine horizontal pixel control for
// dependant on device attached
//PLL stuff 10 bit for extended PLL otherwise 8 bit ( use extended for TV attached )
//for secondary CRTC there is only extended
USHORT usPLL_REF_DIV; //
USHORT usPLL_FB_DIV; // This is for Clock3 (CRTC1), for V2PLL (CRTC2)
UCHAR ucPLL_POST_DIV;
//Flags information (used for crt only)
USHORT usFlags;
} BIOS_GENERAL_CRTC_TIMING, FAR *LPBIOS_GENERAL_CRTC_TIMING;
typedef struct _PLL_DIVIDERS
{
//PLL stuff 10 bit for extended PLL otherwise 8 bit ( use extended for TV attached )
//for secondary CRTC there is only extended
USHORT usPLL_REF_DIV; //
USHORT usPLL_FB_DIV; // This is for Clock3 (CRTC1), for V2PLL (CRTC2)
UCHAR ucPLL_POST_DIV;
} PLL_DIVIDERS, FAR *LPPLL_DIVIDERS;
typedef struct _FREQ_CONSTANTS
{
ULONG ulREF_FREQ;
ULONG ulREF_DIVIDER;
ULONG ulMIN_FREQ;
ULONG ulMAX_FREQ;
} FREQ_CONSTANTS, FAR *LPFREQ_CONSTANTS;
typedef struct _PANEL_INFO
{
USHORT usHorizontalSize; // in pixels
USHORT usVerticalSize; // in lines
USHORT usFlatPanelType;
UCHAR ucPanelRefreshRateData;
USHORT usSupportedRefreshRate;
} PANEL_INFO, FAR *LPPANEL_INFO;
#pragma pack()
#pragma pack(1) // BIOS data must use byte aligment
/*
typedef struct _BIOS_INFO_TABLE
{
UCHAR ucInfoTableSignature[4];
UCHAR ucInfoTableRevision;
UCHAR ucOffsetToBiosInfoTableSize;
USHORT usOffsetToCrtParameterTable;
USHORT usOffsetToCrtParameterTableSize;
USHORT usOffsetToLcdParameterTable;
USHORT usOffsetToTvParameterTable;
USHORT usRefDivider;
USHORT usMinFreq;
USHORT usMaxFreq;
USHORT usRefFreq;
USHORT usOffsetToHardwareInfoTable;
USHORT usOffsetToMultiMediaTable;
}BIOS_INFO_TABLE, FAR *LPBIOS_INFO_TABLE;
*/
typedef struct _PANEL_INFORMATION_TABLE
{
UCHAR ucPanelIdentification; // (0x00 - 0x1F)
UCHAR ucPanelIDString[24];
USHORT usHorizontalSize; // in pixels
USHORT usVerticalSize; // in lines
USHORT usFlatPanelType;
UCHAR ucRedBitsPerPrimary;
UCHAR ucGreenBitsPerPrimary;
UCHAR ucBlueBitsPerPrimary;
UCHAR ucReservedBitsPerPrimary;
ULONG ulPtrToOffScreenMemoryRequired; //for frame buffer
ULONG ulPtrToReservedOffScreenMemory; //for frame buffer
UCHAR ucReserved[13];
UCHAR ucPowerSequenceDelay;
ULONG ulPanelData;
UCHAR ucPanelRefreshRateData;
USHORT usSupportedRefreshRate;
USHORT usModeTableOffset[MAX_NO_OF_LCD_RES_TIMING];
}PANEL_INFORMATION_TABLE, FAR *LPPANEL_INFORMATION_TABLE;
typedef struct _LCD_MODE_TABLE_CENTER
{
USHORT usHorizontalRes;
USHORT usVerticalRes;
UCHAR ucModeType;
USHORT usOffset2ExpParamTable;
USHORT usOffset2TvParamTable;
USHORT usPixelClock;
USHORT usPixelClockAdjustment;
ULONG ulFpPos;
USHORT usCrtcHTotal;
USHORT usCrtcHDisp;
USHORT usCrtcHSyncStrt;
UCHAR ucCrtcHSyncWid;
USHORT usCrtcVTotal;
USHORT usCrtcVDisp;
USHORT usCrtcVSyncStrt;
UCHAR ucOvrWidTop;
}LCD_MODE_TABLE_CENTER, FAR *LPLCD_MODE_TABLE_CENTER;
typedef struct _LCD_MODE_TABLE_EXP
{
USHORT usPixelClock;
USHORT usPixelClockAdjustment;
ULONG ulFpPos;
USHORT usCrtcHTotal;
USHORT usCrtcHDisp;
USHORT usCrtcHSyncStrt;
UCHAR ucCrtcHSyncWid;
USHORT usCrtcVTotal;
USHORT usCrtcVDisp;
USHORT usCrtcVSyncStrt;
UCHAR ucOvrWidTop;
USHORT usHorizontalBlendRatio;
ULONG ulVgaVertStretching;
USHORT usCopVertStretching;
USHORT usVgaExtVertStretching;
}LCD_MODE_TABLE_EXP, FAR *LPLCD_MODE_TABLE_EXP;
typedef struct _TVO_MODE_TABLE
{
USHORT usHorizontalRes;
USHORT usVerticalRes;
USHORT usCrtcHTotalDisp;
USHORT usCrtcHSyncStrtWid;
USHORT usCrtcVTotal;
USHORT usCrtcVSyncStrt;
UCHAR ucCrtcVSyncWid;
USHORT usPixelClock;
}TVO_MODE_TABLE, FAR *LPTVO_MODE_TABLE;
typedef struct _DYNAMIC_PMMODE_TABLE
{
USHORT usMinPixelClock;
USHORT usMaxPixelClock;
USHORT usMinXClkValue;
USHORT usMaxBpp;
USHORT usReserved1;
USHORT usReserevd2;
}DYNAMIC_PMMODE_TABLE, FAR *LPDYNAMIC_PMMODE_TABLE;
typedef struct _MULTI_MEDIA_ATTRB_TABLE
{
UCHAR ucTunerAttribute;
UCHAR ucDecoderAttribute;
UCHAR ucAudioAttribute;
UCHAR ucVideoOutputAttribute;
UCHAR ucMmbType;
UCHAR ucOemRevision;
UCHAR ucFeatures;
UCHAR ucReserved;
}MULTI_MEDIA_ATTRB_TABLE, FAR* LPMULTI_MEDIA_ATTRB_TABLE;
#pragma pack()
/*
typedef struct _ADJUSTMENT_PARAMETERS
{
USHORT usCRTC_H_TOTAL; // Horizontal total (pixels * 8)
UCHAR ucCRTC_H_SYNC_START; // Horizontal sync start (pixels * 8)
USHORT usCRTC_V_TOTAL; // Vertical tatal
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -