Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSergey Sharybin <sergey.vfx@gmail.com>2017-10-06 12:36:26 +0300
committerSergey Sharybin <sergey.vfx@gmail.com>2017-10-06 12:36:41 +0300
commit00eac066f34a5dd27853030fa689ce86baa02cd9 (patch)
treefa261881943ccad20863a3a3685650ed7d7bcb03
parentd56f835bffaab78b6ae13db7b61c522a69098a88 (diff)
Sequencer: Use BLI math functions where possible
-rw-r--r--source/blender/blenkernel/intern/seqeffects.c31
1 files changed, 6 insertions, 25 deletions
diff --git a/source/blender/blenkernel/intern/seqeffects.c b/source/blender/blenkernel/intern/seqeffects.c
index a712b1b201e..8753913d877 100644
--- a/source/blender/blenkernel/intern/seqeffects.c
+++ b/source/blender/blenkernel/intern/seqeffects.c
@@ -1927,17 +1927,10 @@ static void RVBlurBitmap2_float(float *map, int width, int height, float blur, i
fx++;
}
index = (x + y * width) * 4;
- temp[index + GlowR] = curColor[0];
- temp[index + GlowG] = curColor[1];
- temp[index + GlowB] = curColor[2];
- temp[index + GlowA] = curColor[3];
+ copy_v4_v4(temp + index, curColor);
index = (width - 1 - x + y * width) * 4;
- temp[index + GlowR] = curColor2[0];
- temp[index + GlowG] = curColor2[1];
- temp[index + GlowB] = curColor2[2];
- temp[index + GlowA] = curColor2[3];
-
+ copy_v4_v4(temp + index, curColor2);
}
/* Do the main body */
@@ -1953,10 +1946,7 @@ static void RVBlurBitmap2_float(float *map, int width, int height, float blur, i
fx++;
}
index = (x + y * width) * 4;
- temp[index + GlowR] = curColor[0];
- temp[index + GlowG] = curColor[1];
- temp[index + GlowB] = curColor[2];
- temp[index + GlowA] = curColor[3];
+ copy_v4_v4(temp + index, curColor);
}
}
@@ -1989,16 +1979,10 @@ static void RVBlurBitmap2_float(float *map, int width, int height, float blur, i
fy++;
}
index = (x + y * width) * 4;
- temp[index + GlowR] = curColor[0];
- temp[index + GlowG] = curColor[1];
- temp[index + GlowB] = curColor[2];
- temp[index + GlowA] = curColor[3];
+ copy_v4_v4(temp + index, curColor);
index = (x + (height - 1 - y) * width) * 4;
- temp[index + GlowR] = curColor2[0];
- temp[index + GlowG] = curColor2[1];
- temp[index + GlowB] = curColor2[2];
- temp[index + GlowA] = curColor2[3];
+ copy_v4_v4(temp + index, curColor2);
}
/* Do the main body */
@@ -2014,10 +1998,7 @@ static void RVBlurBitmap2_float(float *map, int width, int height, float blur, i
fy++;
}
index = (x + y * width) * 4;
- temp[index + GlowR] = curColor[0];
- temp[index + GlowG] = curColor[1];
- temp[index + GlowB] = curColor[2];
- temp[index + GlowA] = curColor[3];
+ copy_v4_v4(temp + index, curColor);
}
}