Libvje / refactor : alphadampen

* clean headers
This commit is contained in:
[d.j.a.y] Jerome Blanchi
2016-07-30 11:32:51 +02:00
parent 3eb0e46f2f
commit a045fe331a
2 changed files with 7 additions and 12 deletions

View File

@@ -17,9 +17,8 @@
* along with this program; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307 , USA.
*/
#include <config.h>
#include <stdint.h>
#include <stdio.h>
#include "common.h"
#include <libvjmem/vjmem.h>
#include "alphadampen.h"
@@ -46,13 +45,13 @@ vj_effect *alphadampen_init(int w, int h)
void alphadampen_apply( VJFrame *frame, int b1)
{
size_t i;
const size_t len = frame->len;
uint8_t tmp;
uint8_t *A = frame->data[3];
size_t i;
const unsigned int len = frame->len;
uint8_t tmp;
uint8_t *A = frame->data[3];
const int base = (const int) b1;
for( i = 0 ; i < len ; i ++ )
for( i = 0 ; i < len ; i ++ )
{
tmp = A[i];
A[i] = (tmp / base) * base; // loose fractional part

View File

@@ -20,10 +20,6 @@
#ifndef ALPHA_DAMPEN_H
#define ALPHA_DAMPEN_H
#include <libvje/vje.h>
#include <sys/types.h>
#include <stdint.h>
vj_effect *alphadampen_init(int w, int h);
void alphadampen_apply( VJFrame *frame, int b1);
#endif