Skip to content

Instantly share code, notes, and snippets.

Avatar

Sturla Molden sturlamolden

  • Norway
View GitHub Profile
View usleep.c
#include <Windows.h>
#include <mmsystem.h>
#include <math.h>
static BOOL inited = FALSE;
static double dhz;
void usleep( long us )
{
const double sleep_granularity = 2.0E-3;
@sturlamolden
sturlamolden / audioprocessing.py
Last active Dec 21, 2015
Example of audioprocessing in Windows with Python 2.7 using NumPy and pywin32 (Microsoft DirectSound)
View audioprocessing.py
""" Copyright (C) 2013 Sturla Molden """
import threading
import Queue
import pywintypes
import win32event
import win32com.directsound.directsound as directsound
import numpy as np
@sturlamolden
sturlamolden / hello.py
Created Jul 30, 2012
Hello World (testing gist)
View hello.py
print 'Hello World!'
You can’t perform that action at this time.