Ejemplo n.º 1
0
def setup():
    """
    The processing setup statement
    """
    size(500, 500)
    background(200, 200, 0)
    stroke(0, 100, 0)
    plant0 = grammar.repeat(4, AXIOM, RULES)
    plant1 = grammar.repeat(5, AXIOM, RULES)    
    plant2 = grammar.repeat(4, AXIOM, RULES)
    render(plant1)
    translate(-100, 10)
    render(plant0)
    translate(200, 0)
    render(plant2)  
    print grammar.toRuleString(AXIOM, RULES)
Ejemplo n.º 2
0
def setup():
    """
    The processing setup statement
    """
    size(800, 600)
    global production
    production = grammar.repeat(17, AXIOM, RULES)
Ejemplo n.º 3
0
def setup():
    """
    The processing setup statement
    """
    size(800, 600)
    global production
    production = grammar.repeat(17, AXIOM, RULES)
Ejemplo n.º 4
0
def setup():
    """
    The processing setup statement
    """
    size(500, 500)
    background(200, 200, 0)
    stroke(0, 100, 0)
    plant0 = grammar.repeat(4, AXIOM, RULES)
    plant1 = grammar.repeat(5, AXIOM, RULES)
    plant2 = grammar.repeat(4, AXIOM, RULES)
    render(plant1)
    translate(-100, 10)
    render(plant0)
    translate(200, 0)
    render(plant2)
    print grammar.toRuleString(AXIOM, RULES)
Ejemplo n.º 5
0
def setup():
    """
    Is the processing setup function
    """
    size(500, 500)
    background(0)
    stroke(255)
    production = grammar.repeat(7, AXIOM, RULES)
    translate(width * 0.9, height * 0.9)
    render(production)
Ejemplo n.º 6
0
def setup():
    """
    Is the processing setup function
    """
    size(500, 500)
    background(0)
    stroke(255)
    production = grammar.repeat(7, AXIOM, RULES)
    translate(width*0.9, height*0.9) 
    render(production)  
Ejemplo n.º 7
0
def setup():
    """
	Processing setup method
	"""
    size(600, 600, OPENGL)
    __configureOpengl()
    cam = PeasyCam(this, 100)
    cam.setMinimumDistance(200)
    cam.setMaximumDistance(500)
    global production  # Initialize production in setup, use in draw.
    production = grammar.repeat(3, AXIOM, RULES)
Ejemplo n.º 8
0
def setup():
    """
    The processing setup statement
    """
    size(600, 600)
    production = grammar.repeat(7, AXIOM, RULES)
    background(100, 0, 0)
    smooth()
    strokeWeight(3)
    stroke(YELLOW)
    render(production)
Ejemplo n.º 9
0
def setup():
	"""
	Processing setup method
	"""
	size(600, 600, OPENGL)
	__configureOpengl()
	cam = PeasyCam(this, 100) 
	cam.setMinimumDistance(200)
	cam.setMaximumDistance(500)
	global production    # Initialize production in setup, use in draw.
	production = grammar.repeat(3, AXIOM, RULES)
Ejemplo n.º 10
0
def setup():
    """
    The processing setup statement
    """
    size(700, 900, P2D)
    background(255)
    hint(ENABLE_NATIVE_FONTS)
    smooth()
    production = grammar.repeat(5, AXIOM, RULES)
    strokeWeight(2)
    #render(production) # now redundant could be used if pdf render not working?
    renderToPDF(production)
Ejemplo n.º 11
0
def setup():
    """
    The processing setup statement
    """
    size(600, 600)
    production = grammar.repeat(6, AXIOM, RULES)
    background(0, 0, 255)
    smooth()
    stroke(255, 255, 0)
    strokeWeight(3)
    render(production)
    saveFrame("mpeano.png")
Ejemplo n.º 12
0
def setup():
    """
    The processing setup statement
    """
    size(700, 900, P2D)
    background(255)
    hint(ENABLE_NATIVE_FONTS)
    smooth()
    production = grammar.repeat(5, AXIOM, RULES)
    strokeWeight(2)
    #render(production) # now redundant could be used if pdf render not working?
    renderToPDF(production)
Ejemplo n.º 13
0
def setup():
    """
    The processing setup statement
    """
    size(500, 500, OPENGL)
    configure_opengl()
    cam = PeasyCam(this, -70, 70, -70,250)
    cam.setMinimumDistance(height/10)
    cam.setMaximumDistance(height)    
    global production
    production = grammar.repeat(3, AXIOM, RULES)    
    noStroke()
    fill(200, 0, 180)