Jump to content

  • Log In with Google      Sign In   
  • Create Account


Member Since 13 Dec 2009
Offline Last Active Jun 22 2012 12:43 PM

Posts I've Made

In Topic: What is the best method for planet generation in a playable game(if any)?

16 June 2012 - 12:07 PM

If you want to start from scratch to create a workable planetary renderer, over summer, without knowing whether you're going to use OpenGL, DirectX, etc, etc, good luck, you'll need it. Just as a frame of reference, my current planetary renderer achieves around ~350fps in 'space' with the planet taking up most of the screen and maintains around 200fps at the surface. I still need to optimise my CPU throughput more than anything, though profiling has proved difficult with CodeAnalyst, so for now I'm focusing on expanding the project. I used six quadtree faces forming a cube, mapped to a sphere to form the planet in conjunction with GPU based heightmap, normalmap generation. If you need any help, ask, but I assure you this will be no small task. I'm sure you've seen it already, but if not check out the Infinity project for more ideas.

In Topic: The C++ Error challenge

10 November 2011 - 03:06 PM

It took me about 2 minutes, probably slightly less, I was looking for even worse errors, but yeah, turned out to be simple. I've been programming in C++ solely for roughly 2 years, though I have yet to accomplish anything. ;D

In Topic: Scripted GUIs

30 August 2011 - 10:04 AM

In my opinion, based on what you're saying, you want to use Awesomium, essentially, that should give you all you need. You can use both HTML and CSS with the Webkit library to get the kind of customisation you're looking for. Heres a couple of links to the GUI of a guy who did just that:


NOTE: I haven't tried this yet, but I will be doing so soon, so I don't know how easy this is to pull off. You could

In Topic: Error checking/handling - at which level?

28 August 2011 - 04:43 PM

That's the way Direct3D does it for example, very nice. Definitely the best option I think if you're going for an engine, I'm writing a game, though, so I'm not sure if I want to be this 'general' with my functions (which would be perfect for an engine of course) - basically, I think I can afford to be more specialized. Errors are displayed in a messagebox and logged in the console window, they'll shut the game down if they were fatal too.

Am I right in thinking there's a difference in that regard between an engine and an actual game project? Or should I just go with the engine approach anyways?

Well, for one thing, you really shouldn't be tieing that kind of functionality to your error handling. What you want to do is make sure that the errors propagate up your hierarchy to your highest class, I.E your Framework class, which will probably just quit the program. You shouldn't have low level classes ending your game, for whatever reason. At most, you should use an exception handling system, wherein, again, the framework class is the class that does the heavy lifting. Why should an object know how to end the game? At least, this is what approach it seems you're using from what you said.

In Topic: The camera, it's defeating me!

21 August 2011 - 02:30 PM

Directx11 requires the transposed matrices passed to it, it doesn't look like you're doing that. So in your shader, change this:

    // Transform the position from object space to homogeneous projection space
    Output.Position = mul( input.Position, g_mWorldViewProjection );

to this

    // Transform the position from object space to homogeneous projection space
    Output.Position = mul( input.Position, transpose(g_mWorldViewProjection) );

I get called away to help a friend clear a field, a full day's work, and I come back to an immediate answer? Instant Karma!!!

This was the answer, it works great!. Thank you so much, Snail Coder.

Also, that was just a quick fix, you really should be passing the matrices already transposed to the shader, simply use:


Transposing matrices per vertex per frame isn't really good for performance or necessary :P. Oh, and could I have some rep? :D I'm pretty low as you can see...