vertex programs; point sprites

Started by
7 comments, last by RolandofGilead 19 years, 10 months ago
I was looking at the capabilities of my card and found it supports ARB_vertex_program and ARB_point_sprite. I know nothing and my web searches have not been fruitful(thus here I am). What can be done with vertex programs? Could you please direct me to some tutorials? I think I can figure out point sprites. But, if particle systems used to be textured quads made to always point their normals toward the camera, how does the card determine the size and orientation of the particle, and in what units will the size be?
Advertisement
Google is your friend, anything else you need to know is covered in the spec for the extension
Vertex programs (more commonly called vertex shaders) are ways of manipulating vertices on your graphics card GPU. So, instead of calculating things like the vertex color due to lighting on the CPU, you can calculate that kind of thing on the GPU thus freeing up your CPU to do other stuff. Also, you can reduce the amount of data that you send through opengl by calculating it procedurally on the GPU.

The size of point sprites can be controlled via the ARB_point_parameters extension - no doubt your card also supports that extension. The specifics of size and alpha-fading of point sprites are dealt with in the extension specification.

Hope that helped,
do unto others... and then run like hell.
quote:Original post by _the_phantom_
Google is your friend, anything else you need to know is covered in the spec for the extension

Yes, this is why I typically don''t ask for help on gd.net forums. I must admit though, typically everything I''ve ever asked for has always been solvable given enough time. Which is why I usually do it myself. One can read the technical specification of a gun and still not know how to fire it.
quote:my web searches have not been fruitful


@FReY:
I''ve heard that, but that''s what I never understood about the point parameters, is point_size in units or pixels?

http://oss.sgi.com/projects/ogl-sample/registry/ARB/vertex_shader.txt
http://oss.sgi.com/projects/ogl-sample/registry/ARB/vertex_program.txt

quote:What can be done with vertex programs?
This is something I want to go back to. See, the transition from going to low-level assembler gpu programs to ones written in higher-level language was so quick, I can''t find any resources on the former. I''d like to see examples.
quote:Original post by RolandofGilead
quote:Original post by _the_phantom_
Google is your friend, anything else you need to know is covered in the spec for the extension

Yes, this is why I typically don't ask for help on gd.net forums. I must admit though, typically everything I've ever asked for has always been solvable given enough time. Which is why I usually do it myself. One can read the technical specification of a gun and still not know how to fire it.


errm.. did you even look at the link I posted?
I didnt blindly point you are google, I gave you a link to the correct web search, first hit was a tutorial on ARB_Vertex_program and it also mentions in the opening paragraph that if you dont know what the programable pipeline is then you should look at Nvidia's dev site for more infomation (who have a wealth of infomation on this stuff).

As for examples are you even trying google?

[edited by - _the_phantom_ on June 6, 2004 7:32:11 AM]
Well, I haven''t *actually* used point parameters before. But I''d imagine that they would be in pixel size since glPointSize() is pixel size... but that would be speculation. The best way to find out is to try it yourself.

do unto others... and then run like hell.
@_the_phantom_
Funny thing, those are the exact search terms I used, before I posted.

Let me rephrase my earlier example and restate a particular question. One can know how to pull the trigger of a gun and not know how to win a gunfight(in case I lost you again, I'll give you a clue, one of them is more complex than the other).
"What can be done with vertex programs?"
Although that didn't work the first time so let's try this:
What effects can be generated with vertex programs?
--or--
How can I make it purty?

edit: I got a better one, if you tell me how to draw points on the screen in OpenGL, does that help me if I don't know what a point is?

[edited by - RolandofGilead on June 8, 2004 1:40:08 AM]
quote:Original post by RolandofGilead
edit: I got a better one, if you tell me how to draw points on the screen in OpenGL, does that help me if I don''t know what a point is?


thats why the overview part of the specs explain what a point is and what its good for, followed by a lot of decisions that were made, followed by detailed explanations how they work and how they are to be used.

and if thats not helping, then searching for vertex program tutorial shouldnt be hard either.

if you ask "i just read my computer has a fpu.. what can be done with floats?", are you expecting a detailed listing of all possibilities?
f@dzhttp://festini.device-zero.de
quote:Original post by Trienco
quote:Original post by RolandofGilead
edit: I got a better one, if you tell me how to draw points on the screen in OpenGL, does that help me if I don''t know what a point is?


if you ask "i just read my computer has a fpu.. what can be done with floats?", are you expecting a detailed listing of all possibilities?


yes, it''s a short list when you do it by describing the sets of things it can manage rather than each possibility

more to the point of the current example, it can be listed even quicker if you assume the reader has basic knowledge of math and number and basic pattern recognition capabilities(in the case of vertex programs: renders, demos, games, etc.)

int: 13
float: 47.820
tada!

This topic is closed to new replies.

Advertisement