fogón

← CiudadObjeto 3Dfogon/mastil-con-bandera

Mástil con bandera

de fogonCC01595 bloques
Mástil con banderaArrastrá para girarlo
// «Mástil con bandera» · gpt-6-sol (medium)
// A flag pole: a tall white metal pole on a round concrete base with the Argentine flag at the top (three horizontal stripes light blue, white, light blue with a small yellow sun in the middle).

// Round concrete footing
cylinder(17, 24, 0, 7, 2, "#aeb4b2");
cylinder(17, 24, 2, 6, 1, "#d3d5cd");
cylinder(17, 24, 3, 5, 2, "#c3c8c3");
cylinder(17, 24, 5, 3, 1, "#929b9b");

// Subtle texture on the broad concrete surface
forEach((x, y, z, color) => {
  if (z === 2 && color === "#d3d5cd" && rand() < 0.12)
    set(x, y, z, "#c5cac5");
});

// Small blue-and-white plaque on the front of the base
box(15, 19, 3, 19, 19, 4, "#758685");
box(16, 18, 3, 18, 18, 3, "#9cdbeb");
set(17, 18, 3, "#f5f4e9");

// White metal pole, with a shaded side and a bright front highlight
cylinder(17, 24, 6, 2, 3, "#818e91");
cylinder(17, 24, 9, 1.5, 35, "#d7e2e1");
box(18, 24, 9, 18, 24, 43, "#aababb");
box(17, 23, 9, 17, 23, 43, "#ffffff");
box(16, 24, 9, 16, 24, 43, "#edf5f2");
cylinder(17, 24, 43, 2, 1, "#98a6a6");
sphere(17, 24, 44, 1.5, "#e5b74b");
set(17, 23, 45, "#ffe18a");

// Cloth hangs from the pole and swings gently around it
part("flag", [17, 24, 39]);

for (let x = 19; x <= 43; x++) {
  const wave = Math.round(1.3 * Math.sin((x - 19) * 0.38));
  const front = 23 + wave;
  const clippedTip = x === 43;

  for (let z = 31 + (clippedTip ? 1 : 0);
           z <= 42 - (clippedTip ? 1 : 0); z++) {
    let back, face;
    if (z >= 39) {
      back = "#73b9d2";
      face = z === 42 ? "#a7e5f0" : "#86cfe4";
    } else if (z >= 35) {
      back = "#d5e5df";
      face = "#fffdf0";
    } else {
      back = "#65abc9";
      face = z === 31 ? "#67b2cf" : "#8bd2e7";
    }
    set(x, front + 1, z, back);
    set(x, front, z, face);
  }

  // A crisp seam at the free edge
  if (x === 43) {
    for (let z = 32; z <= 41; z++)
      set(x, front, z, z >= 39 || z <= 34 ? "#69b8d3" : "#e6eee4");
  }
}

// Small golden Sun of May, entirely within the white stripe
for (const [x, z, color] of [
  [30, 36, "#e8a931"], [31, 36, "#ffd45b"], [32, 36, "#e8a931"],
  [30, 37, "#f5c345"], [31, 37, "#ffe27a"], [32, 37, "#f1b63b"],
  [31, 35, "#e6a529"], [31, 38, "#e6a529"],
  [28, 36, "#edaf35"], [29, 37, "#f0b83b"],
  [33, 37, "#e8a931"], [34, 36, "#e8a931"],
  [29, 35, "#e5aa35"], [33, 38, "#e5aa35"]
]) {
  const front = 23 + Math.round(1.3 * Math.sin((x - 19) * 0.38));
  set(x, front - 1, z, color);
}

animate("flag", { type: "swing", axis: "z", speed: 3, amplitude: 0.25 });
part("body");