1. NodeBox 1
    1. Homepage
    2. NodeBox 3Node-based app for generative design and data visualization
    3. NodeBox OpenGLHardware-accelerated cross-platform graphics library
    4. NodeBox 1Generate 2D visuals using Python code (Mac OS X only)
  2. Gallery
  3. Documentation
  4. Forum
  5. Blog

problem with clipping paths

Posted by Giorgio Olivero on Mar 14, 2007

Hello nodeboxer,

I'm trying out the path clipping functions.

There some kind of drawing bug if you run a script like this:

size(800,800)
 
pathList = []
 
for i in range(10):
    path = oval(30*i, 10, 40, 40, draw=False)
    pathList.append(path)
    beginclip(pathList[i])
    rect(30*i, 0, 10, 50)
    endclip()


Am I typing something wrong? Is there a workaround?

thanks
Giorgio



Posted by Tom De Smedt on Mar 16, 2007

Yes, this is an old and stubborn bug. One clipping path works, but when you add more, their content appears "flipped" on screen (along with all sorts of weird drawing problems). Ironically, PDF output is still OK.

I don't really know of any workaround. We will simply have to fix the bug.



Posted by Giorgio on Mar 16, 2007

Hi Tom,

actually.. the pdf output from the example code above is exactly the same as the screen result.