Testing if a D3DXMATRIX is NULL

Started by
5 comments, last by nick5454 20 years, 11 months ago
How would I do that, i guess I would do an operator overload but not sure. I just want to be able to see if it has been intialized with values
Advertisement
you mean an identity matrix? try D3DXMatrixIsIdentity.
The D3DXMATRIX class, i think its a class. maybe a structure but I think its a class.
D3DXMatrix Example;if(D3DXMatrixIsIdentity(&Example))   // is an identity matrix, not sure if constructor initializes 


Well I have this

D3DXMATRIX test;

if ( m_bRotateX )
D3DXMatrixRotateX(&test,radAngle);

then later

...

if ( test != NULL )
... do something ...

but the problem is it doesn''t accept null because its numerical. Maybe I should do

if ( &test != NULL )

is that right
umm no, local variables can''t be destroyed lke that. test is gaurenteed to exist when you check it for null, and passing the address will always pass because it always exists.
I''m not trying to destroy them I just want to know if I have passed data to it yet. thats all

This topic is closed to new replies.

Advertisement