Version 0.7.0
We are happy to announce another developmental release from Google Summer of Code! 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
normal_material
assigns a color to a pixel solely based on the normal vector of the fragment being rendered. Useful for debuggingbasic_material
returns a uniform color.blinn_phong_material
is a material based on the Blinn-Phong reflection model. This is the most “realistic” material in p5py. Parameters to adjust it includeambient
is the color that interacts withambient_lights
diffuse/emissive
is the surface color that interacts withpoint_light
s anddirectional_light
sspecular
is the highlight color that interacts withpoint_light
s anddirectional_light
sshininess
determines how glossy a surface is
- Lighting system in P3D
lights
creates default lightsambient_light
is a light that's uniform everywheredirectional_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 highlightlight_falloff
controls how fast a light fades with distance
List of issues fixed in this release
- #31 Implement saveFrame()
- #155 Output canvas to video or sequence of png's
- #156 push_matrix() and pop_matrix() not working
- #158 no_loop incorrectly allows an extra draw frame
- #172 begin_contour and end_contour not working
- #175 no_loop() when used in setup() don't call draw() but it should call draw() only once
- #152 Occlusion of shapes in 3D Mode
- #180 Tutorial wrong? pop_matrix() does nothing, but should be refered as reset_matrix() instead
- #167 end_shape() is closing shapes without 'CLOSE'
- #188 Inconsistent behavior for Arc
- #195 Not able to create holes in a shape using begin and end contour
- #201 remap map to remap
- #141 AttributeError: 'Geometry' object has no attribute 'children'
- #173 The quest for better tessellation
- #183 Scalling with scale(1,0) does nothing. but scale(0,1) works
- #217 Bug: Does not install or get the shaders directory
- #213 Add support for renderer attribute in run() function
- #222 Update installation scripts
- #174 Add 3D material and lighting APIs
- #66 VS Code + pylint integration with p5
This release also includes contributions from @parsoyaarihant, @jeremydouglass, @tushar5526, @Hansimov, @ReneTC, @Andy-Python-Programmer, and @galaxyproduction. Thank you!