Skip to content

Instantly share code, notes, and snippets.

View liovch's full-sized avatar

Lev Zelenskiy liovch

  • Gold Coast, Australia
View GitHub Profile
#include <stdio.h>
#define IMAGE_WIDTH 7
#define DISPLAY_WIDTH 192
#define DISPLAY_HEIGHT 160
unsigned long int display[(DISPLAY_WIDTH * DISPLAY_HEIGHT) / 32];
int asciiHexToDec(char asciiHex)
{
@liovch
liovch / gist:5158302
Last active December 14, 2015 22:28 — forked from anonymous/gist:5158287
#include <stdio.h>
/*int main(int argc, const char * argv[])*/
void concat(char* str1, char* str2, char* output);
{
int i, j, k;
i = j = k = 0;
while (str1[i] != '\0')
@liovch
liovch / GPUImageHueSaturationFilter.h
Created July 25, 2012 14:04
GPUImageHueSaturationFilter
#import "GPUImageFilter.h"
@interface GPUImageHueSaturationFilter : GPUImageFilter {
GLfloat hue[7];
GLfloat lightness[7];
GLfloat saturation[7];
GLint hueUniform;
GLint lightnessUniform;
GLint saturationUniform;
@liovch
liovch / gist:3168961
Created July 24, 2012 09:01
GIMP color balance filter shader
NSString *const kColorShiftFragmentShaderString = SHADER_STRING
(
varying highp vec2 textureCoordinate;
uniform sampler2D inputImageTexture;
uniform lowp float redShift;
uniform lowp float greenShift;
uniform lowp float blueShift;