Skip to content

Instantly share code, notes, and snippets.

@JesusFreke
JesusFreke / shaper_elbow.py
Created October 16, 2019 08:07
Design for 45 degree elbow for shaper origin vacuum hose
# Copyright (c) 2019 Ben Gruver
# All rights reserved.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions
# are met:
# 1. Redistributions of source code must retain the above copyright
# notice, this list of conditions and the following disclaimer.
# 2. Redistributions in binary form must reproduce the above copyright
# notice, this list of conditions and the following disclaimer in the
@JesusFreke
JesusFreke / README.md
Last active August 5, 2020 13:13
Fusion 360 API Example: wrap sketch around surface

This is an example of using SurfaceEvaluator.getModelCurveFromParametricCurve in order to do a true wrap (not just a projection) of a 2D sketch onto a curved surface. This can be used, for example, to wrap text around a cylinder or even a sphere. It should be possible to map a sketch onto most any surface.

Keybase proof

I hereby claim:

  • I am JesusFreke on github.
  • I am jesusfreke (https://keybase.io/jesusfreke) on keybase.
  • I have a public key whose fingerprint is 4E6C F906 6664 F1A6 951E BD58 CBD5 1DD5 A9AC 00F7

To claim this, I am signing this object:

package org.jf.InstrumentationTest;
import com.google.common.collect.Lists;
import org.jf.dexlib2.DexFileFactory;
import org.jf.dexlib2.Opcode;
import org.jf.dexlib2.builder.MutableMethodImplementation;
import org.jf.dexlib2.builder.instruction.BuilderInstruction11x;
import org.jf.dexlib2.builder.instruction.BuilderInstruction21c;
import org.jf.dexlib2.builder.instruction.BuilderInstruction35c;
import org.jf.dexlib2.iface.ClassDef;