Category: homework

Making my way through the Mixing 2D and 3D objects recipe from the Processing 2 Creative programming cookbook source code on GitHub. In this recipe I learned how to use the ENABLE_DEPTH_TEST and the DISABLE_DEPTH_TEST parameter inside the hint function at the beginning and end of the draw function to to enable and disable the z buffer. This […]

Read more

Making my way through the Making polygon soup recipe from the Processing 2 Creative programming cookbook source code on GitHub. In this recipe I learned how to create a 3D cylinder with a flexible function that allows for the top, bottom and sides of the cylinder to be customised. In this recipe, the QUAD_STRIP parameter (draws a series […]

Read more

Making my way through the Using lights recipe from the Processing 2 Creative programming cookbook source code on GitHub. In this recipe, I learned how to declare the lightMode and lightDirection integers to allow for different lighting modes to be activated. Inside the setUp function they’re assigned a value of 0 and then referenced again in the if test. […]

Read more

Making my way through the Drawing 3D primitives recipe from the Processing 2 Creative programming cookbook source code on GitHub. In this recipe I learned how: the box function can be used with one or three parameters to set different values for depth, width and height of the box. the sphereDetail function can be used to define […]

Read more

Making my way through the Understanding 3D space recipe from the Processing 2 Creative programming cookbook source code on GitHub. In this recipe I learned how set a variable for depth and zSpeed and also how to change the variable inside the draw function for animation. I also learned that if you want to use the rect […]

Read more

Making my way through the Offscreen drawing recipe from the Processing 2 Creative programming cookbook source code on GitHub. In this recipe I learned how to: declare a PGraphics object and then initialise it with the createGraphics function inside the setup function. use the createGraphics function to create a new transparent image to be drawn on and […]

Read more

Making my way through the Manipulating SVG files recipe from the Processing 2 Creative programming cookbook source code on GitHub. In this recipe I learned: more about using the shape function to draw shapes in the display window how to declare the PShape object and create custom variables (snowFlake, small1 to small6 and big1) and the disableStyle, […]

Read more

Making my way through the Drawing custom shapes recipe from the Processing 2 Creative programming cookbook source code on GitHub. In this recipe I learned about some of Processing’s funky functions that can be used to draw custom shapes such as a star and a flower. I also learned about the vertex, beginShape and endShape functions.

Read more

Making my way through the Calculating points on a curve recipe from the Processing 2 Creative programming cookbook source code on GitHub. In this recipe I learned how to use the bezierPoint and curvePoint functions to calculate points on curves and splines. bezierPoint uses five parameters. The first four are coordinates for the anchor and control points […]

Read more

Making my way through the Drawing curves recipe from the Processing 2 Creative programming cookbook source code on GitHub. In this recipe I learned how to use the bezier and curve functions to draw Bezier curves and Catmull-rom splines in the display window. For the Bezier curves in this example, 0 and 20 are the coordinates for the first anchor […]

Read more
css.php