Skip to content

Instantly share code, notes, and snippets.

/*
Code developed by Team 7, B.Tech 2011, DA-IICT, India
for making controller for operating in arduino project on TicTacToe
Please feel free to download, use and share
Cheers !!
*/
int j = 1; // integer used in scanning the array designating column number
//2-dimensional array for asigning the buttons and there high and low values
@jaydp17
jaydp17 / fft.cpp
Last active December 21, 2015 04:39
Arduino almost working code
#include <BiColorLED.h>
// LEDPad.cpp
class LEDPad
{
public:
BiColorLED leds[9];
LEDPad() {
int j = 0;
@jaydp17
jaydp17 / gist:5263207
Created March 28, 2013 13:43
WriteableBitmap version
public static Boundaries CheckBoundaries(WriteableBitmap bmp)
{
// check left
double boundayFactor = 0.1; //10% of the image width/height
Boundaries b = new Boundaries();
b.Left = CheckLeft(bmp, boundayFactor);
b.Right = CheckRight(bmp, boundayFactor);
b.Top = CheckTop(bmp, boundayFactor);
b.Bottom = CheckBottom(bmp, boundayFactor);
return b;
@jaydp17
jaydp17 / gist:5263201
Created March 28, 2013 13:42
The array version
public Boundaries CheckBoundaries(int[] pixels) {
// check left
double boundayFactor = 0.1; //10% of the image width/height
Boundaries b = new Boundaries();
b.Left = CheckLeft(pixels, boundayFactor);
b.Right = CheckRight(pixels, boundayFactor);
b.Top = CheckTop(pixels, boundayFactor);
b.Bottom = CheckBottom(pixels, boundayFactor);
return b;
}
using System;
using System.Collections.Generic;
using System.Linq;
using System.Net;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Navigation;
using Microsoft.Phone.Controls;
using Microsoft.Phone.Shell;
using System.ComponentModel;
#include <QCoreApplication>
#include <opencv.hpp>
#include <QDebug>
double compute_skew(QString filename);
void deskew(QString filename, double angle);
int main(int argc, char *argv[])
{
QCoreApplication a(argc, argv);