Index: dxgltest/Tests3D.cpp |
— | — | @@ -1333,6 +1333,7 @@ |
1334 | 1334 | SendDlgItemMessage(hWnd,IDC_FOGEND,WM_SETTEXT,0,(LPARAM)_T("1.0"));
|
1335 | 1335 | SendDlgItemMessage(hWnd,IDC_FOGDENSITY,WM_SETTEXT,0,(LPARAM)_T("1.0"));
|
1336 | 1336 | SendDlgItemMessage(hWnd,IDC_SPINSTAGE,UDM_SETRANGE32,0,7);
|
| 1337 | + SendDlgItemMessage(hWnd,IDC_SPINALPHAREF,UDM_SETRANGE32,0,255);
|
1337 | 1338 | ::width = ddsd.dwWidth;
|
1338 | 1339 | ::height = ddsd.dwHeight;
|
1339 | 1340 | StartTimer(hWnd,WM_APP,60);
|
— | — | @@ -1347,6 +1348,8 @@ |
1348 | 1349 | number = _ttoi(tmpstring);
|
1349 | 1350 | if(number < 0) SendDlgItemMessage(hWnd,IDC_TEXSTAGE,WM_SETTEXT,0,(LPARAM)_T("0"));
|
1350 | 1351 | if(number > 7) SendDlgItemMessage(hWnd,IDC_TEXSTAGE,WM_SETTEXT,0,(LPARAM)_T("7"));
|
| 1352 | + if(number < 0) number = 0;
|
| 1353 | + if(number > 7) number = 7;
|
1351 | 1354 | texshaderstate.currentstage = number;
|
1352 | 1355 | _itot(texshaderstate.texstages[number].keycolor,tmpstring,16);
|
1353 | 1356 | strupper(tmpstring);
|
— | — | @@ -1572,6 +1575,31 @@ |
1573 | 1576 | IDC_DESTBLEND,CB_GETCURSEL,0,0)+1);
|
1574 | 1577 | }
|
1575 | 1578 | break;
|
| 1579 | + case IDC_ALPHATEST:
|
| 1580 | + if(HIWORD(wParam) == BN_CLICKED)
|
| 1581 | + {
|
| 1582 | + if(SendDlgItemMessage(hWnd,IDC_ALPHATEST,BM_GETCHECK,0,0) == BST_CHECKED)
|
| 1583 | + d3d7dev->SetRenderState(D3DRENDERSTATE_ALPHATESTENABLE,TRUE);
|
| 1584 | + else d3d7dev->SetRenderState(D3DRENDERSTATE_ALPHATESTENABLE,FALSE);
|
| 1585 | + }
|
| 1586 | + case IDC_ALPHAFUNC:
|
| 1587 | + if(HIWORD(wParam) == CBN_SELCHANGE)
|
| 1588 | + {
|
| 1589 | + d3d7dev->SetRenderState(D3DRENDERSTATE_ALPHAFUNC,SendDlgItemMessage(hWnd,
|
| 1590 | + IDC_ALPHAFUNC,CB_GETCURSEL,0,0)+1);
|
| 1591 | + }
|
| 1592 | + break;
|
| 1593 | + case IDC_ALPHAREF:
|
| 1594 | + if(HIWORD(wParam) == EN_CHANGE)
|
| 1595 | + {
|
| 1596 | + SendDlgItemMessage(hWnd,IDC_ALPHAREF,WM_GETTEXT,MAX_PATH,(LPARAM)tmpstring);
|
| 1597 | + number = _ttoi(tmpstring);
|
| 1598 | + if(number < 0) SendDlgItemMessage(hWnd,IDC_ALPHAREF,WM_SETTEXT,0,(LPARAM)_T("0"));
|
| 1599 | + if(number > 255) SendDlgItemMessage(hWnd,IDC_ALPHAREF,WM_SETTEXT,0,(LPARAM)_T("255"));
|
| 1600 | + if(number < 0) number = 0;
|
| 1601 | + if(number > 255) number = 255;
|
| 1602 | + if(d3d7dev) d3d7dev->SetRenderState(D3DRENDERSTATE_ALPHAREF,number);
|
| 1603 | + }
|
1576 | 1604 | case IDC_COLORKEY:
|
1577 | 1605 | if(HIWORD(wParam) == BN_CLICKED)
|
1578 | 1606 | {
|
Index: . |
Property changes on: . |
___________________________________________________________________ |
Modified: svn:ignore |
## -10,3 +10,4 ## |
1579 | 1607 | enc_temp_folder |
1580 | 1608 | *.vcxproj.user |
1581 | 1609 | Debug No MSVCRT |
| 1610 | +pingme.txt |