JSCAD User Group

    • Register
    • Login
    • Search
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    1. Home
    2. retroglyph
    R
    • Profile
    • Following 0
    • Followers 0
    • Topics 1
    • Posts 2
    • Best 0
    • Controversial 0
    • Groups 0

    retroglyph

    @retroglyph

    0
    Reputation
    2
    Profile views
    2
    Posts
    0
    Followers
    0
    Following
    Joined Last Online

    retroglyph Unfollow Follow

    Latest posts made by retroglyph

    • RE: Newbie Here. (yet another) 3d to 2d question

      @z3dev Thank you for taking the time to reply. I looked at that (and will go back and study) that discussion, as well as the link to "fromFakePolygons".

      When one is accustomed to a particular set of tools, one tries to tackle a problem using those tools. But when presented with a new set of tools, sometimes one will still try to use a wrench as a hammer. To me, JSCAD is the new set of tools. Now I need to learn how to use them.

      Thanks again for doing so much work.

      All the best

      Steve

      posted in General Discussions
      R
      retroglyph
    • Newbie Here. (yet another) 3d to 2d question

      Hi,

      I wrote a little SCAD script to help those battling with Elephant's Foot. It allows a user to import their STL, and it slices the bottom (n) layers, offsets those layers by user selected amount and, when rendered, creates a new model with basically a custom chamfer along the bottom. Elephants Foot Compensation https://www.thingiverse.com/thing:4800868

      Now I am trying to do the same thing in openJSCAD

      openSCAD uses a "projection" tool that seems to create a 2d path where the model intersects with the Z=0 plane. The path has both external vertices (the outside of the model) and internal vertices (if their are holes).

      openSCAD also has an offset tool. This allows one to offset the aforementioned path. If one offsets in the positive, then it will expand the external vertices along the path pushing out along normals AND it would "shrink" internal vertices, pushing normally inward along the path.

      Those paths can then be re-extruded to recreate the modified model. Anyway, those are the tools I used in openSCAD to make the tool.

      As a newb to JSCAD, I'm not really understanding the overall difference between V1 and V2.

      For slicing, I have tried this

      var cag = obj.projectToOrthoNormalBasis(z0basis);
      return cag;

      And it seems to be a path, but then I can't seem to offset it or extrude it.

      Extrusion:

      When I try this as an example

      var z0basis = CSG.OrthoNormalBasis.Z0Plane();
      var cag = obj.projectToOrthoNormalBasis(z0basis);
      var NewCag = cag.extrude([0,0,25]);
      return NewCag;

      There is a slight extrusion. But no matter what value I put in for the Z val, the slight extrusion appears to be the same.

      Offset:

      I read that there is no offset in V1 but there is in V2.

      After that long intro...

      1. Is there a JSCAD equivalent to SCAD projection that can yield a 2d path
      2. is there a JSCAD equivalent to SCAD offset that can offset that 2d path
      3. can that path then be extruded back into a 3d solid

      Thank you in advance

      Steve

      posted in General Discussions
      R
      retroglyph