# Partial Rotate Extrude (OpenSCAD)

## by CarryTheWhat, published

0
Share

4695
462

Report Thing as Inappropriate
## Description

In the process of designing a printable frame for a mini quad copter, I realized I needed a feature of OpenSCAD that I don't think was implemented yet. While I know this is not a perfect solution, it was a good enough hack for my needs.

Included is the example use case.

Included is the example use case.

## Recent Comments

view all
4695
462

Report Thing as Inappropriate
## Tags

## Give a Shout Out

If you print this Thing and display it in public proudly give attribution by printing and displaying this tag.
Print Thing Tag

## Instructions

Use (same as rotate_extrude):

| partial_rotate_extrude(angle, radius, convexity) circle(5);

This will extrude the circle for `angle` degrees about the origin at a distance of `radius`. The convexity parameter is the same as in rotate_extrude, see en.wikibooks.org/wiki/OpenSCAD_User_Manual/2D_to_3D_Extrusion

Copy/Paste access:

partial_rotate_extrude(235, 20, 10) circle(5);

module pie_slice(radius, angle, step) {

for(theta = [0:step:angle-step]) {

rotate([0,0,0]) linear_extrude(height = radius*2, center=true)

polygon( points = [[0,0],[radius * cos(theta+step) ,radius * sin(theta+step)],[radius*cos(theta),radius*sin(theta)]]);

}}

module partial_rotate_extrude(angle, radius, convex) {

intersection () {

rotate_extrude(convexity=convex) translate([radius,0,0]) child(0);

pie_slice(radius*2, angle, angle/5);

}}

| partial_rotate_extrude(angle, radius, convexity) circle(5);

This will extrude the circle for `angle` degrees about the origin at a distance of `radius`. The convexity parameter is the same as in rotate_extrude, see en.wikibooks.org/wiki/OpenSCAD_User_Manual/2D_to_3D_Extrusion

Copy/Paste access:

partial_rotate_extrude(235, 20, 10) circle(5);

module pie_slice(radius, angle, step) {

for(theta = [0:step:angle-step]) {

rotate([0,0,0]) linear_extrude(height = radius*2, center=true)

polygon( points = [[0,0],[radius * cos(theta+step) ,radius * sin(theta+step)],[radius*cos(theta),radius*sin(theta)]]);

}}

module partial_rotate_extrude(angle, radius, convex) {

intersection () {

rotate_extrude(convexity=convex) translate([radius,0,0]) child(0);

pie_slice(radius*2, angle, angle/5);

}}

Download All Files
(911 b zip file)

Thanks! This is just what I needed to make a part to hold a 3D print spool. I'll put up the part later on if I find it useful + fix the part where you need to drill it out for it to work...