Jump to content

  • Log In with Google      Sign In   
  • Create Account


Good DirectX 11 tutorial/book?


Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.

  • You cannot reply to this topic
8 replies to this topic

#1 HKei   Members   -  Reputation: 106

Like
0Likes
Like

Posted 14 August 2012 - 01:21 PM

I've seen one that seemed ok, but covered very little material. Then there's the rastertek ones... Are these any good? My first impression of them is rather meh because of all that framework stuff that really just seems to delay the point, and of course code that has

///////////////////////////////////////////////////////////////////////
// THIS IS A COMMENT
//////////////////////////////////////////////////////////////////////
// THE ABOVE WAS A COMMENT
//////////////////////////////////////////////////////////////////////

style comments. And then there's the examples in the SDK that are for some reason labeled tutorials. I read a bit about graphics programming before so I could mostly figure out what the program generally did, but then there's stuff like

D3D11_INPUT_ELEMENT_DESC layout[] =
    {
	    { "POSITION", 0, DXGI_FORMAT_R32G32B32_FLOAT, 0, 0, [b]D3D11_INPUT_PER_VERTEX_DATA[/b], 0 }, //what's that?
    };

Let's look it up in the docs!

D3D11_INPUT_PER_VERTEX_DATA
Input data is per-vertex data.
D3D11_INPUT_PER_INSTANCE_DATA
Input data is per-instance data.


Gee thanks, that was very helpful. Maybe the info is in D3D11_INPUT_ELEMENT_DESC?

InputSlotClass
Type: D3D11_INPUT_CLASSIFICATION
Identifies the input data class for a single input slot (see D3D11_INPUT_CLASSIFICATION).


This is probably trivial to all you guys that have years of experience in professional fields, but I'm just a hobbyist. While I do have a solid understanding of C++ and programming in general, I just can't seem to get into graphics programming because all the resources I find are either directed at complete beginners and don't go into any depth at all, or apparently require that you already have a very good understanding of graphics programming. If there's something I'm missing, I'd be glad to be corrected on that one.

Sponsor:

#2 Ripiz   Members   -  Reputation: 529

Like
0Likes
Like

Posted 14 August 2012 - 01:53 PM

I feel MSDN explanation is enough.

D3D11_INPUT_PER_VERTEX_DATA
Input data is per-vertex data.

Just means data will belong to each vertex; as specified in your layout, each vertex will have own POSITION.

While

D3D11_INPUT_PER_INSTANCE_DATA
Input data is per-instance data.

means there's some data that belong to an instance; lets say you want to draw 2 boxes which are identical, but they're at different positions, so you create per instance data, which specifies position of each cube, and you'll end up drawing 2 cubes with single draw call. Lets say your cube has 8 vertexes, then vertex shader will process:

vertex0 instance0
vertex1 instance0
...
vertex7 instance0
vertex0 instance1
vertex1 instance1
...
vertex7 instance1


Edited by Ripiz, 14 August 2012 - 01:55 PM.


#3 greenvertex   Members   -  Reputation: 510

Like
0Likes
Like

Posted 14 August 2012 - 02:04 PM

Have you read the companion help documentation for DX11 tutorials 1 - 7? I believe they first cover the per vertex input format in Tutorial 02. Per instance is a bit of an optimization and isn't really covered in those AFAIK. It's basically a way to pass an object to be rendered many times, and a series of transforms that apply to each instance of that object.

#4 Jeffreyp   Members   -  Reputation: 178

Like
0Likes
Like

Posted 14 August 2012 - 02:08 PM

If you really want an in depth book of directX 11 i recommend Introduction to 3D Game Programming with DirectX 11.
I own it and it is really good. You also got Practical Rendering and Computation with Direct3D 11.
I heard it is good but i don't own it so i can't make a judgement.
If you are not looking for a book but for a website i can recommend www.directxtutorial.com.
I got a membership there and he explains it very well but the site isn't updated very often.
Rastertek is a nice free website which got a lot of tutorials. But in my opinion he doesn't explain it very well.
But it is a really good website because it is free.

I hope this helps you : )

Edited by Jeffreyp, 14 August 2012 - 02:11 PM.


#5 riverreal   Members   -  Reputation: 616

Like
0Likes
Like

Posted 14 August 2012 - 02:35 PM

I prefer this one: http://www.rastertek.com/tutdx11.html

#6 HKei   Members   -  Reputation: 106

Like
0Likes
Like

Posted 14 August 2012 - 04:09 PM

@riverreal - that's exactly the one I was talking about. It seems to cover a lot of stuff so I thought it might be worth looking into it, but the framework chapter was already very offputting. At least for me. So you say it's worth sticking around despite that?

#7 SimLabDevelopments   Members   -  Reputation: 197

Like
0Likes
Like

Posted 15 August 2012 - 02:30 PM

An Introduction to 3D Game Programming with DirectX 11 for the nitty gritty details. Game Coding Complete, 4th Edition for the architectural discussions. And the Rastertek tutorials for a straightforward, easy to understand tutorial.

I'm working my way through the Rastertek tutorials right now. While the style of code is perhaps not to taste, you shouldn't be taking the code samples verbatim anyway. I'm taking the information presented in the tutorials and rewriting it into my code, which has an architecture inspired by Game Coding Complete. This effectively removes the reliance on DXUT that Game Coding Complete has, all the while increasing my understanding of DirectX11. I'm not sure what more you are looking for, honestly.

#8 riverreal   Members   -  Reputation: 616

Like
0Likes
Like

Posted 15 August 2012 - 02:43 PM

@riverreal - that's exactly the one I was talking about. It seems to cover a lot of stuff so I thought it might be worth looking into it, but the framework chapter was already very offputting. At least for me. So you say it's worth sticking around despite that?

Just think the framework is a tool only for the tutorial. So, if you want to make a game, don't use that framework. Make your own framework/engine.
The framework becomes better each chapter. The tutorial seems to be a "How to make a DirectX11 Framework".
After finishing it, you can try one of the books mentioned above.
I think Practical Rendering and Computation with Direct3D 11, is a good book. You can also download the source code of the Hieroglyph 3 rendering engine, and learn about engine making.

#9 CdrTomalak   Members   -  Reputation: 271

Like
0Likes
Like

Posted 16 August 2012 - 08:23 AM

I'm reading this: http://www.amazon.co.uk/Beginning-Directx-11-Game-Programming/dp/1435458958/ref=sr_1_2?ie=UTF8&qid=1345126856&sr=8-2

I found it to clearly explain the principles of DX, and the changes from earlier versions through v9 right up to v11. As I'm a C# coder using SlimDX I've had to combine this book with on-line tutorials, but it's handy to have all the DX principles in one place.

I think it's likely that you'll always need the combination of a good programming holy book plus on-line resources. Feel free to message me about anything if you need to and good luck! 8D




Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.



PARTNERS