Flickering with translucency.
Displaying 1-8 of 8 total.
1
Please enter a numerical value for the importance of this sticky.
Enter 0 to unsticky.
Overkill

Translucency around the 50% mark flickers. I noticed this when I had a looped fading in/fading out animation. It may not be exactly 50% but somewhere in that area.

OK, the example HTML totally destroyed my code here, so you may want to test it for youself. Otherwise, it's just an annoying problem on my graphics card.

(So I don't get yelled at:)
Is there any way to stop this flicker from occurring?

Posted on 2004-03-28 14:24:41 (last edited on 2004-03-28 14:46:46)

mcgrue

Do you only have one ShowPage() in your render loop?

Posted on 2004-03-28 18:03:27

Overkill

I do ShowPage(); only after everything is finished drawing - at the very end of the loop. I made sure to SetLucent(0); after the area which was set translucent was drawn.

Posted on 2004-03-28 18:12:23

mcgrue

Well, I've used 50% trans before, and I believe vec has as well...

Is your FPS under 30?

Posted on 2004-03-28 19:15:41

Overkill

Well, it's got to be on the lower end, as it isn't even a 3d card on here. But it'd be nice if there was a was to find out. Other than actually counting and timing.

Then, I'm guessing that information would be somewhat useful. Or at least, it will provoke you to tell me to get off my ass and buy a new computer.

Posted on 2004-03-29 00:09:54

mcgrue

erm, well, I'd need to see the script to help anymore, really. If you come to #vergehelp and /notice the everloving crap out of me, I'll see what I can do.

Posted on 2004-03-29 01:27:43

Overkill


void Autoexec()
while(!b1)
{
rectfill(0,0,screenx,screeny,rgb(1,1,1),screen);
timer=0;
while(timer<200)
{
RectFill(0,0,screenx,screeny,rgb(0,103,255),screen);
setlucent(100-(timer/4));
RectFill(screenx/2-50,screeny/2-8,screenx/2+50,screeny/2+8,rgb(255,210,30),screen);
Rect(screenx/2-50,screeny/2-8,screenx/2+50,screeny/2+8,rgb(1,1,1),screen);
setlucent(0);
PrintCenter(screenx/2,screeny/2,screen,fnt,"Test");
Showpage();
}
while(timer<200)
{
RectFill(0,0,screenx,screeny,rgb(0,103,255),screen);
setlucent(50+(timer/4));
RectFill(screenx/2-50,screeny/2-8,screenx/2+50,screeny/2+8,rgb(255,210,30),screen);
Rect(screenx/2-50,screeny/2-8,screenx/2+50,screeny/2+8,rgb(1,1,1),screen);
setlucent(0);
PrintCenter(screenx/2,screeny/2,screen,fnt,"Test");
Showpage();
}
}
}

Beware of syntax errors.

Posted on 2004-03-29 02:22:30

Omni

What happens in this code when the internal 'timer' reaches above 200? What affect would that cause? If lucency is calculated from 'timer', then a lucency of "4000" for example, would be very bad.

Maybe you should use modulus.

-------
time = timer % 200

while time

Posted on 2004-04-08 18:08:03


Displaying 1-8 of 8 total.
1
 
Newest messages

Ben McGraw's lovingly crafted this website from scratch for years.
It's a lot prettier this go around because of Jon Wofford.
Verge-rpg.com is a member of the lunarnet irc network, and would like to take this opportunity to remind you that regardless how babies taste, it is wrong to eat them.