This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include "csdl.h" | |
#include "jakesine.h" | |
int jakesine_init (CSOUND *csound, JAKESINE *p) | |
{ | |
p->inc = *p->freq_in * csound->tpidsr; | |
p->phase = *p->phase_in * TWOPI; | |
return OK; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// force certain pages to be refreshed every time. mark such pages with | |
// 'data-cache="never"' | |
// | |
jQuery('div').live('pagehide', function(event, ui){ | |
var page = jQuery(event.target); | |
if(page.attr('data-cache') == 'never'){ | |
page.remove(); | |
}; | |
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
Functional programming in C | |
``````````````````````````` | |
This is an example of how to use executable memory to get partial function | |
application (i.e. bind1st()) in C. (Well, this actually only compiles as C++ | |
since i'm using a varargs typedef, but there's no classes or templates.) | |
To proceed, we need to be comfortable with the cdecl and stdcall calling | |
conventions on x86, and just a little assembly. |
NewerOlder