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
| """Perlin noise implementation.""" | |
| # Licensed under ISC | |
| from itertools import product | |
| import math | |
| import random | |
| def smoothstep(t): | |
| """Smooth curve with a zero derivative at 0 and 1, making it useful for | |
| interpolating. |
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
| import sys | |
| import ply.yacc as yacc | |
| import ply.lex as lex | |
| tokens = ( | |
| 'INCREMENT', | |
| 'DECREMENT', | |
| 'SHIFT_LEFT', | |
| 'SHIFT_RIGHT', | |
| 'OUTPUT', |
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
| <?xml version="1.0" encoding="UTF-8"?> | |
| <!-- | |
| File based about the file "sh.lang" present in GtkSourceView | |
| Author: Nicola Jelmorini <jelmorini@protonmail.ch> | |
| Copyright (C) 2014 Nicola Jelmorini <jelmorini@protonmail.ch> | |
| This file is free software; you can redistribute it and/or | |
| modify it under the terms of the GNU Lesser General Public | |
| License as published by the Free Software Foundation; either |
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
| // very basic embedded Ruby interpreter for C++ programs | |
| // thrown together by Jeff Trull <jetrull@sbcglobal.net> based on googling and asking questions on #ruby-lang | |
| #include <ruby.h> | |
| // access to C variables | |
| static VALUE getter(VALUE ns, VALUE var) { | |
| return Qfalse; | |
| } | |
| VALUE setter(VALUE ns, VALUE var, VALUE val) { |