Sign in to follow this  
3dnewbie

eventviewer doesn't work?

Recommended Posts

Can anyone tell me why this doesn't work ? [code]GLvoid display_events(GLvoid) { events *tmp=e_head; int x=15; /* Line indentation */ int y=15; /* Line spacing */ set_ortho(width,heigth); while(tmp!=NULL) { glColor4f(tmp->r,tmp->g,tmp->b,tmp->a); renderbitmapfont(x,y+=15,0,tmp->event,tmp->timestamp); tmp=tmp->next; } unset_ortho(); }[/code the set and unset ortho work fine, i tested that. the idea is that i get a log of messages on screen with a line spacing of 15. This function is called from the main rendering function, if the user requested it. I get 1 message and after that nada.

Share this post


Link to post
Share on other sites
With more (read: full) source, or at least a whole lot more context, including the functions you called, we could answer your questions more fully. Without seeing any more, though, I'd wager on something of the following:

1) The location specified when rendering the bitmap, if rendered with a rasterpos*, is out of the frustum. This will result in none of the text getting rendered, not just the part that is out of the screen. Have you stepped through in debug mode and checked the positions stored in the individual events?
2) Have you checked if the events (after the first) are valid?
3) Have you checked that the alpha values are > 0.0?

I can hopefully have more insight for you with more code.

Until then!

-jouley

Share this post


Link to post
Share on other sites
I was playing around with the blend option (subconciously turning it on) and voila, all of a sudden i got my events :-). Turns out that somewhere in my list code i assigned a b value to b value where i should have added a alpha value to an alpha value. In the end , the result that i had no alpha value, rendering the text fully tranlucent :-)

Thanks for your help

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this