Weekend Project: Sokoban Clone in p5.js
Posted by clu 2 years ago
Sokoban Clone. Tis a work in progress, but feature complete.
It's been years...
Posted by clu 2 years ago
...
Posted by clu 8 years ago
Carly Fiorina
...
Posted by clu 8 years ago
superman,obama,olympics
...
Posted by clu 8 years ago
More fractals
Posted by clu 8 years ago
Patch Cord Fractal
Fractal 4-2-2
Fractals
Posted by clu 8 years ago
Seven Against ThreeFractal
Built with Processing.
Posted by clu 8 years ago
Fractal Rug
Pac-Fractal
fractal
...
Posted by clu 8 years ago





Fun with numbers
Posted by clu 8 years ago
Factor Relationship Table  
 
Larger here.  
 
Factor relationship table built with processing. Just something I did for fun, because numbers are teh r0x0r!!
This generates a 1 second sinewave
Posted by clu 9 years ago
int main(int argc, char *argv[])  
{  
NSAutoreleasePool *autoreleasepool = [[NSAutoreleasePool alloc] init];  
 
/* Create an FSRef for a directory where a file is to be created */  
OSStatus err = noErr;  
FSRef myFSRef;  
FSRef *myFSRef_ptr = &myFSRef;  
Boolean isDirectory = TRUE;  
NSString *myString = [@"~/code/" stringByStandardizingPath];  
err = FSPathMakeRef((UInt8 *) [myString fileSystemRepresentation], myFSRef_ptr, &isDirectory);  
 
printf("myString: %s\n", [myString UTF8String]);  
printf("err = %d\n", err);  
 
/* Create a new audio file */  
NSString *audioFileName = @"test.aif";  
CFStringRef inFileName = (CFStringRef)audioFileName;  
 
AudioFileTypeID inFileType = kAudioFileAIFFType;  
 
AudioStreamBasicDescription audioStreamInfo;  
AudioStreamBasicDescription *audioStreamInfo_ptr = &audioStreamInfo;  
audioStreamInfo.mSampleRate = 44100.0;  
audioStreamInfo.mFormatID = kAudioFormatLinearPCM;  
audioStreamInfo.mFormatFlags = kLinearPCMFormatFlagIsSignedInteger | kLinearPCMFormatFlagIsBigEndian | kAudioFormatFlagIsPacked;  
audioStreamInfo.mBytesPerPacket = 2;  
audioStreamInfo.mFramesPerPacket = 1;  
audioStreamInfo.mBytesPerFrame = 2;  
audioStreamInfo.mChannelsPerFrame = 1;  
audioStreamInfo.mBitsPerChannel = 16;  
// audioStreamInfo.mReserved = 0;  
 
ExtAudioFileRef outExtAudioFile;  
ExtAudioFileRef *outExtAudioFile_ptr = &outExtAudioFile;  
 
AudioChannelLayout audioChannelLayout;  
AudioChannelLayout *audioChannelLayout_ptr = &audioChannelLayout;  
audioChannelLayout.mChannelLayoutTag = kAudioChannelLayoutTag_Mono;  
audioChannelLayout.mChannelBitmap = 0;  
audioChannelLayout.mNumberChannelDescriptions = 0;  
// audioChannelLayout.mChannelDescriptions[kVariableLengthArray];  
 
err = ExtAudioFileCreateNew(myFSRef_ptr, inFileName, inFileType, audioStreamInfo_ptr, audioChannelLayout_ptr, outExtAudioFile_ptr);  
 
printf("ExtAudioFileCreateNew() err = %d\n", err);  
 
if (err != 0) {  
printf("Something ain't right.\n");  
return 0;  
}  
 
/* Create Sinewave Buffer */  
SInt16 tempBuffer[256];  
SInt16 *tempBuffer_ptr = tempBuffer;  
 
int i = 0;  
 
for (i = 0; i < 256; i++) {  
double d;  
d = sin(2.0 * 3.1459 * (double) i / 256.0);  
tempBuffer[i] = (SInt16) (d * 127.0);  
printf("%d\t", tempBuffer[i]);  
}  
 
printf("\n");  
 
AudioBuffer buffer;  
buffer.mNumberChannels = 1;  
buffer.mDataByteSize = 2;  
buffer.mData = tempBuffer_ptr;  
 
AudioBufferList bufferList;  
AudioBufferList *bufferList_ptr = &bufferList;  
bufferList.mNumberBuffers = 1;  
*bufferList.mBuffers = buffer;  
 
/* Write to Audio file */  
int counter = 0;  
 
while (counter < 44100) {  
err = ExtAudioFileWrite(outExtAudioFile, 256, bufferList_ptr);  
counter += 256;  
}  
 
/* Clean up */  
ExtAudioFileDispose(outExtAudioFile);  
[autoreleasepool release];  
 
return 0;  
}
Things that make you go WTFITBS?!?!
Posted by clu 9 years ago
/* Works */  
OSStatus err = noErr;  
FSRef *foo;  
Boolean isDirectory = TRUE;  
NSString *myString = @"this is my damn string.";  
// err = FSPathMakeRef((UInt8 *) "/Users/clu/code/", foo, &isDirectory);  
 
 
/* Works */  
OSStatus err = noErr;  
FSRef *foo;  
Boolean isDirectory = TRUE;  
// NSString *myString = @"this is my damn string.";  
err = FSPathMakeRef((UInt8 *) "/Users/clu/code/", foo, &isDirectory);  
 
/* Breaks */  
OSStatus err = noErr;  
FSRef *foo;  
Boolean isDirectory = TRUE;  
NSString *myString = @"this is my damn string.";  
err = FSPathMakeRef((UInt8 *) "/Users/clu/code/", foo, &isDirectory);
 
 
As far as I can tell, lines 4 and 5 have absolutely nothing to do with each other. Yet, it breaks when I have both lines uncommented. Objective-C, wth?
Tube Replacement for a Marshall
Posted by clu 9 years ago
I need to get my tubes replaced. Any suggestions? For a Marshall JCM 900 4100 Dual Reverb head.  
 
Currently using Marshall EL34s. I want to stick with EL34s, but am unsure which brand of EL34s. So many to choose from. For example.  
 
Also, I'm thinking about having it modded as well. So if anyone has an information along those lines, that would be super swell.
You must remake movies.
Posted by clu 9 years ago
If you were a director, which movies from your childhood would you want to remake for today's audiences? And don't get all preachy about how remakes are lame, as this is hypothetical, and most of all, for fun.  
 
My choices:  
 
Time Bandits  
Robocop  
TRON  
Clash of the Titans  
War Games  
 
Vote or Die!
Posted by clu 9 years ago
Wok This Way
Posted by clu 9 years ago
 
 
Just two more coats, and our new wok will be properly seasoned. Does anybody have any recipe recommendations?
Robot Dreams
Posted by clu 9 years ago
Mario the Plumber
Posted by clu 9 years ago
Mario the Plumber
John McCursion 2
Posted by clu 9 years ago
John McCursion
Posted by clu 9 years ago
Built with Hope
Posted by clu 9 years ago
 
 
Click here for the Processing version..
huzzuh!
Posted by clu 9 years ago
My recursion animation generator works!!  
 
 
 
This
Posted by clu 9 years ago
"And from a purely practical political  
vantage point, please find me a swing  
voter, an undecided independent, or a torn  
female voter that finds an angry mob  
mentality attractive."  
 
-John Weaver, McCains former top strategist  
source
Paranoids 0 - 3
Posted by clu 9 years ago
Paranoid 0
Paranoid 1
Paranoid 2
Paranoid 3
Processing Experiments 15 - 18
Posted by clu 9 years ago
Processing Experiment 15
Processing Experiment 16
Processing Experiment 17
Processing Experiment 18  
Paranoids
Posted by clu 9 years ago
Paranoid built with Processing.  
 
Paranoids is based on the Rorschach inkblot test, where "Psychologists use this test to try to examine the personality characteristics and emotional functioning of their patients."  
 
When I'm looking at the generated images, I see monsters, aliens, mechs, robots with gun turrets, insects, etc. However, where I see monsters, you may see kittens. So I'm unsure of what this says about my state of mind. :)  
 
Click here to generate your own Paranoids. Built with Processing.  
 
Reposted from my blog.
...
Posted by clu 9 years ago
Maverick. Just sayin'.
The next four Processing Experiments 11-14
Posted by clu 9 years ago
Processing Experiment 11Processing Experiment 12Processing Experiment 13Processing Experiment 14
Processing Experiments 7 - 10
Posted by clu 9 years ago
Processing Experiment 7
Processing Experiment 8
Processing Experiment 9
Processing Experiment 10  
 
Built with Processing.
Built with Processing.
Posted by clu 9 years ago
Been honing my n00b Processing skills this past week:  
 
Processing Experiment 0
Processing Experiment 1
Processing Experiment 2
Processing Experiment 3
Processing Experiment 4
Processing Experiment 5
Processing Experiment 6