Click here to Skip to main content
15,914,160 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: Probelm when window close Pin
Anthony_Yio3-Nov-03 20:35
Anthony_Yio3-Nov-03 20:35 
GeneralDirectX stipple lines Pin
mikeh3-Nov-03 7:52
mikeh3-Nov-03 7:52 
GeneralRe: DirectX stipple lines Pin
Jeryth3-Nov-03 10:25
Jeryth3-Nov-03 10:25 
GeneralRe: DirectX stipple lines Pin
mikeh3-Nov-03 10:54
mikeh3-Nov-03 10:54 
GeneralRe: DirectX stipple lines Pin
Jeryth3-Nov-03 11:54
Jeryth3-Nov-03 11:54 
GeneralRe: DirectX stipple lines Pin
Jeryth3-Nov-03 14:32
Jeryth3-Nov-03 14:32 
GeneralRe: DirectX stipple lines Pin
ZoogieZork3-Nov-03 18:18
ZoogieZork3-Nov-03 18:18 
GeneralRe: DirectX stipple lines Pin
mikeh4-Nov-03 3:05
mikeh4-Nov-03 3:05 
Thanks to both of you for your replies.

I'm currently using the 9.0b (4.09.0000.0902) SDK. I assumed this was the most current. It appears now it might not be. As for a code snippet, the following is the "guts" of the routine that renders the lines:

================================
void draw_line_strip_dx(int numpts, p_3d pts[], MC_BYTE color)
{
D3DXMATRIX worldMatrix;
D3DXMATRIX viewMatrix;
D3DXMATRIX projectionMatrix;
D3DXMATRIX resultMatrix;
D3DXVECTOR3* pVertices=NULL;
BYTE r = GetRValue(Wd_colors[color]);
BYTE g = GetGValue(Wd_colors[color]);
BYTE b = GetBValue(Wd_colors[color]);
D3DCOLOR vcolor = D3DCOLOR_XRGB(r,g,b);

pVertices = new D3DXVECTOR3[numpts];
for (int n=0; n<numpts; ++n)
="" {
="" pvertices[n].x="pts[n][X];
" pvertices[n].y="pts[n][Y];
" pvertices[n].z="pts[n][Z];
" }

="" get="" world,="" view="" and="" projection="" matrices.
="" pdirect3ddevice-="">GetTransform(D3DTS_WORLD, &worldMatrix);
pDirect3DDevice->GetTransform(D3DTS_VIEW, &viewMatrix);
pDirect3DDevice->GetTransform(D3DTS_PROJECTION, &projectionMatrix);
// create a transform: world * view * projection.
D3DXMatrixIdentity(&resultMatrix);
D3DXMatrixMultiply(&resultMatrix, &worldMatrix, &viewMatrix);
D3DXMatrixMultiply(&resultMatrix, &resultMatrix, &projectionMatrix);

// render line strip.
pDirect3DDevice->BeginScene();
pDirect3DLine->Begin();
pDirect3DLine->DrawTransform(pVertices, numpts, &resultMatrix, vcolor);
pDirect3DLine->End();
pDirect3DDevice->EndScene();

// clean up.
delete pVertices;
}
================================

I've also updated my drivers. It did not help. I'm going to take a look at updating to the "Summer SDK".

Gort...Klaatu, Barada Nikto!
GeneralRe: DirectX stipple lines Pin
mikeh6-Nov-03 2:18
mikeh6-Nov-03 2:18 
GeneralGetFolderFromID() from Namespace Pin
chz171065xy3-Nov-03 7:27
chz171065xy3-Nov-03 7:27 
Generalgetline question Pin
Anonymous3-Nov-03 7:27
Anonymous3-Nov-03 7:27 
GeneralRe: getline question Pin
Alton Williams3-Nov-03 7:56
Alton Williams3-Nov-03 7:56 
GeneralRe: getline question Pin
Anonymous3-Nov-03 9:58
Anonymous3-Nov-03 9:58 
GeneralRe: getline question Pin
Joaquín M López Muñoz3-Nov-03 10:04
Joaquín M López Muñoz3-Nov-03 10:04 
GeneralRe: getline question Pin
Jeryth3-Nov-03 10:13
Jeryth3-Nov-03 10:13 
GeneralPorting from WinCE to VC++ Pin
VanHlebar3-Nov-03 7:18
VanHlebar3-Nov-03 7:18 
GeneralGetFolderFromID() from Namespace Pin
johnxx3-Nov-03 6:47
johnxx3-Nov-03 6:47 
GeneralDefault name file in serialization Pin
doctorpi3-Nov-03 5:37
doctorpi3-Nov-03 5:37 
GeneralRe: Default name file in serialization Pin
Markyg3-Nov-03 10:34
Markyg3-Nov-03 10:34 
Generalvector and delete Pin
ns3-Nov-03 5:32
ns3-Nov-03 5:32 
GeneralRe: vector and delete Pin
valikac3-Nov-03 5:44
valikac3-Nov-03 5:44 
GeneralRe: vector and delete Pin
ns3-Nov-03 5:54
ns3-Nov-03 5:54 
GeneralRe: vector and delete Pin
jhwurmbach3-Nov-03 6:32
jhwurmbach3-Nov-03 6:32 
GeneralRe: vector and delete Pin
ns3-Nov-03 7:52
ns3-Nov-03 7:52 
GeneralRe: vector and delete Pin
TFrancis3-Nov-03 8:42
TFrancis3-Nov-03 8:42 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.