0.7.0 - 0.7.1

In GSOC 2020 two releases were published. The goals of the project were:

  1. Standardize p5py API so it’s as close as possible to that of the Processing Language (Java Mode) while being reasonably pythonic (e.g. supporting some python-only features and syntax)
  2. Explore moving tessellation of shapes to OpenGL for improved performance
  3. Improve 3D support

We met all of these goals completely. In addition, the following stretch goals were completed:

  1. Implement a profiling harness to measure performance improvements
  2. Fix existing bugs

0.7.0

We are happy to announce another developmental release from Google Summer of Code! The project was supervised by Arihant Parsoya and Abhik Pal of the Processing Foundation. This release includes bug fixes, a refactored rendering pipeline with improved performance, new 3D capabilities, and new example code.

List of New APIs

New materials in P3D

Lighting system in P3D

  • lights creates default lights
  • ambient_light is a light that’s uniform everywhere
  • directional_light comes from one direction: it is stronger when hitting a surface squarely, and weaker if it hits at a gentle angle.
  • point_light comes from one location and emits to all directions.
  • light_specular controls the color of the specular highlight
  • light_falloff controls how fast a light fades with distance

This release also includes contributions from @parsoyaarihant, @jeremydouglass, @tushar5526, @Hansimov, @ReneTC, @Andy-Python-Programmer, and @galaxyproduction. Thank you!

0.7.1

We are happy to announce another developmental release from Google Summer of Code! The project was supervised by Arihant Parsoya and Abhik Pal of the Processing Foundation. This is the final release for GSOC this year and includes API refactors, addtions, and bug fixes with compatibility and stability as a focus.

List of New APIs

  • fract calculates the fractional part of a number. Contributed by @tushar5526
  • http_get and http_post makes HTTP requests to the web. Contrbuted by @nakul-shahdadpuri
  • pop_matrix and pop_style are alternatives to the context manager syntax used by previous version. Accordingly, push_matrix and pop_matrix can now both act as context managers and be directly called like in Processing or p5.js

The following additional signatures are added for compatibility with other Processing dialects

  • line(x1, y1, x2, y2)
  • line(x1, y1, z1, x2, y2, z2)
  • ellipse(a, b, c, d, mode=None)
  • circle(x, y, radius, mode=None)
  • arc(x, y, width, height, start_angle, stop_angle, mode=None, ellipse_mode=None)
  • image(img, x, y)
  • image(img, x, y, w, h)
  • triangle(x1, y1, x2, y2, x3, y3)
  • quad(x1, y1, x2, y2, x3, y3, x4, y4)
  • rect(x, y, w, h)
  • square(x, y, side_length)
  • bezier(x1, y1, x2, y2, x3, y3, x4, y4)
  • bezier(x1, y1, z1, x2, y2, z2, x3, y3, z3, x4, y4, z4)
  • curve(x1, y1, x2, y2, x3, y3, x4, y4)
  • curve(x1, y1, z1, x2, y2, z2, x3, y3, z3, x4, y4, z4)
  • camera(position_x, position_y, position_z, target_x, target_y, target_z, up_x, up_y, up_z)
  • camera(position, target_position, up_vector)
  • text(text_string, x, y)
  • text(text_string, x, y, z)

The following functions can now take floats and tuples of arbitrary length

  • bezier_point
  • bezier_tangent
  • curve_point
  • curve_tangent
  • quadratic_point

This release also includes contributions from @nakul-shahdadpuri, @tushar5526, and @parsoyaarihant. Thank you!