This file contains hidden or 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
/* | |
* This was created out of my own study | |
* of lexical analysis and expression | |
* parsing. | |
* | |
* Demo at: http://dev.shin.cl/infixtopostfix/ | |
* | |
* @author Felipe Alfonso | |
*/ | |
(function (scope) { |
This file contains hidden or 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
/* | |
* This was created out of my own study | |
* of lexical analysis and expression | |
* parsing. | |
* | |
* Demo at: http://dev.shin.cl/binaryexpression/ | |
* | |
* @author Felipe Alfonso | |
*/ | |
var NUMS = '0123456789', |
This file contains hidden or 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 <stdio.h> | |
#include <stdlib.h> | |
#include <math.h> | |
#define PRECISION 0.00001f | |
double SQRT (double input); | |
double SQRT_PREC (const double *input, double precision); | |
int main (int argc, char **argv) { |
This file contains hidden or 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
using UnityEngine; | |
using System.Collections; | |
namespace SortingOrder | |
{ | |
[RequireComponent(typeof(Renderer))] | |
public class SortComponent : MonoBehaviour { } | |
} |
This file contains hidden or 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
; 6502 STACK BASED CALCULATOR. | |
; THE FIRST ARGUMENT MUST BE | |
; THE ID FOR THE OPERATION. | |
; 1 = ADDITION | 2 = SUBTRACTION | |
; 3 = MULTIPLICATION | 4 = DIVITION | |
; THE RETURN VALUE OF THE OPERATIONS | |
; IS STORED IN THE TOP OF THE STACK. | |
; | |
; *** NOTE: THIS IS NOT A FAST IMPLEMENTATION *** | |
JMP MAIN |
This file contains hidden or 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
# Jekyll setup for windows | |
# it just follows the instructions | |
# from this website: http://jekyll-windows.juthilo.com/ | |
# If you prefer doing it manually, just visit | |
# the previous website. | |
# | |
# author: Felipe Alfonso | |
# url: http://voidptr.io/ | |
import urllib |
This file contains hidden or 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
struct mat4 | |
{ | |
float data[16]; | |
}; |
This file contains hidden or 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
mat4 mat4_add(mat4& lhs, mat4& rhs) | |
{ | |
float *dat_l = lhs.data; | |
float *dat_r = rhs.data; | |
mat4 result; | |
result.data[0] = dat_l[0] + dat_r[0]; result.data[1] = dat_l[1] + dat_r[1]; | |
result.data[2] = dat_l[2] + dat_r[2]; result.data[3] = dat_l[3] + dat_r[3]; | |
result.data[4] = dat_l[4] + dat_r[4]; result.data[5] = dat_l[5] + dat_r[5]; | |
result.data[6] = dat_l[6] + dat_r[6]; result.data[7] = dat_l[7] + dat_r[7]; |
This file contains hidden or 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
struct mat4 | |
{ | |
union alignas(16) | |
{ | |
struct | |
{ | |
float | |
a, b, c, d, | |
e, f, g, h, | |
i, j, k, l, |
This file contains hidden or 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
inline static void sse_mat4_add(__m128* m0, __m128* m1, __m128* dst) | |
{ | |
__asm | |
{ | |
// First load the args addresses | |
// into ecx, edx and edi registers. | |
mov ecx, m0 | |
mov edx, m1 | |
mov edi, dst | |
// Do a an aligned move of m0 |
OlderNewer