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

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

INCLUDELIB OLDNAMES

PUBLIC	?BitBltRects@CPaintingHDC@@QAEXPAUtagRECT@@JPAUHDC__@@@Z ; CPaintingHDC::BitBltRects
; Function compile flags: /Odtp
; File c:\develop\dscaler423a\dscaler\paintinghdc.cpp
;	COMDAT ?BitBltRects@CPaintingHDC@@QAEXPAUtagRECT@@JPAUHDC__@@@Z
_TEXT	SEGMENT
_this$ = -8						; size = 4
_i$144426 = -4						; size = 4
_pRectList$ = 8						; size = 4
_nRectCount$ = 12					; size = 4
_hDstDC$ = 16						; size = 4
?BitBltRects@CPaintingHDC@@QAEXPAUtagRECT@@JPAUHDC__@@@Z PROC ; CPaintingHDC::BitBltRects, COMDAT
; _this$ = ecx

; 173  : {

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

; 174  :     if (m_hBufferDC == NULL)

  0000a	8b 45 f8	 mov	 eax, DWORD PTR _this$[ebp]
  0000d	83 38 00	 cmp	 DWORD PTR [eax], 0
  00010	75 05		 jne	 SHORT $LN6@BitBltRect

; 175  :     {
; 176  :         return;

  00012	e9 bd 00 00 00	 jmp	 $LN7@BitBltRect
$LN6@BitBltRect:

; 177  :     }
; 178  : 
; 179  :     if (hDstDC == NULL)

  00017	83 7d 10 00	 cmp	 DWORD PTR _hDstDC$[ebp], 0
  0001b	75 09		 jne	 SHORT $LN5@BitBltRect

; 180  :     {
; 181  :         hDstDC = m_hOriginalDC;

  0001d	8b 4d f8	 mov	 ecx, DWORD PTR _this$[ebp]
  00020	8b 51 04	 mov	 edx, DWORD PTR [ecx+4]
  00023	89 55 10	 mov	 DWORD PTR _hDstDC$[ebp], edx
$LN5@BitBltRect:

; 182  :     }
; 183  : 
; 184  :     if (hDstDC == NULL)

  00026	83 7d 10 00	 cmp	 DWORD PTR _hDstDC$[ebp], 0
  0002a	75 05		 jne	 SHORT $LN4@BitBltRect

; 185  :     {
; 186  :         return;

  0002c	e9 a3 00 00 00	 jmp	 $LN7@BitBltRect
$LN4@BitBltRect:

; 187  :     }
; 188  : 
; 189  :     for (int i = 0; i < nRectCount; i++)

  00031	c7 45 fc 00 00
	00 00		 mov	 DWORD PTR _i$144426[ebp], 0
  00038	eb 09		 jmp	 SHORT $LN3@BitBltRect
$LN2@BitBltRect:
  0003a	8b 45 fc	 mov	 eax, DWORD PTR _i$144426[ebp]
  0003d	83 c0 01	 add	 eax, 1
  00040	89 45 fc	 mov	 DWORD PTR _i$144426[ebp], eax
$LN3@BitBltRect:
  00043	8b 4d fc	 mov	 ecx, DWORD PTR _i$144426[ebp]
  00046	3b 4d 0c	 cmp	 ecx, DWORD PTR _nRectCount$[ebp]
  00049	0f 8d 85 00 00
	00		 jge	 $LN7@BitBltRect

; 190  :     {
; 191  :         BitBlt(hDstDC, pRectList[i].left, pRectList[i].top,
; 192  :             pRectList[i].right - pRectList[i].left,
; 193  :             pRectList[i].bottom - pRectList[i].top,
; 194  :             m_hBufferDC, pRectList[i].left, pRectList[i].top, SRCCOPY);

  0004f	68 20 00 cc 00	 push	 13369376		; 00cc0020H
  00054	8b 55 fc	 mov	 edx, DWORD PTR _i$144426[ebp]
  00057	c1 e2 04	 shl	 edx, 4
  0005a	8b 45 08	 mov	 eax, DWORD PTR _pRectList$[ebp]
  0005d	8b 4c 10 04	 mov	 ecx, DWORD PTR [eax+edx+4]
  00061	51		 push	 ecx
  00062	8b 55 fc	 mov	 edx, DWORD PTR _i$144426[ebp]
  00065	c1 e2 04	 shl	 edx, 4
  00068	8b 45 08	 mov	 eax, DWORD PTR _pRectList$[ebp]
  0006b	8b 0c 10	 mov	 ecx, DWORD PTR [eax+edx]
  0006e	51		 push	 ecx
  0006f	8b 55 f8	 mov	 edx, DWORD PTR _this$[ebp]
  00072	8b 02		 mov	 eax, DWORD PTR [edx]
  00074	50		 push	 eax
  00075	8b 4d fc	 mov	 ecx, DWORD PTR _i$144426[ebp]
  00078	c1 e1 04	 shl	 ecx, 4
  0007b	8b 55 fc	 mov	 edx, DWORD PTR _i$144426[ebp]
  0007e	c1 e2 04	 shl	 edx, 4
  00081	8b 45 08	 mov	 eax, DWORD PTR _pRectList$[ebp]
  00084	8b 75 08	 mov	 esi, DWORD PTR _pRectList$[ebp]
  00087	8b 4c 08 0c	 mov	 ecx, DWORD PTR [eax+ecx+12]
  0008b	2b 4c 16 04	 sub	 ecx, DWORD PTR [esi+edx+4]
  0008f	51		 push	 ecx
  00090	8b 55 fc	 mov	 edx, DWORD PTR _i$144426[ebp]
  00093	c1 e2 04	 shl	 edx, 4
  00096	8b 45 fc	 mov	 eax, DWORD PTR _i$144426[ebp]
  00099	c1 e0 04	 shl	 eax, 4
  0009c	8b 4d 08	 mov	 ecx, DWORD PTR _pRectList$[ebp]
  0009f	8b 75 08	 mov	 esi, DWORD PTR _pRectList$[ebp]
  000a2	8b 54 11 08	 mov	 edx, DWORD PTR [ecx+edx+8]
  000a6	2b 14 06	 sub	 edx, DWORD PTR [esi+eax]
  000a9	52		 push	 edx
  000aa	8b 45 fc	 mov	 eax, DWORD PTR _i$144426[ebp]
  000ad	c1 e0 04	 shl	 eax, 4
  000b0	8b 4d 08	 mov	 ecx, DWORD PTR _pRectList$[ebp]
  000b3	8b 54 01 04	 mov	 edx, DWORD PTR [ecx+eax+4]
  000b7	52		 push	 edx
  000b8	8b 45 fc	 mov	 eax, DWORD PTR _i$144426[ebp]
  000bb	c1 e0 04	 shl	 eax, 4
  000be	8b 4d 08	 mov	 ecx, DWORD PTR _pRectList$[ebp]
  000c1	8b 14 01	 mov	 edx, DWORD PTR [ecx+eax]
  000c4	52		 push	 edx
  000c5	8b 45 10	 mov	 eax, DWORD PTR _hDstDC$[ebp]
  000c8	50		 push	 eax
  000c9	ff 15 00 00 00
	00		 call	 DWORD PTR __imp__BitBlt@36
  000cf	e9 66 ff ff ff	 jmp	 $LN2@BitBltRect
$LN7@BitBltRect:

; 195  :     }
; 196  : }

  000d4	5e		 pop	 esi
  000d5	8b e5		 mov	 esp, ebp
  000d7	5d		 pop	 ebp
  000d8	c2 0c 00	 ret	 12			; 0000000cH
?BitBltRects@CPaintingHDC@@QAEXPAUtagRECT@@JPAUHDC__@@@Z ENDP ; CPaintingHDC::BitBltRects
_TEXT	ENDS
PUBLIC	?GetBufferDC@CPaintingHDC@@QAEPAUHDC__@@XZ	; CPaintingHDC::GetBufferDC
; Function compile flags: /Odtp
;	COMDAT ?GetBufferDC@CPaintingHDC@@QAEPAUHDC__@@XZ
_TEXT	SEGMENT
_this$ = -4						; size = 4
?GetBufferDC@CPaintingHDC@@QAEPAUHDC__@@XZ PROC		; CPaintingHDC::GetBufferDC, COMDAT
; _this$ = ecx

; 101  : {

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

; 102  :     return m_hBufferDC;

  00007	8b 45 fc	 mov	 eax, DWORD PTR _this$[ebp]
  0000a	8b 00		 mov	 eax, DWORD PTR [eax]

; 103  : }

  0000c	8b e5		 mov	 esp, ebp
  0000e	5d		 pop	 ebp
  0000f	c3		 ret	 0
?GetBufferDC@CPaintingHDC@@QAEPAUHDC__@@XZ ENDP		; CPaintingHDC::GetBufferDC
_TEXT	ENDS
PUBLIC	?ReleaseD3DBuffer@CPaintingHDC@@QAEXXZ		; CPaintingHDC::ReleaseD3DBuffer
; Function compile flags: /Odtp
;	COMDAT ?ReleaseD3DBuffer@CPaintingHDC@@QAEXXZ
_TEXT	SEGMENT
_this$ = -4						; size = 4
?ReleaseD3DBuffer@CPaintingHDC@@QAEXXZ PROC		; CPaintingHDC::ReleaseD3DBuffer, COMDAT
; _this$ = ecx

; 53   : {

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

; 54   :     if(m_ddsurface!=NULL)

  00007	8b 45 fc	 mov	 eax, DWORD PTR _this$[ebp]
  0000a	83 78 28 00	 cmp	 DWORD PTR [eax+40], 0
  0000e	74 1e		 je	 SHORT $LN2@ReleaseD3D

; 55   :     {
; 56   :         m_ddsurface->Release();

  00010	8b 4d fc	 mov	 ecx, DWORD PTR _this$[ebp]
  00013	8b 51 28	 mov	 edx, DWORD PTR [ecx+40]
  00016	8b 45 fc	 mov	 eax, DWORD PTR _this$[ebp]
  00019	8b 48 28	 mov	 ecx, DWORD PTR [eax+40]
  0001c	8b 12		 mov	 edx, DWORD PTR [edx]
  0001e	51		 push	 ecx
  0001f	8b 42 08	 mov	 eax, DWORD PTR [edx+8]
  00022	ff d0		 call	 eax

; 57   :         m_ddsurface=NULL;

  00024	8b 4d fc	 mov	 ecx, DWORD PTR _this$[ebp]
  00027	c7 41 28 00 00
	00 00		 mov	 DWORD PTR [ecx+40], 0
$LN2@ReleaseD3D:

; 58   :     }
; 59   :     if(m_alphasurface!=NULL)

  0002e	8b 55 fc	 mov	 edx, DWORD PTR _this$[ebp]
  00031	83 7a 2c 00	 cmp	 DWORD PTR [edx+44], 0
  00035	74 1e		 je	 SHORT $LN3@ReleaseD3D

; 60   :     {
; 61   :         m_alphasurface->Release();

  00037	8b 45 fc	 mov	 eax, DWORD PTR _this$[ebp]
  0003a	8b 48 2c	 mov	 ecx, DWORD PTR [eax+44]
  0003d	8b 55 fc	 mov	 edx, DWORD PTR _this$[ebp]
  00040	8b 42 2c	 mov	 eax, DWORD PTR [edx+44]
  00043	8b 09		 mov	 ecx, DWORD PTR [ecx]
  00045	50		 push	 eax
  00046	8b 51 08	 mov	 edx, DWORD PTR [ecx+8]
  00049	ff d2		 call	 edx

; 62   :         m_alphasurface=NULL;

  0004b	8b 45 fc	 mov	 eax, DWORD PTR _this$[ebp]
  0004e	c7 40 2c 00 00
	00 00		 mov	 DWORD PTR [eax+44], 0
$LN3@ReleaseD3D:

; 63   :     }
; 64   : }

  00055	8b e5		 mov	 esp, ebp
  00057	5d		 pop	 ebp
  00058	c3		 ret	 0
?ReleaseD3DBuffer@CPaintingHDC@@QAEXXZ ENDP		; CPaintingHDC::ReleaseD3DBuffer
_TEXT	ENDS
PUBLIC	??1CPaintingHDC@@QAE@XZ				; CPaintingHDC::~CPaintingHDC
; Function compile flags: /Odtp
;	COMDAT ??1CPaintingHDC@@QAE@XZ
_TEXT	SEGMENT
_this$ = -4						; size = 4
??1CPaintingHDC@@QAE@XZ PROC				; CPaintingHDC::~CPaintingHDC, COMDAT
; _this$ = ecx

; 42   : {

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

; 43   :     ReleaseD3DBuffer();

  00007	8b 4d fc	 mov	 ecx, DWORD PTR _this$[ebp]
  0000a	e8 00 00 00 00	 call	 ?ReleaseD3DBuffer@CPaintingHDC@@QAEXXZ ; CPaintingHDC::ReleaseD3DBuffer

; 44   :     if (m_hBufferDC != NULL)

  0000f	8b 45 fc	 mov	 eax, DWORD PTR _this$[ebp]
  00012	83 38 00	 cmp	 DWORD PTR [eax], 0
  00015	74 26		 je	 SHORT $LN2@CPaintingH

; 45   :     {
; 46   :         DeleteObject(SelectObject(m_hBufferDC, m_hSaveBmp));

  00017	8b 4d fc	 mov	 ecx, DWORD PTR _this$[ebp]
  0001a	8b 51 30	 mov	 edx, DWORD PTR [ecx+48]
  0001d	52		 push	 edx
  0001e	8b 45 fc	 mov	 eax, DWORD PTR _this$[ebp]
  00021	8b 08		 mov	 ecx, DWORD PTR [eax]
  00023	51		 push	 ecx
  00024	ff 15 00 00 00
	00		 call	 DWORD PTR __imp__SelectObject@8
  0002a	50		 push	 eax
  0002b	ff 15 00 00 00
	00		 call	 DWORD PTR __imp__DeleteObject@4

; 47   :         DeleteDC(m_hBufferDC);

  00031	8b 55 fc	 mov	 edx, DWORD PTR _this$[ebp]
  00034	8b 02		 mov	 eax, DWORD PTR [edx]
  00036	50		 push	 eax
  00037	ff 15 00 00 00
	00		 call	 DWORD PTR __imp__DeleteDC@4
$LN2@CPaintingH:

; 48   :     }
; 49   : 
; 50   : }

  0003d	8b e5		 mov	 esp, ebp
  0003f	5d		 pop	 ebp
  00040	c3		 ret	 0
??1CPaintingHDC@@QAE@XZ ENDP				; CPaintingHDC::~CPaintingHDC
_TEXT	ENDS
PUBLIC	??0CPaintingHDC@@QAE@XZ				; CPaintingHDC::CPaintingHDC
; Function compile flags: /Odtp
;	COMDAT ??0CPaintingHDC@@QAE@XZ
_TEXT	SEGMENT
_this$ = -4						; size = 4
??0CPaintingHDC@@QAE@XZ PROC				; CPaintingHDC::CPaintingHDC, COMDAT
; _this$ = ecx

; 31   : {

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

; 32   :     m_hBufferDC = NULL;

  00007	8b 45 fc	 mov	 eax, DWORD PTR _this$[ebp]
  0000a	c7 00 00 00 00
	00		 mov	 DWORD PTR [eax], 0

; 33   :     m_hOriginalDC = NULL;

  00010	8b 4d fc	 mov	 ecx, DWORD PTR _this$[ebp]
  00013	c7 41 04 00 00
	00 00		 mov	 DWORD PTR [ecx+4], 0

; 34   :     m_hSaveBmp = NULL;

  0001a	8b 55 fc	 mov	 edx, DWORD PTR _this$[ebp]
  0001d	c7 42 30 00 00
	00 00		 mov	 DWORD PTR [edx+48], 0

; 35   :     m_hBmp = NULL;

  00024	8b 45 fc	 mov	 eax, DWORD PTR _this$[ebp]
  00027	c7 40 34 00 00
	00 00		 mov	 DWORD PTR [eax+52], 0

; 36   :     m_ddsurface = NULL;

  0002e	8b 4d fc	 mov	 ecx, DWORD PTR _this$[ebp]
  00031	c7 41 28 00 00
	00 00		 mov	 DWORD PTR [ecx+40], 0

; 37   :     m_alphasurface = NULL;

  00038	8b 55 fc	 mov	 edx, DWORD PTR _this$[ebp]
  0003b	c7 42 2c 00 00
	00 00		 mov	 DWORD PTR [edx+44], 0

; 38   : }

  00042	8b 45 fc	 mov	 eax, DWORD PTR _this$[ebp]
  00045	8b e5		 mov	 esp, ebp
  00047	5d		 pop	 ebp
  00048	c3		 ret	 0
??0CPaintingHDC@@QAE@XZ ENDP				; CPaintingHDC::CPaintingHDC
PUBLIC	?CreateD3DBuffer@CPaintingHDC@@AAEXXZ		; CPaintingHDC::CreateD3DBuffer
; Function compile flags: /Odtp
;	COMDAT ?CreateD3DBuffer@CPaintingHDC@@AAEXXZ
_TEXT	SEGMENT
tv145 = -32						; size = 4
tv95 = -28						; size = 4
tv68 = -24						; size = 4
_this$ = -20						; size = 4
_src$144379 = -16					; size = 16
?CreateD3DBuffer@CPaintingHDC@@AAEXXZ PROC		; CPaintingHDC::CreateD3DBuffer, COMDAT
; _this$ = ecx

; 67   : {

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

; 68   :     if(m_ddsurface==NULL && GetActiveOutput()->Type() == IOutput::OUT_D3D && ((CD3D9Output *)GetActiveOutput())->pDevice != NULL)

  00009	8b 45 ec	 mov	 eax, DWORD PTR _this$[ebp]
  0000c	83 78 28 00	 cmp	 DWORD PTR [eax+40], 0
  00010	0f 85 a4 00 00
	00		 jne	 $LN2@CreateD3DB
  00016	e8 00 00 00 00	 call	 ?GetActiveOutput@@YAPAVIOutput@@XZ ; GetActiveOutput
  0001b	89 45 e8	 mov	 DWORD PTR tv68[ebp], eax
  0001e	8b 4d e8	 mov	 ecx, DWORD PTR tv68[ebp]
  00021	8b 11		 mov	 edx, DWORD PTR [ecx]
  00023	8b 4d e8	 mov	 ecx, DWORD PTR tv68[ebp]
  00026	8b 42 60	 mov	 eax, DWORD PTR [edx+96]
  00029	ff d0		 call	 eax
  0002b	83 f8 01	 cmp	 eax, 1
  0002e	0f 85 86 00 00
	00		 jne	 $LN2@CreateD3DB
  00034	e8 00 00 00 00	 call	 ?GetActiveOutput@@YAPAVIOutput@@XZ ; GetActiveOutput
  00039	83 b8 cc 04 00
	00 00		 cmp	 DWORD PTR [eax+1228], 0
  00040	74 78		 je	 SHORT $LN2@CreateD3DB

; 69   :     {
; 70   : 		RECT src=((CD3D9Output *)GetActiveOutput())->OSD_GetRect();

  00042	8d 4d f0	 lea	 ecx, DWORD PTR _src$144379[ebp]
  00045	51		 push	 ecx
  00046	e8 00 00 00 00	 call	 ?GetActiveOutput@@YAPAVIOutput@@XZ ; GetActiveOutput
  0004b	8b c8		 mov	 ecx, eax
  0004d	e8 00 00 00 00	 call	 ?OSD_GetRect@CD3D9Output@@QAE?AUtagRECT@@XZ ; CD3D9Output::OSD_GetRect

; 71   :         ((CD3D9Output *)GetActiveOutput())->pDevice->CreateOffscreenPlainSurface(src.right,src.bottom,
; 72   :                  D3DFMT_X8R8G8B8, D3DPOOL_SYSTEMMEM, &m_ddsurface, NULL);

  00052	e8 00 00 00 00	 call	 ?GetActiveOutput@@YAPAVIOutput@@XZ ; GetActiveOutput
  00057	8b 90 cc 04 00
	00		 mov	 edx, DWORD PTR [eax+1228]
  0005d	89 55 e4	 mov	 DWORD PTR tv95[ebp], edx
  00060	6a 00		 push	 0
  00062	8b 45 ec	 mov	 eax, DWORD PTR _this$[ebp]
  00065	83 c0 28	 add	 eax, 40			; 00000028H
  00068	50		 push	 eax
  00069	6a 02		 push	 2
  0006b	6a 16		 push	 22			; 00000016H
  0006d	8b 4d fc	 mov	 ecx, DWORD PTR _src$144379[ebp+12]
  00070	51		 push	 ecx
  00071	8b 55 f8	 mov	 edx, DWORD PTR _src$144379[ebp+8]
  00074	52		 push	 edx
  00075	8b 45 e4	 mov	 eax, DWORD PTR tv95[ebp]
  00078	50		 push	 eax
  00079	8b 4d e4	 mov	 ecx, DWORD PTR tv95[ebp]
  0007c	8b 11		 mov	 edx, DWORD PTR [ecx]
  0007e	8b 82 90 00 00
	00		 mov	 eax, DWORD PTR [edx+144]
  00084	ff d0		 call	 eax

; 73   :         ((CD3D9Output *)GetActiveOutput())->pDevice->CreateOffscreenPlainSurface(src.right,src.bottom,
; 74   :                  D3DFMT_A8R8G8B8, D3DPOOL_SYSTEMMEM, &m_alphasurface, NULL);

  00086	e8 00 00 00 00	 call	 ?GetActiveOutput@@YAPAVIOutput@@XZ ; GetActiveOutput
  0008b	8b 88 cc 04 00
	00		 mov	 ecx, DWORD PTR [eax+1228]
  00091	89 4d e0	 mov	 DWORD PTR tv145[ebp], ecx
  00094	6a 00		 push	 0
  00096	8b 55 ec	 mov	 edx, DWORD PTR _this$[ebp]
  00099	83 c2 2c	 add	 edx, 44			; 0000002cH
  0009c	52		 push	 edx
  0009d	6a 02		 push	 2
  0009f	6a 15		 push	 21			; 00000015H
  000a1	8b 45 fc	 mov	 eax, DWORD PTR _src$144379[ebp+12]
  000a4	50		 push	 eax
  000a5	8b 4d f8	 mov	 ecx, DWORD PTR _src$144379[ebp+8]
  000a8	51		 push	 ecx
  000a9	8b 55 e0	 mov	 edx, DWORD PTR tv145[ebp]
  000ac	52		 push	 edx
  000ad	8b 45 e0	 mov	 eax, DWORD PTR tv145[ebp]
  000b0	8b 08		 mov	 ecx, DWORD PTR [eax]
  000b2	8b 91 90 00 00
	00		 mov	 edx, DWORD PTR [ecx+144]
  000b8	ff d2		 call	 edx
$LN2@CreateD3DB:

; 75   :     }
; 76   : }

  000ba	8b e5		 mov	 esp, ebp
  000bc	5d		 pop	 ebp
  000bd	c3		 ret	 0
?CreateD3DBuffer@CPaintingHDC@@AAEXXZ ENDP		; CPaintingHDC::CreateD3DBuffer
PUBLIC	?BitBltRectsD3D@CPaintingHDC@@QAEXPAUtagRECT@@JPAUIDirect3DSurface9@@PAUHDC__@@@Z ; CPaintingHDC::BitBltRectsD3D
; Function compile flags: /Odtp
;	COMDAT ?BitBltRectsD3D@CPaintingHDC@@QAEXPAUtagRECT@@JPAUIDirect3DSurface9@@PAUHDC__@@@Z
_TEXT	SEGMENT
tv579 = -208						; size = 4
tv498 = -204						; size = 4
tv828 = -200						; size = 4
tv431 = -196						; size = 8
tv816 = -188						; size = 4
tv805 = -184						; size = 4
tv400 = -180						; size = 8
tv793 = -172						; size = 4
tv782 = -168						; size = 4
tv369 = -164						; size = 8
tv770 = -156						; size = 4
tv759 = -152						; size = 4
tv338 = -148						; size = 8
tv747 = -140						; size = 4
tv740 = -136						; size = 4
tv738 = -132						; size = 4
tv733 = -128						; size = 4
tv731 = -124						; size = 4
_this$ = -120						; size = 4
_nPixel$144502 = -116					; size = 4
_pPixel$144496 = -112					; size = 4
_ddPixel$144499 = -108					; size = 4
_nLine$144492 = -104					; size = 4
_colorkey$144491 = -100					; size = 4
_src$144466 = -96					; size = 16
_or$144473 = -80					; size = 16
_scaleY$144474 = -64					; size = 4
_ddlr$144486 = -60					; size = 8
_scaleX$144477 = -52					; size = 4
_lr$144485 = -48					; size = 8
_outDC$144455 = -40					; size = 4
_i$144450 = -36						; size = 4
_r$ = -32						; size = 16
_outRect$ = -16						; size = 16
_pRectList$ = 8						; size = 4
_nRectCount$ = 12					; size = 4
_target$ = 16						; size = 4
_hDstDC$ = 20						; size = 4
?BitBltRectsD3D@CPaintingHDC@@QAEXPAUtagRECT@@JPAUIDirect3DSurface9@@PAUHDC__@@@Z PROC ; CPaintingHDC::BitBltRectsD3D, COMDAT
; _this$ = ecx

; 201  : {

  00000	55		 push	 ebp
  00001	8b ec		 mov	 ebp, esp
  00003	81 ec d0 00 00
	00		 sub	 esp, 208		; 000000d0H
  00009	56		 push	 esi
  0000a	89 4d 88	 mov	 DWORD PTR _this$[ebp], ecx

; 202  :     if (m_hBufferDC == NULL || target == NULL)

  0000d	8b 45 88	 mov	 eax, DWORD PTR _this$[ebp]
  00010	83 38 00	 cmp	 DWORD PTR [eax], 0
  00013	74 06		 je	 SHORT $LN32@BitBltRect@2
  00015	83 7d 10 00	 cmp	 DWORD PTR _target$[ebp], 0
  00019	75 05		 jne	 SHORT $LN33@BitBltRect@2
$LN32@BitBltRect@2:

; 203  :     {
; 204  :         return;

  0001b	e9 ea 07 00 00	 jmp	 $LN34@BitBltRect@2
$LN33@BitBltRect@2:

; 205  :     }
; 206  : 
; 207  :     if(m_ddsurface==NULL || m_alphasurface==NULL)

  00020	8b 4d 88	 mov	 ecx, DWORD PTR _this$[ebp]
  00023	83 79 28 00	 cmp	 DWORD PTR [ecx+40], 0
  00027	74 09		 je	 SHORT $LN30@BitBltRect@2
  00029	8b 55 88	 mov	 edx, DWORD PTR _this$[ebp]
  0002c	83 7a 2c 00	 cmp	 DWORD PTR [edx+44], 0
  00030	75 1f		 jne	 SHORT $LN29@BitBltRect@2
$LN30@BitBltRect@2:

; 208  :     {
; 209  :         CreateD3DBuffer();

  00032	8b 4d 88	 mov	 ecx, DWORD PTR _this$[ebp]
  00035	e8 00 00 00 00	 call	 ?CreateD3DBuffer@CPaintingHDC@@AAEXXZ ; CPaintingHDC::CreateD3DBuffer

; 210  :         if(m_ddsurface==NULL || m_alphasurface==NULL)

  0003a	8b 45 88	 mov	 eax, DWORD PTR _this$[ebp]
  0003d	83 78 28 00	 cmp	 DWORD PTR [eax+40], 0
  00041	74 09		 je	 SHORT $LN28@BitBltRect@2
  00043	8b 4d 88	 mov	 ecx, DWORD PTR _this$[ebp]
  00046	83 79 2c 00	 cmp	 DWORD PTR [ecx+44], 0
  0004a	75 05		 jne	 SHORT $LN29@BitBltRect@2
$LN28@BitBltRect@2:

; 211  :         {
; 212  :             return;

  0004c	e9 b9 07 00 00	 jmp	 $LN34@BitBltRect@2
$LN29@BitBltRect@2:

; 213  :         }
; 214  :     }
; 215  : 
; 216  :     if (hDstDC == NULL)

  00051	83 7d 14 00	 cmp	 DWORD PTR _hDstDC$[ebp], 0
  00055	75 09		 jne	 SHORT $LN27@BitBltRect@2

; 217  :     {
; 218  :         hDstDC = m_hOriginalDC;

  00057	8b 55 88	 mov	 edx, DWORD PTR _this$[ebp]
  0005a	8b 42 04	 mov	 eax, DWORD PTR [edx+4]
  0005d	89 45 14	 mov	 DWORD PTR _hDstDC$[ebp], eax
$LN27@BitBltRect@2:

; 219  :     }
; 220  : 
; 221  :     if (hDstDC == NULL)

  00060	83 7d 14 00	 cmp	 DWORD PTR _hDstDC$[ebp], 0
  00064	75 05		 jne	 SHORT $LN26@BitBltRect@2

; 222  :     {
; 223  :         return;

  00066	e9 9f 07 00 00	 jmp	 $LN34@BitBltRect@2
$LN26@BitBltRect@2:

; 224  :     }
; 225  : 
; 226  :     // get rect we output video to
; 227  :     RECT outRect = ((CD3D9Output *)GetActiveOutput())->Overlay_GetCurrentDestRect();

  0006b	8d 4d f0	 lea	 ecx, DWORD PTR _outRect$[ebp]
  0006e	51		 push	 ecx
  0006f	e8 00 00 00 00	 call	 ?GetActiveOutput@@YAPAVIOutput@@XZ ; GetActiveOutput
  00074	8b c8		 mov	 ecx, eax
  00076	e8 00 00 00 00	 call	 ?Overlay_GetCurrentDestRect@CD3D9Output@@QAE?AUtagRECT@@XZ ; CD3D9Output::Overlay_GetCurrentDestRect

; 228  : 
; 229  : 
; 230  :     // VT_BLACK gets painted directly
; 231  :     RECT r;
; 232  :     for (int i = 0; i < nRectCount; i++)

  0007b	c7 45 dc 00 00
	00 00		 mov	 DWORD PTR _i$144450[ebp], 0
  00082	eb 09		 jmp	 SHORT $LN25@BitBltRect@2
$LN24@BitBltRect@2:
  00084	8b 55 dc	 mov	 edx, DWORD PTR _i$144450[ebp]
  00087	83 c2 01	 add	 edx, 1
  0008a	89 55 dc	 mov	 DWORD PTR _i$144450[ebp], edx
$LN25@BitBltRect@2:
  0008d	8b 45 dc	 mov	 eax, DWORD PTR _i$144450[ebp]
  00090	3b 45 0c	 cmp	 eax, DWORD PTR _nRectCount$[ebp]
  00093	0f 8d 33 07 00
	00		 jge	 $LN23@BitBltRect@2

; 233  :     {
; 234  :         if(VT_GetState()!=VT_BLACK && IntersectRect(&r, &pRectList[i], &outRect))

  00099	e8 00 00 00 00	 call	 ?VT_GetState@@YA?AW4eVTState@@XZ ; VT_GetState
  0009e	83 f8 01	 cmp	 eax, 1
  000a1	0f 84 a0 06 00
	00		 je	 $LN22@BitBltRect@2
  000a7	8d 4d f0	 lea	 ecx, DWORD PTR _outRect$[ebp]
  000aa	51		 push	 ecx
  000ab	8b 55 dc	 mov	 edx, DWORD PTR _i$144450[ebp]
  000ae	c1 e2 04	 shl	 edx, 4
  000b1	03 55 08	 add	 edx, DWORD PTR _pRectList$[ebp]
  000b4	52		 push	 edx
  000b5	8d 45 e0	 lea	 eax, DWORD PTR _r$[ebp]
  000b8	50		 push	 eax
  000b9	ff 15 00 00 00
	00		 call	 DWORD PTR __imp__IntersectRect@12
  000bf	85 c0		 test	 eax, eax
  000c1	0f 84 80 06 00
	00		 je	 $LN22@BitBltRect@2

; 235  :         {
; 236  : 
; 237  :             HDC outDC;
; 238  :             // GetDC doesn't work for ARGB surfaces prior to Vista so the m_alphasurface is necessary :( -> slow as hell
; 239  :             if(SUCCEEDED(m_ddsurface->GetDC(&outDC)))

  000c7	8d 4d d8	 lea	 ecx, DWORD PTR _outDC$144455[ebp]
  000ca	51		 push	 ecx
  000cb	8b 55 88	 mov	 edx, DWORD PTR _this$[ebp]
  000ce	8b 42 28	 mov	 eax, DWORD PTR [edx+40]
  000d1	8b 4d 88	 mov	 ecx, DWORD PTR _this$[ebp]
  000d4	8b 51 28	 mov	 edx, DWORD PTR [ecx+40]
  000d7	8b 00		 mov	 eax, DWORD PTR [eax]
  000d9	52		 push	 edx
  000da	8b 48 3c	 mov	 ecx, DWORD PTR [eax+60]
  000dd	ff d1		 call	 ecx
  000df	85 c0		 test	 eax, eax
  000e1	0f 8c 5b 06 00
	00		 jl	 $LN12@BitBltRect@2

; 240  :             {
; 241  :                 // further processing necessary
; 242  :                 // first do the things around output
; 243  :                 if(pRectList[i].left<outRect.left)

  000e7	8b 55 dc	 mov	 edx, DWORD PTR _i$144450[ebp]
  000ea	c1 e2 04	 shl	 edx, 4
  000ed	8b 45 08	 mov	 eax, DWORD PTR _pRectList$[ebp]
  000f0	8b 0c 10	 mov	 ecx, DWORD PTR [eax+edx]
  000f3	3b 4d f0	 cmp	 ecx, DWORD PTR _outRect$[ebp]
  000f6	7d 68		 jge	 SHORT $LN20@BitBltRect@2

; 244  :                 {
; 245  :                     // have to paint left from output
; 246  :                     r.left=pRectList[i].left;

  000f8	8b 55 dc	 mov	 edx, DWORD PTR _i$144450[ebp]
  000fb	c1 e2 04	 shl	 edx, 4
  000fe	8b 45 08	 mov	 eax, DWORD PTR _pRectList$[ebp]
  00101	8b 0c 10	 mov	 ecx, DWORD PTR [eax+edx]
  00104	89 4d e0	 mov	 DWORD PTR _r$[ebp], ecx

; 247  :                     r.right=outRect.left;

  00107	8b 55 f0	 mov	 edx, DWORD PTR _outRect$[ebp]
  0010a	89 55 e8	 mov	 DWORD PTR _r$[ebp+8], edx

; 248  :                     r.top=pRectList[i].top;

  0010d	8b 45 dc	 mov	 eax, DWORD PTR _i$144450[ebp]
  00110	c1 e0 04	 shl	 eax, 4
  00113	8b 4d 08	 mov	 ecx, DWORD PTR _pRectList$[ebp]
  00116	8b 54 01 04	 mov	 edx, DWORD PTR [ecx+eax+4]
  0011a	89 55 e4	 mov	 DWORD PTR _r$[ebp+4], edx

; 249  :                     r.bottom=pRectList[i].bottom;

  0011d	8b 45 dc	 mov	 eax, DWORD PTR _i$144450[ebp]
  00120	c1 e0 04	 shl	 eax, 4
  00123	8b 4d 08	 mov	 ecx, DWORD PTR _pRectList$[ebp]
  00126	8b 54 01 0c	 mov	 edx, DWORD PTR [ecx+eax+12]
  0012a	89 55 ec	 mov	 DWORD PTR _r$[ebp+12], edx

; 250  :                     BitBlt(hDstDC, r.left, r.top,
; 251  :                         r.right - r.left,
; 252  :                         r.bottom - r.top,
; 253  :                         m_hBufferDC, r.left, r.top, SRCCOPY);

  0012d	68 20 00 cc 00	 push	 13369376		; 00cc0020H
  00132	8b 45 e4	 mov	 eax, DWORD PTR _r$[ebp+4]
  00135	50		 push	 eax
  00136	8b 4d e0	 mov	 ecx, DWORD PTR _r$[ebp]
  00139	51		 push	 ecx
  0013a	8b 55 88	 mov	 edx, DWORD PTR _this$[ebp]
  0013d	8b 02		 mov	 eax, DWORD PTR [edx]
  0013f	50		 push	 eax
  00140	8b 4d ec	 mov	 ecx, DWORD PTR _r$[ebp+12]
  00143	2b 4d e4	 sub	 ecx, DWORD PTR _r$[ebp+4]
  00146	51		 push	 ecx
  00147	8b 55 e8	 mov	 edx, DWORD PTR _r$[ebp+8]
  0014a	2b 55 e0	 sub	 edx, DWORD PTR _r$[ebp]
  0014d	52		 push	 edx
  0014e	8b 45 e4	 mov	 eax, DWORD PTR _r$[ebp+4]
  00151	50		 push	 eax
  00152	8b 4d e0	 mov	 ecx, DWORD PTR _r$[ebp]
  00155	51		 push	 ecx
  00156	8b 55 14	 mov	 edx, DWORD PTR _hDstDC$[ebp]
  00159	52		 push	 edx
  0015a	ff 15 00 00 00
	00		 call	 DWORD PTR __imp__BitBlt@36
$LN20@BitBltRect@2:

; 254  :                 }
; 255  :                 if(pRectList[i].right>outRect.right)

  00160	8b 45 dc	 mov	 eax, DWORD PTR _i$144450[ebp]
  00163	c1 e0 04	 shl	 eax, 4
  00166	8b 4d 08	 mov	 ecx, DWORD PTR _pRectList$[ebp]
  00169	8b 54 01 08	 mov	 edx, DWORD PTR [ecx+eax+8]
  0016d	3b 55 f8	 cmp	 edx, DWORD PTR _outRect$[ebp+8]
  00170	7e 69		 jle	 SHORT $LN19@BitBltRect@2

; 256  :                 {
; 257  :                     // have to paint right from output
; 258  :                     r.left=outRect.right;

  00172	8b 45 f8	 mov	 eax, DWORD PTR _outRect$[ebp+8]
  00175	89 45 e0	 mov	 DWORD PTR _r$[ebp], eax

; 259  :                     r.right=pRectList[i].right;

  00178	8b 4d dc	 mov	 ecx, DWORD PTR _i$144450[ebp]
  0017b	c1 e1 04	 shl	 ecx, 4
  0017e	8b 55 08	 mov	 edx, DWORD PTR _pRectList$[ebp]
  00181	8b 44 0a 08	 mov	 eax, DWORD PTR [edx+ecx+8]
  00185	89 45 e8	 mov	 DWORD PTR _r$[ebp+8], eax

; 260  :                     r.top=pRectList[i].top;

  00188	8b 4d dc	 mov	 ecx, DWORD PTR _i$144450[ebp]
  0018b	c1 e1 04	 shl	 ecx, 4
  0018e	8b 55 08	 mov	 edx, DWORD PTR _pRectList$[ebp]
  00191	8b 44 0a 04	 mov	 eax, DWORD PTR [edx+ecx+4]
  00195	89 45 e4	 mov	 DWORD PTR _r$[ebp+4], eax

; 261  :                     r.bottom=pRectList[i].bottom;

  00198	8b 4d dc	 mov	 ecx, DWORD PTR _i$144450[ebp]
  0019b	c1 e1 04	 shl	 ecx, 4
  0019e	8b 55 08	 mov	 edx, DWORD PTR _pRectList$[ebp]
  001a1	8b 44 0a 0c	 mov	 eax, DWORD PTR [edx+ecx+12]
  001a5	89 45 ec	 mov	 DWORD PTR _r$[ebp+12], eax

; 262  :                     BitBlt(hDstDC, r.left, r.top,
; 263  :                         r.right - r.left,
; 264  :                         r.bottom - r.top,
; 265  :                         m_hBufferDC, r.left, r.top, SRCCOPY);

  001a8	68 20 00 cc 00	 push	 13369376		; 00cc0020H
  001ad	8b 4d e4	 mov	 ecx, DWORD PTR _r$[ebp+4]
  001b0	51		 push	 ecx
  001b1	8b 55 e0	 mov	 edx, DWORD PTR _r$[ebp]
  001b4	52		 push	 edx
  001b5	8b 45 88	 mov	 eax, DWORD PTR _this$[ebp]
  001b8	8b 08		 mov	 ecx, DWORD PTR [eax]
  001ba	51		 push	 ecx
  001bb	8b 55 ec	 mov	 edx, DWORD PTR _r$[ebp+12]
  001be	2b 55 e4	 sub	 edx, DWORD PTR _r$[ebp+4]
  001c1	52		 push	 edx
  001c2	8b 45 e8	 mov	 eax, DWORD PTR _r$[ebp+8]
  001c5	2b 45 e0	 sub	 eax, DWORD PTR _r$[ebp]
  001c8	50		 push	 eax
  001c9	8b 4d e4	 mov	 ecx, DWORD PTR _r$[ebp+4]
  001cc	51		 push	 ecx
  001cd	8b 55 e0	 mov	 edx, DWORD PTR _r$[ebp]
  001d0	52		 push	 edx
  001d1	8b 45 14	 mov	 eax, DWORD PTR _hDstDC$[ebp]
  001d4	50		 push	 eax
  001d5	ff 15 00 00 00
	00		 call	 DWORD PTR __imp__BitBlt@36
$LN19@BitBltRect@2:

; 266  :                 }
; 267  :                 if(pRectList[i].top<outRect.top)

  001db	8b 4d dc	 mov	 ecx, DWORD PTR _i$144450[ebp]
  001de	c1 e1 04	 shl	 ecx, 4
  001e1	8b 55 08	 mov	 edx, DWORD PTR _pRectList$[ebp]
  001e4	8b 44 0a 04	 mov	 eax, DWORD PTR [edx+ecx+4]
  001e8	3b 45 f4	 cmp	 eax, DWORD PTR _outRect$[ebp+4]
  001eb	7d 68		 jge	 SHORT $LN18@BitBltRect@2

; 268  :                 {
; 269  :                     // top
; 270  :                     r.left=pRectList[i].left; // maybe drawing 2x ... really necessary? however don't care

  001ed	8b 4d dc	 mov	 ecx, DWORD PTR _i$144450[ebp]
  001f0	c1 e1 04	 shl	 ecx, 4
  001f3	8b 55 08	 mov	 edx, DWORD PTR _pRectList$[ebp]
  001f6	8b 04 0a	 mov	 eax, DWORD PTR [edx+ecx]
  001f9	89 45 e0	 mov	 DWORD PTR _r$[ebp], eax

; 271  :                     r.right=pRectList[i].right;

  001fc	8b 4d dc	 mov	 ecx, DWORD PTR _i$144450[ebp]
  001ff	c1 e1 04	 shl	 ecx, 4
  00202	8b 55 08	 mov	 edx, DWORD PTR _pRectList$[ebp]
  00205	8b 44 0a 08	 mov	 eax, DWORD PTR [edx+ecx+8]
  00209	89 45 e8	 mov	 DWORD PTR _r$[ebp+8], eax

; 272  :                     r.top=pRectList[i].top;

  0020c	8b 4d dc	 mov	 ecx, DWORD PTR _i$144450[ebp]
  0020f	c1 e1 04	 shl	 ecx, 4
  00212	8b 55 08	 mov	 edx, DWORD PTR _pRectList$[ebp]
  00215	8b 44 0a 04	 mov	 eax, DWORD PTR [edx+ecx+4]
  00219	89 45 e4	 mov	 DWORD PTR _r$[ebp+4], eax

; 273  :                     r.bottom=outRect.top;

  0021c	8b 4d f4	 mov	 ecx, DWORD PTR _outRect$[ebp+4]
  0021f	89 4d ec	 mov	 DWORD PTR _r$[ebp+12], ecx

; 274  :                     BitBlt(hDstDC, r.left, r.top,
; 275  :                         r.right - r.left,
; 276  :                         r.bottom - r.top,
; 277  :                         m_hBufferDC, r.left, r.top, SRCCOPY);

  00222	68 20 00 cc 00	 push	 13369376		; 00cc0020H
  00227	8b 55 e4	 mov	 edx, DWORD PTR _r$[ebp+4]
  0022a	52		 push	 edx
  0022b	8b 45 e0	 mov	 eax, DWORD PTR _r$[ebp]
  0022e	50		 push	 eax
  0022f	8b 4d 88	 mov	 ecx, DWORD PTR _this$[ebp]
  00232	8b 11		 mov	 edx, DWORD PTR [ecx]
  00234	52		 push	 edx
  00235	8b 45 ec	 mov	 eax, DWORD PTR _r$[ebp+12]
  00238	2b 45 e4	 sub	 eax, DWORD PTR _r$[ebp+4]
  0023b	50		 push	 eax
  0023c	8b 4d e8	 mov	 ecx, DWORD PTR _r$[ebp+8]
  0023f	2b 4d e0	 sub	 ecx, DWORD PTR _r$[ebp]
  00242	51		 push	 ecx
  00243	8b 55 e4	 mov	 edx, DWORD PTR _r$[ebp+4]
  00246	52		 push	 edx
  00247	8b 45 e0	 mov	 eax, DWORD PTR _r$[ebp]
  0024a	50		 push	 eax
  0024b	8b 4d 14	 mov	 ecx, DWORD PTR _hDstDC$[ebp]
  0024e	51		 push	 ecx
  0024f	ff 15 00 00 00
	00		 call	 DWORD PTR __imp__BitBlt@36
$LN18@BitBltRect@2:

; 278  :                 }
; 279  :                 if(pRectList[i].bottom>outRect.bottom)

  00255	8b 55 dc	 mov	 edx, DWORD PTR _i$144450[ebp]
  00258	c1 e2 04	 shl	 edx, 4
  0025b	8b 45 08	 mov	 eax, DWORD PTR _pRectList$[ebp]
  0025e	8b 4c 10 0c	 mov	 ecx, DWORD PTR [eax+edx+12]
  00262	3b 4d fc	 cmp	 ecx, DWORD PTR _outRect$[ebp+12]
  00265	7e 68		 jle	 SHORT $LN17@BitBltRect@2

; 280  :                 {
; 281  :                     // bottom
; 282  :                     r.left=pRectList[i].left; // maybe drawing 2x ... really necessary? however don't care

  00267	8b 55 dc	 mov	 edx, DWORD PTR _i$144450[ebp]
  0026a	c1 e2 04	 shl	 edx, 4
  0026d	8b 45 08	 mov	 eax, DWORD PTR _pRectList$[ebp]
  00270	8b 0c 10	 mov	 ecx, DWORD PTR [eax+edx]
  00273	89 4d e0	 mov	 DWORD PTR _r$[ebp], ecx

; 283  :                     r.right=pRectList[i].right;

  00276	8b 55 dc	 mov	 edx, DWORD PTR _i$144450[ebp]
  00279	c1 e2 04	 shl	 edx, 4
  0027c	8b 45 08	 mov	 eax, DWORD PTR _pRectList$[ebp]
  0027f	8b 4c 10 08	 mov	 ecx, DWORD PTR [eax+edx+8]
  00283	89 4d e8	 mov	 DWORD PTR _r$[ebp+8], ecx

; 284  :                     r.top=outRect.bottom;

  00286	8b 55 fc	 mov	 edx, DWORD PTR _outRect$[ebp+12]
  00289	89 55 e4	 mov	 DWORD PTR _r$[ebp+4], edx

; 285  :                     r.bottom=pRectList[i].bottom;

  0028c	8b 45 dc	 mov	 eax, DWORD PTR _i$144450[ebp]
  0028f	c1 e0 04	 shl	 eax, 4
  00292	8b 4d 08	 mov	 ecx, DWORD PTR _pRectList$[ebp]
  00295	8b 54 01 0c	 mov	 edx, DWORD PTR [ecx+eax+12]
  00299	89 55 ec	 mov	 DWORD PTR _r$[ebp+12], edx

; 286  :                     BitBlt(hDstDC, r.left, r.top,
; 287  :                         r.right - r.left,
; 288  :                         r.bottom - r.top,
; 289  :                         m_hBufferDC, r.left, r.top, SRCCOPY);

  0029c	68 20 00 cc 00	 push	 13369376		; 00cc0020H
  002a1	8b 45 e4	 mov	 eax, DWORD PTR _r$[ebp+4]
  002a4	50		 push	 eax
  002a5	8b 4d e0	 mov	 ecx, DWORD PTR _r$[ebp]
  002a8	51		 push	 ecx
  002a9	8b 55 88	 mov	 edx, DWORD PTR _this$[ebp]
  002ac	8b 02		 mov	 eax, DWORD PTR [edx]
  002ae	50		 push	 eax
  002af	8b 4d ec	 mov	 ecx, DWORD PTR _r$[ebp+12]
  002b2	2b 4d e4	 sub	 ecx, DWORD PTR _r$[ebp+4]
  002b5	51		 push	 ecx
  002b6	8b 55 e8	 mov	 edx, DWORD PTR _r$[ebp+8]
  002b9	2b 55 e0	 sub	 edx, DWORD PTR _r$[ebp]
  002bc	52		 push	 edx
  002bd	8b 45 e4	 mov	 eax, DWORD PTR _r$[ebp+4]
  002c0	50		 push	 eax
  002c1	8b 4d e0	 mov	 ecx, DWORD PTR _r$[ebp]
  002c4	51		 push	 ecx
  002c5	8b 55 14	 mov	 edx, DWORD PTR _hDstDC$[ebp]
  002c8	52		 push	 edx
  002c9	ff 15 00 00 00
	00		 call	 DWORD PTR __imp__BitBlt@36
$LN17@BitBltRect@2:

; 290  :                 }
; 291  : 
; 292  :                 // TODO: this could be optimized somehow -- any ideas???
; 293  : 
; 294  : 
; 295  : 				RECT src = ((CD3D9Output *)GetActiveOutput())->OSD_GetRect();

  002cf	8d 45 a0	 lea	 eax, DWORD PTR _src$144466[ebp]
  002d2	50		 push	 eax
  002d3	e8 00 00 00 00	 call	 ?GetActiveOutput@@YAPAVIOutput@@XZ ; GetActiveOutput
  002d8	8b c8		 mov	 ecx, eax
  002da	e8 00 00 00 00	 call	 ?OSD_GetRect@CD3D9Output@@QAE?AUtagRECT@@XZ ; CD3D9Output::OSD_GetRect

; 296  : 
; 297  :                 // some scaling around to get proper coordinates for stretchblt
; 298  : 
; 299  :                 if(pRectList[i].top<outRect.top) pRectList[i].top=outRect.top;

  002df	8b 4d dc	 mov	 ecx, DWORD PTR _i$144450[ebp]
  002e2	c1 e1 04	 shl	 ecx, 4
  002e5	8b 55 08	 mov	 edx, DWORD PTR _pRectList$[ebp]
  002e8	8b 44 0a 04	 mov	 eax, DWORD PTR [edx+ecx+4]
  002ec	3b 45 f4	 cmp	 eax, DWORD PTR _outRect$[ebp+4]
  002ef	7d 10		 jge	 SHORT $LN16@BitBltRect@2
  002f1	8b 4d dc	 mov	 ecx, DWORD PTR _i$144450[ebp]
  002f4	c1 e1 04	 shl	 ecx, 4
  002f7	8b 55 08	 mov	 edx, DWORD PTR _pRectList$[ebp]
  002fa	8b 45 f4	 mov	 eax, DWORD PTR _outRect$[ebp+4]
  002fd	89 44 0a 04	 mov	 DWORD PTR [edx+ecx+4], eax
$LN16@BitBltRect@2:

; 300  :                 if(pRectList[i].bottom>outRect.bottom) pRectList[i].bottom=outRect.bottom;

  00301	8b 4d dc	 mov	 ecx, DWORD PTR _i$144450[ebp]
  00304	c1 e1 04	 shl	 ecx, 4
  00307	8b 55 08	 mov	 edx, DWORD PTR _pRectList$[ebp]
  0030a	8b 44 0a 0c	 mov	 eax, DWORD PTR [edx+ecx+12]
  0030e	3b 45 fc	 cmp	 eax, DWORD PTR _outRect$[ebp+12]
  00311	7e 10		 jle	 SHORT $LN15@BitBltRect@2
  00313	8b 4d dc	 mov	 ecx, DWORD PTR _i$144450[ebp]
  00316	c1 e1 04	 shl	 ecx, 4
  00319	8b 55 08	 mov	 edx, DWORD PTR _pRectList$[ebp]
  0031c	8b 45 fc	 mov	 eax, DWORD PTR _outRect$[ebp+12]
  0031f	89 44 0a 0c	 mov	 DWORD PTR [edx+ecx+12], eax
$LN15@BitBltRect@2:

; 301  :                 if(pRectList[i].left<outRect.left) pRectList[i].left=outRect.left;

  00323	8b 4d dc	 mov	 ecx, DWORD PTR _i$144450[ebp]
  00326	c1 e1 04	 shl	 ecx, 4
  00329	8b 55 08	 mov	 edx, DWORD PTR _pRectList$[ebp]
  0032c	8b 04 0a	 mov	 eax, DWORD PTR [edx+ecx]
  0032f	3b 45 f0	 cmp	 eax, DWORD PTR _outRect$[ebp]
  00332	7d 0f		 jge	 SHORT $LN14@BitBltRect@2
  00334	8b 4d dc	 mov	 ecx, DWORD PTR _i$144450[ebp]
  00337	c1 e1 04	 shl	 ecx, 4
  0033a	8b 55 08	 mov	 edx, DWORD PTR _pRectList$[ebp]
  0033d	8b 45 f0	 mov	 eax, DWORD PTR _outRect$[ebp]
  00340	89 04 0a	 mov	 DWORD PTR [edx+ecx], eax
$LN14@BitBltRect@2:

; 302  :                 if(pRectList[i].right>outRect.right) pRectList[i].right=outRect.right;

  00343	8b 4d dc	 mov	 ecx, DWORD PTR _i$144450[ebp]
  00346	c1 e1 04	 shl	 ecx, 4
  00349	8b 55 08	 mov	 edx, DWORD PTR _pRectList$[ebp]
  0034c	8b 44 0a 08	 mov	 eax, DWORD PTR [edx+ecx+8]
  00350	3b 45 f8	 cmp	 eax, DWORD PTR _outRect$[ebp+8]
  00353	7e 10		 jle	 SHORT $LN13@BitBltRect@2
  00355	8b 4d dc	 mov	 ecx, DWORD PTR _i$144450[ebp]
  00358	c1 e1 04	 shl	 ecx, 4
  0035b	8b 55 08	 mov	 edx, DWORD PTR _pRectList$[ebp]
  0035e	8b 45 f8	 mov	 eax, DWORD PTR _outRect$[ebp+8]
  00361	89 44 0a 08	 mov	 DWORD PTR [edx+ecx+8], eax
$LN13@BitBltRect@2:

; 303  : 
; 304  :                 RECT or;
; 305  :                 float scaleY=(float)(src.bottom-src.top)/(float)(outRect.bottom-outRect.top);

  00365	8b 4d ac	 mov	 ecx, DWORD PTR _src$144466[ebp+12]
  00368	2b 4d a4	 sub	 ecx, DWORD PTR _src$144466[ebp+4]
  0036b	89 4d 84	 mov	 DWORD PTR tv731[ebp], ecx
  0036e	db 45 84	 fild	 DWORD PTR tv731[ebp]
  00371	8b 55 fc	 mov	 edx, DWORD PTR _outRect$[ebp+12]
  00374	2b 55 f4	 sub	 edx, DWORD PTR _outRect$[ebp+4]
  00377	89 55 80	 mov	 DWORD PTR tv733[ebp], edx
  0037a	da 75 80	 fidiv	 DWORD PTR tv733[ebp]
  0037d	d9 5d c0	 fstp	 DWORD PTR _scaleY$144474[ebp]

; 306  :                 float scaleX=(float)(src.right-src.left)/(float)(outRect.right-outRect.left);

  00380	8b 45 a8	 mov	 eax, DWORD PTR _src$144466[ebp+8]
  00383	2b 45 a0	 sub	 eax, DWORD PTR _src$144466[ebp]
  00386	89 85 7c ff ff
	ff		 mov	 DWORD PTR tv738[ebp], eax
  0038c	db 85 7c ff ff
	ff		 fild	 DWORD PTR tv738[ebp]
  00392	8b 4d f8	 mov	 ecx, DWORD PTR _outRect$[ebp+8]
  00395	2b 4d f0	 sub	 ecx, DWORD PTR _outRect$[ebp]
  00398	89 8d 78 ff ff
	ff		 mov	 DWORD PTR tv740[ebp], ecx
  0039e	da b5 78 ff ff
	ff		 fidiv	 DWORD PTR tv740[ebp]
  003a4	d9 5d cc	 fstp	 DWORD PTR _scaleX$144477[ebp]

; 307  : 
; 308  :                 or.left=(LONG)max(src.left, scaleX*(pRectList[i].left-outRect.left)+src.left);

  003a7	db 45 a0	 fild	 DWORD PTR _src$144466[ebp]
  003aa	8b 55 dc	 mov	 edx, DWORD PTR _i$144450[ebp]
  003ad	c1 e2 04	 shl	 edx, 4
  003b0	8b 45 08	 mov	 eax, DWORD PTR _pRectList$[ebp]
  003b3	8b 0c 10	 mov	 ecx, DWORD PTR [eax+edx]
  003b6	2b 4d f0	 sub	 ecx, DWORD PTR _outRect$[ebp]
  003b9	89 8d 74 ff ff
	ff		 mov	 DWORD PTR tv747[ebp], ecx
  003bf	db 85 74 ff ff
	ff		 fild	 DWORD PTR tv747[ebp]
  003c5	d8 4d cc	 fmul	 DWORD PTR _scaleX$144477[ebp]
  003c8	da 45 a0	 fiadd	 DWORD PTR _src$144466[ebp]
  003cb	de d9		 fcompp
  003cd	df e0		 fnstsw	 ax
  003cf	f6 c4 05	 test	 ah, 5
  003d2	7a 0b		 jp	 SHORT $LN36@BitBltRect@2
  003d4	db 45 a0	 fild	 DWORD PTR _src$144466[ebp]
  003d7	dd 9d 6c ff ff
	ff		 fstp	 QWORD PTR tv338[ebp]
  003dd	eb 27		 jmp	 SHORT $LN37@BitBltRect@2
$LN36@BitBltRect@2:
  003df	8b 55 dc	 mov	 edx, DWORD PTR _i$144450[ebp]
  003e2	c1 e2 04	 shl	 edx, 4
  003e5	8b 45 08	 mov	 eax, DWORD PTR _pRectList$[ebp]
  003e8	8b 0c 10	 mov	 ecx, DWORD PTR [eax+edx]
  003eb	2b 4d f0	 sub	 ecx, DWORD PTR _outRect$[ebp]
  003ee	89 8d 68 ff ff
	ff		 mov	 DWORD PTR tv759[ebp], ecx
  003f4	db 85 68 ff ff
	ff		 fild	 DWORD PTR tv759[ebp]
  003fa	d8 4d cc	 fmul	 DWORD PTR _scaleX$144477[ebp]
  003fd	da 45 a0	 fiadd	 DWORD PTR _src$144466[ebp]
  00400	dd 9d 6c ff ff
	ff		 fstp	 QWORD PTR tv338[ebp]
$LN37@BitBltRect@2:
  00406	dd 85 6c ff ff
	ff		 fld	 QWORD PTR tv338[ebp]
  0040c	e8 00 00 00 00	 call	 __ftol2_sse
  00411	89 45 b0	 mov	 DWORD PTR _or$144473[ebp], eax

; 309  :                 or.top=(LONG)max(src.top, scaleY*(pRectList[i].top-outRect.top)+src.top);

  00414	db 45 a4	 fild	 DWORD PTR _src$144466[ebp+4]
  00417	8b 55 dc	 mov	 edx, DWORD PTR _i$144450[ebp]
  0041a	c1 e2 04	 shl	 edx, 4
  0041d	8b 45 08	 mov	 eax, DWORD PTR _pRectList$[ebp]
  00420	8b 4c 10 04	 mov	 ecx, DWORD PTR [eax+edx+4]
  00424	2b 4d f4	 sub	 ecx, DWORD PTR _outRect$[ebp+4]
  00427	89 8d 64 ff ff
	ff		 mov	 DWORD PTR tv770[ebp], ecx
  0042d	db 85 64 ff ff
	ff		 fild	 DWORD PTR tv770[ebp]
  00433	d8 4d c0	 fmul	 DWORD PTR _scaleY$144474[ebp]
  00436	da 45 a4	 fiadd	 DWORD PTR _src$144466[ebp+4]
  00439	de d9		 fcompp
  0043b	df e0		 fnstsw	 ax
  0043d	f6 c4 05	 test	 ah, 5
  00440	7a 0b		 jp	 SHORT $LN38@BitBltRect@2
  00442	db 45 a4	 fild	 DWORD PTR _src$144466[ebp+4]
  00445	dd 9d 5c ff ff
	ff		 fstp	 QWORD PTR tv369[ebp]
  0044b	eb 28		 jmp	 SHORT $LN39@BitBltRect@2
$LN38@BitBltRect@2:
  0044d	8b 55 dc	 mov	 edx, DWORD PTR _i$144450[ebp]
  00450	c1 e2 04	 shl	 edx, 4
  00453	8b 45 08	 mov	 eax, DWORD PTR _pRectList$[ebp]
  00456	8b 4c 10 04	 mov	 ecx, DWORD PTR [eax+edx+4]
  0045a	2b 4d f4	 sub	 ecx, DWORD PTR _outRect$[ebp+4]
  0045d	89 8d 58 ff ff
	ff		 mov	 DWORD PTR tv782[ebp], ecx
  00463	db 85 58 ff ff
	ff		 fild	 DWORD PTR tv782[ebp]
  00469	d8 4d c0	 fmul	 DWORD PTR _scaleY$144474[ebp]
  0046c	da 45 a4	 fiadd	 DWORD PTR _src$144466[ebp+4]
  0046f	dd 9d 5c ff ff
	ff		 fstp	 QWORD PTR tv369[ebp]
$LN39@BitBltRect@2:
  00475	dd 85 5c ff ff
	ff		 fld	 QWORD PTR tv369[ebp]
  0047b	e8 00 00 00 00	 call	 __ftol2_sse
  00480	89 45 b4	 mov	 DWORD PTR _or$144473[ebp+4], eax

; 310  :                 or.bottom=(LONG)min(src.bottom, scaleY*(pRectList[i].bottom-outRect.top)+src.top);

  00483	db 45 ac	 fild	 DWORD PTR _src$144466[ebp+12]
  00486	8b 55 dc	 mov	 edx, DWORD PTR _i$144450[ebp]
  00489	c1 e2 04	 shl	 edx, 4
  0048c	8b 45 08	 mov	 eax, DWORD PTR _pRectList$[ebp]
  0048f	8b 4c 10 0c	 mov	 ecx, DWORD PTR [eax+edx+12]
  00493	2b 4d f4	 sub	 ecx, DWORD PTR _outRect$[ebp+4]
  00496	89 8d 54 ff ff
	ff		 mov	 DWORD PTR tv793[ebp], ecx
  0049c	db 85 54 ff ff
	ff		 fild	 DWORD PTR tv793[ebp]
  004a2	d8 4d c0	 fmul	 DWORD PTR _scaleY$144474[ebp]
  004a5	da 45 a4	 fiadd	 DWORD PTR _src$144466[ebp+4]
  004a8	de d9		 fcompp
  004aa	df e0		 fnstsw	 ax
  004ac	f6 c4 41	 test	 ah, 65			; 00000041H
  004af	75 0b		 jne	 SHORT $LN40@BitBltRect@2
  004b1	db 45 ac	 fild	 DWORD PTR _src$144466[ebp+12]
  004b4	dd 9d 4c ff ff
	ff		 fstp	 QWORD PTR tv400[ebp]
  004ba	eb 28		 jmp	 SHORT $LN41@BitBltRect@2
$LN40@BitBltRect@2:
  004bc	8b 55 dc	 mov	 edx, DWORD PTR _i$144450[ebp]
  004bf	c1 e2 04	 shl	 edx, 4
  004c2	8b 45 08	 mov	 eax, DWORD PTR _pRectList$[ebp]
  004c5	8b 4c 10 0c	 mov	 ecx, DWORD PTR [eax+edx+12]
  004c9	2b 4d f4	 sub	 ecx, DWORD PTR _outRect$[ebp+4]
  004cc	89 8d 48 ff ff
	ff		 mov	 DWORD PTR tv805[ebp], ecx
  004d2	db 85 48 ff ff
	ff		 fild	 DWORD PTR tv805[ebp]
  004d8	d8 4d c0	 fmul	 DWORD PTR _scaleY$144474[ebp]
  004db	da 45 a4	 fiadd	 DWORD PTR _src$144466[ebp+4]
  004de	dd 9d 4c ff ff
	ff		 fstp	 QWORD PTR tv400[ebp]
$LN41@BitBltRect@2:
  004e4	dd 85 4c ff ff
	ff		 fld	 QWORD PTR tv400[ebp]
  004ea	e8 00 00 00 00	 call	 __ftol2_sse
  004ef	89 45 bc	 mov	 DWORD PTR _or$144473[ebp+12], eax

; 311  :                 or.right=(LONG)min(src.right, scaleX*(pRectList[i].right-outRect.left)+src.left);

  004f2	db 45 a8	 fild	 DWORD PTR _src$144466[ebp+8]
  004f5	8b 55 dc	 mov	 edx, DWORD PTR _i$144450[ebp]
  004f8	c1 e2 04	 shl	 edx, 4
  004fb	8b 45 08	 mov	 eax, DWORD PTR _pRectList$[ebp]
  004fe	8b 4c 10 08	 mov	 ecx, DWORD PTR [eax+edx+8]
  00502	2b 4d f0	 sub	 ecx, DWORD PTR _outRect$[ebp]
  00505	89 8d 44 ff ff
	ff		 mov	 DWORD PTR tv816[ebp], ecx
  0050b	db 85 44 ff ff
	ff		 fild	 DWORD PTR tv816[ebp]
  00511	d8 4d cc	 fmul	 DWORD PTR _scaleX$144477[ebp]
  00514	da 45 a0	 fiadd	 DWORD PTR _src$144466[ebp]
  00517	de d9		 fcompp
  00519	df e0		 fnstsw	 ax
  0051b	f6 c4 41	 test	 ah, 65			; 00000041H
  0051e	75 0b		 jne	 SHORT $LN42@BitBltRect@2
  00520	db 45 a8	 fild	 DWORD PTR _src$144466[ebp+8]
  00523	dd 9d 3c ff ff
	ff		 fstp	 QWORD PTR tv431[ebp]
  00529	eb 28		 jmp	 SHORT $LN43@BitBltRect@2
$LN42@BitBltRect@2:
  0052b	8b 55 dc	 mov	 edx, DWORD PTR _i$144450[ebp]
  0052e	c1 e2 04	 shl	 edx, 4
  00531	8b 45 08	 mov	 eax, DWORD PTR _pRectList$[ebp]
  00534	8b 4c 10 08	 mov	 ecx, DWORD PTR [eax+edx+8]
  00538	2b 4d f0	 sub	 ecx, DWORD PTR _outRect$[ebp]
  0053b	89 8d 38 ff ff
	ff		 mov	 DWORD PTR tv828[ebp], ecx
  00541	db 85 38 ff ff
	ff		 fild	 DWORD PTR tv828[ebp]
  00547	d8 4d cc	 fmul	 DWORD PTR _scaleX$144477[ebp]
  0054a	da 45 a0	 fiadd	 DWORD PTR _src$144466[ebp]
  0054d	dd 9d 3c ff ff
	ff		 fstp	 QWORD PTR tv431[ebp]
$LN43@BitBltRect@2:
  00553	dd 85 3c ff ff
	ff		 fld	 QWORD PTR tv431[ebp]
  00559	e8 00 00 00 00	 call	 __ftol2_sse
  0055e	89 45 b8	 mov	 DWORD PTR _or$144473[ebp+8], eax

; 312  : 
; 313  :                 StretchBlt(outDC, or.left, or.top,or.right-or.left, or.bottom-or.top,
; 314  :                     m_hBufferDC, pRectList[i].left, pRectList[i].top,
; 315  :                     pRectList[i].right-pRectList[i].left,
; 316  :                     pRectList[i].bottom-pRectList[i].top, SRCCOPY);

  00561	68 20 00 cc 00	 push	 13369376		; 00cc0020H
  00566	8b 55 dc	 mov	 edx, DWORD PTR _i$144450[ebp]
  00569	c1 e2 04	 shl	 edx, 4
  0056c	8b 45 dc	 mov	 eax, DWORD PTR _i$144450[ebp]
  0056f	c1 e0 04	 shl	 eax, 4
  00572	8b 4d 08	 mov	 ecx, DWORD PTR _pRectList$[ebp]
  00575	8b 75 08	 mov	 esi, DWORD PTR _pRectList$[ebp]
  00578	8b 54 11 0c	 mov	 edx, DWORD PTR [ecx+edx+12]
  0057c	2b 54 06 04	 sub	 edx, DWORD PTR [esi+eax+4]
  00580	52		 push	 edx
  00581	8b 45 dc	 mov	 eax, DWORD PTR _i$144450[ebp]
  00584	c1 e0 04	 shl	 eax, 4
  00587	8b 4d dc	 mov	 ecx, DWORD PTR _i$144450[ebp]
  0058a	c1 e1 04	 shl	 ecx, 4
  0058d	8b 55 08	 mov	 edx, DWORD PTR _pRectList$[ebp]
  00590	8b 75 08	 mov	 esi, DWORD PTR _pRectList$[ebp]
  00593	8b 44 02 08	 mov	 eax, DWORD PTR [edx+eax+8]
  00597	2b 04 0e	 sub	 eax, DWORD PTR [esi+ecx]
  0059a	50		 push	 eax
  0059b	8b 4d dc	 mov	 ecx, DWORD PTR _i$144450[ebp]
  0059e	c1 e1 04	 shl	 ecx, 4
  005a1	8b 55 08	 mov	 edx, DWORD PTR _pRectList$[ebp]
  005a4	8b 44 0a 04	 mov	 eax, DWORD PTR [edx+ecx+4]
  005a8	50		 push	 eax
  005a9	8b 4d dc	 mov	 ecx, DWORD PTR _i$144450[ebp]
  005ac	c1 e1 04	 shl	 ecx, 4
  005af	8b 55 08	 mov	 edx, DWORD PTR _pRectList$[ebp]
  005b2	8b 04 0a	 mov	 eax, DWORD PTR [edx+ecx]
  005b5	50		 push	 eax
  005b6	8b 4d 88	 mov	 ecx, DWORD PTR _this$[ebp]
  005b9	8b 11		 mov	 edx, DWORD PTR [ecx]
  005bb	52		 push	 edx
  005bc	8b 45 bc	 mov	 eax, DWORD PTR _or$144473[ebp+12]
  005bf	2b 45 b4	 sub	 eax, DWORD PTR _or$144473[ebp+4]
  005c2	50		 push	 eax
  005c3	8b 4d b8	 mov	 ecx, DWORD PTR _or$144473[ebp+8]
  005c6	2b 4d b0	 sub	 ecx, DWORD PTR _or$144473[ebp]
  005c9	51		 push	 ecx
  005ca	8b 55 b4	 mov	 edx, DWORD PTR _or$144473[ebp+4]
  005cd	52		 push	 edx
  005ce	8b 45 b0	 mov	 eax, DWORD PTR _or$144473[ebp]
  005d1	50		 push	 eax
  005d2	8b 4d d8	 mov	 ecx, DWORD PTR _outDC$144455[ebp]
  005d5	51		 push	 ecx
  005d6	ff 15 00 00 00
	00		 call	 DWORD PTR __imp__StretchBlt@44

; 317  : 
; 318  : 
; 319  : 
; 320  :                 m_ddsurface->ReleaseDC(outDC);

  005dc	8b 55 d8	 mov	 edx, DWORD PTR _outDC$144455[ebp]
  005df	52		 push	 edx
  005e0	8b 45 88	 mov	 eax, DWORD PTR _this$[ebp]
  005e3	8b 48 28	 mov	 ecx, DWORD PTR [eax+40]
  005e6	8b 55 88	 mov	 edx, DWORD PTR _this$[ebp]
  005e9	8b 42 28	 mov	 eax, DWORD PTR [edx+40]
  005ec	8b 09		 mov	 ecx, DWORD PTR [ecx]
  005ee	50		 push	 eax
  005ef	8b 51 40	 mov	 edx, DWORD PTR [ecx+64]
  005f2	ff d2		 call	 edx

; 321  : 
; 322  : 
; 323  :                 // Set alpha channel according to color key - we can't use Direct3D here, at least i found no way
; 324  :                 // read memory access seems to be slow .. so asm isn't much faster here
; 325  : 
; 326  :                 D3DLOCKED_RECT lr, ddlr;
; 327  :                 if(SUCCEEDED(m_ddsurface->LockRect(&ddlr, &or, D3DLOCK_READONLY )))

  005f4	6a 10		 push	 16			; 00000010H
  005f6	8d 45 b0	 lea	 eax, DWORD PTR _or$144473[ebp]
  005f9	50		 push	 eax
  005fa	8d 4d c4	 lea	 ecx, DWORD PTR _ddlr$144486[ebp]
  005fd	51		 push	 ecx
  005fe	8b 55 88	 mov	 edx, DWORD PTR _this$[ebp]
  00601	8b 42 28	 mov	 eax, DWORD PTR [edx+40]
  00604	8b 4d 88	 mov	 ecx, DWORD PTR _this$[ebp]
  00607	8b 51 28	 mov	 edx, DWORD PTR [ecx+40]
  0060a	8b 00		 mov	 eax, DWORD PTR [eax]
  0060c	52		 push	 edx
  0060d	8b 48 34	 mov	 ecx, DWORD PTR [eax+52]
  00610	ff d1		 call	 ecx
  00612	85 c0		 test	 eax, eax
  00614	0f 8c 28 01 00
	00		 jl	 $LN12@BitBltRect@2

; 328  :                 {
; 329  :                     if(SUCCEEDED(m_alphasurface->LockRect(&lr, &or, 0)))

  0061a	6a 00		 push	 0
  0061c	8d 55 b0	 lea	 edx, DWORD PTR _or$144473[ebp]
  0061f	52		 push	 edx
  00620	8d 45 d0	 lea	 eax, DWORD PTR _lr$144485[ebp]
  00623	50		 push	 eax
  00624	8b 4d 88	 mov	 ecx, DWORD PTR _this$[ebp]
  00627	8b 51 2c	 mov	 edx, DWORD PTR [ecx+44]
  0062a	8b 45 88	 mov	 eax, DWORD PTR _this$[ebp]
  0062d	8b 48 2c	 mov	 ecx, DWORD PTR [eax+44]
  00630	8b 12		 mov	 edx, DWORD PTR [edx]
  00632	51		 push	 ecx
  00633	8b 42 34	 mov	 eax, DWORD PTR [edx+52]
  00636	ff d0		 call	 eax
  00638	85 c0		 test	 eax, eax
  0063a	0f 8c ee 00 00
	00		 jl	 $LN11@BitBltRect@2

; 330  :                     {
; 331  :                         COLORREF colorkey=GetActiveOutput()->Overlay_GetColor();

  00640	e8 00 00 00 00	 call	 ?GetActiveOutput@@YAPAVIOutput@@XZ ; GetActiveOutput
  00645	89 85 34 ff ff
	ff		 mov	 DWORD PTR tv498[ebp], eax
  0064b	8b 8d 34 ff ff
	ff		 mov	 ecx, DWORD PTR tv498[ebp]
  00651	8b 11		 mov	 edx, DWORD PTR [ecx]
  00653	8b 8d 34 ff ff
	ff		 mov	 ecx, DWORD PTR tv498[ebp]
  00659	8b 42 34	 mov	 eax, DWORD PTR [edx+52]
  0065c	ff d0		 call	 eax
  0065e	89 45 9c	 mov	 DWORD PTR _colorkey$144491[ebp], eax

; 332  :                         colorkey=((colorkey&0xFF)<<16)|(colorkey&0xFF00)|((colorkey&0xFF0000)>>16);

  00661	8b 4d 9c	 mov	 ecx, DWORD PTR _colorkey$144491[ebp]
  00664	81 e1 ff 00 00
	00		 and	 ecx, 255		; 000000ffH
  0066a	c1 e1 10	 shl	 ecx, 16			; 00000010H
  0066d	8b 55 9c	 mov	 edx, DWORD PTR _colorkey$144491[ebp]
  00670	81 e2 00 ff 00
	00		 and	 edx, 65280		; 0000ff00H
  00676	0b ca		 or	 ecx, edx
  00678	8b 45 9c	 mov	 eax, DWORD PTR _colorkey$144491[ebp]
  0067b	25 00 00 ff 00	 and	 eax, 16711680		; 00ff0000H
  00680	c1 e8 10	 shr	 eax, 16			; 00000010H
  00683	0b c8		 or	 ecx, eax
  00685	89 4d 9c	 mov	 DWORD PTR _colorkey$144491[ebp], ecx

; 333  : 
; 334  :                         for (int nLine = 0; nLine < or.bottom-or.top; nLine++)

  00688	c7 45 98 00 00
	00 00		 mov	 DWORD PTR _nLine$144492[ebp], 0
  0068f	eb 09		 jmp	 SHORT $LN10@BitBltRect@2
$LN9@BitBltRect@2:
  00691	8b 4d 98	 mov	 ecx, DWORD PTR _nLine$144492[ebp]
  00694	83 c1 01	 add	 ecx, 1
  00697	89 4d 98	 mov	 DWORD PTR _nLine$144492[ebp], ecx
$LN10@BitBltRect@2:
  0069a	8b 55 bc	 mov	 edx, DWORD PTR _or$144473[ebp+12]
  0069d	2b 55 b4	 sub	 edx, DWORD PTR _or$144473[ebp+4]
  006a0	39 55 98	 cmp	 DWORD PTR _nLine$144492[ebp], edx
  006a3	7d 75		 jge	 SHORT $LN8@BitBltRect@2

; 335  :                         {
; 336  :                             DWORD *pPixel = (DWORD*)((BYTE*)lr.pBits + nLine * lr.Pitch );

  006a5	8b 45 98	 mov	 eax, DWORD PTR _nLine$144492[ebp]
  006a8	0f af 45 d0	 imul	 eax, DWORD PTR _lr$144485[ebp]
  006ac	03 45 d4	 add	 eax, DWORD PTR _lr$144485[ebp+4]
  006af	89 45 90	 mov	 DWORD PTR _pPixel$144496[ebp], eax

; 337  :                             DWORD *ddPixel = (DWORD*)((BYTE*)ddlr.pBits + nLine * ddlr.Pitch );

  006b2	8b 4d 98	 mov	 ecx, DWORD PTR _nLine$144492[ebp]
  006b5	0f af 4d c4	 imul	 ecx, DWORD PTR _ddlr$144486[ebp]
  006b9	03 4d c8	 add	 ecx, DWORD PTR _ddlr$144486[ebp+4]
  006bc	89 4d 94	 mov	 DWORD PTR _ddPixel$144499[ebp], ecx

; 338  :                             for (int nPixel = 0; nPixel < or.right-or.left; ++nPixel)

  006bf	c7 45 8c 00 00
	00 00		 mov	 DWORD PTR _nPixel$144502[ebp], 0
  006c6	eb 09		 jmp	 SHORT $LN7@BitBltRect@2
$LN6@BitBltRect@2:
  006c8	8b 55 8c	 mov	 edx, DWORD PTR _nPixel$144502[ebp]
  006cb	83 c2 01	 add	 edx, 1
  006ce	89 55 8c	 mov	 DWORD PTR _nPixel$144502[ebp], edx
$LN7@BitBltRect@2:
  006d1	8b 45 b8	 mov	 eax, DWORD PTR _or$144473[ebp+8]
  006d4	2b 45 b0	 sub	 eax, DWORD PTR _or$144473[ebp]
  006d7	39 45 8c	 cmp	 DWORD PTR _nPixel$144502[ebp], eax
  006da	7d 39		 jge	 SHORT $LN5@BitBltRect@2

; 339  :                             {
; 340  :                                 if(*ddPixel==colorkey)

  006dc	8b 4d 94	 mov	 ecx, DWORD PTR _ddPixel$144499[ebp]
  006df	8b 11		 mov	 edx, DWORD PTR [ecx]
  006e1	3b 55 9c	 cmp	 edx, DWORD PTR _colorkey$144491[ebp]
  006e4	75 0b		 jne	 SHORT $LN4@BitBltRect@2

; 341  :                                     *pPixel=0;

  006e6	8b 45 90	 mov	 eax, DWORD PTR _pPixel$144496[ebp]
  006e9	c7 00 00 00 00
	00		 mov	 DWORD PTR [eax], 0

; 342  :                                 else

  006ef	eb 10		 jmp	 SHORT $LN3@BitBltRect@2
$LN4@BitBltRect@2:

; 343  :                                     *pPixel=0xFF000000|*ddPixel;

  006f1	8b 4d 94	 mov	 ecx, DWORD PTR _ddPixel$144499[ebp]
  006f4	8b 11		 mov	 edx, DWORD PTR [ecx]
  006f6	81 ca 00 00 00
	ff		 or	 edx, -16777216		; ff000000H
  006fc	8b 45 90	 mov	 eax, DWORD PTR _pPixel$144496[ebp]
  006ff	89 10		 mov	 DWORD PTR [eax], edx
$LN3@BitBltRect@2:

; 344  :                                 pPixel++;

  00701	8b 4d 90	 mov	 ecx, DWORD PTR _pPixel$144496[ebp]
  00704	83 c1 04	 add	 ecx, 4
  00707	89 4d 90	 mov	 DWORD PTR _pPixel$144496[ebp], ecx

; 345  :                                 ddPixel++;

  0070a	8b 55 94	 mov	 edx, DWORD PTR _ddPixel$144499[ebp]
  0070d	83 c2 04	 add	 edx, 4
  00710	89 55 94	 mov	 DWORD PTR _ddPixel$144499[ebp], edx

; 346  :                             }

  00713	eb b3		 jmp	 SHORT $LN6@BitBltRect@2
$LN5@BitBltRect@2:

; 347  :                         }

  00715	e9 77 ff ff ff	 jmp	 $LN9@BitBltRect@2
$LN8@BitBltRect@2:

; 348  : 
; 349  :                         m_alphasurface->UnlockRect();

  0071a	8b 45 88	 mov	 eax, DWORD PTR _this$[ebp]
  0071d	8b 48 2c	 mov	 ecx, DWORD PTR [eax+44]
  00720	8b 55 88	 mov	 edx, DWORD PTR _this$[ebp]
  00723	8b 42 2c	 mov	 eax, DWORD PTR [edx+44]
  00726	8b 09		 mov	 ecx, DWORD PTR [ecx]
  00728	50		 push	 eax
  00729	8b 51 38	 mov	 edx, DWORD PTR [ecx+56]
  0072c	ff d2		 call	 edx
$LN11@BitBltRect@2:

; 350  :                     }
; 351  :                     m_ddsurface->UnlockRect();

  0072e	8b 45 88	 mov	 eax, DWORD PTR _this$[ebp]
  00731	8b 48 28	 mov	 ecx, DWORD PTR [eax+40]
  00734	8b 55 88	 mov	 edx, DWORD PTR _this$[ebp]
  00737	8b 42 28	 mov	 eax, DWORD PTR [edx+40]
  0073a	8b 09		 mov	 ecx, DWORD PTR [ecx]
  0073c	50		 push	 eax
  0073d	8b 51 38	 mov	 edx, DWORD PTR [ecx+56]
  00740	ff d2		 call	 edx
$LN12@BitBltRect@2:

; 352  :                 }
; 353  : 
; 354  :             }
; 355  : 
; 356  :         }
; 357  :         else

  00742	e9 80 00 00 00	 jmp	 $LN2@BitBltRect@2
$LN22@BitBltRect@2:

; 358  :         {
; 359  :             // outside or black vt output, just blit
; 360  :             BitBlt(hDstDC, pRectList[i].left, pRectList[i].top,
; 361  :                 pRectList[i].right - pRectList[i].left,
; 362  :                 pRectList[i].bottom - pRectList[i].top,
; 363  :                 m_hBufferDC, pRectList[i].left, pRectList[i].top, SRCCOPY);

  00747	68 20 00 cc 00	 push	 13369376		; 00cc0020H
  0074c	8b 45 dc	 mov	 eax, DWORD PTR _i$144450[ebp]
  0074f	c1 e0 04	 shl	 eax, 4
  00752	8b 4d 08	 mov	 ecx, DWORD PTR _pRectList$[ebp]
  00755	8b 54 01 04	 mov	 edx, DWORD PTR [ecx+eax+4]
  00759	52		 push	 edx
  0075a	8b 45 dc	 mov	 eax, DWORD PTR _i$144450[ebp]
  0075d	c1 e0 04	 shl	 eax, 4
  00760	8b 4d 08	 mov	 ecx, DWORD PTR _pRectList$[ebp]
  00763	8b 14 01	 mov	 edx, DWORD PTR [ecx+eax]
  00766	52		 push	 edx
  00767	8b 45 88	 mov	 eax, DWORD PTR _this$[ebp]
  0076a	8b 08		 mov	 ecx, DWORD PTR [eax]
  0076c	51		 push	 ecx
  0076d	8b 55 dc	 mov	 edx, DWORD PTR _i$144450[ebp]
  00770	c1 e2 04	 shl	 edx, 4
  00773	8b 45 dc	 mov	 eax, DWORD PTR _i$144450[ebp]
  00776	c1 e0 04	 shl	 eax, 4
  00779	8b 4d 08	 mov	 ecx, DWORD PTR _pRectList$[ebp]
  0077c	8b 75 08	 mov	 esi, DWORD PTR _pRectList$[ebp]
  0077f	8b 54 11 0c	 mov	 edx, DWORD PTR [ecx+edx+12]
  00783	2b 54 06 04	 sub	 edx, DWORD PTR [esi+eax+4]
  00787	52		 push	 edx
  00788	8b 45 dc	 mov	 eax, DWORD PTR _i$144450[ebp]
  0078b	c1 e0 04	 shl	 eax, 4
  0078e	8b 4d dc	 mov	 ecx, DWORD PTR _i$144450[ebp]
  00791	c1 e1 04	 shl	 ecx, 4
  00794	8b 55 08	 mov	 edx, DWORD PTR _pRectList$[ebp]
  00797	8b 75 08	 mov	 esi, DWORD PTR _pRectList$[ebp]
  0079a	8b 44 02 08	 mov	 eax, DWORD PTR [edx+eax+8]
  0079e	2b 04 0e	 sub	 eax, DWORD PTR [esi+ecx]
  007a1	50		 push	 eax
  007a2	8b 4d dc	 mov	 ecx, DWORD PTR _i$144450[ebp]
  007a5	c1 e1 04	 shl	 ecx, 4
  007a8	8b 55 08	 mov	 edx, DWORD PTR _pRectList$[ebp]
  007ab	8b 44 0a 04	 mov	 eax, DWORD PTR [edx+ecx+4]
  007af	50		 push	 eax
  007b0	8b 4d dc	 mov	 ecx, DWORD PTR _i$144450[ebp]
  007b3	c1 e1 04	 shl	 ecx, 4
  007b6	8b 55 08	 mov	 edx, DWORD PTR _pRectList$[ebp]
  007b9	8b 04 0a	 mov	 eax, DWORD PTR [edx+ecx]
  007bc	50		 push	 eax
  007bd	8b 4d 14	 mov	 ecx, DWORD PTR _hDstDC$[ebp]
  007c0	51		 push	 ecx
  007c1	ff 15 00 00 00
	00		 call	 DWORD PTR __imp__BitBlt@36
$LN2@BitBltRect@2:

; 364  : 
; 365  :         }
; 366  :     }

  007c7	e9 b8 f8 ff ff	 jmp	 $LN24@BitBltRect@2
$LN23@BitBltRect@2:

; 367  : 
; 368  :     if(VT_GetState()!=VT_BLACK)

  007cc	e8 00 00 00 00	 call	 ?VT_GetState@@YA?AW4eVTState@@XZ ; VT_GetState
  007d1	83 f8 01	 cmp	 eax, 1
  007d4	74 34		 je	 SHORT $LN1@BitBltRect@2

; 369  :     {
; 370  :         ((CD3D9Output *)GetActiveOutput())->pDevice->UpdateSurface(m_alphasurface, NULL, target, NULL);

  007d6	e8 00 00 00 00	 call	 ?GetActiveOutput@@YAPAVIOutput@@XZ ; GetActiveOutput
  007db	8b 90 cc 04 00
	00		 mov	 edx, DWORD PTR [eax+1228]
  007e1	89 95 30 ff ff
	ff		 mov	 DWORD PTR tv579[ebp], edx
  007e7	6a 00		 push	 0
  007e9	8b 45 10	 mov	 eax, DWORD PTR _target$[ebp]
  007ec	50		 push	 eax
  007ed	6a 00		 push	 0
  007ef	8b 4d 88	 mov	 ecx, DWORD PTR _this$[ebp]
  007f2	8b 51 2c	 mov	 edx, DWORD PTR [ecx+44]
  007f5	52		 push	 edx
  007f6	8b 85 30 ff ff
	ff		 mov	 eax, DWORD PTR tv579[ebp]
  007fc	50		 push	 eax
  007fd	8b 8d 30 ff ff
	ff		 mov	 ecx, DWORD PTR tv579[ebp]
  00803	8b 11		 mov	 edx, DWORD PTR [ecx]
  00805	8b 42 78	 mov	 eax, DWORD PTR [edx+120]
  00808	ff d0		 call	 eax
$LN1@BitBltRect@2:
$LN34@BitBltRect@2:

; 371  :     }
; 372  : }

  0080a	5e		 pop	 esi
  0080b	8b e5		 mov	 esp, ebp
  0080d	5d		 pop	 ebp
  0080e	c2 10 00	 ret	 16			; 00000010H
?BitBltRectsD3D@CPaintingHDC@@QAEXPAUtagRECT@@JPAUIDirect3DSurface9@@PAUHDC__@@@Z ENDP ; CPaintingHDC::BitBltRectsD3D
_TEXT	ENDS
PUBLIC	?UpdateGeometry@CPaintingHDC@@QAEHPAUHDC__@@PAUtagRECT@@H@Z ; CPaintingHDC::UpdateGeometry
; Function compile flags: /Odtp
;	COMDAT ?UpdateGeometry@CPaintingHDC@@QAEHPAUHDC__@@PAUtagRECT@@H@Z
_TEXT	SEGMENT
_this$ = -8						; size = 4
_bRecreated$ = -4					; size = 4
_hDC$ = 8						; size = 4
_pRect$ = 12						; size = 4
_bBufferTrim$ = 16					; size = 4
?UpdateGeometry@CPaintingHDC@@QAEHPAUHDC__@@PAUtagRECT@@H@Z PROC ; CPaintingHDC::UpdateGeometry, COMDAT
; _this$ = ecx

; 107  : {

  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

; 108  :     BOOL bRecreated = FALSE;

  00009	c7 45 fc 00 00
	00 00		 mov	 DWORD PTR _bRecreated$[ebp], 0

; 109  : 
; 110  :     if (m_hBufferDC != NULL)

  00010	8b 45 f8	 mov	 eax, DWORD PTR _this$[ebp]
  00013	83 38 00	 cmp	 DWORD PTR [eax], 0
  00016	74 7b		 je	 SHORT $LN12@UpdateGeom@2

; 111  :     {
; 112  :         if ((bBufferTrim != FALSE && (m_Rect.right != pRect->right ||
; 113  :             m_Rect.bottom != pRect->bottom)) || (bBufferTrim == FALSE &&
; 114  :             (m_Rect.right < pRect->right || m_Rect.bottom < pRect->bottom)))

  00018	83 7d 10 00	 cmp	 DWORD PTR _bBufferTrim$[ebp], 0
  0001c	74 1c		 je	 SHORT $LN9@UpdateGeom@2
  0001e	8b 4d f8	 mov	 ecx, DWORD PTR _this$[ebp]
  00021	8b 55 0c	 mov	 edx, DWORD PTR _pRect$[ebp]
  00024	8b 41 10	 mov	 eax, DWORD PTR [ecx+16]
  00027	3b 42 08	 cmp	 eax, DWORD PTR [edx+8]
  0002a	75 30		 jne	 SHORT $LN10@UpdateGeom@2
  0002c	8b 4d f8	 mov	 ecx, DWORD PTR _this$[ebp]
  0002f	8b 55 0c	 mov	 edx, DWORD PTR _pRect$[ebp]
  00032	8b 41 14	 mov	 eax, DWORD PTR [ecx+20]
  00035	3b 42 0c	 cmp	 eax, DWORD PTR [edx+12]
  00038	75 22		 jne	 SHORT $LN10@UpdateGeom@2
$LN9@UpdateGeom@2:
  0003a	83 7d 10 00	 cmp	 DWORD PTR _bBufferTrim$[ebp], 0
  0003e	75 53		 jne	 SHORT $LN12@UpdateGeom@2
  00040	8b 4d f8	 mov	 ecx, DWORD PTR _this$[ebp]
  00043	8b 55 0c	 mov	 edx, DWORD PTR _pRect$[ebp]
  00046	8b 41 10	 mov	 eax, DWORD PTR [ecx+16]
  00049	3b 42 08	 cmp	 eax, DWORD PTR [edx+8]
  0004c	7c 0e		 jl	 SHORT $LN10@UpdateGeom@2
  0004e	8b 4d f8	 mov	 ecx, DWORD PTR _this$[ebp]
  00051	8b 55 0c	 mov	 edx, DWORD PTR _pRect$[ebp]
  00054	8b 41 14	 mov	 eax, DWORD PTR [ecx+20]
  00057	3b 42 0c	 cmp	 eax, DWORD PTR [edx+12]
  0005a	7d 37		 jge	 SHORT $LN12@UpdateGeom@2
$LN10@UpdateGeom@2:

; 115  :         {
; 116  :             DeleteObject(SelectObject(m_hBufferDC, m_hSaveBmp));

  0005c	8b 4d f8	 mov	 ecx, DWORD PTR _this$[ebp]
  0005f	8b 51 30	 mov	 edx, DWORD PTR [ecx+48]
  00062	52		 push	 edx
  00063	8b 45 f8	 mov	 eax, DWORD PTR _this$[ebp]
  00066	8b 08		 mov	 ecx, DWORD PTR [eax]
  00068	51		 push	 ecx
  00069	ff 15 00 00 00
	00		 call	 DWORD PTR __imp__SelectObject@8
  0006f	50		 push	 eax
  00070	ff 15 00 00 00
	00		 call	 DWORD PTR __imp__DeleteObject@4

; 117  :             DeleteDC(m_hBufferDC);

  00076	8b 55 f8	 mov	 edx, DWORD PTR _this$[ebp]
  00079	8b 02		 mov	 eax, DWORD PTR [edx]
  0007b	50		 push	 eax
  0007c	ff 15 00 00 00
	00		 call	 DWORD PTR __imp__DeleteDC@4

; 118  :             m_hBufferDC = NULL;

  00082	8b 4d f8	 mov	 ecx, DWORD PTR _this$[ebp]
  00085	c7 01 00 00 00
	00		 mov	 DWORD PTR [ecx], 0

; 119  : 
; 120  :             ReleaseD3DBuffer();

  0008b	8b 4d f8	 mov	 ecx, DWORD PTR _this$[ebp]
  0008e	e8 00 00 00 00	 call	 ?ReleaseD3DBuffer@CPaintingHDC@@QAEXXZ ; CPaintingHDC::ReleaseD3DBuffer
$LN12@UpdateGeom@2:

; 121  :         }
; 122  :     }
; 123  : 
; 124  :     if (m_hBufferDC == NULL)

  00093	8b 55 f8	 mov	 edx, DWORD PTR _this$[ebp]
  00096	83 3a 00	 cmp	 DWORD PTR [edx], 0
  00099	0f 85 c2 00 00
	00		 jne	 $LN7@UpdateGeom@2

; 125  :     {
; 126  :         m_hBufferDC = CreateCompatibleDC(hDC);

  0009f	8b 45 08	 mov	 eax, DWORD PTR _hDC$[ebp]
  000a2	50		 push	 eax
  000a3	ff 15 00 00 00
	00		 call	 DWORD PTR __imp__CreateCompatibleDC@4
  000a9	8b 4d f8	 mov	 ecx, DWORD PTR _this$[ebp]
  000ac	89 01		 mov	 DWORD PTR [ecx], eax

; 127  : 
; 128  :         if (m_hBufferDC != NULL)

  000ae	8b 55 f8	 mov	 edx, DWORD PTR _this$[ebp]
  000b1	83 3a 00	 cmp	 DWORD PTR [edx], 0
  000b4	0f 84 a7 00 00
	00		 je	 $LN7@UpdateGeom@2

; 129  :         {
; 130  :             m_hBmp = CreateCompatibleBitmap(hDC, pRect->right, pRect->bottom);

  000ba	8b 45 0c	 mov	 eax, DWORD PTR _pRect$[ebp]
  000bd	8b 48 0c	 mov	 ecx, DWORD PTR [eax+12]
  000c0	51		 push	 ecx
  000c1	8b 55 0c	 mov	 edx, DWORD PTR _pRect$[ebp]
  000c4	8b 42 08	 mov	 eax, DWORD PTR [edx+8]
  000c7	50		 push	 eax
  000c8	8b 4d 08	 mov	 ecx, DWORD PTR _hDC$[ebp]
  000cb	51		 push	 ecx
  000cc	ff 15 00 00 00
	00		 call	 DWORD PTR __imp__CreateCompatibleBitmap@12
  000d2	8b 55 f8	 mov	 edx, DWORD PTR _this$[ebp]
  000d5	89 42 34	 mov	 DWORD PTR [edx+52], eax

; 131  : 
; 132  :             if (m_hBmp != NULL)

  000d8	8b 45 f8	 mov	 eax, DWORD PTR _this$[ebp]
  000db	83 78 34 00	 cmp	 DWORD PTR [eax+52], 0
  000df	74 39		 je	 SHORT $LN5@UpdateGeom@2

; 133  :             {
; 134  :                 m_hSaveBmp = SelectObject(m_hBufferDC, m_hBmp);

  000e1	8b 4d f8	 mov	 ecx, DWORD PTR _this$[ebp]
  000e4	8b 51 34	 mov	 edx, DWORD PTR [ecx+52]
  000e7	52		 push	 edx
  000e8	8b 45 f8	 mov	 eax, DWORD PTR _this$[ebp]
  000eb	8b 08		 mov	 ecx, DWORD PTR [eax]
  000ed	51		 push	 ecx
  000ee	ff 15 00 00 00
	00		 call	 DWORD PTR __imp__SelectObject@8
  000f4	8b 55 f8	 mov	 edx, DWORD PTR _this$[ebp]
  000f7	89 42 30	 mov	 DWORD PTR [edx+48], eax

; 135  : 
; 136  :                 if (m_hSaveBmp == NULL)

  000fa	8b 45 f8	 mov	 eax, DWORD PTR _this$[ebp]
  000fd	83 78 30 00	 cmp	 DWORD PTR [eax+48], 0
  00101	75 17		 jne	 SHORT $LN5@UpdateGeom@2

; 137  :                 {
; 138  :                     DeleteObject(m_hBmp);

  00103	8b 4d f8	 mov	 ecx, DWORD PTR _this$[ebp]
  00106	8b 51 34	 mov	 edx, DWORD PTR [ecx+52]
  00109	52		 push	 edx
  0010a	ff 15 00 00 00
	00		 call	 DWORD PTR __imp__DeleteObject@4

; 139  :                     m_hBmp = NULL;

  00110	8b 45 f8	 mov	 eax, DWORD PTR _this$[ebp]
  00113	c7 40 34 00 00
	00 00		 mov	 DWORD PTR [eax+52], 0
$LN5@UpdateGeom@2:

; 140  :                 }
; 141  :             }
; 142  : 
; 143  :             if (m_hBmp == NULL)

  0011a	8b 4d f8	 mov	 ecx, DWORD PTR _this$[ebp]
  0011d	83 79 34 00	 cmp	 DWORD PTR [ecx+52], 0
  00121	75 17		 jne	 SHORT $LN3@UpdateGeom@2

; 144  :             {
; 145  :                 DeleteDC(m_hBufferDC);

  00123	8b 55 f8	 mov	 edx, DWORD PTR _this$[ebp]
  00126	8b 02		 mov	 eax, DWORD PTR [edx]
  00128	50		 push	 eax
  00129	ff 15 00 00 00
	00		 call	 DWORD PTR __imp__DeleteDC@4

; 146  :                 m_hBufferDC = NULL;

  0012f	8b 4d f8	 mov	 ecx, DWORD PTR _this$[ebp]
  00132	c7 01 00 00 00
	00		 mov	 DWORD PTR [ecx], 0

; 147  :             }
; 148  :             else

  00138	eb 1f		 jmp	 SHORT $LN2@UpdateGeom@2
$LN3@UpdateGeom@2:

; 149  :             {
; 150  :                 m_Rect.right = pRect->right;

  0013a	8b 55 f8	 mov	 edx, DWORD PTR _this$[ebp]
  0013d	8b 45 0c	 mov	 eax, DWORD PTR _pRect$[ebp]
  00140	8b 48 08	 mov	 ecx, DWORD PTR [eax+8]
  00143	89 4a 10	 mov	 DWORD PTR [edx+16], ecx

; 151  :                 m_Rect.bottom = pRect->bottom;

  00146	8b 55 f8	 mov	 edx, DWORD PTR _this$[ebp]
  00149	8b 45 0c	 mov	 eax, DWORD PTR _pRect$[ebp]
  0014c	8b 48 0c	 mov	 ecx, DWORD PTR [eax+12]
  0014f	89 4a 14	 mov	 DWORD PTR [edx+20], ecx

; 152  :                 bRecreated = TRUE;

  00152	c7 45 fc 01 00
	00 00		 mov	 DWORD PTR _bRecreated$[ebp], 1
$LN2@UpdateGeom@2:

; 153  :             }
; 154  : 
; 155  :             CreateD3DBuffer();

  00159	8b 4d f8	 mov	 ecx, DWORD PTR _this$[ebp]
  0015c	e8 00 00 00 00	 call	 ?CreateD3DBuffer@CPaintingHDC@@AAEXXZ ; CPaintingHDC::CreateD3DBuffer
$LN7@UpdateGeom@2:

; 156  :         }
; 157  :     }
; 158  : 
; 159  :     if (m_hBufferDC != NULL)

  00161	8b 55 f8	 mov	 edx, DWORD PTR _this$[ebp]
  00164	83 3a 00	 cmp	 DWORD PTR [edx], 0
  00167	74 20		 je	 SHORT $LN1@UpdateGeom@2

; 160  :     {
; 161  :         m_hOriginalDC = hDC;

  00169	8b 45 f8	 mov	 eax, DWORD PTR _this$[ebp]
  0016c	8b 4d 08	 mov	 ecx, DWORD PTR _hDC$[ebp]
  0016f	89 48 04	 mov	 DWORD PTR [eax+4], ecx

; 162  : 
; 163  :         m_Rect.left = pRect->left;

  00172	8b 55 f8	 mov	 edx, DWORD PTR _this$[ebp]
  00175	8b 45 0c	 mov	 eax, DWORD PTR _pRect$[ebp]
  00178	8b 08		 mov	 ecx, DWORD PTR [eax]
  0017a	89 4a 08	 mov	 DWORD PTR [edx+8], ecx

; 164  :         m_Rect.top = pRect->top;

  0017d	8b 55 f8	 mov	 edx, DWORD PTR _this$[ebp]
  00180	8b 45 0c	 mov	 eax, DWORD PTR _pRect$[ebp]
  00183	8b 48 04	 mov	 ecx, DWORD PTR [eax+4]
  00186	89 4a 0c	 mov	 DWORD PTR [edx+12], ecx
$LN1@UpdateGeom@2:

; 165  :     }
; 166  : 
; 167  : 
; 168  :     return bRecreated;

  00189	8b 45 fc	 mov	 eax, DWORD PTR _bRecreated$[ebp]

; 169  : }

  0018c	8b e5		 mov	 esp, ebp
  0018e	5d		 pop	 ebp
  0018f	c2 0c 00	 ret	 12			; 0000000cH
?UpdateGeometry@CPaintingHDC@@QAEHPAUHDC__@@PAUtagRECT@@H@Z ENDP ; CPaintingHDC::UpdateGeometry
_TEXT	ENDS
PUBLIC	?EndPaint@CPaintingHDC@@QAEXXZ			; CPaintingHDC::EndPaint
; Function compile flags: /Odtp
;	COMDAT ?EndPaint@CPaintingHDC@@QAEXXZ
_TEXT	SEGMENT
tv66 = -8						; size = 4
_this$ = -4						; size = 4
?EndPaint@CPaintingHDC@@QAEXXZ PROC			; CPaintingHDC::EndPaint, COMDAT
; _this$ = ecx

; 87   : {

  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

; 88   :     if(GetActiveOutput()->Type() == IOutput::OUT_OVERLAY)

  00009	e8 00 00 00 00	 call	 ?GetActiveOutput@@YAPAVIOutput@@XZ ; GetActiveOutput
  0000e	89 45 f8	 mov	 DWORD PTR tv66[ebp], eax
  00011	8b 45 f8	 mov	 eax, DWORD PTR tv66[ebp]
  00014	8b 10		 mov	 edx, DWORD PTR [eax]
  00016	8b 4d f8	 mov	 ecx, DWORD PTR tv66[ebp]
  00019	8b 42 60	 mov	 eax, DWORD PTR [edx+96]
  0001c	ff d0		 call	 eax
  0001e	85 c0		 test	 eax, eax
  00020	75 1f		 jne	 SHORT $LN2@EndPaint

; 89   :     {
; 90   :         BitBltRects(&m_PaintRect, 1);

  00022	6a 00		 push	 0
  00024	6a 01		 push	 1
  00026	8b 4d fc	 mov	 ecx, DWORD PTR _this$[ebp]
  00029	83 c1 18	 add	 ecx, 24			; 00000018H
  0002c	51		 push	 ecx
  0002d	8b 4d fc	 mov	 ecx, DWORD PTR _this$[ebp]
  00030	e8 00 00 00 00	 call	 ?BitBltRects@CPaintingHDC@@QAEXPAUtagRECT@@JPAUHDC__@@@Z ; CPaintingHDC::BitBltRects

; 91   :         m_hOriginalDC = NULL;

  00035	8b 55 fc	 mov	 edx, DWORD PTR _this$[ebp]
  00038	c7 42 04 00 00
	00 00		 mov	 DWORD PTR [edx+4], 0

; 92   :     }
; 93   :     else

  0003f	eb 1f		 jmp	 SHORT $LN3@EndPaint
$LN2@EndPaint:

; 94   :     {
; 95   :         BitBltRectsD3D(&m_PaintRect, 1, ((CD3D9Output *)GetActiveOutput())->lpDDOSD);

  00041	6a 00		 push	 0
  00043	e8 00 00 00 00	 call	 ?GetActiveOutput@@YAPAVIOutput@@XZ ; GetActiveOutput
  00048	8b 80 d0 04 00
	00		 mov	 eax, DWORD PTR [eax+1232]
  0004e	50		 push	 eax
  0004f	6a 01		 push	 1
  00051	8b 4d fc	 mov	 ecx, DWORD PTR _this$[ebp]
  00054	83 c1 18	 add	 ecx, 24			; 00000018H
  00057	51		 push	 ecx
  00058	8b 4d fc	 mov	 ecx, DWORD PTR _this$[ebp]
  0005b	e8 00 00 00 00	 call	 ?BitBltRectsD3D@CPaintingHDC@@QAEXPAUtagRECT@@JPAUIDirect3DSurface9@@PAUHDC__@@@Z ; CPaintingHDC::BitBltRectsD3D
$LN3@EndPaint:

; 96   :     }
; 97   : }

  00060	8b e5		 mov	 esp, ebp
  00062	5d		 pop	 ebp
  00063	c3		 ret	 0
?EndPaint@CPaintingHDC@@QAEXXZ ENDP			; CPaintingHDC::EndPaint
_TEXT	ENDS
PUBLIC	?BeginPaint@CPaintingHDC@@QAEPAUHDC__@@PAU2@PAUtagRECT@@@Z ; CPaintingHDC::BeginPaint
; Function compile flags: /Odtp
;	COMDAT ?BeginPaint@CPaintingHDC@@QAEPAUHDC__@@PAU2@PAUtagRECT@@@Z
_TEXT	SEGMENT
_this$ = -4						; size = 4
_hDC$ = 8						; size = 4
_pRect$ = 12						; size = 4
?BeginPaint@CPaintingHDC@@QAEPAUHDC__@@PAU2@PAUtagRECT@@@Z PROC ; CPaintingHDC::BeginPaint, COMDAT
; _this$ = ecx

; 79   : {

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

; 80   :     UpdateGeometry(hDC, pRect);

  00007	6a 00		 push	 0
  00009	8b 45 0c	 mov	 eax, DWORD PTR _pRect$[ebp]
  0000c	50		 push	 eax
  0000d	8b 4d 08	 mov	 ecx, DWORD PTR _hDC$[ebp]
  00010	51		 push	 ecx
  00011	8b 4d fc	 mov	 ecx, DWORD PTR _this$[ebp]
  00014	e8 00 00 00 00	 call	 ?UpdateGeometry@CPaintingHDC@@QAEHPAUHDC__@@PAUtagRECT@@H@Z ; CPaintingHDC::UpdateGeometry

; 81   :     CopyRect(&m_PaintRect, pRect);

  00019	8b 55 0c	 mov	 edx, DWORD PTR _pRect$[ebp]
  0001c	52		 push	 edx
  0001d	8b 45 fc	 mov	 eax, DWORD PTR _this$[ebp]
  00020	83 c0 18	 add	 eax, 24			; 00000018H
  00023	50		 push	 eax
  00024	ff 15 00 00 00
	00		 call	 DWORD PTR __imp__CopyRect@8

; 82   :     return m_hBufferDC;

  0002a	8b 4d fc	 mov	 ecx, DWORD PTR _this$[ebp]
  0002d	8b 01		 mov	 eax, DWORD PTR [ecx]

; 83   : }

  0002f	8b e5		 mov	 esp, ebp
  00031	5d		 pop	 ebp
  00032	c2 08 00	 ret	 8
?BeginPaint@CPaintingHDC@@QAEPAUHDC__@@PAU2@PAUtagRECT@@@Z ENDP ; CPaintingHDC::BeginPaint
END
