Compare commits
	
		
			5 Commits
		
	
	
		
			achalmers/
			...
			david/fix-
		
	
	| Author | SHA1 | Date | |
|---|---|---|---|
| 185f555ff3 | |||
| c695ec8fef | |||
| 2b9cf9f794 | |||
| 3df23f0ce5 | |||
| 8c062b3c90 | 
| @ -512,7 +512,7 @@ impl Plane { | |||||||
|                 id, |                 id, | ||||||
|                 artifact_id: id.into(), |                 artifact_id: id.into(), | ||||||
|                 origin: Point3d::new(0.0, 0.0, 0.0, UnitLen::Mm), |                 origin: Point3d::new(0.0, 0.0, 0.0, UnitLen::Mm), | ||||||
|                 x_axis: Point3d::new(-1.0, 0.0, 0.0, UnitLen::Mm), |                 x_axis: Point3d::new(1.0, 0.0, 0.0, UnitLen::Mm), | ||||||
|                 y_axis: Point3d::new(0.0, 0.0, 1.0, UnitLen::Mm), |                 y_axis: Point3d::new(0.0, 0.0, 1.0, UnitLen::Mm), | ||||||
|                 z_axis: Point3d::new(0.0, 1.0, 0.0, UnitLen::Mm), |                 z_axis: Point3d::new(0.0, 1.0, 0.0, UnitLen::Mm), | ||||||
|                 value: PlaneType::XZ, |                 value: PlaneType::XZ, | ||||||
|  | |||||||
| @ -1260,21 +1260,30 @@ async fn make_sketch_plane_from_orientation( | |||||||
|     let hide = Some(true); |     let hide = Some(true); | ||||||
|     match data { |     match data { | ||||||
|         PlaneData::XY | PlaneData::NegXY | PlaneData::XZ | PlaneData::NegXZ | PlaneData::YZ | PlaneData::NegYZ => { |         PlaneData::XY | PlaneData::NegXY | PlaneData::XZ | PlaneData::NegXZ | PlaneData::YZ | PlaneData::NegYZ => { | ||||||
|  |             /* | ||||||
|  |                 NOTE(dr): The x_axis defined below isn't consistent with default plane definitions. PlaneData::Neg* variants | ||||||
|  |                 only negate the z axis, x and y axes are the same as PlaneData::*. | ||||||
|  |  | ||||||
|  |                 Defining the x_axis in this way causes `startOnSketch(-XZ)` and `startOnSketch(offsetPlane(-XZ, offset = 0))` | ||||||
|  |                 to produce different results. | ||||||
|  |             */ | ||||||
|  |  | ||||||
|             // TODO: ignoring the default planes here since we already created them, breaks the |             // TODO: ignoring the default planes here since we already created them, breaks the | ||||||
|             // front end for the feature tree which is stupid and we should fix it. |             // front end for the feature tree which is stupid and we should fix it. | ||||||
|             let x_axis = match data { |             // let x_axis = match data { | ||||||
|                 PlaneData::NegXY => Point3d::new(-1.0, 0.0, 0.0, UnitLen::Mm), |             //     PlaneData::NegXY => Point3d::new(-1.0, 0.0, 0.0, UnitLen::Mm), | ||||||
|                 PlaneData::NegXZ => Point3d::new(-1.0, 0.0, 0.0, UnitLen::Mm), |             //     PlaneData::NegXZ => Point3d::new(-1.0, 0.0, 0.0, UnitLen::Mm), | ||||||
|                 PlaneData::NegYZ => Point3d::new(0.0, -1.0, 0.0, UnitLen::Mm), |             //     PlaneData::NegYZ => Point3d::new(0.0, -1.0, 0.0, UnitLen::Mm), | ||||||
|                 _ => plane.x_axis, |             //     _ => plane.x_axis, | ||||||
|             }; |             // }; | ||||||
|             args.batch_modeling_cmd( |             args.batch_modeling_cmd( | ||||||
|                 plane.id, |                 plane.id, | ||||||
|                 ModelingCmd::from(mcmd::MakePlane { |                 ModelingCmd::from(mcmd::MakePlane { | ||||||
|                     clobber, |                     clobber, | ||||||
|                     origin: plane.origin.into(), |                     origin: plane.origin.into(), | ||||||
|                     size, |                     size, | ||||||
|                     x_axis: x_axis.into(), |                     // x_axis: x_axis.into(), | ||||||
|  |                     x_axis: plane.x_axis.into(), | ||||||
|                     y_axis: plane.y_axis.into(), |                     y_axis: plane.y_axis.into(), | ||||||
|                     hide, |                     hide, | ||||||
|                 }), |                 }), | ||||||
|  | |||||||
| @ -306,7 +306,7 @@ description: Variables in memory after executing artifact_graph_example_code_no_ | |||||||
|           } |           } | ||||||
|         }, |         }, | ||||||
|         "xAxis": { |         "xAxis": { | ||||||
|           "x": -1.0, |           "x": 1.0, | ||||||
|           "y": 0.0, |           "y": 0.0, | ||||||
|           "z": 0.0, |           "z": 0.0, | ||||||
|           "units": { |           "units": { | ||||||
|  | |||||||
| @ -771,7 +771,7 @@ description: Variables in memory after executing crazy_multi_profile.kcl | |||||||
|             } |             } | ||||||
|           }, |           }, | ||||||
|           "xAxis": { |           "xAxis": { | ||||||
|             "x": -1.0, |             "x": 1.0, | ||||||
|             "y": 0.0, |             "y": 0.0, | ||||||
|             "z": 0.0, |             "z": 0.0, | ||||||
|             "units": { |             "units": { | ||||||
| @ -2783,7 +2783,7 @@ description: Variables in memory after executing crazy_multi_profile.kcl | |||||||
|           } |           } | ||||||
|         }, |         }, | ||||||
|         "xAxis": { |         "xAxis": { | ||||||
|           "x": -1.0, |           "x": 1.0, | ||||||
|           "y": 0.0, |           "y": 0.0, | ||||||
|           "z": 0.0, |           "z": 0.0, | ||||||
|           "units": { |           "units": { | ||||||
| @ -2932,7 +2932,7 @@ description: Variables in memory after executing crazy_multi_profile.kcl | |||||||
|           } |           } | ||||||
|         }, |         }, | ||||||
|         "xAxis": { |         "xAxis": { | ||||||
|           "x": -1.0, |           "x": 1.0, | ||||||
|           "y": 0.0, |           "y": 0.0, | ||||||
|           "z": 0.0, |           "z": 0.0, | ||||||
|           "units": { |           "units": { | ||||||
| @ -3081,7 +3081,7 @@ description: Variables in memory after executing crazy_multi_profile.kcl | |||||||
|           } |           } | ||||||
|         }, |         }, | ||||||
|         "xAxis": { |         "xAxis": { | ||||||
|           "x": -1.0, |           "x": 1.0, | ||||||
|           "y": 0.0, |           "y": 0.0, | ||||||
|           "z": 0.0, |           "z": 0.0, | ||||||
|           "units": { |           "units": { | ||||||
| @ -3179,7 +3179,7 @@ description: Variables in memory after executing crazy_multi_profile.kcl | |||||||
|           } |           } | ||||||
|         }, |         }, | ||||||
|         "xAxis": { |         "xAxis": { | ||||||
|           "x": -1.0, |           "x": 1.0, | ||||||
|           "y": 0.0, |           "y": 0.0, | ||||||
|           "z": 0.0, |           "z": 0.0, | ||||||
|           "units": { |           "units": { | ||||||
| @ -3353,7 +3353,7 @@ description: Variables in memory after executing crazy_multi_profile.kcl | |||||||
|           } |           } | ||||||
|         }, |         }, | ||||||
|         "xAxis": { |         "xAxis": { | ||||||
|           "x": -1.0, |           "x": 1.0, | ||||||
|           "y": 0.0, |           "y": 0.0, | ||||||
|           "z": 0.0, |           "z": 0.0, | ||||||
|           "units": { |           "units": { | ||||||
| @ -3912,7 +3912,7 @@ description: Variables in memory after executing crazy_multi_profile.kcl | |||||||
|             } |             } | ||||||
|           }, |           }, | ||||||
|           "xAxis": { |           "xAxis": { | ||||||
|             "x": -1.0, |             "x": 1.0, | ||||||
|             "y": 0.0, |             "y": 0.0, | ||||||
|             "z": 0.0, |             "z": 0.0, | ||||||
|             "units": { |             "units": { | ||||||
| @ -4288,7 +4288,7 @@ description: Variables in memory after executing crazy_multi_profile.kcl | |||||||
|         } |         } | ||||||
|       }, |       }, | ||||||
|       "xAxis": { |       "xAxis": { | ||||||
|         "x": -1.0, |         "x": 1.0, | ||||||
|         "y": 0.0, |         "y": 0.0, | ||||||
|         "z": 0.0, |         "z": 0.0, | ||||||
|         "units": { |         "units": { | ||||||
|  | |||||||
| @ -181,7 +181,7 @@ description: Variables in memory after executing i-beam.kcl | |||||||
|             } |             } | ||||||
|           }, |           }, | ||||||
|           "xAxis": { |           "xAxis": { | ||||||
|             "x": -1.0, |             "x": 1.0, | ||||||
|             "y": 0.0, |             "y": 0.0, | ||||||
|             "z": 0.0, |             "z": 0.0, | ||||||
|             "units": { |             "units": { | ||||||
|  | |||||||
| @ -108,7 +108,7 @@ description: Variables in memory after executing neg_xz_plane.kcl | |||||||
|             } |             } | ||||||
|           }, |           }, | ||||||
|           "xAxis": { |           "xAxis": { | ||||||
|             "x": -1.0, |             "x": 1.0, | ||||||
|             "y": 0.0, |             "y": 0.0, | ||||||
|             "z": 0.0, |             "z": 0.0, | ||||||
|             "units": { |             "units": { | ||||||
|  | |||||||
		Reference in New Issue
	
	Block a user
	