Abstracting away DirectX, OpenGL, etc.

Started by
9 comments, last by NathanRidley 10 years, 5 months ago

As the others have mentioned several times, I would also suggest tackling one of the APIs at a time. If you can write a renderer in one API, then another renderer using the other API, then you will be moderately equipped to design a system for putting the two together. Also, keep in mind that your designs will surely evolve as you tackle different challenges, so don't be afraid to experiment and shake things up. Especially if this is a hobby project - don't limit yourself right out of the gate, but rather challenge yourself to make some big steps in the design!

Agreed, and I have sort of come to this conclusion as well. I wouldn't explicitly call what I'm doing a hobby project, as I'd like to do it commrcially, full time in the future, but I have a lot of learning to do first.

I was very similar to you. When I first started using Direct X 7, I wanted to create an abstraction layer so I'd later be able to support other things, maybe even other OS. Well I still think this is a good idea, at the time I was new to graphics programing and just learning DX 7 was a huge task for me. I never ended up supporting any other API, and when I moved to DX8, I scrapped most of the code anyway. (FYI, first attempts usually suck.)

Now that I've written like 5 or 6 different 3D engines, I've finally think I have enough knowledge to do a multiplatform framework. It's working well, but after I finish this game, I'll probably redesign it yet again.

They say, figuratively, that you do everything at least three times; once to learn how to do it, once to do it, and once to do it properly. The third stage is probably more of an endless series of improvements and rewrites, but such as life in the world of development. I've been through this process repeatedly in web and application development, but 3D graphics programming is a whole new ball game, so it's back to the drawing board, to a large degree.

This topic is closed to new replies.

Advertisement