Archived

This topic is now archived and is closed to further replies.

Lens Flare -- drawing

This topic is 5535 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Ok, I understand lens flares and there are numerous tutorials I can read. But the part I don''t understand is not mentioned anywhere! After I calculate everything and do all that, how do I actually render the lens flares to the screen? I have tried texturing some quads but that just doesn''t work! argh!

Share this post


Link to post
Share on other sites
You should disable the z-buffer for starters, as lens flares should be rendered on top of the scene.

What exactly is wrong with the ones you''ve done? Are they showing at all?

Share this post


Link to post
Share on other sites
I don''t know what the problem was but they just weren''t being drawn at all.

But I found a tutorial on a blit function that does almost exactly what I was doing. But this function works where mine doesn''t. :D

Now I just need to fix bugs and it''s all good.

Share this post


Link to post
Share on other sites
so the thing i don't don't get about lense flare is who has ever seen it in real life? i certainly haven't, well not in the classic 3d game style anyways.

[edited by - necromancer_df on October 22, 2002 2:25:26 AM]

Share this post


Link to post
Share on other sites
quote:
Original post by necromancer_df
so the thing i don''t don''t get about lense flare is who has ever seen it in real life? i certainly haven''t, well not in the classic 3d game style anyways.


Lens flares only occur with cameras, and then only some cameras. In games, they are fundamentally useless eyecandy that don''t do a damn thing to increase realism.


Don''t listen to me. I''ve had too much coffee.

Share this post


Link to post
Share on other sites
Guest Anonymous Poster
quote:
Original post by Sneftel Lens flares only occur with cameras, and then only some cameras. In games, they are fundamentally useless eyecandy that don''t do a damn thing to increase realism.

Lens Flares do havea relevant effect in games. They slightly obscure the view when you are looking at the sun. Especially in racing games this is a major thing, in my opinion.

Share this post


Link to post
Share on other sites
Sometimes eye candy make the experience more worthwhile. I used to REALLY get into the graphics of games. ("Wow, that was a cool explosion when that spacecraft blew up. And now, as I''m turning, oh yeah, the sun gives off lens flares! Weeee!")

Share this post


Link to post
Share on other sites
They definately are useless in my game at any rate, but I think they look cool!

My problem was that I was using a vertex buffer that wasn''t working for whatever reason. DrawPrimitiveUP fixed my probs.

Share this post


Link to post
Share on other sites
quote:
Original post by Anonymous Poster
Lens Flares do havea relevant effect in games. They slightly obscure the view when you are looking at the sun. Especially in racing games this is a major thing, in my opinion.


Ever driven into the sun in real life? No lens flare. If a game wants to wash out the exposure, fine. But I don''t think anyone thinks of a lens flare as a means to deliberately occlude vision when looking at the sun. After all, if you are looking directly towards the sun, there is NO lens flare.


Don''t listen to me. I''ve had too much coffee.

Share this post


Link to post
Share on other sites