# Halftone 1.0.0

(0 reviews)

## 1 Screenshot

This is my first marionette and it's based on @Marissa Farrell's image processing!

It takes an image and creates a Halftone object of it with black circles:

IMPROVEMENTS:

• Final objective is that I'll add cnc DXF milling information to this marionette so that it can be milled on a CNC machine.
(We've milled Halftone parts in the past using Jason Dorie's Halftone program http://jasondorie.com/page_cnc.html)

Result:

Detail:

• Maybe add a line milling. The image below is milled by us in the past with Jason's program.

• Be able to change the dimensions of the final halftone image. Now it takes the pixel width and height of the image, but I would like this to be some adjustable parameters. Changing the height and width with Set Height and Set Width has no effect. Somebody has a suggestion on how to do this?

• Now the marionette looks at the color of each pixel on a grid with step "Distance between Circle Centers". Related to that color, it creates a circle with according radius on the position of that pixel:

The problem with this method is that that single pixel on the grid has total control on the radius and the one pixel just next to the chosen one has no relevance. A better mechanisme would be that the size of the circle is related to the average color of all the pixels in the area of the square "Distance between Circle Centers"x"Distance between Circle Centers". Anyone with some advice on handeling this? I got some little progress on it:
Here we have 2 lists. One with all the pixels. X,Y coordinates of the pixel, Z is the radius of the circle according to the color. The other list has the X,Y values of the centers of where the final circles have to be placed.

Following this we need to check the distance of all the image points to the center points. If this is smaller than a condition, then that point's radius had to be taken into account for calculating the average radius of that centerpoint. Any one has a quick hint on how to create this in marionette?

## What's New in Version 1.0.0See changelog

Released

No changelog available for this version.

• 9

## User Feedback

• Marionette Maven

This is great and is actually identical to my first project with Image Processing! (I'll have to see if I can find a photo of my results)

I can definitely help you out with some, if not all of your questions, if you can be patient with me! I'll have to look for my example on the averaging colors, I did some of that when I was working on my triangulation project, but I don't think I ever shared the network here because it was during the pre-release cycle.

Give me some time and I'll get back to you on this!

Hey Bert, I was wondering how long until you came up with something in Marionette. You know you can use interiorcad's DXF output to get the milling info? Post us some photos when you're done. Nice work!

Posted (edited)

@Marissa Farrell Thank you!

17 hours ago, Stephan Moenninghoff said:

Hey Bert, I was wondering how long until you came up with something in Marionette. You know you can use interiorcad's DXF output to get the milling info? Post us some photos when you're done. Nice work!

Hi Stephan, Thank you! With which interiorcad tool can you export 3D polylines or which DXF output do you mean?
I've developed our own DXF to NC-Hops converter. It's written in python and we're using this mainly to mill our stairs and worktops. It creates NC-Hops files from a DXF file generated in Brics/Autocad or Vectorworks. With this program I can convert a 3D polyline straight to mill lines, which is how I was thinking to create the mill lines on this marionette.

Edited by Bertf

Ok, I thought you had VectorWop, our VWX-to-machine interface. It comes with a built-in DXF output (and one for Hops, too, actually). You are the Bert I know from "forest+", right?

Posted (edited)

12 hours ago, Stephan Moenninghoff said:

Ok, I thought you had VectorWop, our VWX-to-machine interface. It comes with a built-in DXF output (and one for Hops, too, actually). You are the Bert I know from "forest+", right?

Yep Stephan, that's me!
Yes we have VectorWop, which exports to NC-Hops for our cabinets. But for stairs, worktops and other stuff like these millings, we use our own converter.

For example this Halftone image has to be milled with a 45° point mill. To create a circle with radius R on the surface, we have move the point mill to depth R. To visualize this, I've drawn some mill lines:

It's a 3D poly which runs over the board at a safe distance of about 2mm. At every circle the mill goes down to the depth -R. I don't think this is doable with InteriorCAD's "Contour 3D" or "2D Contour"? They have a predefined depth for the full line:

So with this tool, I don't think I'm able to "go down" to certain depths with my mill...

We could discuss to try to draw "Drilling 3D" with depth = R at the circles, but then we'd have to adjust interiorcad's NC post processor to convert these drillings to millings. Very important in this case would be that the millings of different circles are all connected, else the machine will pull the mill back to it's default safe distance and have a short break every time. This increases the proces time a lot!

So if I'm not missing any interiorcad tool, I think the easiest way would be to use the 3D poly.

Edited by Bertf

You are right, the contour is not designed to adjust the router's z on the fly. As for the drillings, conversion is done automatically in cases where no matching drill is found for a given diameter. I understand the need to stop the tool to return home between each milling. I'm not totally sure it would do that, actually. AFAIR, it only returns to safe distance between different directions of drillings. There is a setting for that in your machine configuration. Anyway, if this works for you, that's fantastic and the result looks promising!

This is Great Bert

Have you also tried to mill in a line structure? and connect the Points?

Should this work, if I had a 3D Polygon. And can convert this to a 3D Path with the DXF Post-Prozessor?

Thank you @DomC!

50 minutes ago, DomC said:

Have you also tried to mill in a line structure? and connect the Points?

Yes, I've milled multiple line images with the same technique you're showing. I've created them with Jason Dorie's program. (one example is shown in the first post) But as I mentioned in improvements point 2, I hope to implement this in this marionette as well.

49 minutes ago, DomC said:

Should this work, if I had a 3D Polygon. And can convert this to a 3D Path with the DXF Post-Prozessor?

If your CNC-machine has a DXF import that supports polygons with varying z-value, you will be able to mill it. Our machines doesn't, that's why we build our own DXF to NC-Hops converter.

Posted (edited)

I've found pictures of 2 millings I did in the past:

With a detail:

Edited by Bertf

Posted (edited)

Great @Bertf

Your Screenshots shows a contour in x direction with different z values. My screenshot (found out now) shows simple Drillings (v-fräser). But the x-distance is 10x of the y distance. Thats why we can see lines.

My screenshot shows the variant of 3D contour with a v-fräser. Too bad I have no place for a CNC-Milling machine.

Can be done easy with the chunk node (to get single polygons for every line). EAP created for visualisation.

Edited by DomC

Posted (edited)

Wow, thanks for the hint to the Chunk list node!
I was looking for something similar when i was working on the average pixel color for the halftone circle!

And, yes. I don't use drillings close together for the line milling effect. Just a continuous milling with varying depth:

Edited by Bertf

Where I can get the Phyton Modul?! I doesn´t work at my VW2018.

Posted (edited)

I got it to work on Windows but not on Mac. I was not able to get a working url for Pillow with Vectorworks 2018 on Macintosh. Reported a Bug for VW 2018 but I am not sure, if this is A Vectorworks issue other modules can be installed without any issues.

Would be glad to got a solution for Pillow on Macintosh. This is the only module for image processing i found. Other image modules also needs pillow as an image library.

Edited by DomC
• Marionette Maven
12 minutes ago, DomC said:

I was not able to get a working url for Pillow with Vectorworks 2018 on Macintosh

I also haven't found one yet, but most other libraries have been installing fine. I don't think this is a Vectorworks issue.

A Workaround for 2018 Macintosh

1. Unzip and copy the attached Folder into the user folder (Vectorworks Preferences -> User Folder -> Revieal in Finder) into the Folder "Python Externals"

2. You can use with all scripts that uses Pillow. Also the above Script will work.

PIL.zip

Hey DomC

vielen Dank für deine Hilfe.

Hast du das auch für Vectorworks2017?

Lieben Gruß aus Dresden

CUA

The Attached Example (Copy of the original file but with different Pillow download path) works with VW 2017 Mac Version (Windows not tested, but it also should work).

Submitted_Halftone_Marionette_v1_v2017.vwx

Thanx a ot, it works great!!!

I've updated the first post with images of the halftone milling on "Trespa".

Hey everybody,

is it also possible to get the vectorized dots in the real color of the image?

Best regards from Dresden!

Mathias

Sure

The Script needed a little Updates for 2019. Cause the Path Handling in 2019 is better than in 2017/2018 I had to delete some lines.

Halftoning Farbige Punkte.vwx

I have tried to open the various files with version 2020 but always getting an error message. Anyone knows how to fix it?

• Marionette Maven
1 hour ago, Hans-Olav said:

I have tried to open the various files with version 2020 but always getting an error message. Anyone knows how to fix it?

I have a fix for this. Let me find the revised nodes and I'll get back to you.

Did you manage to find the fix?

• Marionette Maven

This file has updated GetPixRGB and ReadImage nodes that should work across all versions after 2017(?) (I can't recall which version we added the install library commands)

## Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

×   Pasted as rich text.   Restore formatting

Only 75 emoji are allowed.

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×

• KBASE
• #### MARIONETTE

×
• Create New...