; Listing generated by Microsoft (R) Optimizing Compiler Version 15.00.21022.08 

	TITLE	c:\Develop\DScaler423a\DScaler\SAA7134Card_Video.cpp
	.686P
	.XMM
	include listing.inc
	.model	flat

INCLUDELIB OLDNAMES

EXTRN	_pow:PROC
;	COMDAT ?vals@?1??SetHPrescale@CSAA7134Card@@IAEXW4eTaskID@CSAA7134Common@@GG@Z@4QBU<unnamed-type-vals>@?1??12@IAEX0GG@Z@B
CONST	SEGMENT
?vals@?1??SetHPrescale@CSAA7134Card@@IAEXW4eTaskID@CSAA7134Common@@GG@Z@4QBU<unnamed-type-vals>@?1??12@IAEX0GG@Z@B DD 01H ; `CSAA7134Card::SetHPrescale'::`2'::vals
	DD	00H
	DD	00H
	DD	00H
	DD	00H
	DD	02H
	DD	02H
	DD	01H
	DD	02H
	DD	02H
	DD	03H
	DD	04H
	DD	01H
	DD	03H
	DD	02H
	DD	04H
	DD	08H
	DD	01H
	DD	04H
	DD	02H
	DD	05H
	DD	08H
	DD	01H
	DD	04H
	DD	02H
	DD	06H
	DD	08H
	DD	01H
	DD	04H
	DD	03H
	DD	07H
	DD	08H
	DD	01H
	DD	04H
	DD	03H
	DD	08H
	DD	0fH
	DD	00H
	DD	04H
	DD	03H
	DD	09H
	DD	0fH
	DD	00H
	DD	04H
	DD	03H
	DD	0aH
	DD	010H
	DD	01H
	DD	05H
	DD	03H
PUBLIC	?GetMinimumVDelayWithVBI@CSAA7134Card@@QAEJXZ	; CSAA7134Card::GetMinimumVDelayWithVBI
; Function compile flags: /Odtp
; File c:\develop\dscaler423a\dscaler\saa7134card_video.cpp
;	COMDAT ?GetMinimumVDelayWithVBI@CSAA7134Card@@QAEJXZ
_TEXT	SEGMENT
_this$ = -12						; size = 4
_VDelay$ = -8						; size = 2
_VBIStopLine$ = -4					; size = 2
?GetMinimumVDelayWithVBI@CSAA7134Card@@QAEJXZ PROC	; CSAA7134Card::GetMinimumVDelayWithVBI, COMDAT
; _this$ = ecx

; 347  : {

  00000	55		 push	 ebp
  00001	8b ec		 mov	 ebp, esp
  00003	83 ec 0c	 sub	 esp, 12			; 0000000cH
  00006	89 4d f4	 mov	 DWORD PTR _this$[ebp], ecx

; 348  :     WORD VDelay         = m_VideoStandards[m_VideoStandard].wVDelay;

  00009	8b 45 f4	 mov	 eax, DWORD PTR _this$[ebp]
  0000c	8b 88 ac 00 00
	00		 mov	 ecx, DWORD PTR [eax+172]
  00012	6b c9 14	 imul	 ecx, 20			; 00000014H
  00015	66 8b 91 06 00
	00 00		 mov	 dx, WORD PTR ?m_VideoStandards@CSAA7134Common@@1PAUTVideoStandardDefinition@1@A[ecx+6]
  0001c	66 89 55 f8	 mov	 WORD PTR _VDelay$[ebp], dx

; 349  :     WORD VBIStopLine    = m_VideoStandards[m_VideoStandard].wVBIStopLine;

  00020	8b 45 f4	 mov	 eax, DWORD PTR _this$[ebp]
  00023	8b 88 ac 00 00
	00		 mov	 ecx, DWORD PTR [eax+172]
  00029	6b c9 14	 imul	 ecx, 20			; 00000014H
  0002c	66 8b 91 0e 00
	00 00		 mov	 dx, WORD PTR ?m_VideoStandards@CSAA7134Common@@1PAUTVideoStandardDefinition@1@A[ecx+14]
  00033	66 89 55 fc	 mov	 WORD PTR _VBIStopLine$[ebp], dx

; 350  : 
; 351  :     return -(VDelay - VBIStopLine - 1) * 2;

  00037	0f b7 45 f8	 movzx	 eax, WORD PTR _VDelay$[ebp]
  0003b	0f b7 4d fc	 movzx	 ecx, WORD PTR _VBIStopLine$[ebp]
  0003f	2b c1		 sub	 eax, ecx
  00041	83 e8 01	 sub	 eax, 1
  00044	f7 d8		 neg	 eax
  00046	d1 e0		 shl	 eax, 1

; 352  : }

  00048	8b e5		 mov	 esp, ebp
  0004a	5d		 pop	 ebp
  0004b	c3		 ret	 0
?GetMinimumVDelayWithVBI@CSAA7134Card@@QAEJXZ ENDP	; CSAA7134Card::GetMinimumVDelayWithVBI
_TEXT	ENDS
PUBLIC	?GetMinimumVDelay@CSAA7134Card@@QAEJXZ		; CSAA7134Card::GetMinimumVDelay
; Function compile flags: /Odtp
;	COMDAT ?GetMinimumVDelay@CSAA7134Card@@QAEJXZ
_TEXT	SEGMENT
_this$ = -4						; size = 4
?GetMinimumVDelay@CSAA7134Card@@QAEJXZ PROC		; CSAA7134Card::GetMinimumVDelay, COMDAT
; _this$ = ecx

; 340  : {

  00000	55		 push	 ebp
  00001	8b ec		 mov	 ebp, esp
  00003	51		 push	 ecx
  00004	89 4d fc	 mov	 DWORD PTR _this$[ebp], ecx

; 341  :     // x2 because field lines x 2 = frame lines
; 342  :     return -(m_VideoStandards[m_VideoStandard].wVDelay) * 2;

  00007	8b 45 fc	 mov	 eax, DWORD PTR _this$[ebp]
  0000a	8b 88 ac 00 00
	00		 mov	 ecx, DWORD PTR [eax+172]
  00010	6b c9 14	 imul	 ecx, 20			; 00000014H
  00013	0f b7 81 06 00
	00 00		 movzx	 eax, WORD PTR ?m_VideoStandards@CSAA7134Common@@1PAUTVideoStandardDefinition@1@A[ecx+6]
  0001a	f7 d8		 neg	 eax
  0001c	d1 e0		 shl	 eax, 1

; 343  : }

  0001e	8b e5		 mov	 esp, ebp
  00020	5d		 pop	 ebp
  00021	c3		 ret	 0
?GetMinimumVDelay@CSAA7134Card@@QAEJXZ ENDP		; CSAA7134Card::GetMinimumVDelay
PUBLIC	?IsInterlacedSignalDetected@CSAA7134Card@@QAEHXZ ; CSAA7134Card::IsInterlacedSignalDetected
; Function compile flags: /Odtp
;	COMDAT ?IsInterlacedSignalDetected@CSAA7134Card@@QAEHXZ
_TEXT	SEGMENT
_this$ = -4						; size = 4
?IsInterlacedSignalDetected@CSAA7134Card@@QAEHXZ PROC	; CSAA7134Card::IsInterlacedSignalDetected, COMDAT
; _this$ = ecx

; 567  : {

  00000	55		 push	 ebp
  00001	8b ec		 mov	 ebp, esp
  00003	51		 push	 ecx
  00004	89 4d fc	 mov	 DWORD PTR _this$[ebp], ecx

; 568  :     return (ReadWord(SAA7134_STATUS_VIDEO) &
; 569  :         SAA7134_STATUS_VIDEO_INTL) != 0;

  00007	68 1e 01 00 00	 push	 286			; 0000011eH
  0000c	8b 4d fc	 mov	 ecx, DWORD PTR _this$[ebp]
  0000f	e8 00 00 00 00	 call	 ?ReadWord@CPCICard@@QAEGK@Z ; CPCICard::ReadWord
  00014	0f b7 c0	 movzx	 eax, ax
  00017	25 00 80 00 00	 and	 eax, 32768		; 00008000H
  0001c	f7 d8		 neg	 eax
  0001e	1b c0		 sbb	 eax, eax
  00020	f7 d8		 neg	 eax

; 570  : }

  00022	8b e5		 mov	 esp, ebp
  00024	5d		 pop	 ebp
  00025	c3		 ret	 0
?IsInterlacedSignalDetected@CSAA7134Card@@QAEHXZ ENDP	; CSAA7134Card::IsInterlacedSignalDetected
_TEXT	ENDS
PUBLIC	?Is25fpsSignalDetected@CSAA7134Card@@QAEHXZ	; CSAA7134Card::Is25fpsSignalDetected
; Function compile flags: /Odtp
;	COMDAT ?Is25fpsSignalDetected@CSAA7134Card@@QAEHXZ
_TEXT	SEGMENT
_this$ = -4						; size = 4
?Is25fpsSignalDetected@CSAA7134Card@@QAEHXZ PROC	; CSAA7134Card::Is25fpsSignalDetected, COMDAT
; _this$ = ecx

; 560  : {

  00000	55		 push	 ebp
  00001	8b ec		 mov	 ebp, esp
  00003	51		 push	 ecx
  00004	89 4d fc	 mov	 DWORD PTR _this$[ebp], ecx

; 561  :     return (ReadWord(SAA7134_STATUS_VIDEO) &
; 562  :         SAA7134_STATUS_VIDEO_FIDT) == 0;

  00007	68 1e 01 00 00	 push	 286			; 0000011eH
  0000c	8b 4d fc	 mov	 ecx, DWORD PTR _this$[ebp]
  0000f	e8 00 00 00 00	 call	 ?ReadWord@CPCICard@@QAEGK@Z ; CPCICard::ReadWord
  00014	0f b7 c0	 movzx	 eax, ax
  00017	25 00 20 00 00	 and	 eax, 8192		; 00002000H
  0001c	f7 d8		 neg	 eax
  0001e	1b c0		 sbb	 eax, eax
  00020	83 c0 01	 add	 eax, 1

; 563  : }

  00023	8b e5		 mov	 esp, ebp
  00025	5d		 pop	 ebp
  00026	c3		 ret	 0
?Is25fpsSignalDetected@CSAA7134Card@@QAEHXZ ENDP	; CSAA7134Card::Is25fpsSignalDetected
_TEXT	ENDS
PUBLIC	?SetGammaLevel@CSAA7134Card@@QAEXG@Z		; CSAA7134Card::SetGammaLevel
; Function compile flags: /Odtp
;	COMDAT ?SetGammaLevel@CSAA7134Card@@QAEXG@Z
_TEXT	SEGMENT
tv194 = -32						; size = 4
tv192 = -28						; size = 4
tv189 = -22						; size = 2
tv181 = -20						; size = 4
tv178 = -16						; size = 4
_this$ = -12						; size = 4
_AdjustedValue$144004 = -5				; size = 1
_i$144000 = -4						; size = 4
_bGammaLevel$ = 8					; size = 2
?SetGammaLevel@CSAA7134Card@@QAEXG@Z PROC		; CSAA7134Card::SetGammaLevel, COMDAT
; _this$ = ecx

; 524  : {

  00000	55		 push	 ebp
  00001	8b ec		 mov	 ebp, esp
  00003	83 ec 20	 sub	 esp, 32			; 00000020H
  00006	89 4d f4	 mov	 DWORD PTR _this$[ebp], ecx

; 525  :     WriteByte(SAA7134_START_GREEN, 0x00);

  00009	6a 00		 push	 0
  0000b	6a 0c		 push	 12			; 0000000cH
  0000d	8b 4d f4	 mov	 ecx, DWORD PTR _this$[ebp]
  00010	e8 00 00 00 00	 call	 ?WriteByte@CPCICard@@QAEXKE@Z ; CPCICard::WriteByte

; 526  :     WriteByte(SAA7134_START_BLUE, 0x00);

  00015	6a 00		 push	 0
  00017	6a 0d		 push	 13			; 0000000dH
  00019	8b 4d f4	 mov	 ecx, DWORD PTR _this$[ebp]
  0001c	e8 00 00 00 00	 call	 ?WriteByte@CPCICard@@QAEXKE@Z ; CPCICard::WriteByte

; 527  :     WriteByte(SAA7134_START_RED, 0x00);

  00021	6a 00		 push	 0
  00023	6a 0e		 push	 14			; 0000000eH
  00025	8b 4d f4	 mov	 ecx, DWORD PTR _this$[ebp]
  00028	e8 00 00 00 00	 call	 ?WriteByte@CPCICard@@QAEXKE@Z ; CPCICard::WriteByte

; 528  : 
; 529  :     for (int i = 0; i < 0x0F; i++)

  0002d	c7 45 fc 00 00
	00 00		 mov	 DWORD PTR _i$144000[ebp], 0
  00034	eb 09		 jmp	 SHORT $LN3@SetGammaLe
$LN2@SetGammaLe:
  00036	8b 45 fc	 mov	 eax, DWORD PTR _i$144000[ebp]
  00039	83 c0 01	 add	 eax, 1
  0003c	89 45 fc	 mov	 DWORD PTR _i$144000[ebp], eax
$LN3@SetGammaLe:
  0003f	83 7d fc 0f	 cmp	 DWORD PTR _i$144000[ebp], 15 ; 0000000fH
  00043	0f 8d 9e 00 00
	00		 jge	 $LN1@SetGammaLe

; 530  :     {
; 531  :         BYTE AdjustedValue = (BYTE)(255.0 * pow(((i+1)<<4)/255.0, 1000/(double)bGammaLevel));

  00049	0f b7 4d 08	 movzx	 ecx, WORD PTR _bGammaLevel$[ebp]
  0004d	89 4d f0	 mov	 DWORD PTR tv178[ebp], ecx
  00050	db 45 f0	 fild	 DWORD PTR tv178[ebp]
  00053	dc 3d 00 00 00
	00		 fdivr	 QWORD PTR __real@408f400000000000
  00059	83 ec 08	 sub	 esp, 8
  0005c	dd 1c 24	 fstp	 QWORD PTR [esp]
  0005f	8b 55 fc	 mov	 edx, DWORD PTR _i$144000[ebp]
  00062	83 c2 01	 add	 edx, 1
  00065	c1 e2 04	 shl	 edx, 4
  00068	89 55 ec	 mov	 DWORD PTR tv181[ebp], edx
  0006b	db 45 ec	 fild	 DWORD PTR tv181[ebp]
  0006e	dc 35 00 00 00
	00		 fdiv	 QWORD PTR __real@406fe00000000000
  00074	83 ec 08	 sub	 esp, 8
  00077	dd 1c 24	 fstp	 QWORD PTR [esp]
  0007a	e8 00 00 00 00	 call	 _pow
  0007f	83 c4 10	 add	 esp, 16			; 00000010H
  00082	dc 0d 00 00 00
	00		 fmul	 QWORD PTR __real@406fe00000000000
  00088	d9 7d ea	 fnstcw	 WORD PTR tv189[ebp]
  0008b	0f b7 45 ea	 movzx	 eax, WORD PTR tv189[ebp]
  0008f	0d 00 0c 00 00	 or	 eax, 3072		; 00000c00H
  00094	89 45 e4	 mov	 DWORD PTR tv192[ebp], eax
  00097	d9 6d e4	 fldcw	 WORD PTR tv192[ebp]
  0009a	db 5d e0	 fistp	 DWORD PTR tv194[ebp]
  0009d	d9 6d ea	 fldcw	 WORD PTR tv189[ebp]
  000a0	8a 45 e0	 mov	 al, BYTE PTR tv194[ebp]
  000a3	88 45 fb	 mov	 BYTE PTR _AdjustedValue$144004[ebp], al

; 532  : 
; 533  :         WriteByte(SAA7134_GREEN_PATH(i), AdjustedValue);

  000a6	0f b6 4d fb	 movzx	 ecx, BYTE PTR _AdjustedValue$144004[ebp]
  000aa	51		 push	 ecx
  000ab	8b 55 fc	 mov	 edx, DWORD PTR _i$144000[ebp]
  000ae	83 ca 10	 or	 edx, 16			; 00000010H
  000b1	52		 push	 edx
  000b2	8b 4d f4	 mov	 ecx, DWORD PTR _this$[ebp]
  000b5	e8 00 00 00 00	 call	 ?WriteByte@CPCICard@@QAEXKE@Z ; CPCICard::WriteByte

; 534  :         WriteByte(SAA7134_BLUE_PATH(i), AdjustedValue);

  000ba	0f b6 45 fb	 movzx	 eax, BYTE PTR _AdjustedValue$144004[ebp]
  000be	50		 push	 eax
  000bf	8b 4d fc	 mov	 ecx, DWORD PTR _i$144000[ebp]
  000c2	83 c9 20	 or	 ecx, 32			; 00000020H
  000c5	51		 push	 ecx
  000c6	8b 4d f4	 mov	 ecx, DWORD PTR _this$[ebp]
  000c9	e8 00 00 00 00	 call	 ?WriteByte@CPCICard@@QAEXKE@Z ; CPCICard::WriteByte

; 535  :         WriteByte(SAA7134_RED_PATH(i), AdjustedValue);

  000ce	0f b6 55 fb	 movzx	 edx, BYTE PTR _AdjustedValue$144004[ebp]
  000d2	52		 push	 edx
  000d3	8b 45 fc	 mov	 eax, DWORD PTR _i$144000[ebp]
  000d6	83 c8 30	 or	 eax, 48			; 00000030H
  000d9	50		 push	 eax
  000da	8b 4d f4	 mov	 ecx, DWORD PTR _this$[ebp]
  000dd	e8 00 00 00 00	 call	 ?WriteByte@CPCICard@@QAEXKE@Z ; CPCICard::WriteByte

; 536  :     }

  000e2	e9 4f ff ff ff	 jmp	 $LN2@SetGammaLe
$LN1@SetGammaLe:

; 537  : 
; 538  :     WriteByte(SAA7134_GREEN_PATH(0x0F), 0xFF);

  000e7	68 ff 00 00 00	 push	 255			; 000000ffH
  000ec	6a 1f		 push	 31			; 0000001fH
  000ee	8b 4d f4	 mov	 ecx, DWORD PTR _this$[ebp]
  000f1	e8 00 00 00 00	 call	 ?WriteByte@CPCICard@@QAEXKE@Z ; CPCICard::WriteByte

; 539  :     WriteByte(SAA7134_BLUE_PATH(0x0F), 0xFF);

  000f6	68 ff 00 00 00	 push	 255			; 000000ffH
  000fb	6a 2f		 push	 47			; 0000002fH
  000fd	8b 4d f4	 mov	 ecx, DWORD PTR _this$[ebp]
  00100	e8 00 00 00 00	 call	 ?WriteByte@CPCICard@@QAEXKE@Z ; CPCICard::WriteByte

; 540  :     WriteByte(SAA7134_RED_PATH(0x0F), 0xFF);

  00105	68 ff 00 00 00	 push	 255			; 000000ffH
  0010a	6a 3f		 push	 63			; 0000003fH
  0010c	8b 4d f4	 mov	 ecx, DWORD PTR _this$[ebp]
  0010f	e8 00 00 00 00	 call	 ?WriteByte@CPCICard@@QAEXKE@Z ; CPCICard::WriteByte

; 541  : }

  00114	8b e5		 mov	 esp, ebp
  00116	5d		 pop	 ebp
  00117	c2 04 00	 ret	 4
?SetGammaLevel@CSAA7134Card@@QAEXG@Z ENDP		; CSAA7134Card::SetGammaLevel
_TEXT	ENDS
PUBLIC	?GetColorPeak@CSAA7134Card@@QAEHXZ		; CSAA7134Card::GetColorPeak
; Function compile flags: /Odtp
;	COMDAT ?GetColorPeak@CSAA7134Card@@QAEHXZ
_TEXT	SEGMENT
_this$ = -4						; size = 4
?GetColorPeak@CSAA7134Card@@QAEHXZ PROC			; CSAA7134Card::GetColorPeak, COMDAT
; _this$ = ecx

; 460  : {

  00000	55		 push	 ebp
  00001	8b ec		 mov	 ebp, esp
  00003	51		 push	 ecx
  00004	89 4d fc	 mov	 DWORD PTR _this$[ebp], ecx

; 461  :     return (ReadByte(SAA7134_ANALOG_IN_CTRL2) &
; 462  :         SAA7134_ANALOG_IN_CTRL2_CPOFF) == 0;

  00007	68 03 01 00 00	 push	 259			; 00000103H
  0000c	8b 4d fc	 mov	 ecx, DWORD PTR _this$[ebp]
  0000f	e8 00 00 00 00	 call	 ?ReadByte@CPCICard@@QAEEK@Z ; CPCICard::ReadByte
  00014	0f b6 c0	 movzx	 eax, al
  00017	83 e0 10	 and	 eax, 16			; 00000010H
  0001a	f7 d8		 neg	 eax
  0001c	1b c0		 sbb	 eax, eax
  0001e	83 c0 01	 add	 eax, 1

; 463  : }

  00021	8b e5		 mov	 esp, ebp
  00023	5d		 pop	 ebp
  00024	c3		 ret	 0
?GetColorPeak@CSAA7134Card@@QAEHXZ ENDP			; CSAA7134Card::GetColorPeak
_TEXT	ENDS
PUBLIC	?GetWhitePeak@CSAA7134Card@@QAEHXZ		; CSAA7134Card::GetWhitePeak
; Function compile flags: /Odtp
;	COMDAT ?GetWhitePeak@CSAA7134Card@@QAEHXZ
_TEXT	SEGMENT
_this$ = -4						; size = 4
?GetWhitePeak@CSAA7134Card@@QAEHXZ PROC			; CSAA7134Card::GetWhitePeak, COMDAT
; _this$ = ecx

; 441  : {

  00000	55		 push	 ebp
  00001	8b ec		 mov	 ebp, esp
  00003	51		 push	 ecx
  00004	89 4d fc	 mov	 DWORD PTR _this$[ebp], ecx

; 442  :     return (ReadByte(SAA7134_INCR_DELAY) & SAA7134_INCR_DELAY_WPOFF) == 0;

  00007	68 01 01 00 00	 push	 257			; 00000101H
  0000c	8b 4d fc	 mov	 ecx, DWORD PTR _this$[ebp]
  0000f	e8 00 00 00 00	 call	 ?ReadByte@CPCICard@@QAEEK@Z ; CPCICard::ReadByte
  00014	0f b6 c0	 movzx	 eax, al
  00017	83 e0 40	 and	 eax, 64			; 00000040H
  0001a	f7 d8		 neg	 eax
  0001c	1b c0		 sbb	 eax, eax
  0001e	83 c0 01	 add	 eax, 1

; 443  : }

  00021	8b e5		 mov	 esp, ebp
  00023	5d		 pop	 ebp
  00024	c3		 ret	 0
?GetWhitePeak@CSAA7134Card@@QAEHXZ ENDP			; CSAA7134Card::GetWhitePeak
_TEXT	ENDS
PUBLIC	?IsVBIActive@CSAA7134Card@@IAEHXZ		; CSAA7134Card::IsVBIActive
; Function compile flags: /Odtp
;	COMDAT ?IsVBIActive@CSAA7134Card@@IAEHXZ
_TEXT	SEGMENT
_this$ = -8						; size = 4
_Region$ = -1						; size = 1
?IsVBIActive@CSAA7134Card@@IAEHXZ PROC			; CSAA7134Card::IsVBIActive, COMDAT
; _this$ = ecx

; 332  : {

  00000	55		 push	 ebp
  00001	8b ec		 mov	 ebp, esp
  00003	83 ec 08	 sub	 esp, 8
  00006	89 4d f8	 mov	 DWORD PTR _this$[ebp], ecx

; 333  :     BYTE Region = SAA7134_REGION_ENABLE_VBI_ENA | SAA7134_REGION_ENABLE_VBI_ENB;

  00009	c6 45 ff 22	 mov	 BYTE PTR _Region$[ebp], 34 ; 00000022H

; 334  : 
; 335  :     return (ReadByte(SAA7134_REGION_ENABLE) & Region) != 0;

  0000d	6a 04		 push	 4
  0000f	8b 4d f8	 mov	 ecx, DWORD PTR _this$[ebp]
  00012	e8 00 00 00 00	 call	 ?ReadByte@CPCICard@@QAEEK@Z ; CPCICard::ReadByte
  00017	0f b6 c0	 movzx	 eax, al
  0001a	0f b6 4d ff	 movzx	 ecx, BYTE PTR _Region$[ebp]
  0001e	23 c1		 and	 eax, ecx
  00020	f7 d8		 neg	 eax
  00022	1b c0		 sbb	 eax, eax
  00024	f7 d8		 neg	 eax

; 336  : }

  00026	8b e5		 mov	 esp, ebp
  00028	5d		 pop	 ebp
  00029	c3		 ret	 0
?IsVBIActive@CSAA7134Card@@IAEHXZ ENDP			; CSAA7134Card::IsVBIActive
_TEXT	ENDS
PUBLIC	?CheckVBIAndVideoOverlap@CSAA7134Card@@IAEXW4eTaskID@CSAA7134Common@@@Z ; CSAA7134Card::CheckVBIAndVideoOverlap
; Function compile flags: /Odtp
;	COMDAT ?CheckVBIAndVideoOverlap@CSAA7134Card@@IAEXW4eTaskID@CSAA7134Common@@@Z
_TEXT	SEGMENT
_this$ = -24						; size = 4
_VIDStopLine$143912 = -20				; size = 2
_VBIStopLine$ = -16					; size = 2
_VIDStartLine$ = -12					; size = 2
_Delta$ = -8						; size = 4
_TaskMask$ = -1						; size = 1
_TaskID$ = 8						; size = 4
?CheckVBIAndVideoOverlap@CSAA7134Card@@IAEXW4eTaskID@CSAA7134Common@@@Z PROC ; CSAA7134Card::CheckVBIAndVideoOverlap, COMDAT
; _this$ = ecx

; 313  : {

  00000	55		 push	 ebp
  00001	8b ec		 mov	 ebp, esp
  00003	83 ec 18	 sub	 esp, 24			; 00000018H
  00006	89 4d e8	 mov	 DWORD PTR _this$[ebp], ecx

; 314  :     BYTE TaskMask = TaskID2TaskMask(TaskID);

  00009	8b 45 08	 mov	 eax, DWORD PTR _TaskID$[ebp]
  0000c	50		 push	 eax
  0000d	8b 4d e8	 mov	 ecx, DWORD PTR _this$[ebp]
  00010	e8 00 00 00 00	 call	 ?TaskID2TaskMask@CSAA7134Card@@IAEEW4eTaskID@CSAA7134Common@@@Z ; CSAA7134Card::TaskID2TaskMask
  00015	88 45 ff	 mov	 BYTE PTR _TaskMask$[ebp], al

; 315  : 
; 316  :     WORD VBIStopLine = ReadWord(SAA7134_VBI_V_STOP(TaskMask));

  00018	0f b6 4d ff	 movzx	 ecx, BYTE PTR _TaskMask$[ebp]
  0001c	83 c9 0a	 or	 ecx, 10			; 0000000aH
  0001f	51		 push	 ecx
  00020	8b 4d e8	 mov	 ecx, DWORD PTR _this$[ebp]
  00023	e8 00 00 00 00	 call	 ?ReadWord@CPCICard@@QAEGK@Z ; CPCICard::ReadWord
  00028	66 89 45 f0	 mov	 WORD PTR _VBIStopLine$[ebp], ax

; 317  :     WORD VIDStartLine = ReadWord(SAA7134_VIDEO_V_START(TaskMask));

  0002c	0f b6 55 ff	 movzx	 edx, BYTE PTR _TaskMask$[ebp]
  00030	83 ca 18	 or	 edx, 24			; 00000018H
  00033	52		 push	 edx
  00034	8b 4d e8	 mov	 ecx, DWORD PTR _this$[ebp]
  00037	e8 00 00 00 00	 call	 ?ReadWord@CPCICard@@QAEGK@Z ; CPCICard::ReadWord
  0003c	66 89 45 f4	 mov	 WORD PTR _VIDStartLine$[ebp], ax

; 318  : 
; 319  :     int Delta;
; 320  : 
; 321  :     if ((Delta = VIDStartLine - VBIStopLine) < 1)

  00040	0f b7 45 f4	 movzx	 eax, WORD PTR _VIDStartLine$[ebp]
  00044	0f b7 4d f0	 movzx	 ecx, WORD PTR _VBIStopLine$[ebp]
  00048	2b c1		 sub	 eax, ecx
  0004a	89 45 f8	 mov	 DWORD PTR _Delta$[ebp], eax
  0004d	83 7d f8 01	 cmp	 DWORD PTR _Delta$[ebp], 1
  00051	7d 4a		 jge	 SHORT $LN2@CheckVBIAn

; 322  :     {
; 323  :         WriteWord(SAA7134_VIDEO_V_START(TaskMask), VIDStartLine - Delta + 1);

  00053	0f b7 55 f4	 movzx	 edx, WORD PTR _VIDStartLine$[ebp]
  00057	2b 55 f8	 sub	 edx, DWORD PTR _Delta$[ebp]
  0005a	83 c2 01	 add	 edx, 1
  0005d	52		 push	 edx
  0005e	0f b6 45 ff	 movzx	 eax, BYTE PTR _TaskMask$[ebp]
  00062	83 c8 18	 or	 eax, 24			; 00000018H
  00065	50		 push	 eax
  00066	8b 4d e8	 mov	 ecx, DWORD PTR _this$[ebp]
  00069	e8 00 00 00 00	 call	 ?WriteWord@CPCICard@@QAEXKG@Z ; CPCICard::WriteWord

; 324  : 
; 325  :         WORD VIDStopLine = ReadWord(SAA7134_VIDEO_V_STOP(TaskMask));

  0006e	0f b6 4d ff	 movzx	 ecx, BYTE PTR _TaskMask$[ebp]
  00072	83 c9 1a	 or	 ecx, 26			; 0000001aH
  00075	51		 push	 ecx
  00076	8b 4d e8	 mov	 ecx, DWORD PTR _this$[ebp]
  00079	e8 00 00 00 00	 call	 ?ReadWord@CPCICard@@QAEGK@Z ; CPCICard::ReadWord
  0007e	66 89 45 ec	 mov	 WORD PTR _VIDStopLine$143912[ebp], ax

; 326  :         WriteWord(SAA7134_VIDEO_V_STOP(TaskMask), VIDStopLine - Delta + 1);

  00082	0f b7 55 ec	 movzx	 edx, WORD PTR _VIDStopLine$143912[ebp]
  00086	2b 55 f8	 sub	 edx, DWORD PTR _Delta$[ebp]
  00089	83 c2 01	 add	 edx, 1
  0008c	52		 push	 edx
  0008d	0f b6 45 ff	 movzx	 eax, BYTE PTR _TaskMask$[ebp]
  00091	83 c8 1a	 or	 eax, 26			; 0000001aH
  00094	50		 push	 eax
  00095	8b 4d e8	 mov	 ecx, DWORD PTR _this$[ebp]
  00098	e8 00 00 00 00	 call	 ?WriteWord@CPCICard@@QAEXKG@Z ; CPCICard::WriteWord
$LN2@CheckVBIAn:

; 327  :     }
; 328  : }

  0009d	8b e5		 mov	 esp, ebp
  0009f	5d		 pop	 ebp
  000a0	c2 04 00	 ret	 4
?CheckVBIAndVideoOverlap@CSAA7134Card@@IAEXW4eTaskID@CSAA7134Common@@@Z ENDP ; CSAA7134Card::CheckVBIAndVideoOverlap
_TEXT	ENDS
PUBLIC	?GetHue@CSAA7134Card@@QAEEXZ			; CSAA7134Card::GetHue
; Function compile flags: /Odtp
;	COMDAT ?GetHue@CSAA7134Card@@QAEEXZ
_TEXT	SEGMENT
_this$ = -4						; size = 4
?GetHue@CSAA7134Card@@QAEEXZ PROC			; CSAA7134Card::GetHue, COMDAT
; _this$ = ecx

; 74   : {

  00000	55		 push	 ebp
  00001	8b ec		 mov	 ebp, esp
  00003	51		 push	 ecx
  00004	89 4d fc	 mov	 DWORD PTR _this$[ebp], ecx

; 75   :     return ReadByte(SAA7134_DEC_CHROMA_HUE);

  00007	68 0d 01 00 00	 push	 269			; 0000010dH
  0000c	8b 4d fc	 mov	 ecx, DWORD PTR _this$[ebp]
  0000f	e8 00 00 00 00	 call	 ?ReadByte@CPCICard@@QAEEK@Z ; CPCICard::ReadByte

; 76   : }

  00014	8b e5		 mov	 esp, ebp
  00016	5d		 pop	 ebp
  00017	c3		 ret	 0
?GetHue@CSAA7134Card@@QAEEXZ ENDP			; CSAA7134Card::GetHue
_TEXT	ENDS
PUBLIC	?SetHue@CSAA7134Card@@QAEXE@Z			; CSAA7134Card::SetHue
; Function compile flags: /Odtp
;	COMDAT ?SetHue@CSAA7134Card@@QAEXE@Z
_TEXT	SEGMENT
_this$ = -4						; size = 4
_Hue$ = 8						; size = 1
?SetHue@CSAA7134Card@@QAEXE@Z PROC			; CSAA7134Card::SetHue, COMDAT
; _this$ = ecx

; 69   : {

  00000	55		 push	 ebp
  00001	8b ec		 mov	 ebp, esp
  00003	51		 push	 ecx
  00004	89 4d fc	 mov	 DWORD PTR _this$[ebp], ecx

; 70   :     WriteByte(SAA7134_DEC_CHROMA_HUE, Hue);

  00007	0f b6 45 08	 movzx	 eax, BYTE PTR _Hue$[ebp]
  0000b	50		 push	 eax
  0000c	68 0d 01 00 00	 push	 269			; 0000010dH
  00011	8b 4d fc	 mov	 ecx, DWORD PTR _this$[ebp]
  00014	e8 00 00 00 00	 call	 ?WriteByte@CPCICard@@QAEXKE@Z ; CPCICard::WriteByte

; 71   : }

  00019	8b e5		 mov	 esp, ebp
  0001b	5d		 pop	 ebp
  0001c	c2 04 00	 ret	 4
?SetHue@CSAA7134Card@@QAEXE@Z ENDP			; CSAA7134Card::SetHue
_TEXT	ENDS
PUBLIC	?GetSaturation@CSAA7134Card@@QAEEXZ		; CSAA7134Card::GetSaturation
; Function compile flags: /Odtp
;	COMDAT ?GetSaturation@CSAA7134Card@@QAEEXZ
_TEXT	SEGMENT
_this$ = -4						; size = 4
?GetSaturation@CSAA7134Card@@QAEEXZ PROC		; CSAA7134Card::GetSaturation, COMDAT
; _this$ = ecx

; 64   : {

  00000	55		 push	 ebp
  00001	8b ec		 mov	 ebp, esp
  00003	51		 push	 ecx
  00004	89 4d fc	 mov	 DWORD PTR _this$[ebp], ecx

; 65   :     return ReadByte(SAA7134_DEC_CHROMA_SATURATION);

  00007	68 0c 01 00 00	 push	 268			; 0000010cH
  0000c	8b 4d fc	 mov	 ecx, DWORD PTR _this$[ebp]
  0000f	e8 00 00 00 00	 call	 ?ReadByte@CPCICard@@QAEEK@Z ; CPCICard::ReadByte

; 66   : }

  00014	8b e5		 mov	 esp, ebp
  00016	5d		 pop	 ebp
  00017	c3		 ret	 0
?GetSaturation@CSAA7134Card@@QAEEXZ ENDP		; CSAA7134Card::GetSaturation
_TEXT	ENDS
PUBLIC	?SetSaturation@CSAA7134Card@@QAEXE@Z		; CSAA7134Card::SetSaturation
; Function compile flags: /Odtp
;	COMDAT ?SetSaturation@CSAA7134Card@@QAEXE@Z
_TEXT	SEGMENT
_this$ = -4						; size = 4
_SaturationU$ = 8					; size = 1
?SetSaturation@CSAA7134Card@@QAEXE@Z PROC		; CSAA7134Card::SetSaturation, COMDAT
; _this$ = ecx

; 59   : {

  00000	55		 push	 ebp
  00001	8b ec		 mov	 ebp, esp
  00003	51		 push	 ecx
  00004	89 4d fc	 mov	 DWORD PTR _this$[ebp], ecx

; 60   :     WriteByte(SAA7134_DEC_CHROMA_SATURATION, SaturationU);

  00007	0f b6 45 08	 movzx	 eax, BYTE PTR _SaturationU$[ebp]
  0000b	50		 push	 eax
  0000c	68 0c 01 00 00	 push	 268			; 0000010cH
  00011	8b 4d fc	 mov	 ecx, DWORD PTR _this$[ebp]
  00014	e8 00 00 00 00	 call	 ?WriteByte@CPCICard@@QAEXKE@Z ; CPCICard::WriteByte

; 61   : }

  00019	8b e5		 mov	 esp, ebp
  0001b	5d		 pop	 ebp
  0001c	c2 04 00	 ret	 4
?SetSaturation@CSAA7134Card@@QAEXE@Z ENDP		; CSAA7134Card::SetSaturation
_TEXT	ENDS
PUBLIC	?GetContrast@CSAA7134Card@@QAEEXZ		; CSAA7134Card::GetContrast
; Function compile flags: /Odtp
;	COMDAT ?GetContrast@CSAA7134Card@@QAEEXZ
_TEXT	SEGMENT
_this$ = -4						; size = 4
?GetContrast@CSAA7134Card@@QAEEXZ PROC			; CSAA7134Card::GetContrast, COMDAT
; _this$ = ecx

; 54   : {

  00000	55		 push	 ebp
  00001	8b ec		 mov	 ebp, esp
  00003	51		 push	 ecx
  00004	89 4d fc	 mov	 DWORD PTR _this$[ebp], ecx

; 55   :     return ReadByte(SAA7134_DEC_LUMA_CONTRAST);

  00007	68 0b 01 00 00	 push	 267			; 0000010bH
  0000c	8b 4d fc	 mov	 ecx, DWORD PTR _this$[ebp]
  0000f	e8 00 00 00 00	 call	 ?ReadByte@CPCICard@@QAEEK@Z ; CPCICard::ReadByte

; 56   : }

  00014	8b e5		 mov	 esp, ebp
  00016	5d		 pop	 ebp
  00017	c3		 ret	 0
?GetContrast@CSAA7134Card@@QAEEXZ ENDP			; CSAA7134Card::GetContrast
_TEXT	ENDS
PUBLIC	?SetContrast@CSAA7134Card@@QAEXE@Z		; CSAA7134Card::SetContrast
; Function compile flags: /Odtp
;	COMDAT ?SetContrast@CSAA7134Card@@QAEXE@Z
_TEXT	SEGMENT
_this$ = -4						; size = 4
_Contrast$ = 8						; size = 1
?SetContrast@CSAA7134Card@@QAEXE@Z PROC			; CSAA7134Card::SetContrast, COMDAT
; _this$ = ecx

; 49   : {

  00000	55		 push	 ebp
  00001	8b ec		 mov	 ebp, esp
  00003	51		 push	 ecx
  00004	89 4d fc	 mov	 DWORD PTR _this$[ebp], ecx

; 50   :     WriteByte(SAA7134_DEC_LUMA_CONTRAST, Contrast);

  00007	0f b6 45 08	 movzx	 eax, BYTE PTR _Contrast$[ebp]
  0000b	50		 push	 eax
  0000c	68 0b 01 00 00	 push	 267			; 0000010bH
  00011	8b 4d fc	 mov	 ecx, DWORD PTR _this$[ebp]
  00014	e8 00 00 00 00	 call	 ?WriteByte@CPCICard@@QAEXKE@Z ; CPCICard::WriteByte

; 51   : }

  00019	8b e5		 mov	 esp, ebp
  0001b	5d		 pop	 ebp
  0001c	c2 04 00	 ret	 4
?SetContrast@CSAA7134Card@@QAEXE@Z ENDP			; CSAA7134Card::SetContrast
_TEXT	ENDS
PUBLIC	?GetBrightness@CSAA7134Card@@QAEEXZ		; CSAA7134Card::GetBrightness
; Function compile flags: /Odtp
;	COMDAT ?GetBrightness@CSAA7134Card@@QAEEXZ
_TEXT	SEGMENT
_this$ = -4						; size = 4
?GetBrightness@CSAA7134Card@@QAEEXZ PROC		; CSAA7134Card::GetBrightness, COMDAT
; _this$ = ecx

; 44   : {

  00000	55		 push	 ebp
  00001	8b ec		 mov	 ebp, esp
  00003	51		 push	 ecx
  00004	89 4d fc	 mov	 DWORD PTR _this$[ebp], ecx

; 45   :     return ReadByte(SAA7134_DEC_LUMA_BRIGHT);

  00007	68 0a 01 00 00	 push	 266			; 0000010aH
  0000c	8b 4d fc	 mov	 ecx, DWORD PTR _this$[ebp]
  0000f	e8 00 00 00 00	 call	 ?ReadByte@CPCICard@@QAEEK@Z ; CPCICard::ReadByte

; 46   : }

  00014	8b e5		 mov	 esp, ebp
  00016	5d		 pop	 ebp
  00017	c3		 ret	 0
?GetBrightness@CSAA7134Card@@QAEEXZ ENDP		; CSAA7134Card::GetBrightness
_TEXT	ENDS
PUBLIC	?SetBrightness@CSAA7134Card@@QAEXE@Z		; CSAA7134Card::SetBrightness
; Function compile flags: /Odtp
;	COMDAT ?SetBrightness@CSAA7134Card@@QAEXE@Z
_TEXT	SEGMENT
_this$ = -4						; size = 4
_Brightness$ = 8					; size = 1
?SetBrightness@CSAA7134Card@@QAEXE@Z PROC		; CSAA7134Card::SetBrightness, COMDAT
; _this$ = ecx

; 39   : {

  00000	55		 push	 ebp
  00001	8b ec		 mov	 ebp, esp
  00003	51		 push	 ecx
  00004	89 4d fc	 mov	 DWORD PTR _this$[ebp], ecx

; 40   :     WriteByte(SAA7134_DEC_LUMA_BRIGHT, Brightness);

  00007	0f b6 45 08	 movzx	 eax, BYTE PTR _Brightness$[ebp]
  0000b	50		 push	 eax
  0000c	68 0a 01 00 00	 push	 266			; 0000010aH
  00011	8b 4d fc	 mov	 ecx, DWORD PTR _this$[ebp]
  00014	e8 00 00 00 00	 call	 ?WriteByte@CPCICard@@QAEXKE@Z ; CPCICard::WriteByte

; 41   : }

  00019	8b e5		 mov	 esp, ebp
  0001b	5d		 pop	 ebp
  0001c	c2 04 00	 ret	 4
?SetBrightness@CSAA7134Card@@QAEXE@Z ENDP		; CSAA7134Card::SetBrightness
PUBLIC	?ResetHPrescale@CSAA7134Card@@IAEXW4eTaskID@CSAA7134Common@@@Z ; CSAA7134Card::ResetHPrescale
; Function compile flags: /Odtp
;	COMDAT ?ResetHPrescale@CSAA7134Card@@IAEXW4eTaskID@CSAA7134Common@@@Z
_TEXT	SEGMENT
_this$ = -8						; size = 4
_TaskMask$ = -1						; size = 1
_TaskID$ = 8						; size = 4
?ResetHPrescale@CSAA7134Card@@IAEXW4eTaskID@CSAA7134Common@@@Z PROC ; CSAA7134Card::ResetHPrescale, COMDAT
; _this$ = ecx

; 611  : {

  00000	55		 push	 ebp
  00001	8b ec		 mov	 ebp, esp
  00003	83 ec 08	 sub	 esp, 8
  00006	89 4d f8	 mov	 DWORD PTR _this$[ebp], ecx

; 612  :     BYTE TaskMask = TaskID2TaskMask(TaskID);

  00009	8b 45 08	 mov	 eax, DWORD PTR _TaskID$[ebp]
  0000c	50		 push	 eax
  0000d	8b 4d f8	 mov	 ecx, DWORD PTR _this$[ebp]
  00010	e8 00 00 00 00	 call	 ?TaskID2TaskMask@CSAA7134Card@@IAEEW4eTaskID@CSAA7134Common@@@Z ; CSAA7134Card::TaskID2TaskMask
  00015	88 45 ff	 mov	 BYTE PTR _TaskMask$[ebp], al

; 613  : 
; 614  :     WriteByte(SAA7134_H_PRESCALE(TaskMask), 0x01);

  00018	6a 01		 push	 1
  0001a	0f b6 4d ff	 movzx	 ecx, BYTE PTR _TaskMask$[ebp]
  0001e	83 c9 20	 or	 ecx, 32			; 00000020H
  00021	51		 push	 ecx
  00022	8b 4d f8	 mov	 ecx, DWORD PTR _this$[ebp]
  00025	e8 00 00 00 00	 call	 ?WriteByte@CPCICard@@QAEXKE@Z ; CPCICard::WriteByte

; 615  :     WriteByte(SAA7134_ACC_LENGTH(TaskMask), 0x00);

  0002a	6a 00		 push	 0
  0002c	0f b6 55 ff	 movzx	 edx, BYTE PTR _TaskMask$[ebp]
  00030	83 ca 21	 or	 edx, 33			; 00000021H
  00033	52		 push	 edx
  00034	8b 4d f8	 mov	 ecx, DWORD PTR _this$[ebp]
  00037	e8 00 00 00 00	 call	 ?WriteByte@CPCICard@@QAEXKE@Z ; CPCICard::WriteByte

; 616  : 
; 617  :     /* 0x07 mask = XDCG, 0x08 mask = 0xXC2_1 whatever that means */
; 618  :     WriteByte(SAA7134_LEVEL_CTRL(TaskMask), 0x00);

  0003c	6a 00		 push	 0
  0003e	0f b6 45 ff	 movzx	 eax, BYTE PTR _TaskMask$[ebp]
  00042	83 c8 22	 or	 eax, 34			; 00000022H
  00045	50		 push	 eax
  00046	8b 4d f8	 mov	 ecx, DWORD PTR _this$[ebp]
  00049	e8 00 00 00 00	 call	 ?WriteByte@CPCICard@@QAEXKE@Z ; CPCICard::WriteByte

; 619  :     MaskDataByte(SAA7134_FIR_PREFILTER_CTRL(TaskMask), 0x08, 0x0F); /* VPFY ?? */

  0004e	6a 0f		 push	 15			; 0000000fH
  00050	6a 08		 push	 8
  00052	0f b6 4d ff	 movzx	 ecx, BYTE PTR _TaskMask$[ebp]
  00056	83 c9 23	 or	 ecx, 35			; 00000023H
  00059	51		 push	 ecx
  0005a	8b 4d f8	 mov	 ecx, DWORD PTR _this$[ebp]
  0005d	e8 00 00 00 00	 call	 ?MaskDataByte@CPCICard@@QAEXKEE@Z ; CPCICard::MaskDataByte

; 620  : }

  00062	8b e5		 mov	 esp, ebp
  00064	5d		 pop	 ebp
  00065	c2 04 00	 ret	 4
?ResetHPrescale@CSAA7134Card@@IAEXW4eTaskID@CSAA7134Common@@@Z ENDP ; CSAA7134Card::ResetHPrescale
_TEXT	ENDS
PUBLIC	?SetHPrescale@CSAA7134Card@@IAEXW4eTaskID@CSAA7134Common@@GG@Z ; CSAA7134Card::SetHPrescale
; Function compile flags: /Odtp
;	COMDAT ?SetHPrescale@CSAA7134Card@@IAEXW4eTaskID@CSAA7134Common@@GG@Z
_TEXT	SEGMENT
_this$ = -12						; size = 4
_i$ = -8						; size = 4
_TaskMask$ = -1						; size = 1
_TaskID$ = 8						; size = 4
_wSourceSize$ = 12					; size = 2
_wScaleSize$ = 16					; size = 2
?SetHPrescale@CSAA7134Card@@IAEXW4eTaskID@CSAA7134Common@@GG@Z PROC ; CSAA7134Card::SetHPrescale, COMDAT
; _this$ = ecx

; 577  : {

  00000	55		 push	 ebp
  00001	8b ec		 mov	 ebp, esp
  00003	83 ec 0c	 sub	 esp, 12			; 0000000cH
  00006	89 4d f4	 mov	 DWORD PTR _this$[ebp], ecx

; 578  :     BYTE TaskMask = TaskID2TaskMask(TaskID);

  00009	8b 45 08	 mov	 eax, DWORD PTR _TaskID$[ebp]
  0000c	50		 push	 eax
  0000d	8b 4d f4	 mov	 ecx, DWORD PTR _this$[ebp]
  00010	e8 00 00 00 00	 call	 ?TaskID2TaskMask@CSAA7134Card@@IAEEW4eTaskID@CSAA7134Common@@@Z ; CSAA7134Card::TaskID2TaskMask
  00015	88 45 ff	 mov	 BYTE PTR _TaskMask$[ebp], al

; 579  : 
; 580  :     static const struct {
; 581  :         int xpsc;
; 582  :         int xacl;
; 583  :         int xc2_1;
; 584  :         int xdcg;
; 585  :         int vpfy;
; 586  :     } vals[] = {
; 587  :         /* XPSC XACL XC2_1 XDCG VPFY */
; 588  :         {    1,   0,    0,    0,   0 },
; 589  :         {    2,   2,    1,    2,   2 },
; 590  :         {    3,   4,    1,    3,   2 },
; 591  :         {    4,   8,    1,    4,   2 },
; 592  :         {    5,   8,    1,    4,   2 },
; 593  :         {    6,   8,    1,    4,   3 },
; 594  :         {    7,   8,    1,    4,   3 },
; 595  :         {    8,  15,    0,    4,   3 },
; 596  :         {    9,  15,    0,    4,   3 },
; 597  :         {   10,  16,    1,    5,   3 },
; 598  :     };
; 599  : 
; 600  :     int i = 2;

  00018	c7 45 f8 02 00
	00 00		 mov	 DWORD PTR _i$[ebp], 2

; 601  : 
; 602  :     WriteByte(SAA7134_H_PRESCALE(TaskMask), vals[i].xpsc);

  0001f	8b 4d f8	 mov	 ecx, DWORD PTR _i$[ebp]
  00022	6b c9 14	 imul	 ecx, 20			; 00000014H
  00025	0f b6 91 00 00
	00 00		 movzx	 edx, BYTE PTR ?vals@?1??SetHPrescale@CSAA7134Card@@IAEXW4eTaskID@CSAA7134Common@@GG@Z@4QBU<unnamed-type-vals>@?1??12@IAEX0GG@Z@B[ecx]
  0002c	52		 push	 edx
  0002d	0f b6 45 ff	 movzx	 eax, BYTE PTR _TaskMask$[ebp]
  00031	83 c8 20	 or	 eax, 32			; 00000020H
  00034	50		 push	 eax
  00035	8b 4d f4	 mov	 ecx, DWORD PTR _this$[ebp]
  00038	e8 00 00 00 00	 call	 ?WriteByte@CPCICard@@QAEXKE@Z ; CPCICard::WriteByte

; 603  :     WriteByte(SAA7134_ACC_LENGTH(TaskMask), vals[i].xacl);

  0003d	8b 4d f8	 mov	 ecx, DWORD PTR _i$[ebp]
  00040	6b c9 14	 imul	 ecx, 20			; 00000014H
  00043	0f b6 91 04 00
	00 00		 movzx	 edx, BYTE PTR ?vals@?1??SetHPrescale@CSAA7134Card@@IAEXW4eTaskID@CSAA7134Common@@GG@Z@4QBU<unnamed-type-vals>@?1??12@IAEX0GG@Z@B[ecx+4]
  0004a	52		 push	 edx
  0004b	0f b6 45 ff	 movzx	 eax, BYTE PTR _TaskMask$[ebp]
  0004f	83 c8 21	 or	 eax, 33			; 00000021H
  00052	50		 push	 eax
  00053	8b 4d f4	 mov	 ecx, DWORD PTR _this$[ebp]
  00056	e8 00 00 00 00	 call	 ?WriteByte@CPCICard@@QAEXKE@Z ; CPCICard::WriteByte

; 604  :     WriteByte(SAA7134_LEVEL_CTRL(TaskMask), (vals[i].xc2_1 << 3) | (vals[i].xdcg));

  0005b	8b 4d f8	 mov	 ecx, DWORD PTR _i$[ebp]
  0005e	6b c9 14	 imul	 ecx, 20			; 00000014H
  00061	8b 91 08 00 00
	00		 mov	 edx, DWORD PTR ?vals@?1??SetHPrescale@CSAA7134Card@@IAEXW4eTaskID@CSAA7134Common@@GG@Z@4QBU<unnamed-type-vals>@?1??12@IAEX0GG@Z@B[ecx+8]
  00067	c1 e2 03	 shl	 edx, 3
  0006a	8b 45 f8	 mov	 eax, DWORD PTR _i$[ebp]
  0006d	6b c0 14	 imul	 eax, 20			; 00000014H
  00070	0b 90 0c 00 00
	00		 or	 edx, DWORD PTR ?vals@?1??SetHPrescale@CSAA7134Card@@IAEXW4eTaskID@CSAA7134Common@@GG@Z@4QBU<unnamed-type-vals>@?1??12@IAEX0GG@Z@B[eax+12]
  00076	52		 push	 edx
  00077	0f b6 4d ff	 movzx	 ecx, BYTE PTR _TaskMask$[ebp]
  0007b	83 c9 22	 or	 ecx, 34			; 00000022H
  0007e	51		 push	 ecx
  0007f	8b 4d f4	 mov	 ecx, DWORD PTR _this$[ebp]
  00082	e8 00 00 00 00	 call	 ?WriteByte@CPCICard@@QAEXKE@Z ; CPCICard::WriteByte

; 605  :     MaskDataByte(SAA7134_FIR_PREFILTER_CTRL(TaskMask),
; 606  :         (vals[i].vpfy << 2) | vals[i].vpfy, 0x0F);

  00087	6a 0f		 push	 15			; 0000000fH
  00089	8b 55 f8	 mov	 edx, DWORD PTR _i$[ebp]
  0008c	6b d2 14	 imul	 edx, 20			; 00000014H
  0008f	8b 82 10 00 00
	00		 mov	 eax, DWORD PTR ?vals@?1??SetHPrescale@CSAA7134Card@@IAEXW4eTaskID@CSAA7134Common@@GG@Z@4QBU<unnamed-type-vals>@?1??12@IAEX0GG@Z@B[edx+16]
  00095	c1 e0 02	 shl	 eax, 2
  00098	8b 4d f8	 mov	 ecx, DWORD PTR _i$[ebp]
  0009b	6b c9 14	 imul	 ecx, 20			; 00000014H
  0009e	0b 81 10 00 00
	00		 or	 eax, DWORD PTR ?vals@?1??SetHPrescale@CSAA7134Card@@IAEXW4eTaskID@CSAA7134Common@@GG@Z@4QBU<unnamed-type-vals>@?1??12@IAEX0GG@Z@B[ecx+16]
  000a4	50		 push	 eax
  000a5	0f b6 55 ff	 movzx	 edx, BYTE PTR _TaskMask$[ebp]
  000a9	83 ca 23	 or	 edx, 35			; 00000023H
  000ac	52		 push	 edx
  000ad	8b 4d f4	 mov	 ecx, DWORD PTR _this$[ebp]
  000b0	e8 00 00 00 00	 call	 ?MaskDataByte@CPCICard@@QAEXKEE@Z ; CPCICard::MaskDataByte

; 607  : }

  000b5	8b e5		 mov	 esp, ebp
  000b7	5d		 pop	 ebp
  000b8	c2 0c 00	 ret	 12			; 0000000cH
?SetHPrescale@CSAA7134Card@@IAEXW4eTaskID@CSAA7134Common@@GG@Z ENDP ; CSAA7134Card::SetHPrescale
_TEXT	ENDS
PUBLIC	?SetVideoMirror@CSAA7134Card@@QAEXH@Z		; CSAA7134Card::SetVideoMirror
; Function compile flags: /Odtp
;	COMDAT ?SetVideoMirror@CSAA7134Card@@QAEXH@Z
_TEXT	SEGMENT
_this$ = -4						; size = 4
_bMirror$ = 8						; size = 4
?SetVideoMirror@CSAA7134Card@@QAEXH@Z PROC		; CSAA7134Card::SetVideoMirror, COMDAT
; _this$ = ecx

; 545  : {

  00000	55		 push	 ebp
  00001	8b ec		 mov	 ebp, esp
  00003	51		 push	 ecx
  00004	89 4d fc	 mov	 DWORD PTR _this$[ebp], ecx

; 546  :     if (bMirror)

  00007	83 7d 08 00	 cmp	 DWORD PTR _bMirror$[ebp], 0
  0000b	74 1d		 je	 SHORT $LN2@SetVideoMi

; 547  :     {
; 548  :         OrDataByte(SAA7134_V_FILTER(SAA7134_TASK_A_MASK), SAA7134_V_FILTER_YMIR);

  0000d	6a 02		 push	 2
  0000f	6a 72		 push	 114			; 00000072H
  00011	8b 4d fc	 mov	 ecx, DWORD PTR _this$[ebp]
  00014	e8 00 00 00 00	 call	 ?OrDataByte@CPCICard@@QAEXKE@Z ; CPCICard::OrDataByte

; 549  :         OrDataByte(SAA7134_V_FILTER(SAA7134_TASK_B_MASK), SAA7134_V_FILTER_YMIR);

  00019	6a 02		 push	 2
  0001b	68 b2 00 00 00	 push	 178			; 000000b2H
  00020	8b 4d fc	 mov	 ecx, DWORD PTR _this$[ebp]
  00023	e8 00 00 00 00	 call	 ?OrDataByte@CPCICard@@QAEXKE@Z ; CPCICard::OrDataByte

; 550  :     }
; 551  :     else

  00028	eb 21		 jmp	 SHORT $LN3@SetVideoMi
$LN2@SetVideoMi:

; 552  :     {
; 553  :         AndDataByte(SAA7134_V_FILTER(SAA7134_TASK_A_MASK), ~SAA7134_V_FILTER_YMIR);

  0002a	68 fd 00 00 00	 push	 253			; 000000fdH
  0002f	6a 72		 push	 114			; 00000072H
  00031	8b 4d fc	 mov	 ecx, DWORD PTR _this$[ebp]
  00034	e8 00 00 00 00	 call	 ?AndDataByte@CPCICard@@QAEXKE@Z ; CPCICard::AndDataByte

; 554  :         AndDataByte(SAA7134_V_FILTER(SAA7134_TASK_B_MASK), ~SAA7134_V_FILTER_YMIR);

  00039	68 fd 00 00 00	 push	 253			; 000000fdH
  0003e	68 b2 00 00 00	 push	 178			; 000000b2H
  00043	8b 4d fc	 mov	 ecx, DWORD PTR _this$[ebp]
  00046	e8 00 00 00 00	 call	 ?AndDataByte@CPCICard@@QAEXKE@Z ; CPCICard::AndDataByte
$LN3@SetVideoMi:

; 555  :     }
; 556  : }

  0004b	8b e5		 mov	 esp, ebp
  0004d	5d		 pop	 ebp
  0004e	c2 04 00	 ret	 4
?SetVideoMirror@CSAA7134Card@@QAEXH@Z ENDP		; CSAA7134Card::SetVideoMirror
_TEXT	ENDS
PUBLIC	?SetGammaControl@CSAA7134Card@@QAEXH@Z		; CSAA7134Card::SetGammaControl
; Function compile flags: /Odtp
;	COMDAT ?SetGammaControl@CSAA7134Card@@QAEXH@Z
_TEXT	SEGMENT
_this$ = -4						; size = 4
_bGammaControl$ = 8					; size = 4
?SetGammaControl@CSAA7134Card@@QAEXH@Z PROC		; CSAA7134Card::SetGammaControl, COMDAT
; _this$ = ecx

; 499  : {

  00000	55		 push	 ebp
  00001	8b ec		 mov	 ebp, esp
  00003	51		 push	 ecx
  00004	89 4d fc	 mov	 DWORD PTR _this$[ebp], ecx

; 500  :     // bit 0: ??? (this one is not explained in the documentation. Set to bypass RGB to YUV matrix?)
; 501  :     // bit 1: set to bypass YUV to RGB matrix
; 502  :     // bit 2: set to enable transformation via LUT curve
; 503  : 
; 504  :     if(bGammaControl)

  00007	83 7d 08 00	 cmp	 DWORD PTR _bGammaControl$[ebp], 0
  0000b	74 3e		 je	 SHORT $LN2@SetGammaCo@2

; 505  :     {
; 506  :         AndDataByte(SAA7134_DATA_PATH(SAA7134_TASK_A_MASK), ~3);

  0000d	68 fc 00 00 00	 push	 252			; 000000fcH
  00012	6a 42		 push	 66			; 00000042H
  00014	8b 4d fc	 mov	 ecx, DWORD PTR _this$[ebp]
  00017	e8 00 00 00 00	 call	 ?AndDataByte@CPCICard@@QAEXKE@Z ; CPCICard::AndDataByte

; 507  :         OrDataByte(SAA7134_DATA_PATH(SAA7134_TASK_A_MASK), 4);

  0001c	6a 04		 push	 4
  0001e	6a 42		 push	 66			; 00000042H
  00020	8b 4d fc	 mov	 ecx, DWORD PTR _this$[ebp]
  00023	e8 00 00 00 00	 call	 ?OrDataByte@CPCICard@@QAEXKE@Z ; CPCICard::OrDataByte

; 508  : 
; 509  :         AndDataByte(SAA7134_DATA_PATH(SAA7134_TASK_B_MASK), ~3);

  00028	68 fc 00 00 00	 push	 252			; 000000fcH
  0002d	68 82 00 00 00	 push	 130			; 00000082H
  00032	8b 4d fc	 mov	 ecx, DWORD PTR _this$[ebp]
  00035	e8 00 00 00 00	 call	 ?AndDataByte@CPCICard@@QAEXKE@Z ; CPCICard::AndDataByte

; 510  :         OrDataByte(SAA7134_DATA_PATH(SAA7134_TASK_B_MASK), 4);

  0003a	6a 04		 push	 4
  0003c	68 82 00 00 00	 push	 130			; 00000082H
  00041	8b 4d fc	 mov	 ecx, DWORD PTR _this$[ebp]
  00044	e8 00 00 00 00	 call	 ?OrDataByte@CPCICard@@QAEXKE@Z ; CPCICard::OrDataByte

; 511  : 
; 512  :     }
; 513  :     else

  00049	eb 3c		 jmp	 SHORT $LN3@SetGammaCo@2
$LN2@SetGammaCo@2:

; 514  :     {
; 515  :         AndDataByte(SAA7134_DATA_PATH(SAA7134_TASK_A_MASK), ~4);

  0004b	68 fb 00 00 00	 push	 251			; 000000fbH
  00050	6a 42		 push	 66			; 00000042H
  00052	8b 4d fc	 mov	 ecx, DWORD PTR _this$[ebp]
  00055	e8 00 00 00 00	 call	 ?AndDataByte@CPCICard@@QAEXKE@Z ; CPCICard::AndDataByte

; 516  :         OrDataByte(SAA7134_DATA_PATH(SAA7134_TASK_A_MASK), 3);

  0005a	6a 03		 push	 3
  0005c	6a 42		 push	 66			; 00000042H
  0005e	8b 4d fc	 mov	 ecx, DWORD PTR _this$[ebp]
  00061	e8 00 00 00 00	 call	 ?OrDataByte@CPCICard@@QAEXKE@Z ; CPCICard::OrDataByte

; 517  : 
; 518  :         AndDataByte(SAA7134_DATA_PATH(SAA7134_TASK_B_MASK), ~4);

  00066	68 fb 00 00 00	 push	 251			; 000000fbH
  0006b	68 82 00 00 00	 push	 130			; 00000082H
  00070	8b 4d fc	 mov	 ecx, DWORD PTR _this$[ebp]
  00073	e8 00 00 00 00	 call	 ?AndDataByte@CPCICard@@QAEXKE@Z ; CPCICard::AndDataByte

; 519  :         OrDataByte(SAA7134_DATA_PATH(SAA7134_TASK_B_MASK), 3);

  00078	6a 03		 push	 3
  0007a	68 82 00 00 00	 push	 130			; 00000082H
  0007f	8b 4d fc	 mov	 ecx, DWORD PTR _this$[ebp]
  00082	e8 00 00 00 00	 call	 ?OrDataByte@CPCICard@@QAEXKE@Z ; CPCICard::OrDataByte
$LN3@SetGammaCo@2:

; 520  :     }
; 521  : }

  00087	8b e5		 mov	 esp, ebp
  00089	5d		 pop	 ebp
  0008a	c2 04 00	 ret	 4
?SetGammaControl@CSAA7134Card@@QAEXH@Z ENDP		; CSAA7134Card::SetGammaControl
_TEXT	ENDS
PUBLIC	?SetGainControl@CSAA7134Card@@QAEXG@Z		; CSAA7134Card::SetGainControl
; Function compile flags: /Odtp
;	COMDAT ?SetGainControl@CSAA7134Card@@QAEXG@Z
_TEXT	SEGMENT
_this$ = -8						; size = 4
_AnalogInputCtrl2$ = -1					; size = 1
_GainControl$ = 8					; size = 2
?SetGainControl@CSAA7134Card@@QAEXG@Z PROC		; CSAA7134Card::SetGainControl, COMDAT
; _this$ = ecx

; 480  : {

  00000	55		 push	 ebp
  00001	8b ec		 mov	 ebp, esp
  00003	83 ec 08	 sub	 esp, 8
  00006	89 4d f8	 mov	 DWORD PTR _this$[ebp], ecx

; 481  :     // Only 9 bits of GainControl is used
; 482  : 
; 483  :     WriteByte(SAA7134_ANALOG_IN_CTRL3, GainControl & 0xFF);

  00009	0f b7 45 08	 movzx	 eax, WORD PTR _GainControl$[ebp]
  0000d	25 ff 00 00 00	 and	 eax, 255		; 000000ffH
  00012	50		 push	 eax
  00013	68 04 01 00 00	 push	 260			; 00000104H
  00018	8b 4d f8	 mov	 ecx, DWORD PTR _this$[ebp]
  0001b	e8 00 00 00 00	 call	 ?WriteByte@CPCICard@@QAEXKE@Z ; CPCICard::WriteByte

; 484  :     WriteByte(SAA7134_ANALOG_IN_CTRL4, GainControl & 0xFF);

  00020	0f b7 4d 08	 movzx	 ecx, WORD PTR _GainControl$[ebp]
  00024	81 e1 ff 00 00
	00		 and	 ecx, 255		; 000000ffH
  0002a	51		 push	 ecx
  0002b	68 05 01 00 00	 push	 261			; 00000105H
  00030	8b 4d f8	 mov	 ecx, DWORD PTR _this$[ebp]
  00033	e8 00 00 00 00	 call	 ?WriteByte@CPCICard@@QAEXKE@Z ; CPCICard::WriteByte

; 485  : 
; 486  :     BYTE AnalogInputCtrl2 = 0x00;

  00038	c6 45 ff 00	 mov	 BYTE PTR _AnalogInputCtrl2$[ebp], 0

; 487  : 
; 488  :     if (GainControl & 0x0100)

  0003c	0f b7 55 08	 movzx	 edx, WORD PTR _GainControl$[ebp]
  00040	81 e2 00 01 00
	00		 and	 edx, 256		; 00000100H
  00046	74 04		 je	 SHORT $LN1@SetGainCon

; 489  :     {
; 490  :         AnalogInputCtrl2 = 0x03;

  00048	c6 45 ff 03	 mov	 BYTE PTR _AnalogInputCtrl2$[ebp], 3
$LN1@SetGainCon:

; 491  :     }
; 492  : 
; 493  :     MaskDataByte(SAA7134_ANALOG_IN_CTRL2, AnalogInputCtrl2,
; 494  :         SAA7134_ANALOG_IN_CTRL2_GAI18 |
; 495  :         SAA7134_ANALOG_IN_CTRL2_GAI18);

  0004c	6a 01		 push	 1
  0004e	0f b6 45 ff	 movzx	 eax, BYTE PTR _AnalogInputCtrl2$[ebp]
  00052	50		 push	 eax
  00053	68 03 01 00 00	 push	 259			; 00000103H
  00058	8b 4d f8	 mov	 ecx, DWORD PTR _this$[ebp]
  0005b	e8 00 00 00 00	 call	 ?MaskDataByte@CPCICard@@QAEXKEE@Z ; CPCICard::MaskDataByte

; 496  : }

  00060	8b e5		 mov	 esp, ebp
  00062	5d		 pop	 ebp
  00063	c2 04 00	 ret	 4
?SetGainControl@CSAA7134Card@@QAEXG@Z ENDP		; CSAA7134Card::SetGainControl
_TEXT	ENDS
PUBLIC	?SetAutomaticGainControl@CSAA7134Card@@QAEXH@Z	; CSAA7134Card::SetAutomaticGainControl
; Function compile flags: /Odtp
;	COMDAT ?SetAutomaticGainControl@CSAA7134Card@@QAEXH@Z
_TEXT	SEGMENT
_this$ = -4						; size = 4
_bAGC$ = 8						; size = 4
?SetAutomaticGainControl@CSAA7134Card@@QAEXH@Z PROC	; CSAA7134Card::SetAutomaticGainControl, COMDAT
; _this$ = ecx

; 467  : {

  00000	55		 push	 ebp
  00001	8b ec		 mov	 ebp, esp
  00003	51		 push	 ecx
  00004	89 4d fc	 mov	 DWORD PTR _this$[ebp], ecx

; 468  :     if (bAGC)

  00007	83 7d 08 00	 cmp	 DWORD PTR _bAGC$[ebp], 0
  0000b	74 14		 je	 SHORT $LN2@SetAutomat

; 469  :     {
; 470  :         AndDataByte(SAA7134_ANALOG_IN_CTRL2, ~SAA7134_ANALOG_IN_CTRL2_GAFIX);

  0000d	68 fb 00 00 00	 push	 251			; 000000fbH
  00012	68 03 01 00 00	 push	 259			; 00000103H
  00017	8b 4d fc	 mov	 ecx, DWORD PTR _this$[ebp]
  0001a	e8 00 00 00 00	 call	 ?AndDataByte@CPCICard@@QAEXKE@Z ; CPCICard::AndDataByte

; 471  :     }
; 472  :     else

  0001f	eb 0f		 jmp	 SHORT $LN3@SetAutomat
$LN2@SetAutomat:

; 473  :     {
; 474  :         OrDataByte(SAA7134_ANALOG_IN_CTRL2, SAA7134_ANALOG_IN_CTRL2_GAFIX);

  00021	6a 04		 push	 4
  00023	68 03 01 00 00	 push	 259			; 00000103H
  00028	8b 4d fc	 mov	 ecx, DWORD PTR _this$[ebp]
  0002b	e8 00 00 00 00	 call	 ?OrDataByte@CPCICard@@QAEXKE@Z ; CPCICard::OrDataByte
$LN3@SetAutomat:

; 475  :     }
; 476  : }

  00030	8b e5		 mov	 esp, ebp
  00032	5d		 pop	 ebp
  00033	c2 04 00	 ret	 4
?SetAutomaticGainControl@CSAA7134Card@@QAEXH@Z ENDP	; CSAA7134Card::SetAutomaticGainControl
_TEXT	ENDS
PUBLIC	?SetColorPeak@CSAA7134Card@@QAEXH@Z		; CSAA7134Card::SetColorPeak
; Function compile flags: /Odtp
;	COMDAT ?SetColorPeak@CSAA7134Card@@QAEXH@Z
_TEXT	SEGMENT
_this$ = -4						; size = 4
_ColorPeak$ = 8						; size = 4
?SetColorPeak@CSAA7134Card@@QAEXH@Z PROC		; CSAA7134Card::SetColorPeak, COMDAT
; _this$ = ecx

; 447  : {

  00000	55		 push	 ebp
  00001	8b ec		 mov	 ebp, esp
  00003	51		 push	 ecx
  00004	89 4d fc	 mov	 DWORD PTR _this$[ebp], ecx

; 448  :     if (ColorPeak)

  00007	83 7d 08 00	 cmp	 DWORD PTR _ColorPeak$[ebp], 0
  0000b	74 14		 je	 SHORT $LN2@SetColorPe

; 449  :     {
; 450  :         AndDataByte(SAA7134_ANALOG_IN_CTRL2, ~SAA7134_ANALOG_IN_CTRL2_CPOFF);

  0000d	68 ef 00 00 00	 push	 239			; 000000efH
  00012	68 03 01 00 00	 push	 259			; 00000103H
  00017	8b 4d fc	 mov	 ecx, DWORD PTR _this$[ebp]
  0001a	e8 00 00 00 00	 call	 ?AndDataByte@CPCICard@@QAEXKE@Z ; CPCICard::AndDataByte

; 451  :     }
; 452  :     else

  0001f	eb 0f		 jmp	 SHORT $LN3@SetColorPe
$LN2@SetColorPe:

; 453  :     {
; 454  :         OrDataByte(SAA7134_ANALOG_IN_CTRL2, SAA7134_ANALOG_IN_CTRL2_CPOFF);

  00021	6a 10		 push	 16			; 00000010H
  00023	68 03 01 00 00	 push	 259			; 00000103H
  00028	8b 4d fc	 mov	 ecx, DWORD PTR _this$[ebp]
  0002b	e8 00 00 00 00	 call	 ?OrDataByte@CPCICard@@QAEXKE@Z ; CPCICard::OrDataByte
$LN3@SetColorPe:

; 455  :     }
; 456  : }

  00030	8b e5		 mov	 esp, ebp
  00032	5d		 pop	 ebp
  00033	c2 04 00	 ret	 4
?SetColorPeak@CSAA7134Card@@QAEXH@Z ENDP		; CSAA7134Card::SetColorPeak
_TEXT	ENDS
PUBLIC	?SetWhitePeak@CSAA7134Card@@QAEXH@Z		; CSAA7134Card::SetWhitePeak
; Function compile flags: /Odtp
;	COMDAT ?SetWhitePeak@CSAA7134Card@@QAEXH@Z
_TEXT	SEGMENT
_this$ = -4						; size = 4
_WhitePeak$ = 8						; size = 4
?SetWhitePeak@CSAA7134Card@@QAEXH@Z PROC		; CSAA7134Card::SetWhitePeak, COMDAT
; _this$ = ecx

; 428  : {

  00000	55		 push	 ebp
  00001	8b ec		 mov	 ebp, esp
  00003	51		 push	 ecx
  00004	89 4d fc	 mov	 DWORD PTR _this$[ebp], ecx

; 429  :     if (WhitePeak)

  00007	83 7d 08 00	 cmp	 DWORD PTR _WhitePeak$[ebp], 0
  0000b	74 14		 je	 SHORT $LN2@SetWhitePe

; 430  :     {
; 431  :         AndDataByte(SAA7134_INCR_DELAY, ~SAA7134_INCR_DELAY_WPOFF);

  0000d	68 bf 00 00 00	 push	 191			; 000000bfH
  00012	68 01 01 00 00	 push	 257			; 00000101H
  00017	8b 4d fc	 mov	 ecx, DWORD PTR _this$[ebp]
  0001a	e8 00 00 00 00	 call	 ?AndDataByte@CPCICard@@QAEXKE@Z ; CPCICard::AndDataByte

; 432  :     }
; 433  :     else

  0001f	eb 0f		 jmp	 SHORT $LN3@SetWhitePe
$LN2@SetWhitePe:

; 434  :     {
; 435  :         OrDataByte(SAA7134_INCR_DELAY, SAA7134_INCR_DELAY_WPOFF);

  00021	6a 40		 push	 64			; 00000040H
  00023	68 01 01 00 00	 push	 257			; 00000101H
  00028	8b 4d fc	 mov	 ecx, DWORD PTR _this$[ebp]
  0002b	e8 00 00 00 00	 call	 ?OrDataByte@CPCICard@@QAEXKE@Z ; CPCICard::OrDataByte
$LN3@SetWhitePe:

; 436  :     }
; 437  : }

  00030	8b e5		 mov	 esp, ebp
  00032	5d		 pop	 ebp
  00033	c2 04 00	 ret	 4
?SetWhitePeak@CSAA7134Card@@QAEXH@Z ENDP		; CSAA7134Card::SetWhitePeak
_TEXT	ENDS
PUBLIC	?SetCombFilter@CSAA7134Card@@QAEXW4eCombFilter@CSAA7134Common@@@Z ; CSAA7134Card::SetCombFilter
; Function compile flags: /Odtp
;	COMDAT ?SetCombFilter@CSAA7134Card@@QAEXW4eCombFilter@CSAA7134Common@@@Z
_TEXT	SEGMENT
tv64 = -8						; size = 4
_this$ = -4						; size = 4
_CombFilter$ = 8					; size = 4
?SetCombFilter@CSAA7134Card@@QAEXW4eCombFilter@CSAA7134Common@@@Z PROC ; CSAA7134Card::SetCombFilter, COMDAT
; _this$ = ecx

; 403  : {

  00000	55		 push	 ebp
  00001	8b ec		 mov	 ebp, esp
  00003	83 ec 08	 sub	 esp, 8
  00006	89 4d fc	 mov	 DWORD PTR _this$[ebp], ecx

; 404  :     switch (CombFilter)

  00009	8b 45 08	 mov	 eax, DWORD PTR _CombFilter$[ebp]
  0000c	89 45 f8	 mov	 DWORD PTR tv64[ebp], eax
  0000f	83 7d f8 00	 cmp	 DWORD PTR tv64[ebp], 0
  00013	74 0e		 je	 SHORT $LN4@SetCombFil@2
  00015	83 7d f8 01	 cmp	 DWORD PTR tv64[ebp], 1
  00019	74 2e		 je	 SHORT $LN3@SetCombFil@2
  0001b	83 7d f8 02	 cmp	 DWORD PTR tv64[ebp], 2
  0001f	74 4b		 je	 SHORT $LN2@SetCombFil@2
  00021	eb 67		 jmp	 SHORT $LN7@SetCombFil@2
$LN4@SetCombFil@2:

; 405  :     {
; 406  :     case COMBFILTER_OFF:
; 407  :         AndDataByte(SAA7134_LUMA_CTRL, ~SAA7134_LUMA_CTRL_YCOMB);

  00023	68 bf 00 00 00	 push	 191			; 000000bfH
  00028	68 09 01 00 00	 push	 265			; 00000109H
  0002d	8b 4d fc	 mov	 ecx, DWORD PTR _this$[ebp]
  00030	e8 00 00 00 00	 call	 ?AndDataByte@CPCICard@@QAEXKE@Z ; CPCICard::AndDataByte

; 408  :         AndDataByte(SAA7134_CHROMA_CTRL1, ~SAA7134_CHROMA_CTRL1_CCOMB);

  00035	68 fe 00 00 00	 push	 254			; 000000feH
  0003a	68 0e 01 00 00	 push	 270			; 0000010eH
  0003f	8b 4d fc	 mov	 ecx, DWORD PTR _this$[ebp]
  00042	e8 00 00 00 00	 call	 ?AndDataByte@CPCICard@@QAEXKE@Z ; CPCICard::AndDataByte

; 409  :         break;

  00047	eb 41		 jmp	 SHORT $LN7@SetCombFil@2
$LN3@SetCombFil@2:

; 410  : 
; 411  :     case COMBFILTER_CHROMA_ONLY:
; 412  :         AndDataByte(SAA7134_LUMA_CTRL, ~SAA7134_LUMA_CTRL_YCOMB);

  00049	68 bf 00 00 00	 push	 191			; 000000bfH
  0004e	68 09 01 00 00	 push	 265			; 00000109H
  00053	8b 4d fc	 mov	 ecx, DWORD PTR _this$[ebp]
  00056	e8 00 00 00 00	 call	 ?AndDataByte@CPCICard@@QAEXKE@Z ; CPCICard::AndDataByte

; 413  :         OrDataByte(SAA7134_CHROMA_CTRL1, SAA7134_CHROMA_CTRL1_CCOMB);

  0005b	6a 01		 push	 1
  0005d	68 0e 01 00 00	 push	 270			; 0000010eH
  00062	8b 4d fc	 mov	 ecx, DWORD PTR _this$[ebp]
  00065	e8 00 00 00 00	 call	 ?OrDataByte@CPCICard@@QAEXKE@Z ; CPCICard::OrDataByte

; 414  :         break;

  0006a	eb 1e		 jmp	 SHORT $LN7@SetCombFil@2
$LN2@SetCombFil@2:

; 415  : 
; 416  :     case COMBFILTER_FULL:
; 417  :         OrDataByte(SAA7134_LUMA_CTRL, SAA7134_LUMA_CTRL_YCOMB);

  0006c	6a 40		 push	 64			; 00000040H
  0006e	68 09 01 00 00	 push	 265			; 00000109H
  00073	8b 4d fc	 mov	 ecx, DWORD PTR _this$[ebp]
  00076	e8 00 00 00 00	 call	 ?OrDataByte@CPCICard@@QAEXKE@Z ; CPCICard::OrDataByte

; 418  :         OrDataByte(SAA7134_CHROMA_CTRL1, SAA7134_CHROMA_CTRL1_CCOMB);

  0007b	6a 01		 push	 1
  0007d	68 0e 01 00 00	 push	 270			; 0000010eH
  00082	8b 4d fc	 mov	 ecx, DWORD PTR _this$[ebp]
  00085	e8 00 00 00 00	 call	 ?OrDataByte@CPCICard@@QAEXKE@Z ; CPCICard::OrDataByte
$LN7@SetCombFil@2:

; 419  :         break;
; 420  : 
; 421  :     default:
; 422  :         break;
; 423  :     }
; 424  : }

  0008a	8b e5		 mov	 esp, ebp
  0008c	5d		 pop	 ebp
  0008d	c2 04 00	 ret	 4
?SetCombFilter@CSAA7134Card@@QAEXW4eCombFilter@CSAA7134Common@@@Z ENDP ; CSAA7134Card::SetCombFilter
_TEXT	ENDS
PUBLIC	?SetVSyncRecovery@CSAA7134Card@@QAEXW4eVSyncRecovery@CSAA7134Common@@@Z ; CSAA7134Card::SetVSyncRecovery
; Function compile flags: /Odtp
;	COMDAT ?SetVSyncRecovery@CSAA7134Card@@QAEXW4eVSyncRecovery@CSAA7134Common@@@Z
_TEXT	SEGMENT
tv64 = -12						; size = 4
_this$ = -8						; size = 4
_VNOI$ = -1						; size = 1
_VSyncRecovery$ = 8					; size = 4
?SetVSyncRecovery@CSAA7134Card@@QAEXW4eVSyncRecovery@CSAA7134Common@@@Z PROC ; CSAA7134Card::SetVSyncRecovery, COMDAT
; _this$ = ecx

; 373  : {

  00000	55		 push	 ebp
  00001	8b ec		 mov	 ebp, esp
  00003	83 ec 0c	 sub	 esp, 12			; 0000000cH
  00006	89 4d f8	 mov	 DWORD PTR _this$[ebp], ecx

; 374  :     BYTE VNOI = 0x00;

  00009	c6 45 ff 00	 mov	 BYTE PTR _VNOI$[ebp], 0

; 375  : 
; 376  :     switch (VSyncRecovery)

  0000d	8b 45 08	 mov	 eax, DWORD PTR _VSyncRecovery$[ebp]
  00010	89 45 f4	 mov	 DWORD PTR tv64[ebp], eax
  00013	83 7d f4 03	 cmp	 DWORD PTR tv64[ebp], 3
  00017	77 3e		 ja	 SHORT $LN7@SetVSyncRe
  00019	8b 4d f4	 mov	 ecx, DWORD PTR tv64[ebp]
  0001c	ff 24 8d 00 00
	00 00		 jmp	 DWORD PTR $LN11@SetVSyncRe[ecx*4]
$LN6@SetVSyncRe:

; 377  :     {
; 378  :     case VSYNCRECOVERY_NORMAL:
; 379  :         VNOI = 0x00;

  00023	c6 45 ff 00	 mov	 BYTE PTR _VNOI$[ebp], 0

; 380  :         break;

  00027	eb 2e		 jmp	 SHORT $LN7@SetVSyncRe
$LN5@SetVSyncRe:

; 381  :     case VSYNCRECOVERY_FAST_TRACKING:
; 382  :         if (ReadByte(SAA7134_SYNC_CTRL) & SAA7134_SYNC_CTRL_AUFD)

  00029	68 08 01 00 00	 push	 264			; 00000108H
  0002e	8b 4d f8	 mov	 ecx, DWORD PTR _this$[ebp]
  00031	e8 00 00 00 00	 call	 ?ReadByte@CPCICard@@QAEEK@Z ; CPCICard::ReadByte
  00036	0f b6 d0	 movzx	 edx, al
  00039	81 e2 80 00 00
	00		 and	 edx, 128		; 00000080H
  0003f	74 06		 je	 SHORT $LN4@SetVSyncRe

; 383  :         {
; 384  :             VNOI = 0x00;

  00041	c6 45 ff 00	 mov	 BYTE PTR _VNOI$[ebp], 0

; 385  :         }
; 386  :         else

  00045	eb 04		 jmp	 SHORT $LN3@SetVSyncRe
$LN4@SetVSyncRe:

; 387  :         {
; 388  :             VNOI = 0x01;

  00047	c6 45 ff 01	 mov	 BYTE PTR _VNOI$[ebp], 1
$LN3@SetVSyncRe:

; 389  :         }
; 390  :         break;

  0004b	eb 0a		 jmp	 SHORT $LN7@SetVSyncRe
$LN2@SetVSyncRe:

; 391  :     case VSYNCRECOVERY_FREE_RUNNING:
; 392  :         VNOI = 0x02;

  0004d	c6 45 ff 02	 mov	 BYTE PTR _VNOI$[ebp], 2

; 393  :         break;

  00051	eb 04		 jmp	 SHORT $LN7@SetVSyncRe
$LN1@SetVSyncRe:

; 394  :     case VSYNCRECOVERY_IMMEDIATE_MODE:
; 395  :         VNOI = 0x03;

  00053	c6 45 ff 03	 mov	 BYTE PTR _VNOI$[ebp], 3
$LN7@SetVSyncRe:

; 396  :         break;
; 397  :     }
; 398  :     MaskDataByte(SAA7134_SYNC_CTRL, VNOI, SAA7134_SYNC_CTRL_VNOI);

  00057	6a 03		 push	 3
  00059	0f b6 45 ff	 movzx	 eax, BYTE PTR _VNOI$[ebp]
  0005d	50		 push	 eax
  0005e	68 08 01 00 00	 push	 264			; 00000108H
  00063	8b 4d f8	 mov	 ecx, DWORD PTR _this$[ebp]
  00066	e8 00 00 00 00	 call	 ?MaskDataByte@CPCICard@@QAEXKEE@Z ; CPCICard::MaskDataByte

; 399  : }

  0006b	8b e5		 mov	 esp, ebp
  0006d	5d		 pop	 ebp
  0006e	c2 04 00	 ret	 4
  00071	8d 49 00	 npad	 3
$LN11@SetVSyncRe:
  00074	00 00 00 00	 DD	 $LN6@SetVSyncRe
  00078	00 00 00 00	 DD	 $LN5@SetVSyncRe
  0007c	00 00 00 00	 DD	 $LN2@SetVSyncRe
  00080	00 00 00 00	 DD	 $LN1@SetVSyncRe
?SetVSyncRecovery@CSAA7134Card@@QAEXW4eVSyncRecovery@CSAA7134Common@@@Z ENDP ; CSAA7134Card::SetVSyncRecovery
_TEXT	ENDS
PUBLIC	?SetHPLLMode@CSAA7134Card@@QAEXW4eHPLLMode@CSAA7134Common@@@Z ; CSAA7134Card::SetHPLLMode
; Function compile flags: /Odtp
;	COMDAT ?SetHPLLMode@CSAA7134Card@@QAEXW4eHPLLMode@CSAA7134Common@@@Z
_TEXT	SEGMENT
_this$ = -4						; size = 4
_HPLLMode$ = 8						; size = 4
?SetHPLLMode@CSAA7134Card@@QAEXW4eHPLLMode@CSAA7134Common@@@Z PROC ; CSAA7134Card::SetHPLLMode, COMDAT
; _this$ = ecx

; 356  : {

  00000	55		 push	 ebp
  00001	8b ec		 mov	 ebp, esp
  00003	51		 push	 ecx
  00004	89 4d fc	 mov	 DWORD PTR _this$[ebp], ecx

; 357  :     if (HPLLMode == HPLLMODE_TV)

  00007	83 7d 08 00	 cmp	 DWORD PTR _HPLLMode$[ebp], 0
  0000b	75 13		 jne	 SHORT $LN4@SetHPLLMod

; 358  :     {
; 359  :         MaskDataByte(SAA7134_SYNC_CTRL, 0x00, SAA7134_SYNC_CTRL_HTD);

  0000d	6a 18		 push	 24			; 00000018H
  0000f	6a 00		 push	 0
  00011	68 08 01 00 00	 push	 264			; 00000108H
  00016	8b 4d fc	 mov	 ecx, DWORD PTR _this$[ebp]
  00019	e8 00 00 00 00	 call	 ?MaskDataByte@CPCICard@@QAEXKEE@Z ; CPCICard::MaskDataByte
  0001e	eb 2a		 jmp	 SHORT $LN5@SetHPLLMod
$LN4@SetHPLLMod:

; 360  :     }
; 361  :     else if (HPLLMode == HPLLMODE_VCR)

  00020	83 7d 08 01	 cmp	 DWORD PTR _HPLLMode$[ebp], 1
  00024	75 13		 jne	 SHORT $LN2@SetHPLLMod

; 362  :     {
; 363  :         MaskDataByte(SAA7134_SYNC_CTRL, 0x08, SAA7134_SYNC_CTRL_HTD);

  00026	6a 18		 push	 24			; 00000018H
  00028	6a 08		 push	 8
  0002a	68 08 01 00 00	 push	 264			; 00000108H
  0002f	8b 4d fc	 mov	 ecx, DWORD PTR _this$[ebp]
  00032	e8 00 00 00 00	 call	 ?MaskDataByte@CPCICard@@QAEXKEE@Z ; CPCICard::MaskDataByte

; 364  :     }
; 365  :     else

  00037	eb 11		 jmp	 SHORT $LN5@SetHPLLMod
$LN2@SetHPLLMod:

; 366  :     {
; 367  :         MaskDataByte(SAA7134_SYNC_CTRL, 0x18, SAA7134_SYNC_CTRL_HTD);

  00039	6a 18		 push	 24			; 00000018H
  0003b	6a 18		 push	 24			; 00000018H
  0003d	68 08 01 00 00	 push	 264			; 00000108H
  00042	8b 4d fc	 mov	 ecx, DWORD PTR _this$[ebp]
  00045	e8 00 00 00 00	 call	 ?MaskDataByte@CPCICard@@QAEXKEE@Z ; CPCICard::MaskDataByte
$LN5@SetHPLLMod:

; 368  :     }
; 369  : }

  0004a	8b e5		 mov	 esp, ebp
  0004c	5d		 pop	 ebp
  0004d	c2 04 00	 ret	 4
?SetHPLLMode@CSAA7134Card@@QAEXW4eHPLLMode@CSAA7134Common@@@Z ENDP ; CSAA7134Card::SetHPLLMode
_TEXT	ENDS
PUBLIC	?SetTaskGeometry@CSAA7134Card@@IAEXW4eTaskID@CSAA7134Common@@GGGGGG@Z ; CSAA7134Card::SetTaskGeometry
; Function compile flags: /Odtp
;	COMDAT ?SetTaskGeometry@CSAA7134Card@@IAEXW4eTaskID@CSAA7134Common@@GGGGGG@Z
_TEXT	SEGMENT
_this$ = -28						; size = 4
_LinesAvailable$143901 = -24				; size = 2
_HorizScale$ = -20					; size = 2
_RegionID$ = -16					; size = 4
_Lines$ = -12						; size = 2
_VertScale$ = -8					; size = 2
_TaskMask$ = -1						; size = 1
_TaskID$ = 8						; size = 4
_Width$ = 12						; size = 2
_Height$ = 16						; size = 2
_HDelay$ = 20						; size = 2
_VDelay$ = 24						; size = 2
_ScaleWidth$ = 28					; size = 2
_ScaleHeight$ = 32					; size = 2
?SetTaskGeometry@CSAA7134Card@@IAEXW4eTaskID@CSAA7134Common@@GGGGGG@Z PROC ; CSAA7134Card::SetTaskGeometry, COMDAT
; _this$ = ecx

; 272  : {

  00000	55		 push	 ebp
  00001	8b ec		 mov	 ebp, esp
  00003	83 ec 1c	 sub	 esp, 28			; 0000001cH
  00006	89 4d e4	 mov	 DWORD PTR _this$[ebp], ecx

; 273  :     BYTE TaskMask = TaskID2TaskMask(TaskID);

  00009	8b 45 08	 mov	 eax, DWORD PTR _TaskID$[ebp]
  0000c	50		 push	 eax
  0000d	8b 4d e4	 mov	 ecx, DWORD PTR _this$[ebp]
  00010	e8 00 00 00 00	 call	 ?TaskID2TaskMask@CSAA7134Card@@IAEEW4eTaskID@CSAA7134Common@@@Z ; CSAA7134Card::TaskID2TaskMask
  00015	88 45 ff	 mov	 BYTE PTR _TaskMask$[ebp], al

; 274  : 
; 275  :     WriteWord(SAA7134_VIDEO_H_START(TaskMask), HDelay);

  00018	0f b7 4d 14	 movzx	 ecx, WORD PTR _HDelay$[ebp]
  0001c	51		 push	 ecx
  0001d	0f b6 55 ff	 movzx	 edx, BYTE PTR _TaskMask$[ebp]
  00021	83 ca 14	 or	 edx, 20			; 00000014H
  00024	52		 push	 edx
  00025	8b 4d e4	 mov	 ecx, DWORD PTR _this$[ebp]
  00028	e8 00 00 00 00	 call	 ?WriteWord@CPCICard@@QAEXKG@Z ; CPCICard::WriteWord

; 276  :     WriteWord(SAA7134_VIDEO_H_STOP(TaskMask), HDelay + Width - 1);

  0002d	0f b7 45 14	 movzx	 eax, WORD PTR _HDelay$[ebp]
  00031	0f b7 4d 0c	 movzx	 ecx, WORD PTR _Width$[ebp]
  00035	8d 54 08 ff	 lea	 edx, DWORD PTR [eax+ecx-1]
  00039	52		 push	 edx
  0003a	0f b6 45 ff	 movzx	 eax, BYTE PTR _TaskMask$[ebp]
  0003e	83 c8 16	 or	 eax, 22			; 00000016H
  00041	50		 push	 eax
  00042	8b 4d e4	 mov	 ecx, DWORD PTR _this$[ebp]
  00045	e8 00 00 00 00	 call	 ?WriteWord@CPCICard@@QAEXKG@Z ; CPCICard::WriteWord

; 277  :     WriteWord(SAA7134_VIDEO_V_START(TaskMask), VDelay);

  0004a	0f b7 4d 18	 movzx	 ecx, WORD PTR _VDelay$[ebp]
  0004e	51		 push	 ecx
  0004f	0f b6 55 ff	 movzx	 edx, BYTE PTR _TaskMask$[ebp]
  00053	83 ca 18	 or	 edx, 24			; 00000018H
  00056	52		 push	 edx
  00057	8b 4d e4	 mov	 ecx, DWORD PTR _this$[ebp]
  0005a	e8 00 00 00 00	 call	 ?WriteWord@CPCICard@@QAEXKG@Z ; CPCICard::WriteWord

; 278  :     WriteWord(SAA7134_VIDEO_V_STOP(TaskMask), VDelay + Height - 1);

  0005f	0f b7 45 18	 movzx	 eax, WORD PTR _VDelay$[ebp]
  00063	0f b7 4d 10	 movzx	 ecx, WORD PTR _Height$[ebp]
  00067	8d 54 08 ff	 lea	 edx, DWORD PTR [eax+ecx-1]
  0006b	52		 push	 edx
  0006c	0f b6 45 ff	 movzx	 eax, BYTE PTR _TaskMask$[ebp]
  00070	83 c8 1a	 or	 eax, 26			; 0000001aH
  00073	50		 push	 eax
  00074	8b 4d e4	 mov	 ecx, DWORD PTR _this$[ebp]
  00077	e8 00 00 00 00	 call	 ?WriteWord@CPCICard@@QAEXKG@Z ; CPCICard::WriteWord

; 279  : 
; 280  :     // settings for no horizontal prescaling
; 281  :     ResetHPrescale(TaskID);

  0007c	8b 4d 08	 mov	 ecx, DWORD PTR _TaskID$[ebp]
  0007f	51		 push	 ecx
  00080	8b 4d e4	 mov	 ecx, DWORD PTR _this$[ebp]
  00083	e8 00 00 00 00	 call	 ?ResetHPrescale@CSAA7134Card@@IAEXW4eTaskID@CSAA7134Common@@@Z ; CSAA7134Card::ResetHPrescale

; 282  : 
; 283  :     // 1024UL = median
; 284  :     WORD HorizScale = 1024UL * Width / ScaleWidth;

  00088	0f b7 45 0c	 movzx	 eax, WORD PTR _Width$[ebp]
  0008c	c1 e0 0a	 shl	 eax, 10			; 0000000aH
  0008f	0f b7 4d 1c	 movzx	 ecx, WORD PTR _ScaleWidth$[ebp]
  00093	33 d2		 xor	 edx, edx
  00095	f7 f1		 div	 ecx
  00097	66 89 45 ec	 mov	 WORD PTR _HorizScale$[ebp], ax

; 285  :     WriteWord(SAA7134_H_SCALE_INC(TaskMask), HorizScale);

  0009b	0f b7 55 ec	 movzx	 edx, WORD PTR _HorizScale$[ebp]
  0009f	52		 push	 edx
  000a0	0f b6 45 ff	 movzx	 eax, BYTE PTR _TaskMask$[ebp]
  000a4	83 c8 2c	 or	 eax, 44			; 0000002cH
  000a7	50		 push	 eax
  000a8	8b 4d e4	 mov	 ecx, DWORD PTR _this$[ebp]
  000ab	e8 00 00 00 00	 call	 ?WriteWord@CPCICard@@QAEXKG@Z ; CPCICard::WriteWord

; 286  : 
; 287  :     // settings for vertical scaling
; 288  :     WORD VertScale = 1024UL * Height / ScaleHeight;

  000b0	0f b7 45 10	 movzx	 eax, WORD PTR _Height$[ebp]
  000b4	c1 e0 0a	 shl	 eax, 10			; 0000000aH
  000b7	0f b7 4d 20	 movzx	 ecx, WORD PTR _ScaleHeight$[ebp]
  000bb	33 d2		 xor	 edx, edx
  000bd	f7 f1		 div	 ecx
  000bf	66 89 45 f8	 mov	 WORD PTR _VertScale$[ebp], ax

; 289  :     WriteWord(SAA7134_V_SCALE_RATIO(TaskMask), VertScale);

  000c3	0f b7 55 f8	 movzx	 edx, WORD PTR _VertScale$[ebp]
  000c7	52		 push	 edx
  000c8	0f b6 45 ff	 movzx	 eax, BYTE PTR _TaskMask$[ebp]
  000cc	83 c8 30	 or	 eax, 48			; 00000030H
  000cf	50		 push	 eax
  000d0	8b 4d e4	 mov	 ecx, DWORD PTR _this$[ebp]
  000d3	e8 00 00 00 00	 call	 ?WriteWord@CPCICard@@QAEXKG@Z ; CPCICard::WriteWord

; 290  : 
; 291  :     WORD Lines = ScaleHeight;

  000d8	66 8b 4d 20	 mov	 cx, WORD PTR _ScaleHeight$[ebp]
  000dc	66 89 4d f4	 mov	 WORD PTR _Lines$[ebp], cx

; 292  : 
; 293  :     eRegionID RegionID = TaskID2VideoRegion(TaskID);

  000e0	8b 55 08	 mov	 edx, DWORD PTR _TaskID$[ebp]
  000e3	52		 push	 edx
  000e4	8b 4d e4	 mov	 ecx, DWORD PTR _this$[ebp]
  000e7	83 c1 58	 add	 ecx, 88			; 00000058H
  000ea	e8 00 00 00 00	 call	 ?TaskID2VideoRegion@CSAA7134Common@@IAE?AW4eRegionID@1@W4eTaskID@1@@Z ; CSAA7134Common::TaskID2VideoRegion
  000ef	89 45 f0	 mov	 DWORD PTR _RegionID$[ebp], eax

; 294  :     if (GetDMA(RegionID))

  000f2	8b 45 f0	 mov	 eax, DWORD PTR _RegionID$[ebp]
  000f5	50		 push	 eax
  000f6	8b 4d e4	 mov	 ecx, DWORD PTR _this$[ebp]
  000f9	e8 00 00 00 00	 call	 ?GetDMA@CSAA7134Card@@QAEHW4eRegionID@CSAA7134Common@@@Z ; CSAA7134Card::GetDMA
  000fe	85 c0		 test	 eax, eax
  00100	74 2b		 je	 SHORT $LN2@SetTaskGeo

; 295  :     {
; 296  :         // Make sure we aren't grabbing more lines than we have memory
; 297  :         // Multiply CurrentX by 2 because YUV is two bytes per pixel
; 298  :         WORD LinesAvailable = CalculateLinesAvailable(RegionID, ScaleWidth * 2);

  00102	0f b7 4d 1c	 movzx	 ecx, WORD PTR _ScaleWidth$[ebp]
  00106	d1 e1		 shl	 ecx, 1
  00108	51		 push	 ecx
  00109	8b 55 f0	 mov	 edx, DWORD PTR _RegionID$[ebp]
  0010c	52		 push	 edx
  0010d	8b 4d e4	 mov	 ecx, DWORD PTR _this$[ebp]
  00110	e8 00 00 00 00	 call	 ?CalculateLinesAvailable@CSAA7134Card@@IAEGW4eRegionID@CSAA7134Common@@G@Z ; CSAA7134Card::CalculateLinesAvailable
  00115	66 89 45 e8	 mov	 WORD PTR _LinesAvailable$143901[ebp], ax

; 299  : 
; 300  :         if (LinesAvailable < Lines)

  00119	0f b7 45 e8	 movzx	 eax, WORD PTR _LinesAvailable$143901[ebp]
  0011d	0f b7 4d f4	 movzx	 ecx, WORD PTR _Lines$[ebp]
  00121	3b c1		 cmp	 eax, ecx
  00123	7d 08		 jge	 SHORT $LN2@SetTaskGeo

; 301  :         {
; 302  :             Lines = LinesAvailable;

  00125	66 8b 55 e8	 mov	 dx, WORD PTR _LinesAvailable$143901[ebp]
  00129	66 89 55 f4	 mov	 WORD PTR _Lines$[ebp], dx
$LN2@SetTaskGeo:

; 303  :         }
; 304  :     }
; 305  : 
; 306  :     // The number of lines and pixels to DMA
; 307  :     WriteWord(SAA7134_VIDEO_LINES(TaskMask), Lines);

  0012d	0f b7 45 f4	 movzx	 eax, WORD PTR _Lines$[ebp]
  00131	50		 push	 eax
  00132	0f b6 4d ff	 movzx	 ecx, BYTE PTR _TaskMask$[ebp]
  00136	83 c9 1e	 or	 ecx, 30			; 0000001eH
  00139	51		 push	 ecx
  0013a	8b 4d e4	 mov	 ecx, DWORD PTR _this$[ebp]
  0013d	e8 00 00 00 00	 call	 ?WriteWord@CPCICard@@QAEXKG@Z ; CPCICard::WriteWord

; 308  :     WriteWord(SAA7134_VIDEO_PIXELS(TaskMask), ScaleWidth);

  00142	0f b7 55 1c	 movzx	 edx, WORD PTR _ScaleWidth$[ebp]
  00146	52		 push	 edx
  00147	0f b6 45 ff	 movzx	 eax, BYTE PTR _TaskMask$[ebp]
  0014b	83 c8 1c	 or	 eax, 28			; 0000001cH
  0014e	50		 push	 eax
  0014f	8b 4d e4	 mov	 ecx, DWORD PTR _this$[ebp]
  00152	e8 00 00 00 00	 call	 ?WriteWord@CPCICard@@QAEXKG@Z ; CPCICard::WriteWord

; 309  : }

  00157	8b e5		 mov	 esp, ebp
  00159	5d		 pop	 ebp
  0015a	c2 1c 00	 ret	 28			; 0000001cH
?SetTaskGeometry@CSAA7134Card@@IAEXW4eTaskID@CSAA7134Common@@GGGGGG@Z ENDP ; CSAA7134Card::SetTaskGeometry
_TEXT	ENDS
PUBLIC	?SetGeometry@CSAA7134Card@@QAEXGGJJ@Z		; CSAA7134Card::SetGeometry
; Function compile flags: /Odtp
;	COMDAT ?SetGeometry@CSAA7134Card@@QAEXGGJJ@Z
_TEXT	SEGMENT
_this$ = -20						; size = 4
_VDelay$ = -16						; size = 2
_HDelay$ = -12						; size = 2
_FieldWidth$ = -8					; size = 2
_FieldHeight$ = -4					; size = 2
_ScaleWidth$ = 8					; size = 2
_ScaleHeight$ = 12					; size = 2
_HDelayShift$ = 16					; size = 4
_VDelayShift$ = 20					; size = 4
?SetGeometry@CSAA7134Card@@QAEXGGJJ@Z PROC		; CSAA7134Card::SetGeometry, COMDAT
; _this$ = ecx

; 223  : {

  00000	55		 push	 ebp
  00001	8b ec		 mov	 ebp, esp
  00003	83 ec 14	 sub	 esp, 20			; 00000014H
  00006	89 4d ec	 mov	 DWORD PTR _this$[ebp], ecx

; 224  :     if (m_VideoStandard == VIDEOSTANDARD_INVALID)

  00009	8b 45 ec	 mov	 eax, DWORD PTR _this$[ebp]
  0000c	83 b8 ac 00 00
	00 ff		 cmp	 DWORD PTR [eax+172], -1
  00013	75 05		 jne	 SHORT $LN7@SetGeometr

; 225  :     {
; 226  :         return;

  00015	e9 36 01 00 00	 jmp	 $LN8@SetGeometr
$LN7@SetGeometr:

; 227  :     }
; 228  : 
; 229  :     WORD FieldWidth     = m_VideoStandards[m_VideoStandard].wFieldWidth;

  0001a	8b 4d ec	 mov	 ecx, DWORD PTR _this$[ebp]
  0001d	8b 91 ac 00 00
	00		 mov	 edx, DWORD PTR [ecx+172]
  00023	6b d2 14	 imul	 edx, 20			; 00000014H
  00026	66 8b 82 00 00
	00 00		 mov	 ax, WORD PTR ?m_VideoStandards@CSAA7134Common@@1PAUTVideoStandardDefinition@1@A[edx]
  0002d	66 89 45 f8	 mov	 WORD PTR _FieldWidth$[ebp], ax

; 230  :     WORD FieldHeight    = m_VideoStandards[m_VideoStandard].wFieldHeight;

  00031	8b 4d ec	 mov	 ecx, DWORD PTR _this$[ebp]
  00034	8b 91 ac 00 00
	00		 mov	 edx, DWORD PTR [ecx+172]
  0003a	6b d2 14	 imul	 edx, 20			; 00000014H
  0003d	66 8b 82 02 00
	00 00		 mov	 ax, WORD PTR ?m_VideoStandards@CSAA7134Common@@1PAUTVideoStandardDefinition@1@A[edx+2]
  00044	66 89 45 fc	 mov	 WORD PTR _FieldHeight$[ebp], ax

; 231  : 
; 232  :     WORD HDelay         = m_VideoStandards[m_VideoStandard].wHDelay;

  00048	8b 4d ec	 mov	 ecx, DWORD PTR _this$[ebp]
  0004b	8b 91 ac 00 00
	00		 mov	 edx, DWORD PTR [ecx+172]
  00051	6b d2 14	 imul	 edx, 20			; 00000014H
  00054	66 8b 82 04 00
	00 00		 mov	 ax, WORD PTR ?m_VideoStandards@CSAA7134Common@@1PAUTVideoStandardDefinition@1@A[edx+4]
  0005b	66 89 45 f4	 mov	 WORD PTR _HDelay$[ebp], ax

; 233  :     WORD VDelay         = m_VideoStandards[m_VideoStandard].wVDelay;

  0005f	8b 4d ec	 mov	 ecx, DWORD PTR _this$[ebp]
  00062	8b 91 ac 00 00
	00		 mov	 edx, DWORD PTR [ecx+172]
  00068	6b d2 14	 imul	 edx, 20			; 00000014H
  0006b	66 8b 82 06 00
	00 00		 mov	 ax, WORD PTR ?m_VideoStandards@CSAA7134Common@@1PAUTVideoStandardDefinition@1@A[edx+6]
  00072	66 89 45 f0	 mov	 WORD PTR _VDelay$[ebp], ax

; 234  : 
; 235  :     if (HDelayShift != 0)

  00076	83 7d 10 00	 cmp	 DWORD PTR _HDelayShift$[ebp], 0
  0007a	74 20		 je	 SHORT $LN6@SetGeometr

; 236  :     {
; 237  :         if (HDelay + HDelayShift < 0)

  0007c	0f b7 4d f4	 movzx	 ecx, WORD PTR _HDelay$[ebp]
  00080	03 4d 10	 add	 ecx, DWORD PTR _HDelayShift$[ebp]
  00083	79 09		 jns	 SHORT $LN5@SetGeometr

; 238  :         {
; 239  :             HDelayShift = -HDelay;

  00085	0f b7 55 f4	 movzx	 edx, WORD PTR _HDelay$[ebp]
  00089	f7 da		 neg	 edx
  0008b	89 55 10	 mov	 DWORD PTR _HDelayShift$[ebp], edx
$LN5@SetGeometr:

; 240  :         }
; 241  :         HDelay += (WORD)HDelayShift;

  0008e	0f b7 45 10	 movzx	 eax, WORD PTR _HDelayShift$[ebp]
  00092	0f b7 4d f4	 movzx	 ecx, WORD PTR _HDelay$[ebp]
  00096	03 c8		 add	 ecx, eax
  00098	66 89 4d f4	 mov	 WORD PTR _HDelay$[ebp], cx
$LN6@SetGeometr:

; 242  :     }
; 243  : 
; 244  :     if (VDelayShift != 0)

  0009c	83 7d 14 00	 cmp	 DWORD PTR _VDelayShift$[ebp], 0
  000a0	74 54		 je	 SHORT $LN4@SetGeometr

; 245  :     {
; 246  :         if (IsVBIActive())

  000a2	8b 4d ec	 mov	 ecx, DWORD PTR _this$[ebp]
  000a5	e8 00 00 00 00	 call	 ?IsVBIActive@CSAA7134Card@@IAEHXZ ; CSAA7134Card::IsVBIActive
  000aa	85 c0		 test	 eax, eax
  000ac	74 18		 je	 SHORT $LN3@SetGeometr

; 247  :         {
; 248  :             if (VDelayShift < GetMinimumVDelayWithVBI())

  000ae	8b 4d ec	 mov	 ecx, DWORD PTR _this$[ebp]
  000b1	e8 00 00 00 00	 call	 ?GetMinimumVDelayWithVBI@CSAA7134Card@@QAEJXZ ; CSAA7134Card::GetMinimumVDelayWithVBI
  000b6	39 45 14	 cmp	 DWORD PTR _VDelayShift$[ebp], eax
  000b9	7d 0b		 jge	 SHORT $LN3@SetGeometr

; 249  :             {
; 250  :                 VDelayShift = GetMinimumVDelayWithVBI();

  000bb	8b 4d ec	 mov	 ecx, DWORD PTR _this$[ebp]
  000be	e8 00 00 00 00	 call	 ?GetMinimumVDelayWithVBI@CSAA7134Card@@QAEJXZ ; CSAA7134Card::GetMinimumVDelayWithVBI
  000c3	89 45 14	 mov	 DWORD PTR _VDelayShift$[ebp], eax
$LN3@SetGeometr:

; 251  :             }
; 252  :         }
; 253  : 
; 254  :         if (VDelay + (VDelayShift / 2) < 0)

  000c6	0f b7 4d f0	 movzx	 ecx, WORD PTR _VDelay$[ebp]
  000ca	8b 45 14	 mov	 eax, DWORD PTR _VDelayShift$[ebp]
  000cd	99		 cdq
  000ce	2b c2		 sub	 eax, edx
  000d0	d1 f8		 sar	 eax, 1
  000d2	03 c8		 add	 ecx, eax
  000d4	79 0b		 jns	 SHORT $LN1@SetGeometr

; 255  :         {
; 256  :             VDelayShift = -VDelay * 2;

  000d6	0f b7 55 f0	 movzx	 edx, WORD PTR _VDelay$[ebp]
  000da	f7 da		 neg	 edx
  000dc	d1 e2		 shl	 edx, 1
  000de	89 55 14	 mov	 DWORD PTR _VDelayShift$[ebp], edx
$LN1@SetGeometr:

; 257  :         }
; 258  :         VDelay += (WORD)(VDelayShift / 2);

  000e1	8b 45 14	 mov	 eax, DWORD PTR _VDelayShift$[ebp]
  000e4	99		 cdq
  000e5	2b c2		 sub	 eax, edx
  000e7	d1 f8		 sar	 eax, 1
  000e9	0f b7 c0	 movzx	 eax, ax
  000ec	0f b7 4d f0	 movzx	 ecx, WORD PTR _VDelay$[ebp]
  000f0	03 c8		 add	 ecx, eax
  000f2	66 89 4d f0	 mov	 WORD PTR _VDelay$[ebp], cx
$LN4@SetGeometr:

; 259  :     }
; 260  : 
; 261  :     SetTaskGeometry(TASKID_A, FieldWidth, FieldHeight, HDelay, VDelay,
; 262  :         ScaleWidth, ScaleHeight / 2);

  000f6	0f b7 45 0c	 movzx	 eax, WORD PTR _ScaleHeight$[ebp]
  000fa	99		 cdq
  000fb	2b c2		 sub	 eax, edx
  000fd	d1 f8		 sar	 eax, 1
  000ff	50		 push	 eax
  00100	0f b7 55 08	 movzx	 edx, WORD PTR _ScaleWidth$[ebp]
  00104	52		 push	 edx
  00105	0f b7 45 f0	 movzx	 eax, WORD PTR _VDelay$[ebp]
  00109	50		 push	 eax
  0010a	0f b7 4d f4	 movzx	 ecx, WORD PTR _HDelay$[ebp]
  0010e	51		 push	 ecx
  0010f	0f b7 55 fc	 movzx	 edx, WORD PTR _FieldHeight$[ebp]
  00113	52		 push	 edx
  00114	0f b7 45 f8	 movzx	 eax, WORD PTR _FieldWidth$[ebp]
  00118	50		 push	 eax
  00119	6a 00		 push	 0
  0011b	8b 4d ec	 mov	 ecx, DWORD PTR _this$[ebp]
  0011e	e8 00 00 00 00	 call	 ?SetTaskGeometry@CSAA7134Card@@IAEXW4eTaskID@CSAA7134Common@@GGGGGG@Z ; CSAA7134Card::SetTaskGeometry

; 263  :     SetTaskGeometry(TASKID_B, FieldWidth, FieldHeight, HDelay, VDelay,
; 264  :         ScaleWidth, ScaleHeight / 2);

  00123	0f b7 45 0c	 movzx	 eax, WORD PTR _ScaleHeight$[ebp]
  00127	99		 cdq
  00128	2b c2		 sub	 eax, edx
  0012a	d1 f8		 sar	 eax, 1
  0012c	50		 push	 eax
  0012d	0f b7 4d 08	 movzx	 ecx, WORD PTR _ScaleWidth$[ebp]
  00131	51		 push	 ecx
  00132	0f b7 55 f0	 movzx	 edx, WORD PTR _VDelay$[ebp]
  00136	52		 push	 edx
  00137	0f b7 45 f4	 movzx	 eax, WORD PTR _HDelay$[ebp]
  0013b	50		 push	 eax
  0013c	0f b7 4d fc	 movzx	 ecx, WORD PTR _FieldHeight$[ebp]
  00140	51		 push	 ecx
  00141	0f b7 55 f8	 movzx	 edx, WORD PTR _FieldWidth$[ebp]
  00145	52		 push	 edx
  00146	6a 01		 push	 1
  00148	8b 4d ec	 mov	 ecx, DWORD PTR _this$[ebp]
  0014b	e8 00 00 00 00	 call	 ?SetTaskGeometry@CSAA7134Card@@IAEXW4eTaskID@CSAA7134Common@@GGGGGG@Z ; CSAA7134Card::SetTaskGeometry
$LN8@SetGeometr:

; 265  : }

  00150	8b e5		 mov	 esp, ebp
  00152	5d		 pop	 ebp
  00153	c2 10 00	 ret	 16			; 00000010H
?SetGeometry@CSAA7134Card@@QAEXGGJJ@Z ENDP		; CSAA7134Card::SetGeometry
_TEXT	ENDS
PUBLIC	?SetTaskVBIGeometry@CSAA7134Card@@IAEXW4eTaskID@CSAA7134Common@@GGGGG@Z ; CSAA7134Card::SetTaskVBIGeometry
; Function compile flags: /Odtp
;	COMDAT ?SetTaskVBIGeometry@CSAA7134Card@@IAEXW4eTaskID@CSAA7134Common@@GGGGG@Z
_TEXT	SEGMENT
tv206 = -44						; size = 4
tv204 = -40						; size = 4
tv201 = -34						; size = 2
tv200 = -32						; size = 4
tv198 = -28						; size = 4
_this$ = -24						; size = 4
_LinesAvailable$143863 = -20				; size = 2
_RegionID$ = -16					; size = 4
_Lines$ = -12						; size = 2
_SampleBytes$ = -8					; size = 2
_TaskMask$ = -1						; size = 1
_TaskID$ = 8						; size = 4
_HStart$ = 12						; size = 2
_HStop$ = 16						; size = 2
_VStart$ = 20						; size = 2
_VStop$ = 24						; size = 2
_UpscaleDivisor$ = 28					; size = 2
?SetTaskVBIGeometry@CSAA7134Card@@IAEXW4eTaskID@CSAA7134Common@@GGGGG@Z PROC ; CSAA7134Card::SetTaskVBIGeometry, COMDAT
; _this$ = ecx

; 190  : {

  00000	55		 push	 ebp
  00001	8b ec		 mov	 ebp, esp
  00003	83 ec 2c	 sub	 esp, 44			; 0000002cH
  00006	89 4d e8	 mov	 DWORD PTR _this$[ebp], ecx

; 191  :     BYTE TaskMask = TaskID2TaskMask(TaskID);

  00009	8b 45 08	 mov	 eax, DWORD PTR _TaskID$[ebp]
  0000c	50		 push	 eax
  0000d	8b 4d e8	 mov	 ecx, DWORD PTR _this$[ebp]
  00010	e8 00 00 00 00	 call	 ?TaskID2TaskMask@CSAA7134Card@@IAEEW4eTaskID@CSAA7134Common@@@Z ; CSAA7134Card::TaskID2TaskMask
  00015	88 45 ff	 mov	 BYTE PTR _TaskMask$[ebp], al

; 192  : 
; 193  :     WORD SampleBytes = (WORD)((double) 0x400 / UpscaleDivisor * (HStop - HStart + 1));

  00018	0f b7 4d 1c	 movzx	 ecx, WORD PTR _UpscaleDivisor$[ebp]
  0001c	89 4d e4	 mov	 DWORD PTR tv198[ebp], ecx
  0001f	db 45 e4	 fild	 DWORD PTR tv198[ebp]
  00022	dc 3d 00 00 00
	00		 fdivr	 QWORD PTR __real@4090000000000000
  00028	0f b7 55 10	 movzx	 edx, WORD PTR _HStop$[ebp]
  0002c	0f b7 45 0c	 movzx	 eax, WORD PTR _HStart$[ebp]
  00030	2b d0		 sub	 edx, eax
  00032	83 c2 01	 add	 edx, 1
  00035	89 55 e0	 mov	 DWORD PTR tv200[ebp], edx
  00038	db 45 e0	 fild	 DWORD PTR tv200[ebp]
  0003b	de c9		 fmulp	 ST(1), ST(0)
  0003d	d9 7d de	 fnstcw	 WORD PTR tv201[ebp]
  00040	0f b7 45 de	 movzx	 eax, WORD PTR tv201[ebp]
  00044	0d 00 0c 00 00	 or	 eax, 3072		; 00000c00H
  00049	89 45 d8	 mov	 DWORD PTR tv204[ebp], eax
  0004c	d9 6d d8	 fldcw	 WORD PTR tv204[ebp]
  0004f	db 5d d4	 fistp	 DWORD PTR tv206[ebp]
  00052	d9 6d de	 fldcw	 WORD PTR tv201[ebp]
  00055	66 8b 4d d4	 mov	 cx, WORD PTR tv206[ebp]
  00059	66 89 4d f8	 mov	 WORD PTR _SampleBytes$[ebp], cx

; 194  : 
; 195  :     WriteWord(SAA7134_VBI_H_START(TaskMask), HStart);

  0005d	0f b7 55 0c	 movzx	 edx, WORD PTR _HStart$[ebp]
  00061	52		 push	 edx
  00062	0f b6 45 ff	 movzx	 eax, BYTE PTR _TaskMask$[ebp]
  00066	83 c8 04	 or	 eax, 4
  00069	50		 push	 eax
  0006a	8b 4d e8	 mov	 ecx, DWORD PTR _this$[ebp]
  0006d	e8 00 00 00 00	 call	 ?WriteWord@CPCICard@@QAEXKG@Z ; CPCICard::WriteWord

; 196  :     WriteWord(SAA7134_VBI_H_STOP(TaskMask), HStop);

  00072	0f b7 4d 10	 movzx	 ecx, WORD PTR _HStop$[ebp]
  00076	51		 push	 ecx
  00077	0f b6 55 ff	 movzx	 edx, BYTE PTR _TaskMask$[ebp]
  0007b	83 ca 06	 or	 edx, 6
  0007e	52		 push	 edx
  0007f	8b 4d e8	 mov	 ecx, DWORD PTR _this$[ebp]
  00082	e8 00 00 00 00	 call	 ?WriteWord@CPCICard@@QAEXKG@Z ; CPCICard::WriteWord

; 197  :     WriteWord(SAA7134_VBI_V_START(TaskMask), VStart);

  00087	0f b7 45 14	 movzx	 eax, WORD PTR _VStart$[ebp]
  0008b	50		 push	 eax
  0008c	0f b6 4d ff	 movzx	 ecx, BYTE PTR _TaskMask$[ebp]
  00090	83 c9 08	 or	 ecx, 8
  00093	51		 push	 ecx
  00094	8b 4d e8	 mov	 ecx, DWORD PTR _this$[ebp]
  00097	e8 00 00 00 00	 call	 ?WriteWord@CPCICard@@QAEXKG@Z ; CPCICard::WriteWord

; 198  :     WriteWord(SAA7134_VBI_V_STOP(TaskMask), VStop);

  0009c	0f b7 55 18	 movzx	 edx, WORD PTR _VStop$[ebp]
  000a0	52		 push	 edx
  000a1	0f b6 45 ff	 movzx	 eax, BYTE PTR _TaskMask$[ebp]
  000a5	83 c8 0a	 or	 eax, 10			; 0000000aH
  000a8	50		 push	 eax
  000a9	8b 4d e8	 mov	 ecx, DWORD PTR _this$[ebp]
  000ac	e8 00 00 00 00	 call	 ?WriteWord@CPCICard@@QAEXKG@Z ; CPCICard::WriteWord

; 199  : 
; 200  :     WriteWord(SAA7134_VBI_H_SCALE_INC(TaskMask), UpscaleDivisor);

  000b1	0f b7 4d 1c	 movzx	 ecx, WORD PTR _UpscaleDivisor$[ebp]
  000b5	51		 push	 ecx
  000b6	0f b6 55 ff	 movzx	 edx, BYTE PTR _TaskMask$[ebp]
  000ba	83 ca 28	 or	 edx, 40			; 00000028H
  000bd	52		 push	 edx
  000be	8b 4d e8	 mov	 ecx, DWORD PTR _this$[ebp]
  000c1	e8 00 00 00 00	 call	 ?WriteWord@CPCICard@@QAEXKG@Z ; CPCICard::WriteWord

; 201  : 
; 202  :     WORD Lines = VStop - VStart + 1;

  000c6	0f b7 45 18	 movzx	 eax, WORD PTR _VStop$[ebp]
  000ca	0f b7 4d 14	 movzx	 ecx, WORD PTR _VStart$[ebp]
  000ce	2b c1		 sub	 eax, ecx
  000d0	83 c0 01	 add	 eax, 1
  000d3	66 89 45 f4	 mov	 WORD PTR _Lines$[ebp], ax

; 203  : 
; 204  :     eRegionID RegionID = TaskID2VBIRegion(TaskID);

  000d7	8b 55 08	 mov	 edx, DWORD PTR _TaskID$[ebp]
  000da	52		 push	 edx
  000db	8b 4d e8	 mov	 ecx, DWORD PTR _this$[ebp]
  000de	83 c1 58	 add	 ecx, 88			; 00000058H
  000e1	e8 00 00 00 00	 call	 ?TaskID2VBIRegion@CSAA7134Common@@IAE?AW4eRegionID@1@W4eTaskID@1@@Z ; CSAA7134Common::TaskID2VBIRegion
  000e6	89 45 f0	 mov	 DWORD PTR _RegionID$[ebp], eax

; 205  :     if (GetDMA(RegionID))

  000e9	8b 45 f0	 mov	 eax, DWORD PTR _RegionID$[ebp]
  000ec	50		 push	 eax
  000ed	8b 4d e8	 mov	 ecx, DWORD PTR _this$[ebp]
  000f0	e8 00 00 00 00	 call	 ?GetDMA@CSAA7134Card@@QAEHW4eRegionID@CSAA7134Common@@@Z ; CSAA7134Card::GetDMA
  000f5	85 c0		 test	 eax, eax
  000f7	74 29		 je	 SHORT $LN1@SetTaskVBI

; 206  :     {
; 207  :         // Make sure we aren't grabbing more lines than we have memory
; 208  :         WORD LinesAvailable = CalculateLinesAvailable(RegionID, SampleBytes);

  000f9	0f b7 4d f8	 movzx	 ecx, WORD PTR _SampleBytes$[ebp]
  000fd	51		 push	 ecx
  000fe	8b 55 f0	 mov	 edx, DWORD PTR _RegionID$[ebp]
  00101	52		 push	 edx
  00102	8b 4d e8	 mov	 ecx, DWORD PTR _this$[ebp]
  00105	e8 00 00 00 00	 call	 ?CalculateLinesAvailable@CSAA7134Card@@IAEGW4eRegionID@CSAA7134Common@@G@Z ; CSAA7134Card::CalculateLinesAvailable
  0010a	66 89 45 ec	 mov	 WORD PTR _LinesAvailable$143863[ebp], ax

; 209  : 
; 210  :         if (LinesAvailable < Lines)

  0010e	0f b7 45 ec	 movzx	 eax, WORD PTR _LinesAvailable$143863[ebp]
  00112	0f b7 4d f4	 movzx	 ecx, WORD PTR _Lines$[ebp]
  00116	3b c1		 cmp	 eax, ecx
  00118	7d 08		 jge	 SHORT $LN1@SetTaskVBI

; 211  :         {
; 212  :             Lines = LinesAvailable;

  0011a	66 8b 55 ec	 mov	 dx, WORD PTR _LinesAvailable$143863[ebp]
  0011e	66 89 55 f4	 mov	 WORD PTR _Lines$[ebp], dx
$LN1@SetTaskVBI:

; 213  :         }
; 214  :     }
; 215  : 
; 216  :     WriteWord(SAA7134_VBI_V_LEN(TaskMask), Lines);

  00122	0f b7 45 f4	 movzx	 eax, WORD PTR _Lines$[ebp]
  00126	50		 push	 eax
  00127	0f b6 4d ff	 movzx	 ecx, BYTE PTR _TaskMask$[ebp]
  0012b	83 c9 0e	 or	 ecx, 14			; 0000000eH
  0012e	51		 push	 ecx
  0012f	8b 4d e8	 mov	 ecx, DWORD PTR _this$[ebp]
  00132	e8 00 00 00 00	 call	 ?WriteWord@CPCICard@@QAEXKG@Z ; CPCICard::WriteWord

; 217  :     WriteWord(SAA7134_VBI_H_LEN(TaskMask), SampleBytes);

  00137	0f b7 55 f8	 movzx	 edx, WORD PTR _SampleBytes$[ebp]
  0013b	52		 push	 edx
  0013c	0f b6 45 ff	 movzx	 eax, BYTE PTR _TaskMask$[ebp]
  00140	83 c8 0c	 or	 eax, 12			; 0000000cH
  00143	50		 push	 eax
  00144	8b 4d e8	 mov	 ecx, DWORD PTR _this$[ebp]
  00147	e8 00 00 00 00	 call	 ?WriteWord@CPCICard@@QAEXKG@Z ; CPCICard::WriteWord

; 218  : }

  0014c	8b e5		 mov	 esp, ebp
  0014e	5d		 pop	 ebp
  0014f	c2 18 00	 ret	 24			; 00000018H
?SetTaskVBIGeometry@CSAA7134Card@@IAEXW4eTaskID@CSAA7134Common@@GGGGG@Z ENDP ; CSAA7134Card::SetTaskVBIGeometry
_TEXT	ENDS
PUBLIC	?SetVBIGeometry@CSAA7134Card@@QAEXG@Z		; CSAA7134Card::SetVBIGeometry
; Function compile flags: /Odtp
;	COMDAT ?SetVBIGeometry@CSAA7134Card@@QAEXG@Z
_TEXT	SEGMENT
_this$ = -12						; size = 4
_VStart$ = -8						; size = 2
_VStop$ = -4						; size = 2
_UpscaleDivisor$ = 8					; size = 2
?SetVBIGeometry@CSAA7134Card@@QAEXG@Z PROC		; CSAA7134Card::SetVBIGeometry, COMDAT
; _this$ = ecx

; 174  : {

  00000	55		 push	 ebp
  00001	8b ec		 mov	 ebp, esp
  00003	83 ec 0c	 sub	 esp, 12			; 0000000cH
  00006	89 4d f4	 mov	 DWORD PTR _this$[ebp], ecx

; 175  :     if (m_VideoStandard == VIDEOSTANDARD_INVALID)

  00009	8b 45 f4	 mov	 eax, DWORD PTR _this$[ebp]
  0000c	83 b8 ac 00 00
	00 ff		 cmp	 DWORD PTR [eax+172], -1
  00013	75 02		 jne	 SHORT $LN1@SetVBIGeom

; 176  :     {
; 177  :         return;

  00015	eb 6e		 jmp	 SHORT $LN2@SetVBIGeom
$LN1@SetVBIGeom:

; 178  :     }
; 179  : 
; 180  :     WORD VStart = m_VideoStandards[m_VideoStandard].wVBIStartLine;

  00017	8b 4d f4	 mov	 ecx, DWORD PTR _this$[ebp]
  0001a	8b 91 ac 00 00
	00		 mov	 edx, DWORD PTR [ecx+172]
  00020	6b d2 14	 imul	 edx, 20			; 00000014H
  00023	66 8b 82 0c 00
	00 00		 mov	 ax, WORD PTR ?m_VideoStandards@CSAA7134Common@@1PAUTVideoStandardDefinition@1@A[edx+12]
  0002a	66 89 45 f8	 mov	 WORD PTR _VStart$[ebp], ax

; 181  :     WORD VStop  = m_VideoStandards[m_VideoStandard].wVBIStopLine;

  0002e	8b 4d f4	 mov	 ecx, DWORD PTR _this$[ebp]
  00031	8b 91 ac 00 00
	00		 mov	 edx, DWORD PTR [ecx+172]
  00037	6b d2 14	 imul	 edx, 20			; 00000014H
  0003a	66 8b 82 0e 00
	00 00		 mov	 ax, WORD PTR ?m_VideoStandards@CSAA7134Common@@1PAUTVideoStandardDefinition@1@A[edx+14]
  00041	66 89 45 fc	 mov	 WORD PTR _VStop$[ebp], ax

; 182  : 
; 183  :     SetTaskVBIGeometry(TASKID_A, 0, 719, VStart, VStop, UpscaleDivisor);

  00045	0f b7 4d 08	 movzx	 ecx, WORD PTR _UpscaleDivisor$[ebp]
  00049	51		 push	 ecx
  0004a	0f b7 55 fc	 movzx	 edx, WORD PTR _VStop$[ebp]
  0004e	52		 push	 edx
  0004f	0f b7 45 f8	 movzx	 eax, WORD PTR _VStart$[ebp]
  00053	50		 push	 eax
  00054	68 cf 02 00 00	 push	 719			; 000002cfH
  00059	6a 00		 push	 0
  0005b	6a 00		 push	 0
  0005d	8b 4d f4	 mov	 ecx, DWORD PTR _this$[ebp]
  00060	e8 00 00 00 00	 call	 ?SetTaskVBIGeometry@CSAA7134Card@@IAEXW4eTaskID@CSAA7134Common@@GGGGG@Z ; CSAA7134Card::SetTaskVBIGeometry

; 184  :     SetTaskVBIGeometry(TASKID_B, 0, 719, VStart, VStop, UpscaleDivisor);

  00065	0f b7 4d 08	 movzx	 ecx, WORD PTR _UpscaleDivisor$[ebp]
  00069	51		 push	 ecx
  0006a	0f b7 55 fc	 movzx	 edx, WORD PTR _VStop$[ebp]
  0006e	52		 push	 edx
  0006f	0f b7 45 f8	 movzx	 eax, WORD PTR _VStart$[ebp]
  00073	50		 push	 eax
  00074	68 cf 02 00 00	 push	 719			; 000002cfH
  00079	6a 00		 push	 0
  0007b	6a 01		 push	 1
  0007d	8b 4d f4	 mov	 ecx, DWORD PTR _this$[ebp]
  00080	e8 00 00 00 00	 call	 ?SetTaskVBIGeometry@CSAA7134Card@@IAEXW4eTaskID@CSAA7134Common@@GGGGG@Z ; CSAA7134Card::SetTaskVBIGeometry
$LN2@SetVBIGeom:

; 185  : }

  00085	8b e5		 mov	 esp, ebp
  00087	5d		 pop	 ebp
  00088	c2 04 00	 ret	 4
?SetVBIGeometry@CSAA7134Card@@QAEXG@Z ENDP		; CSAA7134Card::SetVBIGeometry
PUBLIC	?SetVideoStandard@CSAA7134Card@@QAEXW4eVideoStandard@CSAA7134Common@@AAJ11JJJ@Z ; CSAA7134Card::SetVideoStandard
; Function compile flags: /Odtp
;	COMDAT ?SetVideoStandard@CSAA7134Card@@QAEXW4eVideoStandard@CSAA7134Common@@AAJ11JJJ@Z
_TEXT	SEGMENT
_this$ = -12						; size = 4
_ChromaGain$ = -6					; size = 1
_ChromaCtrl2$ = -5					; size = 1
_MiscVGateMSB$ = -4					; size = 1
_SyncControl$ = -3					; size = 1
_LumaControl$ = -2					; size = 1
_ChromaCtrl1$ = -1					; size = 1
_VideoStandard$ = 8					; size = 4
_VBILines$ = 12						; size = 4
_VideoWidth$ = 16					; size = 4
_VideoHeight$ = 20					; size = 4
_HDelayShift$ = 24					; size = 4
_VDelayShift$ = 28					; size = 4
_VBIUpscaleDivisor$ = 32				; size = 4
?SetVideoStandard@CSAA7134Card@@QAEXW4eVideoStandard@CSAA7134Common@@AAJ11JJJ@Z PROC ; CSAA7134Card::SetVideoStandard, COMDAT
; _this$ = ecx

; 83   : {

  00000	55		 push	 ebp
  00001	8b ec		 mov	 ebp, esp
  00003	83 ec 0c	 sub	 esp, 12			; 0000000cH
  00006	89 4d f4	 mov	 DWORD PTR _this$[ebp], ecx

; 84   :     BYTE SyncControl    = 0;

  00009	c6 45 fd 00	 mov	 BYTE PTR _SyncControl$[ebp], 0

; 85   :     BYTE LumaControl    = 0;

  0000d	c6 45 fe 00	 mov	 BYTE PTR _LumaControl$[ebp], 0

; 86   :     BYTE ChromaCtrl1    = 0;

  00011	c6 45 ff 00	 mov	 BYTE PTR _ChromaCtrl1$[ebp], 0

; 87   :     BYTE ChromaGain     = 0;

  00015	c6 45 fa 00	 mov	 BYTE PTR _ChromaGain$[ebp], 0

; 88   :     BYTE ChromaCtrl2    = 0;

  00019	c6 45 fb 00	 mov	 BYTE PTR _ChromaCtrl2$[ebp], 0

; 89   :     BYTE MiscVGateMSB   = 0;

  0001d	c6 45 fc 00	 mov	 BYTE PTR _MiscVGateMSB$[ebp], 0

; 90   : 
; 91   :     if (VideoStandard == VIDEOSTANDARD_AUTODETECT)

  00021	83 7d 08 00	 cmp	 DWORD PTR _VideoStandard$[ebp], 0
  00025	75 0d		 jne	 SHORT $LN10@SetVideoSt

; 92   :     {
; 93   :         // Automatic field rate (50Hz/60z) detection
; 94   :         SyncControl = SAA7134_SYNC_CTRL_AUFD;

  00027	c6 45 fd 80	 mov	 BYTE PTR _SyncControl$[ebp], 128 ; 00000080H

; 95   : 
; 96   :         // Automatic colour standard detection
; 97   :         ChromaCtrl1 = SAA7134_CHROMA_CTRL1_AUTO | SAA7134_CHROMA_CTRL1_DCVF;

  0002b	c6 45 ff 0a	 mov	 BYTE PTR _ChromaCtrl1$[ebp], 10 ; 0000000aH

; 98   :     }
; 99   :     else

  0002f	e9 83 00 00 00	 jmp	 $LN9@SetVideoSt
$LN10@SetVideoSt:

; 100  :     {
; 101  :         if (m_VideoStandards[VideoStandard].Is25fps)

  00034	8b 45 08	 mov	 eax, DWORD PTR _VideoStandard$[ebp]
  00037	6b c0 14	 imul	 eax, 20			; 00000014H
  0003a	83 b8 08 00 00
	00 00		 cmp	 DWORD PTR ?m_VideoStandards@CSAA7134Common@@1PAUTVideoStandardDefinition@1@A[eax+8], 0
  00041	74 06		 je	 SHORT $LN8@SetVideoSt

; 102  :         {
; 103  :             MiscVGateMSB = SAA7134_MISC_VGATE_MSB_VGPS;

  00043	c6 45 fc 04	 mov	 BYTE PTR _MiscVGateMSB$[ebp], 4

; 104  :         }
; 105  :         else

  00047	eb 04		 jmp	 SHORT $LN7@SetVideoSt
$LN8@SetVideoSt:

; 106  :         {
; 107  :             SyncControl = SAA7134_SYNC_CTRL_FSEL;

  00049	c6 45 fd 40	 mov	 BYTE PTR _SyncControl$[ebp], 64 ; 00000040H
$LN7@SetVideoSt:

; 108  :         }
; 109  : 
; 110  :         if (IsPALVideoStandard(VideoStandard))

  0004d	8b 4d 08	 mov	 ecx, DWORD PTR _VideoStandard$[ebp]
  00050	51		 push	 ecx
  00051	8b 4d f4	 mov	 ecx, DWORD PTR _this$[ebp]
  00054	83 c1 58	 add	 ecx, 88			; 00000058H
  00057	e8 00 00 00 00	 call	 ?IsPALVideoStandard@CSAA7134Common@@IAEHW4eVideoStandard@1@@Z ; CSAA7134Common::IsPALVideoStandard
  0005c	85 c0		 test	 eax, eax
  0005e	74 06		 je	 SHORT $LN6@SetVideoSt

; 111  :         {
; 112  :             ChromaCtrl2 = 0x06;

  00060	c6 45 fb 06	 mov	 BYTE PTR _ChromaCtrl2$[ebp], 6
  00064	eb 38		 jmp	 SHORT $LN5@SetVideoSt
$LN6@SetVideoSt:

; 113  :         }
; 114  :         else if (IsSECAMVideoStandard(VideoStandard))

  00066	8b 55 08	 mov	 edx, DWORD PTR _VideoStandard$[ebp]
  00069	52		 push	 edx
  0006a	8b 4d f4	 mov	 ecx, DWORD PTR _this$[ebp]
  0006d	83 c1 58	 add	 ecx, 88			; 00000058H
  00070	e8 00 00 00 00	 call	 ?IsSECAMVideoStandard@CSAA7134Common@@IAEHW4eVideoStandard@1@@Z ; CSAA7134Common::IsSECAMVideoStandard
  00075	85 c0		 test	 eax, eax
  00077	74 0a		 je	 SHORT $LN4@SetVideoSt

; 115  :         {
; 116  :             LumaControl = SAA7134_LUMA_CTRL_LUBW | 0x0B;

  00079	c6 45 fe 1b	 mov	 BYTE PTR _LumaControl$[ebp], 27 ; 0000001bH

; 117  :             ChromaGain  = SAA7134_CHROMA_GAIN_CTRL_ACGC;

  0007d	c6 45 fa 80	 mov	 BYTE PTR _ChromaGain$[ebp], 128 ; 00000080H
  00081	eb 1b		 jmp	 SHORT $LN5@SetVideoSt
$LN4@SetVideoSt:

; 118  :         }
; 119  :         else if (IsNTSCVideoStandard(VideoStandard))

  00083	8b 45 08	 mov	 eax, DWORD PTR _VideoStandard$[ebp]
  00086	50		 push	 eax
  00087	8b 4d f4	 mov	 ecx, DWORD PTR _this$[ebp]
  0008a	83 c1 58	 add	 ecx, 88			; 00000058H
  0008d	e8 00 00 00 00	 call	 ?IsNTSCVideoStandard@CSAA7134Common@@IAEHW4eVideoStandard@1@@Z ; CSAA7134Common::IsNTSCVideoStandard
  00092	85 c0		 test	 eax, eax
  00094	74 08		 je	 SHORT $LN5@SetVideoSt

; 120  :         {
; 121  :             ChromaCtrl1 = SAA7134_CHROMA_CTRL1_DCVF;

  00096	c6 45 ff 08	 mov	 BYTE PTR _ChromaCtrl1$[ebp], 8

; 122  :             ChromaCtrl2 = SAA7134_CHROMA_CTRL2_CHBW | 0x06;

  0009a	c6 45 fb 0e	 mov	 BYTE PTR _ChromaCtrl2$[ebp], 14 ; 0000000eH
$LN5@SetVideoSt:

; 123  :         }
; 124  :         else
; 125  :         {
; 126  :             // NEVER_GET_HERE;
; 127  :         }
; 128  : 
; 129  :         ChromaCtrl1 |= (m_VideoStandards[VideoStandard].CSTDMask << 4);

  0009e	8b 4d 08	 mov	 ecx, DWORD PTR _VideoStandard$[ebp]
  000a1	6b c9 14	 imul	 ecx, 20			; 00000014H
  000a4	0f b6 91 10 00
	00 00		 movzx	 edx, BYTE PTR ?m_VideoStandards@CSAA7134Common@@1PAUTVideoStandardDefinition@1@A[ecx+16]
  000ab	c1 e2 04	 shl	 edx, 4
  000ae	0f b6 45 ff	 movzx	 eax, BYTE PTR _ChromaCtrl1$[ebp]
  000b2	0b c2		 or	 eax, edx
  000b4	88 45 ff	 mov	 BYTE PTR _ChromaCtrl1$[ebp], al
$LN9@SetVideoSt:

; 130  :     }
; 131  : 
; 132  :     MaskDataByte(SAA7134_SYNC_CTRL, SyncControl,
; 133  :        SAA7134_SYNC_CTRL_AUFD |
; 134  :        SAA7134_SYNC_CTRL_FSEL |
; 135  :        SAA7134_SYNC_CTRL_VNOI);

  000b7	68 c3 00 00 00	 push	 195			; 000000c3H
  000bc	0f b6 4d fd	 movzx	 ecx, BYTE PTR _SyncControl$[ebp]
  000c0	51		 push	 ecx
  000c1	68 08 01 00 00	 push	 264			; 00000108H
  000c6	8b 4d f4	 mov	 ecx, DWORD PTR _this$[ebp]
  000c9	e8 00 00 00 00	 call	 ?MaskDataByte@CPCICard@@QAEXKEE@Z ; CPCICard::MaskDataByte

; 136  : 
; 137  :     MaskDataByte(SAA7134_LUMA_CTRL, LumaControl,
; 138  :         SAA7134_LUMA_CTRL_LUFI |
; 139  :         SAA7134_LUMA_CTRL_LUBW |
; 140  :         SAA7134_LUMA_CTRL_LDEL);

  000ce	6a 3f		 push	 63			; 0000003fH
  000d0	0f b6 55 fe	 movzx	 edx, BYTE PTR _LumaControl$[ebp]
  000d4	52		 push	 edx
  000d5	68 09 01 00 00	 push	 265			; 00000109H
  000da	8b 4d f4	 mov	 ecx, DWORD PTR _this$[ebp]
  000dd	e8 00 00 00 00	 call	 ?MaskDataByte@CPCICard@@QAEXKEE@Z ; CPCICard::MaskDataByte

; 141  : 
; 142  :     MaskDataByte(SAA7134_CHROMA_CTRL1, ChromaCtrl1,
; 143  :         SAA7134_CHROMA_CTRL1_CSTD |
; 144  :         SAA7134_CHROMA_CTRL1_DCVF |
; 145  :         SAA7134_CHROMA_CTRL1_AUTO);

  000e2	6a 7a		 push	 122			; 0000007aH
  000e4	0f b6 45 ff	 movzx	 eax, BYTE PTR _ChromaCtrl1$[ebp]
  000e8	50		 push	 eax
  000e9	68 0e 01 00 00	 push	 270			; 0000010eH
  000ee	8b 4d f4	 mov	 ecx, DWORD PTR _this$[ebp]
  000f1	e8 00 00 00 00	 call	 ?MaskDataByte@CPCICard@@QAEXKEE@Z ; CPCICard::MaskDataByte

; 146  : 
; 147  :     MaskDataByte(SAA7134_CHROMA_GAIN_CTRL, ChromaGain,
; 148  :         SAA7134_CHROMA_GAIN_CTRL_CGAIN |
; 149  :         SAA7134_CHROMA_GAIN_CTRL_ACGC);

  000f6	68 ff 00 00 00	 push	 255			; 000000ffH
  000fb	0f b6 4d fa	 movzx	 ecx, BYTE PTR _ChromaGain$[ebp]
  000ff	51		 push	 ecx
  00100	68 0f 01 00 00	 push	 271			; 0000010fH
  00105	8b 4d f4	 mov	 ecx, DWORD PTR _this$[ebp]
  00108	e8 00 00 00 00	 call	 ?MaskDataByte@CPCICard@@QAEXKEE@Z ; CPCICard::MaskDataByte

; 150  : 
; 151  :     MaskDataByte(SAA7134_CHROMA_CTRL2, ChromaCtrl2,
; 152  :         SAA7134_CHROMA_CTRL2_LCBW |
; 153  :         SAA7134_CHROMA_CTRL2_CHBW);

  0010d	6a 0f		 push	 15			; 0000000fH
  0010f	0f b6 55 fb	 movzx	 edx, BYTE PTR _ChromaCtrl2$[ebp]
  00113	52		 push	 edx
  00114	68 10 01 00 00	 push	 272			; 00000110H
  00119	8b 4d f4	 mov	 ecx, DWORD PTR _this$[ebp]
  0011c	e8 00 00 00 00	 call	 ?MaskDataByte@CPCICard@@QAEXKEE@Z ; CPCICard::MaskDataByte

; 154  : 
; 155  :     MaskDataByte(SAA7134_MISC_VGATE_MSB, MiscVGateMSB,
; 156  :         SAA7134_MISC_VGATE_MSB_VGPS);

  00121	6a 04		 push	 4
  00123	0f b6 45 fc	 movzx	 eax, BYTE PTR _MiscVGateMSB$[ebp]
  00127	50		 push	 eax
  00128	68 17 01 00 00	 push	 279			; 00000117H
  0012d	8b 4d f4	 mov	 ecx, DWORD PTR _this$[ebp]
  00130	e8 00 00 00 00	 call	 ?MaskDataByte@CPCICard@@QAEXKEE@Z ; CPCICard::MaskDataByte

; 157  : 
; 158  :     m_VideoStandard = VideoStandard;

  00135	8b 4d f4	 mov	 ecx, DWORD PTR _this$[ebp]
  00138	8b 55 08	 mov	 edx, DWORD PTR _VideoStandard$[ebp]
  0013b	89 91 ac 00 00
	00		 mov	 DWORD PTR [ecx+172], edx

; 159  : 
; 160  :     UpdateAudioClocksPerField(VideoStandard);

  00141	8b 45 08	 mov	 eax, DWORD PTR _VideoStandard$[ebp]
  00144	50		 push	 eax
  00145	8b 4d f4	 mov	 ecx, DWORD PTR _this$[ebp]
  00148	e8 00 00 00 00	 call	 ?UpdateAudioClocksPerField@CSAA7134Card@@IAEXW4eVideoStandard@CSAA7134Common@@@Z ; CSAA7134Card::UpdateAudioClocksPerField

; 161  : 
; 162  :     VBILines = m_VideoStandards[VideoStandard].wVBIStopLine -
; 163  :         m_VideoStandards[VideoStandard].wVBIStartLine + 1;

  0014d	8b 4d 08	 mov	 ecx, DWORD PTR _VideoStandard$[ebp]
  00150	6b c9 14	 imul	 ecx, 20			; 00000014H
  00153	0f b7 91 0e 00
	00 00		 movzx	 edx, WORD PTR ?m_VideoStandards@CSAA7134Common@@1PAUTVideoStandardDefinition@1@A[ecx+14]
  0015a	8b 45 08	 mov	 eax, DWORD PTR _VideoStandard$[ebp]
  0015d	6b c0 14	 imul	 eax, 20			; 00000014H
  00160	0f b7 88 0c 00
	00 00		 movzx	 ecx, WORD PTR ?m_VideoStandards@CSAA7134Common@@1PAUTVideoStandardDefinition@1@A[eax+12]
  00167	2b d1		 sub	 edx, ecx
  00169	83 c2 01	 add	 edx, 1
  0016c	8b 45 0c	 mov	 eax, DWORD PTR _VBILines$[ebp]
  0016f	89 10		 mov	 DWORD PTR [eax], edx

; 164  : 
; 165  :     SetVBIGeometry((WORD)VBIUpscaleDivisor);

  00171	0f b7 4d 20	 movzx	 ecx, WORD PTR _VBIUpscaleDivisor$[ebp]
  00175	51		 push	 ecx
  00176	8b 4d f4	 mov	 ecx, DWORD PTR _this$[ebp]
  00179	e8 00 00 00 00	 call	 ?SetVBIGeometry@CSAA7134Card@@QAEXG@Z ; CSAA7134Card::SetVBIGeometry

; 166  : 
; 167  :     VideoHeight = m_VideoStandards[VideoStandard].wFieldHeight * 2;

  0017e	8b 55 08	 mov	 edx, DWORD PTR _VideoStandard$[ebp]
  00181	6b d2 14	 imul	 edx, 20			; 00000014H
  00184	0f b7 82 02 00
	00 00		 movzx	 eax, WORD PTR ?m_VideoStandards@CSAA7134Common@@1PAUTVideoStandardDefinition@1@A[edx+2]
  0018b	d1 e0		 shl	 eax, 1
  0018d	8b 4d 14	 mov	 ecx, DWORD PTR _VideoHeight$[ebp]
  00190	89 01		 mov	 DWORD PTR [ecx], eax

; 168  : 
; 169  :     SetGeometry((WORD)VideoWidth, (WORD)VideoHeight, HDelayShift, VDelayShift);

  00192	8b 55 1c	 mov	 edx, DWORD PTR _VDelayShift$[ebp]
  00195	52		 push	 edx
  00196	8b 45 18	 mov	 eax, DWORD PTR _HDelayShift$[ebp]
  00199	50		 push	 eax
  0019a	8b 4d 14	 mov	 ecx, DWORD PTR _VideoHeight$[ebp]
  0019d	0f b7 11	 movzx	 edx, WORD PTR [ecx]
  001a0	52		 push	 edx
  001a1	8b 45 10	 mov	 eax, DWORD PTR _VideoWidth$[ebp]
  001a4	0f b7 08	 movzx	 ecx, WORD PTR [eax]
  001a7	51		 push	 ecx
  001a8	8b 4d f4	 mov	 ecx, DWORD PTR _this$[ebp]
  001ab	e8 00 00 00 00	 call	 ?SetGeometry@CSAA7134Card@@QAEXGGJJ@Z ; CSAA7134Card::SetGeometry

; 170  : }

  001b0	8b e5		 mov	 esp, ebp
  001b2	5d		 pop	 ebp
  001b3	c2 1c 00	 ret	 28			; 0000001cH
?SetVideoStandard@CSAA7134Card@@QAEXW4eVideoStandard@CSAA7134Common@@AAJ11JJJ@Z ENDP ; CSAA7134Card::SetVideoStandard
END
