On Tue, Dec 31, 2013 at 6:19 AM, ChunEon Park <[email protected]> wrote:
> hermet pushed a commit to branch master.
>
> http://git.enlightenment.org/core/efl.git/commit/?id=0d33d30accdafc5b057de0d01a7ccd5f78f35e73
>
> commit 0d33d30accdafc5b057de0d01a7ccd5f78f35e73
> Author: ChunEon Park <[email protected]>
> Date: Tue Dec 31 18:19:41 2013 +0900
>
> evas/common - more elaborated compuatation in interpolation.
>
> we should not +1 in divide but only do it when the quotient is zero.
Then why divide?
> ---
> src/lib/evas/common/evas_map_image.c | 6 ++++--
> 1 file changed, 4 insertions(+), 2 deletions(-)
>
> diff --git a/src/lib/evas/common/evas_map_image.c
> b/src/lib/evas/common/evas_map_image.c
> index c3f3e37..793abf3 100644
> --- a/src/lib/evas/common/evas_map_image.c
> +++ b/src/lib/evas/common/evas_map_image.c
> @@ -38,9 +38,10 @@ _interp(int x1, int x2, int p, FPc u1, FPc u2)
> FPc u;
>
> x2 -= x1;
> + if (x2 == 0) x2 = 1;
> p -= x1;
> u = u2 - u1;
> - u = (u * p) / (x2 + 1);
> + u = ((u * p) / x2);
> // FIXME: do z persp
> return u1 + u;
> }
> @@ -49,8 +50,9 @@ static inline DATA32
> _interp_col(int x1, int x2, int p, DATA32 col1, DATA32 col2)
> {
> x2 -= x1;
> + if (x2 == 0) x2 = 1;
> p -= x1;
> - p = (p << 8) / (x2 + 1);
> + p = ((p << 8) / x2);
> // FIXME: do z persp
> return INTERP_256(p, col2, col1);
> }
>
> --
>
>
------------------------------------------------------------------------------
Rapidly troubleshoot problems before they affect your business. Most IT
organizations don't have a clear picture of how application performance
affects their revenue. With AppDynamics, you get 100% visibility into your
Java,.NET, & PHP application. Start your 15-day FREE TRIAL of AppDynamics Pro!
http://pubads.g.doubleclick.net/gampad/clk?id=84349831&iu=/4140/ostg.clktrk
_______________________________________________
enlightenment-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/enlightenment-devel