Re: Source code or algorithm for these effects??
- From: "Dave Eberly" <dNOSPAMeberly@xxxxxxxxxxxxxxx>
- Date: Wed, 26 Oct 2005 13:51:53 GMT
"eminemence" <eminemence@xxxxxxxxx> wrote in message
news:1130309988.509864.60360@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
> Also to add I want to use blur as a transition effect rather than a
> image processing effect.
> What i basically mean is that I will be transitioning(i.e. blurring )
> from one screen to
> another screen.
> Is it really a good idea to do so?
Well, then, you have posed the wrong problem to us :)
Gaussian blurring is definitely not the way to do a transition
effect. The simplest thing to do is
transitionPixel = (1-t)*sourcePixel + t*destinationPixel
for 0 <= t <= 1. The transition takes you from the source
image to the destination image. Your program will vary t,
each time performing the blend between the two images.
You still have the same floating-point issue, so the actual
implementation might do something like select N = 2^p
where N = 2^p with p > 1, and for each i in {0,1,...,N}
do the blend
trn = (((N-i)*src + i*dst) >> p);
--
Dave Eberly
http://www.geometrictools.com
.
- References:
- Source code or algorithm for these effects??
- From: eminemence
- Re: Source code or algorithm for these effects??
- From: eminemence
- Re: Source code or algorithm for these effects??
- From: Alan S
- Re: Source code or algorithm for these effects??
- From: eminemence
- Re: Source code or algorithm for these effects??
- From: eminemence
- Source code or algorithm for these effects??
- Prev by Date: Re: Source code or algorithm for these effects??
- Next by Date: Re: polygon intersection
- Previous by thread: Re: Source code or algorithm for these effects??
- Next by thread: Re: Source code or algorithm for these effects??
- Index(es):