diff --git a/CHANGELOG.md b/CHANGELOG.md index 1209d20fe..52f3c6d66 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -27,6 +27,7 @@ - Fixed differentiability of `wp.fem.PicQuadrature` w.r.t. positions and measures - Improve error messages for unsupported constructs - Update `wp.matmul()` CPU fallback to use dtype explicitly in `np.matmul()` call +- Fix ShapeInstancer `__new__()` method (missing instance return and `*args` parameter) ## [1.2.2] - 2024-07-04 diff --git a/warp/render/render_opengl.py b/warp/render/render_opengl.py index cc69c772d..969a64bf9 100644 --- a/warp/render/render_opengl.py +++ b/warp/render/render_opengl.py @@ -666,10 +666,11 @@ class ShapeInstancer: [3D point, 3D normal, UV texture coordinates] """ - def __new__(cls): + def __new__(cls, *args, **kwargs): instance = super(ShapeInstancer, cls).__new__(cls) instance.instance_transform_gl_buffer = None instance.vao = None + return instance def __init__(self, shape_shader, device): self.shape_shader = shape_shader