Welcome to the Onshape forum! Ask questions and join in the discussions about everything Onshape.

First time visiting? Here are some places to start:
  1. Looking for a certain topic? Check out the categories filter or use Search (upper right).
  2. Need support? Ask a question to our Community Support category.
  3. Please submit support tickets for bugs but you can request improvements in the Product Feedback category.
  4. Be respectful, on topic and if you see a problem, Flag it.

If you would like to contact our Community Manager personally, feel free to send a private message or an email.

🚨Custom Feature Alert 🚨: Displacement Maps in Onshape

EvanReeseEvanReese Member, Mentor Posts: 2,707 PRO

I'm really excited to share this one. I've finally figured out how to get pixel values into a format that FeatureScript can process, which opens up a number of interesting possibilities. First up in that list is using images to modify surfaces. There's a whole video on the topic, so I won't detail it here, but here are some teasers of what's possible.

Link to feature

image.png image.png lithophane example.jpg image.png
Evan Reese
The Onsherpa | Reach peak Onshape productivity
www.theonsherpa.com

Comments

  • MichaelPascoeMichaelPascoe Member Posts: 2,712 PRO
    edited December 2025

    @EvanReese Video and Document are private. This looks really cool though! Can't wait to see it, this sounds insane!

    From what I can tell in the pictures, looks like your generating one surface that has points controlling it from the heightmap of an image. Then applying the original image to the surface? Brilliant work. This is a game changer.

    .


    Learn more about the Gospel of Christ  ( Here )

    CADSharp  -  We make custom features and integrated Onshape apps!   Learn How to FeatureScript Here 🔴
  • martin_kopplowmartin_kopplow Member Posts: 1,118 PRO
    edited December 2025

    Yeah, very cool! Even without being able to watch the private video yet, I can think of a thousand applications this might be useful for, just by looking at the pictures a bit ... The FS itself appears to be unavailable, too.

  • EvanReeseEvanReese Member, Mentor Posts: 2,707 PRO

    Lol my bad! Fumbled it at the 1 yd line. Try now

    Evan Reese
    The Onsherpa | Reach peak Onshape productivity
    www.theonsherpa.com
  • MichaelPascoeMichaelPascoe Member Posts: 2,712 PRO

    Just in time for the Feature of the Year award 2025.

    This has to win, hands down.

    .


    Learn more about the Gospel of Christ  ( Here )

    CADSharp  -  We make custom features and integrated Onshape apps!   Learn How to FeatureScript Here 🔴
  • Matt_ShieldsMatt_Shields Member, Onshape Employees Posts: 865 PRO

    This is nuts. Amazing work.

  • Derek_Van_Allen_BDDerek_Van_Allen_BD Member Posts: 507 PRO

    Heads up for anyone viewing in dark mode: the surface analysis tool is going to blind you.

    image.png

    Smooth combs tho

  • S1monS1mon Member Posts: 3,810 PRO

    @EvanReese

    This is amazing to finally have this power in Onshape.

    One thing that I could see being super helpful would be to have Horizontal and Vertical flip options. If you want a texture to match up along edges, using the same input CSV and being able to have the mirrored flavor of the image/CSV without needing to create multiple images/CSV exports would be great.

    Definitely feature of the year.

    Simon Gatrall | Product Development Specialist | Open For Work

  • MichaelPascoeMichaelPascoe Member Posts: 2,712 PRO
    edited December 2025

    Going to have to implement this as a texture option in the upcoming Texture feature update (which is finally in progress).
    This paired with approximate face or your drape surface should give us some sweet functionality.

    .


    Learn more about the Gospel of Christ  ( Here )

    CADSharp  -  We make custom features and integrated Onshape apps!   Learn How to FeatureScript Here 🔴
  • GWS50GWS50 Member Posts: 492 PRO

    Wow….just amazing…what a feature. Fantastic.

  • EvanReeseEvanReese Member, Mentor Posts: 2,707 PRO

    Thanks, all!

    @S1mon There already are flip/rotate buttons, which should be able to get you what you need, though it could be a few clicks. Lemme know if it's not enough to get you there.

    @MichaelPascoe I was thinking about Texture a lot while I made this! I think a number of your pre-set models could be modeled this way.

    Evan Reese
    The Onsherpa | Reach peak Onshape productivity
    www.theonsherpa.com
  • Konst_ShKonst_Sh Member Posts: 112 PRO

    Indeed its a great idea and implementation, Evan!

  • Derek_Van_Allen_BDDerek_Van_Allen_BD Member Posts: 507 PRO

    I'm kind of afraid to go back and redo the sand-bar file I had to pass to our Rhino jockey in the office and see if I could have replaced his whole entire grasshopper stack with an AI generated depth map and this script but my instinct is telling me that yeah, that would have been way easier. The best features always come out 5 minutes after you're already finished with the project that needed them is what my team just told me.

  • S1monS1mon Member Posts: 3,810 PRO

    Yep. With the flip and rotate you can get to the result I was trying to achieve fairly easily. The flip/rotate choices are not visible other than in the preview of the displacement itself, but maybe that's ok. This test is using the P image_50x50.csv file from your document.

    image.png

    Another request/idea: it would be great if there was a variation on Attractor Pattern ("Image Pattern"?) which used the same image→CSV flow to control the size/positioning of the patterned entities.

    To the official Onshape crew: please make it so that we can just import images into features like this directly without a conversion to .CSV first.

    I'd love to be able to preview the displacement with the basic image - the same way one does with the decal feature.

    Simon Gatrall | Product Development Specialist | Open For Work

  • Derek_Van_Allen_BDDerek_Van_Allen_BD Member Posts: 507 PRO

    I was gonna say, the only major improvements I see over this implementation would be in a decal preview or in performance optimization. One of the only ways to do this script more optimally is not to do the displacement in featurescript, but instead to do the displacement only at export time. Imagine something like the cosmetic thread feature, but if the cosmetic threads became dimensional if you exported to an .stl file when you went to send it to your printer. All of the data you need is in the Onshape engine already, it just needs a way to be linked together.

Sign In or Register to comment.