Simplification of the code

Started by
0 comments, last by circlesoft 19 years, 1 month ago
Yo, I have grasped some of the Direct-X concepts a bit (that meaning I got how to create a window with nothing in it) But since my friends are just starting out with the Direct-X, and the fact that we are going to individually create builds that will have large code segments updated, I was wondering if there was a way to do "simple code". If you notice how Direct-X is extremely complex, like the multitude of code files, general syntax, is there a way to make the code legible and more understandable? I'm not talking about newbie code like "display a window", but something that would create a simple aspect to the code. So is there a method like that, or is there a game library that is similar to that? P.S. Can anyone tell me how to correctly parse and display .x or .obj files in Direct-X? The API is not very explanetory.
Advertisement
If you want simplify the code, I suggest that you write your own wrapper for it. This can effectively hide the implementation of many tedious things. It also stores all of these operations, so you can reuse them in all of your projects. For example, you could make a CreateWindow() function that generalizes the process of instantiating a window.

In essence, you would be creating your own small engine. There are many code bases out there that already do this, though. Probably one of the best comes with the DXSDK itself, in the form of the Sample Framework. It's a great library to base small applications off of. Make sure that you get one of the latest versions of the SDK, because it has recently experienced a major face lift [smile]

Quote:Can anyone tell me how to correctly parse and display .x or .obj files in Direct-X? The API is not very explanetory.

There are many tutorials that can guide you through this process. One of them is included with the SDK (it's "Tutorial #6: Meshes", I believe). There is another good one over at Andy Pike. Also, the Sample Framework that I mentioned above implements a pretty good wrapper of X files.
Dustin Franklin ( circlesoft :: KBase :: Mystic GD :: ApolloNL )

This topic is closed to new replies.

Advertisement