Is D3DX undesirable?

Started by
36 comments, last by Mezz 18 years, 10 months ago
I do not even feel like I need to read a single post... although I did skim the first few.


D3DX is beautiful, a nice use when you are at a complete loss but I find 2 big problems with it:

- You should never use something if you do not understand at least how it works even at a basic level.
- No longer does D3DX compile static, it is dynamically linked, so for some people they will need your D3D9X_DLL or be forced to update since you cannot distro just that file without the whole 30mb distro. Annoying.


I am trying to and always have been to replace every instance of a D3DX function I can. Faster or not, at least my knowledge is highly developed.
Advertisement
Is it possible to share a vertexbuffer between multiple D3DXMesh and to let the mesh use the baseindex when drawing ? If not, I think that you can't use the mesh class then, because it could be slower than your own solution.
Quote:Original post by LarsMiddendorf
Is it possible to share a vertexbuffer between multiple D3DXMesh and to let the mesh use the baseindex when drawing ? If not, I think that you can't use the mesh class then, because it could be slower than your own solution.

That is a valid point, but it's worth baring in mind that it's rare that one size fits all. ID3DXMesh (and associated technologies) is probably good for the majority of uses, but it aint perfect!

For our engine I dropped all of the D3DX/D3D text rendering stuff as I could get about a 12x (~50fps -> ~1200fps) speed increase from taking advantage that I knew the domain in which it was being used and could customize/optimize to take advantage of this...

Jack

<hr align="left" width="25%" />
Jack Hoxley <small>[</small><small> Forum FAQ | Revised FAQ | MVP Profile | Developer Journal ]</small>

Quote:Original post by Halsafar
I do not even feel like I need to read a single post... although I did skim the first few.


D3DX is beautiful, a nice use when you are at a complete loss but I find 2 big problems with it:

- You should never use something if you do not understand at least how it works even at a basic level.
- No longer does D3DX compile static, it is dynamically linked, so for some people they will need your D3D9X_DLL or be forced to update since you cannot distro just that file without the whole 30mb distro. Annoying.


I am trying to and always have been to replace every instance of a D3DX function I can. Faster or not, at least my knowledge is highly developed.
Knowing how everyhting works is maybe desirable, but certainly not a necessity. For instance at work we've licensed a product to send SMS text messages. We have no interest in knowing how it does this. Similarly at my last job, the physics engine we used was Mathengine. I don't think many people knew much about collision detection at all; whether even the lead physics guy understood the special matrices it used to optimise PS2 performance is doubtable.
You wouldn't try to re-write the Windows functionality for dialogs etc. And why is it different to do your own versions of D3DX functions, but not the D3D ones? Do you plan to write your own interface to the hardware - I think not.
Quote:Original post by Halsafar
I do not even feel like I need to read a single post...
And yet you should have done, because if you had you would have realised that your second point is invalid. Please stop propagating misleading information.

Richard "Superpig" Fine - saving pigs from untimely fates - Microsoft DirectX MVP 2006/2007/2008/2009
"Shaders are not meant to do everything. Of course you can try to use it for everything, but it's like playing football using cabbage." - MickeyMouse

Chuck Walbourn (MS), just posted this on the DX Dev list:

Quote:
A D3DX DLL only redist with the required DirectXSetup files compresses
to about 1.4 Mbytes.


Obviously the user needs DX9c already, but I think 1.4MB should be workable for just about everyone.

Stay Casual,KenDrunken Hyena
Yes that is good, and a relief as I can finally update T2 using the latest SDK.
------------------------See my games programming site at: www.toymaker.info
I can name 7 games in development right at this point in time that are using D3DX and there are obviously a lot more than just I know of... so I wouldn't really call it undesirable as it is probably the most widely used library for PC/XBox.
All of you say that you don't use D3DX for platform incompability (pause) Please tell me, since when was DirectX cross-platform, do they have a new DirectX out, genericDX maybe?
A reason you might not want to use D3DX, is because you dont want people to require directX 9, but rather just use directX 8 --all XP machines have it.

Another reason is then it can work for both directX or OpenGL --look at the Ogre Engine?. You could probably have some ifdefs to achieve the same effect but... anyway

If you are writing your own versions its good practice (then you could know how to write it for something like java3d). You might be able to make a more well suited solution, a specific solution rather then a general one. It seems much like using the STD versions of things or making your own version, in most cases the STD will be better but there are times when it wont.
Insufficent Information: we need more infromationhttp://staff.samods.org/aiursrage2k/

This topic is closed to new replies.

Advertisement