/* * H E X A C O N E - E S S A I * nouveau projet du Thu Dec 5 11:37:05 AM UTC 2024 */ #version 3.7; #include "globals.inc" #debug "\n GLOBALS INCLUDED\n" #include "contexte.inc" #include "gadgets.inc" #include "hexacone.inc" #include "hexabenz.inc" #include "hexawood.inc" #include "trident.inc" // ======================================================= /* nouveau du 7 octobre 2025 */ #macro Une_Boule () sphere { 0, 0.25 #local R = rand(Rng1); #if (R < 0.333) pigment { color Red } #elseif (R < 0.666) pigment { color Green } #else pigment { color Blue } #end } #end // macro #declare Les_Boules = object { union { #for (A, 0, 12, 1) object { Une_Boule () #local TX = 1.2 * (0.5 - NormClock); #local TY = 2 * Cos_010(abs(sin(clock))); #local TZ = 3.31 * cos(NormClock*888); translate } #end // for } finish { ambient 0 phong 1 } //translate <-0.5, -0.5, -0.5> // recalage de l'objet fini scale 1.3333333 } // ======================================================= #debug " ACTION !!!\n" // ------------------------------------------------------ ## #declare Tridents = object { #local RX = -11 + (80*sin(NormClock*9.81) + 3*sin(NormClock*23)); #local RZ = 96 - (54*Cos_010(NormClock)); union { object { Trident_A () rotate translate < -1.4, 1.2, 0> } object { Trident_A () rotate <0, clock, 0> translate < 1.4, 2.0, 0> } } } // ------------------------------------------------------ ## #declare Gyros = object { union { #for (I, 0, 359, 30) #declare E = 9; #declare Dx = E * sin(radians(I)); #declare Dz = E * cos(radians(I)); object { GyroPhare () translate } // #debug " Gyro !!!\n" #end } } // ------------------------------------------------------ ## // object { Gyros } #declare Selector = mod(int(clock/32), 6); #debug concat("Selector = ", str(Selector, 6, 0), "\n") #switch (Selector) #case (0) object { Tridents scale 1.2 rotate -y*(clock*0.666) } #debug " Tridents\n" #break #case (1) object { HexaPole () } #debug " Hexapole\n" #break #case (2) object { HexaWood translate y } #debug " Hexawood !!!\n" #break #case (3) object { Chose rotate y*clock } #debug " Chose\n" #break #case (4) object { HexaBenz () scale 2 translate 2.7*y rotate -y*clock } #debug " HexaBenz\n" #break #case (5) object { Les_Boules translate y*1.33 } #debug " boules\n" #break #end // switch selector plane { y, 0 texture { T_Planete_B scale 0.666 } } object { Repere translate y*0.8 } // ======================================================= #local CamX = -2.7 + (1.8*Cos_010(NormClock)); #local CamY = 0.41 + (1.2*exp(NormClock)); #local CamZ = -5.777 + (1.2*Cos_01(NormClock)); #local K = 8.6; #local CamX = CamX * K; #local CamY = CamY * K * 0.65; #local CamZ = CamZ * K; camera { // orthographic location look_at <0, 1.4, 0> angle 12 - 3*Cos_01(NormClock) }