3D Workspace
Home
Assets
Affiliate Program
Sign up/Log in
?
Upgrade
DCC Bridge
3D Creation Made Simple
Text & Image to 3D Model in seconds
One-Click Texturing & Smart Detail Editing
Free Credits Monthly
Start Free
Anonymous1758705401
09-25 08:10
Model Name
محرك رباعي الأسطوانات ثلاثي الأبعاد
Tags
machine
rendering
realistic
Prompt
// هذا الكود يقوم بإنشاء نموذج محرك ثلاثي الأبعاد بسيط في OpenSCAD. // يمكنك تعديل المتغيرات في البداية لتغيير أبعاد المحرك. // ==================== المتغيرات ==================== // =================================================== // أبعاد الأسطوانة cylinder_diameter = 20; cylinder_height = 50; piston_diameter = 18; piston_height = 40; // أبعاد العمود المرفقي crankshaft_diameter = 10; crankshaft_length = 100; crankshaft_offset = 15; // عدد الأسطوانات num_cylinders = 4; cylinder_spacing = 30; // ==================== الوظائف ==================== // ================================================= // وظيفة لإنشاء أسطوانة محرك module cylinder_block() { color([0.5, 0.5, 0.5]) { cylinder(h = cylinder_height, d = cylinder_diameter, $fn = 50); } } // وظيفة لإنشاء مكبس module piston() { color([0.8, 0.8, 0.8]) { cylinder(h = piston_height, d = piston_diameter, $fn = 50); } } // وظيفة لإنشاء العمود المرفقي module crankshaft() { color([0.3, 0.3, 0.3]) { cylinder(h = crankshaft_length, d = crankshaft_diameter, $fn = 50); // ربط المكابس بالعمود المرفقي for (i = [0:num_cylinders - 1]) { translate([0, -crankshaft_offset, (i * cylinder_spacing) + (crankshaft_length / 2)]) { rotate([0, 90, 0]) { cylinder(h = crankshaft_offset * 2, d = 5, $fn = 20); } } } } } // ==================== التجميع ==================== // ================================================ // إنشاء كتلة المحرك مع الأسطوانات for (i = [0:num_cylinders - 1]) { translate([0, 0, i * cylinder_spacing]) { cylinder_block(); } } // إنشاء المكابس for (i = [0:num_cylinders - 1]) { translate([0, 0, (i * cylinder_spacing) + (cylinder_height / 2)]) { piston(); } } // إنشاء وتحديد موقع العمود المرفقي translate([0, -crankshaft_offset * 2, -crankshaft_length / 2]) { crankshaft(); }
Detailed Info
Related Models
Enter invite code
Enter invite code to get credits!