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
typedef unsigned int8 uint8; | |
extern const float sRGBToLinear[1 << 8]; | |
// BlendSRGB blends a uint8 alpha-channel mask onto an RGBA uint8 destination surface, using the OVER operater, | |
// and with gamma-correct blending. The alpha channel is modulated by an RGB color. | |
// | |
// This function was built to draw glyphs that are produced by Freetype. | |
// | |
// nPix: number of pixels to blend |
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
3 Initialize Go project | |
8 DB design (DocMeta, DocBlob, Share, Link) | |
Migration | |
16 Use native Go/Mongo driver - SELECT ALL on everything except Blob | |
8 Test migrations on infraqa, imqsrc, demo | |
While migration is taking place, service must respond to ping. | |
Use regular migration system to ensure correctness. |
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
/* | |
Output: | |
operator= reference copy (same memory) | |
copy_ value copy (different memory) | |
operator= of operator[] value copy (different memory) | |
slice reference copy (same memory) | |
*/ |
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
void FitQuadratic(const std::vector<std::pair<double, double>>& xy, double& a, double& b, double& c) { | |
// http://mathforum.org/library/drmath/view/72047.html | |
/* | |
Now all you have to do is take your data (your eight points) and | |
evaluate the various sums | |
n | |
Sj0 = sum x_i^j | |
i=1 |
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
Images illustrating mode: |
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 <windows.h> | |
#include <stdio.h> | |
#pragma comment(lib, "Advapi32") | |
const int CorpusSize = 26 * 2 + 10; | |
const char Corpus[CorpusSize + 1] = "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789"; | |
int main(int argc, char** argv) | |
{ |