Advertisement Jump to content
  • Advertisement


  • Content Count

  • Joined

  • Last visited

Community Reputation

462 Neutral

About fais

  • Rank

Recent Profile Visitors

The recent visitors block is disabled and is not being shown to other users.

  1. If you are looking to determine the inertia tensor of a rigid body object by summing up different masses/components, then there is a way. It is called the parallel axis theorem (I believe, It has been several years since I last looked into it) The idea is to find the inertia of a complex shape by breaking it down into simpler shapes with known properties (cubes, spheres, cones, etc) and then summing them up in a way analogous to summing up the different CoGs.  A good book that covers it is the O'Reilly Phyisics for Game developers, specifically the flight simulator section.
  2. Perhaps have a small delay before processing the key press event to optionally detect combo key presses/key holds? Or you can start and action, detect a change during the animation sequence and morph the action into another? For instance, if your sprite has only begun moving and you detect a jump command within a small window of time, switch/morph/override your action into a forward jump. In my game whenever I detect a jump press, I check to see if the character is standing or moving, if he is moving I queue a moving jump otherwise I queue a standing jump.
  3. fais

    Does our icon suck? - brutal honesty required

    While I like the cheeky smile and that kniving glance, the facial muscles around the eyes/nose/cheeks failing to conform around his grin makes it look like the picture is oddly warped rather than him grinning.
  4. Like so many of you guys, I myself work full time and am a hobbyist game programmer on the side. Though most of my "demos" have been more technical based (oh look, I figured out how to write and atmospheric scattering demo based on Nishita's paper, or a 2D fluid simulator based on Stam's paper... or how about that impulse-based physics engine based on Baraff work? You know what, I want to write a flight simulator, where is that O'Reilly's book?) Only recently (like last year) I decided to sit create something end to end. So much done but do much to do, but such an enlightening journey. For me, my days tend to conclude with kids in bed, wifey watching some fun shows on CBS, and me with my laptop coding away. (I personally, will always chose coding over TV!). Also, God bless the creators of Gimp, Blender, Eclipse CDT, MinGW, SDL and GLEW.
  5. fais

    How Does One Learn C++ ?

    How does one eat an elephant? One bite at s time.
  6. So angular velocity be the same. In 3D the angular velocity vector is an axis around which an object spins, and the magnitude of this vector is the the speed radians/seconds. If a big object makes a full circle (360 degrees/2 pi radians) in one second, all the points on this object are also spinning at 360 degrees per second. The linear velocity however, is different for for points closer to the axis than further. If this point is at a distance R from the center of the spin, the angular velocity vector A has a magnitude specifying rotational speed in radians per seconds, and V0 is the linear speed of the entire object then, the linear velocity V for point i is: V(i) = V0 + R(i) x A
  7. fais

    Converting float4x4 to float4x3

    Always remember: Row dot column. Is your input position a float3? If so, then you need to convert it to float4 with 1.0 for w otherwise the translation will not occur. So, if I'm not mistaken, you need to do the following float4 = float4( float4(float3,1) * float4x3, 1.0) Your float4x3 when multiplied TO a 1x4 matrix will yield a 3x1: 1x4 * 4x3 = 1x3 In your case you are doing the following: 1x3 * 4x3 = ? This doesn't make any sense mathematically. If it isn't giving you a compile error, it may be upcomverting it to a float4(float3,0), scaling translation by 0.
  8. fais

    Downsizing normal maps

    I have calculated normal maps from mip mapped displacement maps in the fragment shader before and have found it to look more realistic. I myself have been meaning to add this capability in my multi purpose image tool that generates normal map from height maps, where I generate that mip levels of the normal map by recalculating the normals from the associated mip level of the height map.
  9. In a behind the scenes reveal for the team fortress 2 short vid "meet the medic" (more information here: the creators describe the creativity process as a "game of Jenga". "99% of it involves making room for an idea and seeing what happens" reads the post. "Most of the time what happens is the whole structure collapses. Then you have to figure out why it collapsed and rebuild it, this time making sure to add in some structural support for your idea so it doesn't bring the whole short down." this is why I encourage you to not get disheartened and keep at it. You will get there. You have to kind of find what doesn't work before you find what does. And because it will ultimately lead you to what you are looking for, it's actually a good thing.
  10. I would say it's probably a lack of ambient occlusion type lighting. Everything looks flat and devoid of depth cues. You should also look to add stark contrasts and colorful lighting to create an atmosphere. I think the art isn't bad, it's merely incomplete. Don't give up, keep at it!
  11. You can get by with 4 samples and a normalize.
  12. It's like this site has an irrational fear of LUTs. Maybe several thousand square roots being executed ~60 frames a second isn't the ideal candidate for LUTs. I implemented an LUT table for exponential decay in a real atmospheric scattering demo I wrote years ago (early gen i7) to illuminate the exp() call being invoked several thousand times a frame, and my frame rate jumped drastically. I will pull that code out on my year old i3 laptop and retest, but I highly suspect the results will be the same. Also, if my CPU is frequently paging out a table that is being addressed several 100 thousands of times a second , then I would think my CPU has bigger problems to deal with and this whole point is moot.
  13.   In the event that I'm calculating tens of thousands of square roots per frame, could the initial hit of pulling that LUT into memory be offseted by the possible gain? If the size of the table is smaller, then do the chances of it staying in cache rise since it is vying for fewer resources?    Thanks for taking the time to respond.    Edit: my platform isn't limited (my game engine currently targets an i3 level processor).
  14. So the motivation behind my question comes from my attempt at creating a fairly small 2d lookup table for the square-root function (with a small domain - from 0 to ~1.5), assumption being that by optimizing my sub-domain for my piecewise function, I can maximize my accuracy. Having covered combinatorics in one of my classes years ago, i got to thinking on how a 2d table can essentially functions as a numeral system, and that if you have a function f(x), how can one extract a numeral system to serve that function better (somewhat akin to how factoradics are adapted to numbering permutations)? Also, how do I determine if a LUT to big, that memory lookup costs exceed fast interative approximations. Would a "float sqrt_tab[4096]" terribly inefficient? Not looking for anything more than a heuristic because I understand every system is different and programs are definitely not compiled equally. Edit: more importantly, is it possible to get more accuracy out of something like a smart "float sqrt_tab_pw[8][8]" than the naive, fixed interval approach like "float sqrt_tab[1000]".
  15. fais

    How do i implement advection on 2d grid

    So, implementing a numerical advection model is not a trivial task. To the contrary, So much research has been poured into this one particular topic (from various different disciplines including oceanography/coastal engineering, plasma physics, meteorology/atmospheric science and modeling, fluid mechanics, linear algebra) that one can easily become overwhelmed. There is a reason why video games sacrifice fidelity/accuracy for speed and stability when it comes to simulating fluids. (Especially numerical stability, which can be a b***h!) Before you can jump into creating your own/implement an existing an advection model, check out this articles the two fundamental approaches to fluid mechanics ( lagrangian vs eulerian) and you may begin to see why such a simple scheme that I outlined earlier is called "semi" lagrangian: If you've taken any calculus classes and you have a basic grasp on derivatives, then I also encourage you to look st material derivatives Heck, it took me a longer than I care to admit grasping the difference between D(x)/Dt and d(x)/dt and how it relates to lagrangian vs eulerian integration.
  • Advertisement

Important Information

By using, you agree to our community Guidelines, Terms of Use, and Privacy Policy. is your game development community. Create an account for your GameDev Portfolio and participate in the largest developer community in the games industry.

Sign me up!