Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

3d object rendered difference from mac version #115

Open
obicho opened this issue Feb 23, 2025 · 1 comment
Open

3d object rendered difference from mac version #115

obicho opened this issue Feb 23, 2025 · 1 comment

Comments

@obicho
Copy link

obicho commented Feb 23, 2025

Image OpenSCAD mac version

Image OpenSCAD WebAssembly version

I have been doing a bit of testing. I noticed there is a difference between OpenSCAD Mac desktop version vs WebAssembly version. See images above.

Is this expected? My OpenSCAD code below:


// Parameters
length = 18 * 25.4; // Convert inches to mm (18 inches)
outer_diameter = 25; // Approximate outer diameter in mm
inner_diameter = 20; // Approximate inner diameter in mm
corrugation_depth = 2; // Depth of corrugations
corrugation_width = 5; // Width of each corrugation
num_corrugations = length / corrugation_width; // Number of corrugations

// Corrugated hose
module corrugated_hose() {
    difference() {
        // Outer corrugated surface
        for (i = [0 : num_corrugations - 1]) {
            translate([0, 0, i * corrugation_width])
            cylinder(h = corrugation_width, d1 = outer_diameter, d2 = outer_diameter - corrugation_depth, $fn = 100);
            translate([0, 0, i * corrugation_width + corrugation_width / 2])
            cylinder(h = corrugation_width, d1 = outer_diameter - corrugation_depth, d2 = outer_diameter, $fn = 100);
        }
        // Inner smooth surface
        cylinder(h = length, d = inner_diameter, $fn = 100);
    }
}

// FIP connectors (simplified)
module fip_connector() {
    cylinder(h = 10, d = outer_diameter, $fn = 100);
}

// Assembly
translate([0, 0, -5]) fip_connector();
corrugated_hose();
translate([0, 0, length + 5]) fip_connector();
@t-paul
Copy link
Member

t-paul commented Feb 23, 2025

Likely caused by the experimental feature "lazy-union". This one is unstable and not generally recommended to be enabled.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants