Jump to content
  • Advertisement
Sign in to follow this  
Emil_Halim

Untitled

This topic is 4122 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Hi everybody I do want to aviod using d3dx9_30.dll with my library. and i use some functions from it such as D3DXMatrixTranslation , D3DXMatrixRotationYawPitchRoll ... here is my transformation part D3DXMATRIX World,Rot,Scl,Trns; D3DXMatrixRotationYawPitchRoll(&Rot,0,0,mRotate); D3DXMatrixTranslation(&Trns,mTransX-mhalfScreenWidth, mhalfScreenHeight-mTransY,0); D3DXMatrixScaling( &Scl, mScaleX,mScaleY,1); World = Rot * Scl * Trns; DX9Device->SetTransform( D3DTS_WORLD, &World); so where can i get the source code of D3DXMatrixRotationYawPitchRoll ,D3DXMatrixTranslation , and D3DXMatrixScaling any help please ?

Share this post


Link to post
Share on other sites
Advertisement
You can't get the actual source code, but there's equations for crating various matrices all over the Internet. However, the D3DX ones are optimised to use SSE, 3DNow! and other instructions where available.

Why don't you want to link to d3dx9_30.dll? It shouldn't be a problem really, and you can just distribute the DX runtime with your app for users who don't have it.

EDIT: Why are you doing this: D3DXMatrixRotationYawPitchRoll(&Rot,0,0,mRotate);? What's wrong with D3DXMatrixRotationZ?

Share this post


Link to post
Share on other sites
Quote:
Original post by Evil Steve

Why don't you want to link to d3dx9_30.dll?

EDIT: Why are you doing this: D3DXMatrixRotationYawPitchRoll(&Rot,0,0,mRotate);? What's wrong with D3DXMatrixRotationZ?



Really I want to reduce the number of dll's those my library relies on, also i do not need all functions of d3dx9_30.dll ,just using set matrix functions and load textures functions.

I will replace the load texture function with static FreeImage library , but still stuck with
set matrix functions.

no problem of using D3DXMatrixRotationZ , it is just explanaition code.

Share this post


Link to post
Share on other sites
The source code to the various D3DX functions, while generally trivial, isn't available publically, AFAIK.

Frankly, if you don't know how to implement these features, creating an application that does not use D3DX sounds out of your league.

If you're serious about this, now would be a good time to take a break, and learn some of the basics of linear algebra. Out of Jpetrie's list of recommended books, I think you could use a read of "Fundamentals of Computer Graphics" or "Geometry Toolbox" (or equivalent material online). That should provide you the base knowledge for performing pretty much anything D3DX does yourself.

Hope this helps.

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!