mirror of
https://github.com/rsheldiii/KeyV2.git
synced 2025-01-22 09:27:46 +00:00
fix minkowski top_placement and additive artisans
This commit is contained in:
parent
1a10d1e5bc
commit
cc8892364c
3 changed files with 10 additions and 9 deletions
1
TODO.md
1
TODO.md
|
@ -1,6 +1,5 @@
|
||||||
TODO:
|
TODO:
|
||||||
* Make flat stem support default
|
* Make flat stem support default
|
||||||
* make flat inner shape default
|
|
||||||
* support repositioning to print on the back surface of the keycap
|
* support repositioning to print on the back surface of the keycap
|
||||||
* implement regular polygon for skin extrusions
|
* implement regular polygon for skin extrusions
|
||||||
* switch to skin-shaped extrusions by default
|
* switch to skin-shaped extrusions by default
|
||||||
|
|
|
@ -6086,7 +6086,6 @@ module shape(thickness_difference, depth_difference=0){
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// Not currently used due to CGAL errors. Rounds the shape via minkowski
|
|
||||||
module rounded_shape() {
|
module rounded_shape() {
|
||||||
color($primary_color) minkowski(){
|
color($primary_color) minkowski(){
|
||||||
// half minkowski in the z direction
|
// half minkowski in the z direction
|
||||||
|
@ -6175,9 +6174,9 @@ module top_placement(depth_difference=0) {
|
||||||
top_tilt_by_height = -$top_tilt / $key_height;
|
top_tilt_by_height = -$top_tilt / $key_height;
|
||||||
top_tilt_y_by_length = $double_sculpted ? (-$top_tilt_y / $key_length) : 0;
|
top_tilt_y_by_length = $double_sculpted ? (-$top_tilt_y / $key_length) : 0;
|
||||||
|
|
||||||
minkowski_height = $rounded_key ? $minkowski_radius : 0;
|
// minkowski_height = $rounded_key ? $minkowski_radius : 0;
|
||||||
|
|
||||||
translate([$top_skew_x + $dish_skew_x, $top_skew + $dish_skew_y, $total_depth - depth_difference + minkowski_height/2]){
|
translate([$top_skew_x + $dish_skew_x, $top_skew + $dish_skew_y, $total_depth - depth_difference]){
|
||||||
rotate([top_tilt_by_height, top_tilt_y_by_length,0]){
|
rotate([top_tilt_by_height, top_tilt_y_by_length,0]){
|
||||||
children();
|
children();
|
||||||
}
|
}
|
||||||
|
@ -6297,7 +6296,9 @@ module outer_total_shape(inset=false) {
|
||||||
// takes all the bits and glues them together. requires configuration with special variables.
|
// takes all the bits and glues them together. requires configuration with special variables.
|
||||||
module key(inset=false) {
|
module key(inset=false) {
|
||||||
difference(){
|
difference(){
|
||||||
outer_total_shape(inset);
|
outer_total_shape(inset) {
|
||||||
|
children();
|
||||||
|
};
|
||||||
|
|
||||||
if ($inner_shape_type != "disable") {
|
if ($inner_shape_type != "disable") {
|
||||||
translate([0,0,-SMALLEST_POSSIBLE]) {
|
translate([0,0,-SMALLEST_POSSIBLE]) {
|
||||||
|
|
|
@ -24,7 +24,6 @@ module shape(thickness_difference, depth_difference=0){
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// Not currently used due to CGAL errors. Rounds the shape via minkowski
|
|
||||||
module rounded_shape() {
|
module rounded_shape() {
|
||||||
color($primary_color) minkowski(){
|
color($primary_color) minkowski(){
|
||||||
// half minkowski in the z direction
|
// half minkowski in the z direction
|
||||||
|
@ -113,9 +112,9 @@ module top_placement(depth_difference=0) {
|
||||||
top_tilt_by_height = -$top_tilt / $key_height;
|
top_tilt_by_height = -$top_tilt / $key_height;
|
||||||
top_tilt_y_by_length = $double_sculpted ? (-$top_tilt_y / $key_length) : 0;
|
top_tilt_y_by_length = $double_sculpted ? (-$top_tilt_y / $key_length) : 0;
|
||||||
|
|
||||||
minkowski_height = $rounded_key ? $minkowski_radius : 0;
|
// minkowski_height = $rounded_key ? $minkowski_radius : 0;
|
||||||
|
|
||||||
translate([$top_skew_x + $dish_skew_x, $top_skew + $dish_skew_y, $total_depth - depth_difference + minkowski_height/2]){
|
translate([$top_skew_x + $dish_skew_x, $top_skew + $dish_skew_y, $total_depth - depth_difference]){
|
||||||
rotate([top_tilt_by_height, top_tilt_y_by_length,0]){
|
rotate([top_tilt_by_height, top_tilt_y_by_length,0]){
|
||||||
children();
|
children();
|
||||||
}
|
}
|
||||||
|
@ -235,7 +234,9 @@ module outer_total_shape(inset=false) {
|
||||||
// takes all the bits and glues them together. requires configuration with special variables.
|
// takes all the bits and glues them together. requires configuration with special variables.
|
||||||
module key(inset=false) {
|
module key(inset=false) {
|
||||||
difference(){
|
difference(){
|
||||||
outer_total_shape(inset);
|
outer_total_shape(inset) {
|
||||||
|
children();
|
||||||
|
};
|
||||||
|
|
||||||
if ($inner_shape_type != "disable") {
|
if ($inner_shape_type != "disable") {
|
||||||
translate([0,0,-SMALLEST_POSSIBLE]) {
|
translate([0,0,-SMALLEST_POSSIBLE]) {
|
||||||
|
|
Loading…
Reference in a new issue