Search Results

Showing results 1 to 40 of 1000
Search took 0.07 seconds.
Search: Posts Made By: MattEvans
Forum: Game Development Jul 14th, 2009
Replies: 3
Views: 439
Posted By MattEvans
Read these articles:

http://chrishecker.com/Rigid_Body_Dynamics

You can probably ignore all of the rotational stuff, since a sphere is rotation-invariant.

You can get away with a very, very...
Forum: Game Development Jul 14th, 2009
Replies: 1
Views: 312
Posted By MattEvans
it's D3DCOLOR_XRGB.. (You have B and G the wrong way).
Forum: Game Development Jul 13th, 2009
Replies: 18
Views: 991
Posted By MattEvans
Heres a good starting point: http://www.riemers.net/eng/Tutorials/DirectX/C++/series1.php

unfortunately, the navigation of this site isn't obvious, the tutorial steps are in the 'contents' box on...
Forum: Game Development Jul 13th, 2009
Replies: 18
Views: 991
Posted By MattEvans
Yes, you can program in a Mac OS environment. I don't have any experience doing so, though.

Programming in a very cross-platform language like Python wouldn't be much different between win/mac. ...
Forum: Game Development Jul 13th, 2009
Replies: 18
Views: 991
Posted By MattEvans
When I first learnt, Basic (DOS and then Visual Basic) was the standard 'beginners' language. Python seems to be one of the beginners languages of today. Personally, I don't care much for Python, but...
Forum: Game Development Jul 13th, 2009
Replies: 18
Views: 991
Posted By MattEvans
Alternatively, get a good knowledge of the 2D, 3D, game mechanics and programming concepts in general, then you can take that to ANY programming language (within reason). You need to learn one...
Forum: Game Development Jul 6th, 2009
Replies: 3
Views: 541
Posted By MattEvans
You can use threads, I do: One thread for render calls, one thread for ai+physics+scripting. Both mutexed so only one entire update body runs at the same time, which isn't the most efficient way to...
Forum: Game Development Jul 5th, 2009
Replies: 9
Views: 525
Posted By MattEvans
Just FYI, the __vfptr = CXX0030 thing is because the debugger thinks that d3ddev is pointing to an actual instance of a D3D device, if there's some error in the call to CreateDevice, and for whatever...
Forum: Game Development Jul 5th, 2009
Replies: 9
Views: 525
Posted By MattEvans
The function call CreateDevice returns a HRESULT (error code), so do:

HRESULT result = CreateDevice (...);

the possible values are defined as D3D_OK, D3DERR_DEVICELOST, D3DERR_INVALIDCALL,...
Forum: Game Development Jul 5th, 2009
Replies: 9
Views: 525
Posted By MattEvans
Ah ok. There shouldn't be any problem with doing what you're doing from a DLL. I have only ever written DX applications that are staticly linked and DLLs that don't do anything DX, so I don't know...
Forum: Game Development Jul 4th, 2009
Replies: 9
Views: 525
Posted By MattEvans
Oh, and the reason that a D3DPRESENT_PARAMETERS object 'just works' is that the D3DPRESENT_PARAMETERS is a value (structure) type not a pointer type.

Learn this distinction ASAP.
Forum: Game Development Jul 4th, 2009
Replies: 9
Views: 525
Posted By MattEvans
You're just creating a pointer variable without actually setting it to anything, so what you're getting is 'worse' than a null pointer, it's a pointer to some random location. The message in the...
Forum: Game Development Jun 23rd, 2009
Replies: 3
Views: 582
Posted By MattEvans
What happens when you use the same mesh, different textures and no shader?

What you're doing looks right to me, assuming that all of your variables and functions are 'correct' with respect to what...
Forum: Game Development Jun 12th, 2009
Replies: 2
Views: 617
Posted By MattEvans
You call this function multiple times right? Via a timer callback or in a while loop with a sleep?

If so, you're not keeping the rect2 variable around: every time this function gets called the...
Forum: Game Development Jun 12th, 2009
Replies: 3
Views: 377
Posted By MattEvans
You can use GLUT (http://www.xmission.com/~nate/glut.html) or SDL (http://www.libsdl.org/) or other similar libraries, which basically abstract away the underlying OS windowing and input mechanisms...
Forum: Geeks' Lounge May 24th, 2009
Replies: 71
Views: 6,014
Posted By MattEvans
The machine uses 1 and 0 because it's easier to do binary arithmetic (in electronics) than denary arithmetic. 1 and 0 map very well to the intrinsic states 'on' and 'off'.

You can make bigger...
Forum: Game Development May 24th, 2009
Replies: 3
Views: 517
Posted By MattEvans
In DirectDraw (2D api) you could set pixels directly, I've not used either for a long time, and I'm pretty sure that DirectDraw was discontinued a while back.

This kind of thing is going to be the...
Forum: Game Development May 18th, 2009
Replies: 1
Views: 797
Posted By MattEvans
It's because you are using an orthographic projection, in an orthographic projection, a higher depth doesn't make objects appear smaller.

See : http://www.songho.ca/opengl/gl_projectionmatrix.html...
Forum: Game Development May 12th, 2009
Replies: 10
Views: 1,523
Posted By MattEvans
Matrix transforms are perhaps harder to initially understand than applying offsets and rotations directly to points, but it's IMO the 'right choice' to use matrices, because it makes everything in...
Forum: Game Development May 12th, 2009
Replies: 10
Views: 1,523
Posted By MattEvans
What kind of 2D library? Graphics, or physics? or something else?

I like this book alot, it says collision detection, but it also has a lengthly intro to many of the concepts of simulated 'space...
Forum: Game Development May 10th, 2009
Replies: 4
Views: 1,733
Posted By MattEvans
It's easy enough to arbitrarily set the rotation point, e.g. this will work:


case 'E':
case 'e':
{
//Rotation of the red square.
glMatrixMode(GL_MODELVIEW_MATRIX);...
Forum: Game Development May 8th, 2009
Replies: 4
Views: 1,733
Posted By MattEvans
You setup an orthographic projection matrix, and then in the pushmatrix/popmatrix block, you load a matrix in model space, this 'undoes' your projection until the matrix is popped...

You could...
Forum: Game Development Apr 17th, 2009
Replies: 5
Views: 660
Posted By MattEvans
#include <vector>
#include <iostream>

int main ( void )
{
std::vector < int > myvector;
for ( int i = 0; i != 10; ++i ) {
myvector.push_back ( i );
}
int * myarray = &( myvector...
Forum: Game Development Apr 15th, 2009
Replies: 5
Views: 660
Posted By MattEvans
Don't optimize too early. Use a vector if it's more convenient to do so. You'll probably find that you can have more points than any maximum you'd consider before the cost of occasionally resizing...
Forum: HTML and CSS Apr 12th, 2009
Replies: 5
Views: 671
Posted By MattEvans
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en" dir="ltr">

minor bug with...
Forum: Game Development Apr 11th, 2009
Replies: 6
Views: 850
Posted By MattEvans
You need to initialize each sampler uniform to the correct unit, usually you do that from host (C/C++/etc) code, I'm not sure how shader builder does that, if at all.

So, to test something for me,...
Forum: Game Development Apr 10th, 2009
Replies: 6
Views: 850
Posted By MattEvans
do you get a compile error ( use glGetShaderInfoLog ) ?

what code are you using to:

- generate, compile, and link the shader
- initialize the shader for each render pass
- render each pass
...
Forum: Game Development Apr 8th, 2009
Replies: 2
Solved: alleg.a library
Views: 543
Posted By MattEvans
You can't really modify the .a file, it contains already compiled code and symbols. You can however modify the source code and rebuild the library with whatever changes you need. Exactly how to do...
Forum: Game Development Apr 7th, 2009
Replies: 7
Views: 935
Posted By MattEvans
Look at OpenGL also, if you want to do 3D... Infact, I'd recommend doing 2D in OpenGL aswel, because SDL's drawing stuff isn't that great (it's good for getting a window to render OpenGL in, and it's...
Forum: Game Development Apr 6th, 2009
Replies: 7
Views: 935
Posted By MattEvans
Yep, SDL is a godsend.


Er, with USA and Japan being about the biggest producers and consumers of computer games... =P

There aren't many (high profile) 'current gen' or even 'last gen' games...
Forum: Game Development Apr 6th, 2009
Replies: 7
Views: 935
Posted By MattEvans
Probably because Linux isn't really seen as a gaming platform.. But I think that as it is being quite readily adopted as a home desktop PC platform right now, that this is going to change soonish.
...
Forum: Game Development Apr 6th, 2009
Replies: 4
Views: 1,341
Posted By MattEvans
Of course it is possible; there is necessarily always a projection from object>screen coords and there is always a projection from screen>a subset of object coords on a plane parallel with the view...
Forum: HTML and CSS Mar 24th, 2009
Replies: 32
Views: 3,071
Posted By MattEvans
Indeed.

But absolute positioning (I mean moving the displayed order of things while keeping the actual markup in a different order) is worse for a screenreader user than a (simple) table.. e.g.
...
Forum: HTML and CSS Mar 23rd, 2009
Replies: 32
Views: 3,071
Posted By MattEvans
That's a myth. Screenreaders aren't confused by tables, they just read them in a specific way. Weird markup order and other 'unusual' div constructs can confuse screenreaders just as much, sometimes...
Forum: C++ Mar 20th, 2009
Replies: 2
Views: 563
Posted By MattEvans
In your for loops, you are adding 2 to i and k. You probably want to add 1 to i and k, since your trying to get 2*i and 2*k-1, i.e the odds and evens... so it looks like you are skipping half of the...
Forum: Game Development Mar 20th, 2009
Replies: 12
Views: 992
Posted By MattEvans
use nodelay ( [yourscreen], true );, apparently, to make getch asynchronous (i.e. it will return even if no key is pressed).
Forum: Game Development Mar 20th, 2009
Replies: 1
Views: 1,023
Posted By MattEvans
Brute force isn't too bad.. you don't have to check every pair of pixels between the two sprites, you only have to check each pixel space to see if it's occupied twice, and that's not very costly (...
Forum: Game Development Mar 16th, 2009
Replies: 12
Views: 992
Posted By MattEvans
I've not used Gamemaker myself, but I'm quite aware of the setup. I think you might benefit from looking at SDL (http://www.libsdl.org/) rather than curses, it's got facility to create and work with...
Forum: Game Development Mar 16th, 2009
Replies: 12
Views: 992
Posted By MattEvans
Immediate follow up; if the 'co-ordinates on screen' are just derived from some other properties of the entity, then there's probably no need to store them anywhere... e.g. (in OpenGL) actual screen...
Forum: Game Development Mar 16th, 2009
Replies: 12
Views: 992
Posted By MattEvans
I can't think of an advantage of keeping coordinates outside of the entity, providing that you don't intend entities to be duplicated in the list. If you do intend that, it's better to split the...
Showing results 1 to 40 of 1000

 


About Us | Contact Us | Advertise | DaniWeb | Acceptable Use Policy | RSS Feed

©2003 - 2009 DaniWeb® LLC