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 abc | |
import random | |
import logging | |
import pyglet | |
from pglib import utils | |
from pglib.region import Region | |
from pglib.samplers.range import Range | |
from pglib.geometry.point import Point2d |
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
from functools import partial | |
import nodebox.graphics as nbg | |
import nodebox.graphics.context as nbc | |
def grid( width, height, spacing, stroke ): | |
for x in range( 0, width, spacing ): | |
nbg.line( x, 0, x, height, stroke=stroke ) | |
for y in range( 0, height, spacing ): |
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 os | |
import sys | |
import random | |
import nodebox.graphics as nbg | |
thisDirPath = os.path.dirname( os.path.abspath( __file__ ) ) | |
uberPath = os.path.join( thisDirPath, '..' ) | |
if uberPath not in sys.path: | |
sys.path.append( uberPath ) |
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 os | |
import sys | |
import nodebox.graphics as nbg | |
thisDirPath = os.path.dirname( os.path.abspath( __file__ ) ) | |
uberPath = os.path.join( thisDirPath, '..' ) | |
if uberPath not in sys.path: | |
sys.path.append( uberPath ) | |
from uberNode import UberNode |
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
# Cantor set done with nodebox-opengl. | |
# https://github.com/nodebox/nodebox-opengl/tree/master/nodebox/graphics | |
import random | |
import nodebox.graphics as nbg | |
STEP_HEIGHT = 20 | |
BUF_HEIGHT = 5 | |
MAX_DEPTH = 8 |