viernes, 25 de mayo de 2007

Drawing circle primitives using GL_POINTS in GLSL


One of the best things that I love in openGL due to performance is to draw using GL_POINTS instead standard triangles or lines, because it's an ideal primitive for debug purposes or 3d geometry editor (I think that it's more easy than GL_POINT_SPRITES to show all vertices in our geometry, for example).

But the lack is that you're only allowed to paint ugly scaled quads :S. Using the programmable pipeline you can paint any shape that you want. I upload 2 shaders for paint circles in GLSL using GL_POINTS.


circles_with_gl_points.vert
circles_with_gl_points.frag

jueves, 17 de mayo de 2007

Realtime 3d hair physics simulation

My first program to show to the world :) This demo was a bit old, but I always remember with wet eyes :>



You can download the video and other programming stuff in my website
I use verlet integration for physics, where each spring matches to any edge in the face patch (I import the hair as a single model from a modeling program). Before simulation starts I must sort faces by distance to the head center for allow a more realistic simulation.

The algorithm is too fast, and I use sphere-triangle collision instead sphere-point for more accurate results (and avoid interpenetration).

Questions? :)

ains

Code::Blocks for Slax 5.1.8, or my 2 cents to open-source cause

Another cool program that I use in my job is codeblocks

"Code::Blocks is a free C++ IDE built to meet the most demanding needs of its users. It is designed to be very extensible and fully configurable..."

...ok, ok. Until here nothing awesome... but... the power of this IDE is the multiplatform concept. Like java says: "program once, runs everywhere". With only one project file, you can compile and run your application in Windows, Linux and MacOSX.

This is my little contribution to open-source cause:

Codeblocks for Slax


ains.

Open Source++;

Hi to all :)

I want to dedicate my first post to the very first "open source" program concept: "linux"... and probably the best distro that I've discovered: slax.

This Slackware based distribution have the ability to allow users load modules 'on the fly'. And this feature was perfect for my modest project: a-minimalist-game-with-auto-loader-os-unix-based-with-less-than-100mb :)

After one week I've been done a custom optimized distro with automatic hardware acceleration graphics card detection (and was my first kernel recompilation too).

Despite the perfect match for my "world domination" project, I truly think that is the best linux distro by far (obviully I've been tested at least 15 other distros).

ains.