question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

To reproduce:

from sdf import *
f = slab()

Output:

  File "example.py", line 3, in <module>
    f = slab()
  File "C:\Users\Brandon\Documents\GitHub\sdf\sdf\d3.py", line 49, in wrapper
    return SDF3(f(*args, **kwargs))
  File "C:\Users\Brandon\Documents\GitHub\sdf\sdf\d3.py", line 133, in slab
    return intersection(*fs, k=k)
  File "C:\Users\Brandon\Documents\GitHub\sdf\sdf\d3.py", line 54, in wrapper
    return SDF3(f(*args, **kwargs))
TypeError: intersection() missing 1 required positional argument: 'a'```

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Comments:5 (3 by maintainers)

github_iconTop GitHub Comments

1reaction
foglemancommented, Feb 4, 2021

In fact, maybe it shouldn’t be defined like a primitive at all. And instead be like an “operator” that functions on another SDF:

sphere(1).cut(z0=-0.2, z1=0.2)

0reactions
pomeroybcommented, Feb 5, 2021

There are a couple primitives that act like that (Plane and non-capped Cylinder). I’ve been differentiating them by referring to them as “non-meshable” in the comments: https://github.com/pomeroyb/sdf/blob/main/sdf/d3.py#L119

But hiding the pseudo-primitives behind a function will probably be easier for new users to understand. Something like sphere(1).hole(radius=0.25) for a cylinder and sphere(1).section((1,1,0) for a plane.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Slab Over a Damaged Slab
A.: If built on a very rough base of broken concrete, the new concrete slab would undoubtedly crack. We suggest you don't break...
Read more >
Can You Repair a Damaged Concrete Slab?
Do you need to seek concrete slab repair services or would like to fix a broken slab yourself? Learn more in our handy...
Read more >
Where to use Broken Slab Resident Evil Village - YouTube
Where to use Broken Slab Resident Evil Village video. Where to use Broken Slab gameplay is related to the Resident Evil Village game....
Read more >
Resident Evil 8 Village How To Get Beneviento's ... - YouTube
Location of the broken slab and solution to Beneviento's treasure in RE8 Village.Get The Game Here & Support The Channel: ...
Read more >
How to Replace a Broken Sidewalk Slab
Separate the section of broken slab by cutting each of the control-joint lines at the adjacent sections of the sidewalk with a jackhammer...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found