Moving from Chili framework to making my own

The Partridge Family were neither partridges nor a family. Discuss.
Post Reply
Csharp
Posts: 7
Joined: December 12th, 2012, 12:34 pm

Moving from Chili framework to making my own

Post by Csharp » February 23rd, 2013, 1:43 pm

Hello I was hoping some of the more experienced can help me.

I've been trying to create my own framework for DirectX.

So far all I have is the blank screen.
and if I follow tutorials I can have a single triangle on screen and thats it.

I cannot understand where or how I put the code for the keyboard input, or where to draw to the screen.

I'm at this stage. pretty much.
http://www.directxtutorial.com/Lesson.a ... nid=11-4-3

Could someone help explain how I can get to the point where I have a seperate .cpp file for where I put all my drawing code, like in Chili's frame work.

User avatar
LuX
Posts: 1492
Joined: April 22nd, 2012, 12:33 pm
Location: Finland

Re: Moving from Chili framework to making my own

Post by LuX » March 2nd, 2013, 2:30 pm

You can have the drawing code where ever you like. What's important, is that you tell the framework properly how to draw and that you have access to it.

In the tutorial you have it seems at a quick glance that rendering will happen the "RenderFrame" function where it says so. I don't know for sure how dx11 works, but in dx9 you would have to lock "pBackBuffer" to a lockedRect where you can draw the pixels and then unlock and render.
ʕ •ᴥ•ʔ

Post Reply