-
Notifications
You must be signed in to change notification settings - Fork 11
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
incremented version to 1.2
- Loading branch information
Showing
4 changed files
with
19 additions
and
5 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -30,10 +30,14 @@ Copyright 2020 by Allwine Designs ([email protected]) | |
#define BUFFER_SIZE 4096 | ||
|
||
void print_usage() { | ||
fprintf(stderr, "stl_cylinders outputs an STL file of a single cylinder.\n\n"); | ||
fprintf(stderr, "stl_cylinders outputs an STL file with multiple cylinders defined by a custom binary input file.\n\n"); | ||
fprintf(stderr, "usage: stl_cylinders [ -r <radius> ] [ -s <segments> ] <input file> <output file>\n"); | ||
fprintf(stderr, " Outputs an stl file of a cylinder with the provided radius, height and number of segments to approximate a circle.\n"); | ||
fprintf(stderr, " If the radius or height are omitted, they default to 1. If segments is omitted, it defaults to 32. If no output file is provided, data is sent to stdout. \n"); | ||
fprintf(stderr, " Outputs an stl file made up of N cylinders defined by start and end points in the input file each with the specified\n"); | ||
fprintf(stderr, " radius and number of segments provided on the command line. The first 4 bytes of the input file represent how many \n"); | ||
fprintf(stderr, " cylinders to generate, N. The rest of the input file defines start and end points that define a line segment of the\n"); | ||
fprintf(stderr, " the central axis of the cylinder. Each segment is defined by 6, 4 byte floats. The first three are the X,Y,Z values\n"); | ||
fprintf(stderr, " of the start point and the second three are the X,Y,Z values of the end point.\n"); | ||
fprintf(stderr, " If the radius is omitted, it defaults to 1. If segments is omitted, it defaults to 32.\n"); | ||
} | ||
|
||
void write_cylinder(FILE *outf, const vec &pt1, const vec &pt2, float radius, int segments) { | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -32,7 +32,7 @@ Copyright 2014 by Freakin' Sweet Apps, LLC ([email protected]) | |
void print_usage() { | ||
fprintf(stderr, "stl_zero centres an STL file.\n\n"); | ||
fprintf(stderr, "usage: stl_zero [-base] [<input file> [<output file>] ]\n"); | ||
fprintf(stderr, " Centre an STL file around the origin. "); | ||
fprintf(stderr, " Center an STL file around the origin. "); | ||
fprintf(stderr, " If no input file is provided, data is read from stdin. If no output file is provided, data is sent to stdout. \n"); | ||
fprintf(stderr, " -base - If this is specified, set the lowest point in the design to z = 0. \n"); | ||
} | ||
|