Releases: pygfx/pygfx
v0.15.3
Full Changelog: v0.15.2...v0.15.3
v0.15.2
A hotfix that updates the upper bounds for dependencies rendercanvas and wgpu-py.
This is not a reflection of main at the time of release, but basically v0.15.0 with updated dependency bounds.
Full Changelog compared to 0.15.0: v0.15.0...v0.15.2
v0.15.0
What's Changed
- fix typo in marker exception message by @kushalkolar in #1214
- remove assert in sprite, some cleanup by @kushalkolar in #1216
- Add six-legged asterisk marker by @almarklein in #1219
- account for transform of instanced objects for calculating bbox by @kushalkolar in #1220
- use
pylinalg>=0.6.8,<7.0by @kushalkolar in #1225
Full Changelog: v0.14.0...v0.15.0
v0.14.0
What's Changed
Added:
- Per-vertex markers by @almarklein in #1208 and #1211
- Support for proper tick marks by adding a 'tick' marker and rotation_mode 'curve' by @almarklein in #1209
- Add Eye Dome Lighting (EDL) EffectPass by @mortacious in #1200
Changed:
- Remove last use of wgpu.gui by @almarklein in #1198
- Update for new imgui by @almarklein in #1196
- Use font-awesome again in 2 examples by @almarklein in #1201
- Encode face coords as 2x9 bits instead of 3x6 bits by @limdaepl in #1206
- Update ssaa.wgsl and ddaa.wgsl by @almarklein in #1207
Other:
- Adjust to new Ruff by @almarklein in #1195
- Allow up to wgpu 0.25 by @hmaarrfk in #1205
- No upper bounds on versions of dependencies by @almarklein in #1212
New Contributors
- @mortacious made their first contribution in #1200
Full Changelog: v0.13.0...v0.14.0
v0.13.0
Introduction
This release represents a lot of work on refactoring how PyGfx deals with transparency. We recommend reading https://docs.pygfx.org/latest/transparency.html to learn how PyGfx works now.
The most important changes related to transparency:
The renderer.blend_mode is no more. Some modes like the 'ordered2' and 'weighted_plus' no longer exist. Instead, you can now set material.alpha_mode on each object separately. Yes, you can mix different modes in the same scene.
It does mean that as a user you'll have to be a bit more aware of whether your objects are transparent, and how to approach that. In short, the default material.alpha_mode='auto' works fine for opaque and most semi-transparent objects, as well as for objects that have mixed opaque/transparent fragments. But if you know your object is opaque, use alpha_mode='solid', and if it's transparent, use alpha_mode='blend'. For more context check https://docs.pygfx.org/latest/transparency.html#a-quick-guide-to-select-alpha-mode
We also changed some things on how we approach anti-aliasing:
- The SSAA (super-sample anti-aliasing) that we already applied now uses an improved filter (the Mitchell filter). The same improved filter is also used for upsampling. Also see the new
renderer.pixel_scaleandrenderer.pixel_filter. - We added support for PPAA (post-processing anti-aliasing) to improve the smoothness of the rendered result. It's enabled by default. See the new
renderer.ppaa. - The
material.aafor text lines and points is now off by default, to prevent blending artifacts. Though we recommend turning it on for text for higher quality glyphs. - See https://docs.pygfx.org/latest/aa.html for details.
API changes
Objects and materials:
- Removed
WorldObject.render_mask. - Added
Material.alpha_mode, default is 'auto'. - Adeded
.alpha_config,.alpha_method(settingalpha_modealso sets these). - Added
Material.render_queue, default is None (auto). - Added
Material.depth_write, default is None (auto). - Added `Material.depth_compare, default is "<".
- Added
Material.alpha_test. - Added
Material.alpha_compare, default is "<". - Removed
material.color_is_transparentforLine,Mesh,Points,Text. Usematerial.color.a < 1instead. - Removed
material.edge_color_is_transparentforPoints. Usematerial.edge_color.a < 1instead. - Removed
material.outline_color_is_transparentforText. Usematerial.outline_color.a < 1instead.
Renderer:
- Removed
Renderer.blend_mode. - The
renderer.sort_objectsis True by default. - The renderer's sorting logic is completely overhauled.
- Added
renderer.effect_passes. - Added
renderer.ppaa. - Added
renderer.pixel_scale. - The
renderer.pixel_filteris now a string instead of an int. - Added
renderer.clear()to clear render targets.
Commits
Changes related to transparency and anti-aliasing
- Simplify blending by @almarklein in #1002
- Add support for post-processing effects by @almarklein in #1114
- Improve the interpolation filter in flush by @almarklein in #1121
- Fix that snapshot may not include the last effect by @almarklein in #1126
- Syncing ssaa.wgsl by @almarklein in #1131
- Improve dithered alpha_mode by @almarklein in #1139
- Add support for FXAA and DDAA by @almarklein in #1117
- remove unused variable in image_stitching example by @hmaarrfk in #1143
- Add docs for blending by @almarklein in #1124
- Implement material.alpha_mode to replace .blending and .transparent by @almarklein in #1144
- Allow calling renderer.clear(depth=True, color=True) by @hmaarrfk in #1170
- Rename alpha-method 'composite' to 'blended' by @almarklein in #1172
- Add renderer.pixel_scale by @almarklein in #1174
- Turn off material.aa by default by @almarklein in #1171
- Enable weighted blending between calls to render by @hmaarrfk in #1148
- Add docs on aa by @almarklein in #1173
- Make background use alpha_mode and render_queue correctly by @almarklein in #1180
- Add material.alpha_method (readonly) by @almarklein in #1184
- Refactor logic related to 'auto' mode by @almarklein in #1186
- Tweak docs by @almarklein in #1188
- Add arg to Ruler for alpha_mode of child objects by @almarklein in #1189
- Remove that material.opacity affects alpha logic by @almarklein in #1190
- Small tweak to docs of render_queue by @almarklein in #1194
Changes to the engine
- Add support for custom orbit center in OrbitController by @panxinmiao in #1115
- Cloth Simulation with Compute Shaders by @panxinmiao in #1116
- Fix that the ruler did not take world transform into account by @almarklein in #1130
- update roll by @sawbz in #1134
- Fix pan in orbit controller by @almarklein in #1135
- fix GLTFMaterialsSheenExtension by @panxinmiao in #1150
- Fixed some edge cases in the Interpolant by @panxinmiao in #1154
- Implement GpuCache with LRU strategy (split from #974) by @panxinmiao in #1142
- Add
EXT_texture_webpsupport by @panxinmiao in #1155 - Support
KHR_draco_mesh_compressionby @panxinmiao in #1159 - Fix keyframe optimization by @panxinmiao in #1166
- Fix docstring of get_bounding_box by @almarklein in #1178
- Make sure the pick face coords add up to one by @almarklein in #1179
- Support GLTF alphaMode by @almarklein in #1177
- Dereference world-object in case its a weakproxy by @almarklein in #1183
- Can use wgpu 0.23 by @almarklein in #1193
Other changes
- Use rendercanvas in all our examples by @almarklein in #1127
- Minor tweaks to avoid warnings in CI by @almarklein in #1129
- Fix vertical text because uharfbuzz 0.51 broke something by @hmaarrfk in #1151
- Update uharfbuzz constraint for future proofing by @hmaarrfk in #1152
- Adjust how version is reported when one checkouts a tag by @hmaarrfk in #1153
- Update validation example screenshot by @almarklein in #1161
- updated "expected 1.0" to 1 year from today by @hmaarrfk in #1160
- Add dedicated email address to coc by @almarklein in #1181
- Update _version.py by @almarklein in #1185
- Add slotscheck to CI by @almarklein in #1187
- Switch to trusted publishing for PyPI publish in CI by @EpicWink in #1192
New Contributors
Full Changelog: v0.12.0...v0.13.0
v0.12.0
What's Changed
- Add option to ScreenCoordsCamera to invert y by @almarklein in #1092
- Ray tracing example by @panxinmiao in #1068
- Support texture transform by @panxinmiao in #999
Full Changelog: v0.11.0...v0.12.0
v0.11.0
What's Changed
Some more improvements related to camera and depth
- Camera with fov==0 does not move backwards when zooming out by @almarklein in #1090
- Set ruler's z-position closer to origin to avoid ruler disappearing when camera.depth is small by @almarklein in #1101
User-facing changes
- Drop Python 3.9 because its already broken, and bump CIs by @hmaarrfk in #1104
- Pass through worldobject parameters from Text Object by @hmaarrfk in #1102
- Promote the use of VolumeMipMaterial instead of the VolumeRayMaterial base class by @almarklein in #1107
Internal (and low-level) changes
- fix pre-computed tangents by @panxinmiao in #1088
- Uniform buffers can now handle vec3 and matnx3 by @almarklein in #1091
- Fix matnx3 fields in uniforms by @almarklein in #1094
- Migrate to
logger.warningby @emmanuel-ferdman in #1098
New Contributors
- @emmanuel-ferdman made their first contribution in #1098
Full Changelog: v0.10.0...v0.11.0
v0.10.0
What's Changed
Camera's and controllers
- Add
match_aspectarg to camera.show_object() by @almarklein in #1051 - Change controller.add_camera so it does not change camera order by @almarklein in #1086
- add
Controller.pausecontext manager by @kushalkolar in #1080 Camera.get_state()returns new copy of the array instead of a view by @kushalkolar in #1076- Improvements to cameras by @almarklein in #1085
- Added
camera.depththat gets automaticallet bycamera.show_()methods. Can be manually set in cases where the depth is very different from width and height. - Avoid depth clip issues when zooming in by calculating depth range using
depth.. - The
Rulerno longer reports a bounding box, so that axii in the scene no longer breakcamera.show_object(). - The OrthographicCamera no longer move in the view direction (typically z-axis) as it zooms. Note that a PerspectiveCamera with
fov==0still does.
- Added
Rendering
- Add support for loops to line object by @almarklein in #1056
- Add LineInfSegmentMaterial for infinite lines by @almarklein in #1072
- Refactor engine's resolving of fragment shader output by @almarklein in #1053
- Fix pick info inheritance by @limdaepl in #1057
- Instanced lines by @limdaepl in #1058
Examples
- Create background subtraction example by @kingbedjed in #1067
- Example to compute histogram using a compute shader by @almarklein in #1063
Other
- Small cleanups for the CI pipeline by @berendkleinhaneveld in #1061
- Don't throw AttributeError when calling dict attributes by @berendkleinhaneveld in #1062
- Make the Store track hashable objects by value by @almarklein in #1066
- Properly implement
register_wgsl_loaderby @almarklein in #1083 - Increase upper bound to wgpu version by @almarklein in #1074
New Contributors
- @limdaepl made their first contribution in #1057
- @kingbedjed made their first contribution in #1067
Full Changelog: v0.9.0...v0.10.0
v0.9.0
API changes
The biggest change in the release is that we made the geometry a simple object to contain buffers and textures. It does not have any methods, and you should probably not subclass it.
- Move Text API and implementation to Text world object by @almarklein in #1034
TextGeometryandMultiTextGeometryare gone. UseTextandMultiTextinstead.- See #1034 for a small migration guide.
- Remove
get_bounding_box()from geometry by @almarklein in #1042 - Make geometry a simple Store by @almarklein in #1044
Behavioral changes
- Change colormap interpolation to be consistent by @almarklein in #1025
New features
- Support marker rotation by @hmaarrfk in #1027
- Support for custom colormaps, and lazy loading by @almarklein in #1031
- Support βKHR_lights_punctualβ by @panxinmiao in #1030
- Add Anisotropy support by @panxinmiao in #1037
- Add Sheen support by @panxinmiao in #1039
Other changes
- Allow wgpu 0.19 - 0.21 by @almarklein in #1043
- Improve tracking of bindings by @almarklein in #1026
- Unified mesh texture map logic and special treatment for colormaps by @panxinmiao in #1008
- Rename internal define_colormap() func for clarity by @almarklein in #1032
- Early exit in buffer/texture update_xx methods by @almarklein in #1033
- Refactor IBL related code by @panxinmiao in #1035
- Fix and enhance normal map and tangents by @panxinmiao in #1036
- Add back the text "dither" in the validation example by @hmaarrfk in #1040
- Fix test on windows by @almarklein in #1038
- No longer set the Bone object as invisible by default by @panxinmiao in #1041
- Fix morph on MacOS by @almarklein in #1046
- Small typo fix by @kevinyamauchi in #1050
Full Changelog: v0.8.0...v0.9.0
v0.8.0
Summary
It's been a while, so quite a lot of changes! The gltf support has been improved a lot, the transform system has been optimized for performance, gamma prop for image and volume materials, improved text rendering (inc. multi-text), faster clipping planes, and much more!
API changes
- Added
ImageBasicMaterial.gammaandVolumeBasicMaterial.gamma. - Added
PointsMarkerMaterial.edge_color_mode. - Added
MeshPhysicalMaterial.iridescence,.iridescence_ior, and.iridescence_thickness_range. - Added
MultiTextGeometryandTextBlockfor efficiently handling multiple texts (e.g. labels). - Added
TextGeometry.max_width,.paragraph_spacing, added Markdown support for headers and bullets, and support for vertical text.
PRs merged
- Tweak caching of shadow pipeline by @almarklein in #935
- Implement GLTFCubicSplineInterpolant by @panxinmiao in #936
- Refactor environment and pipeline by @almarklein in #912
- Add MeshPhysicalMaterial with Clearcoat, Specular, and IOR Support by @panxinmiao in #908
- Associate pipeline-container also with Material by @almarklein in #939
- Add
package_nameas an argument forload_wgslby @m-agour in #943 - Fix ior & specular not work correctly by @panxinmiao in #942
- Refactor the plugin extension mechanism of the glTF loader by @panxinmiao in #940
- Cache camera matrices by @Korijn in #945
- Fix CI by pinning trimesh by @almarklein in #952
- Tweak some docstrings by @almarklein in #949
- Optimize last_modified tracking by @Korijn in #950
- Refactor to have a single scene traverse in the renderer by @almarklein in #953
- Tweak the method names that update world objects by @almarklein in #955
- Make
bind_matrixa read-only property, and clean upnp.linalg.inv. by @panxinmiao in #948 - Auto update skeleton and skeleton_helper by @panxinmiao in #894
- decrease minimum version of imgui-bundle by @hmaarrfk in #958
- Add more details on drivers in install instructions by @almarklein in #959
- add gamma to image and volume by @tlambert03 in #957
- Add typing to
objects._baseby @tlambert03 in #960 - π RecursiveTransform optimization by @Korijn in #963
- Add typing to Geometry and Material by @tlambert03 in #961
- Update CI badge by @Korijn in #964
- β‘ Micro optimization by @Korijn in #965
- β‘β‘ Micro-optimized flag_update again by @Korijn in #969
- Improve z fighting control for text by @hmaarrfk in #968
- Add support for edge_colors on a per vertex for Points by @hmaarrfk in #970
- Provide a path for end users to register their own blenders by @hmaarrfk in #966
- Add slots to transform objects by @Korijn in #971
- Reduce intermediate array usage in Transform by @Korijn in #973
- Set writeable false in appropriate places, clean up a few computations by @Korijn in #977
- Fix typo in guide.rst by @boisgera in #983
- No need to divide by the length of a unit vector in grid by @hmaarrfk in #984
- Add Iridescence support to MeshPhysicalMaterial by @panxinmiao in #980
- Components setter & animation optimization by @Korijn in #978
- Stabilize ruler step calculation to avoid grid flicker by @almarklein in #986
- Colormap clamp by @almarklein in #987
- Improve performance of wobject.world.position by @Korijn in #988
- Add glTF Extension: "KHR_materials_emissive_strength" by @panxinmiao in #994
- Use correct diffuse color by @panxinmiao in #991
- Fix clearcoat_roughness_map channel by @panxinmiao in #997
- Micro optimize video decoding by @hmaarrfk in #993
- Generate mipmaps using RenderPipline and linear interpolation downsampling by @panxinmiao in #995
- Add "KHR_materials_unlit" support by @panxinmiao in #1004
- Multitext and text refactoring by @almarklein in #834
- Update gitignore by @panxinmiao in #1009
- Text performance tweaks by @almarklein in #1006
- Use single buffer to store per-glyph data by @almarklein in #1010
- Fix waterfall example by @almarklein in #1012
- Refactor punctual light shading code by @panxinmiao in #1016
- Prevent glyphs from bleeding into neighbours in atlas by @almarklein in #1014
- Fix for latest trimesh by @almarklein in #1017
- Fix TransformGizmo.set_object when object is
Noneby @schlegelp in #1020 - Add image comparator example by @hmaarrfk in #1019
- Improve clipping planes by @panxinmiao in #1022
- fix two bugs in atlas allocator by @hmaarrfk in #1021
- Ruler use multitext by @almarklein in #1018
- Bump version by @almarklein in #1023
New Contributors
Full Changelog: v0.7.0...v0.8.0