#version 3.7; global_settings { assumed_gamma 1.3 max_trace_level 16 radiosity { pretrace_start 0.08 pretrace_end 0.01 count 200 nearest_count 10 error_bound 0.5 recursion_limit 2 low_error_factor 0.5 gray_threshold 0.0 } } #include "functions.inc" background { color rgb <0.04, 0.06, 0.10> } // Zoomed out camera camera { location <85, 42, -120> look_at <0, 14, 0> angle 40 up <0,9,0> right <16,0,0> // right,up -> 16:9 } // Warm, soft lights light_source { <140, 120, -110> color rgb <1.0, 0.78, 0.60>*1.20 area_light <28,0,0>, <0,0,28>, 7, 7 adaptive 1 jitter } light_source { <-120, 85, -40> color rgb <1.0, 0.82, 0.65>*0.55 area_light <22,0,0>, <0,0,22>, 6, 6 adaptive 1 jitter } light_source { <0, 180, 0> color rgb <1.0, 0.90, 0.80>*0.20 } // Atmospheric haze fog { fog_type 2 distance 220 color rgb <0.12, 0.14, 0.18> fog_offset 0 fog_alt 14 turbulence 0.55 } // Sky gradient for a more “future city” feel sphere { <0,0,0>, 2000 hollow texture { pigment { gradient y color_map { [0.00 color rgb <0.03,0.05,0.08>] [0.55 color rgb <0.06,0.08,0.11>] [1.00 color rgb <0.14,0.16,0.19>] } scale 800 translate <0,-200,0> } finish { diffuse 0 ambient 1 } } } // -------------------- Procedural materials (simple “texturing”) -------------------- #declare Fn_Grain = function { f_noise3d(x*1.7, y*1.7, z*1.7) }; #declare Mat_Concrete = texture { pigment { bozo color_map { [0.00 color rgb <0.18, 0.19, 0.22>] [0.55 color rgb <0.22, 0.24, 0.28>] [1.00 color rgb <0.14, 0.15, 0.18>] } scale 2.3 } finish { diffuse 0.80 specular 0.10 roughness 0.06 } }; #declare Mat_DarkMetal = texture { pigment { granite color_map { [0.00 color rgb <0.09, 0.10, 0.12>] [0.70 color rgb <0.14, 0.15, 0.17>] [1.00 color rgb <0.06, 0.07, 0.08>] } scale 1.2 } finish { diffuse 0.55 specular 0.35 roughness 0.02 } }; #declare Mat_Glass = texture { pigment { color rgbt <0.18, 0.33, 0.45, 0.68> } finish { diffuse 0.08 specular 0.55 roughness 0.008 reflection 0.10 } }; #declare Mat_LightCyan = texture { pigment { color rgb <0.25, 0.85, 0.95> } finish { diffuse 0.45 specular 0.30 roughness 0.02 ambient 0.0 } }; #declare Mat_LightMagenta = texture { pigment { color rgb <0.95, 0.30, 0.75> } finish { diffuse 0.45 specular 0.30 roughness 0.02 ambient 0.0 } }; #declare Mat_LightAmber = texture { pigment { color rgb <1.0, 0.70, 0.25> } finish { diffuse 0.50 specular 0.22 roughness 0.03 ambient 0.0 } }; #declare Mat_Road = texture { pigment { wrinkles color_map { [0.00 color rgb <0.05, 0.055, 0.06>] [1.00 color rgb <0.09, 0.095, 0.10>] } scale 6 } finish { diffuse 0.95 specular 0.06 roughness 0.10 } }; #declare Mat_AsphaltPaint = texture { pigment { color rgb <0.12,0.12,0.13> } finish { diffuse 0.9 specular 0.05 roughness 0.08 } }; // -------------------- Ground + base slab -------------------- plane { y, 0 texture { Mat_Road } } box { <-220, 0, -220>, <220, 0.6, 220> texture { Mat_DarkMetal } } // Subtle lane lines / grid accents (fast) #declare i = -10; #while (i <= 10) box { <-220, 0.601, i*20-0.35>, <220, 0.605, i*20+0.35> texture { Mat_AsphaltPaint } } box { , texture { Mat_AsphaltPaint } } #declare i = i + 1; #end // -------------------- Macros -------------------- #macro Building(BaseX, BaseZ, W, D, H, StepCount, StepInset) union { #local i = 0; #while (i < StepCount) #local w2 = W - 2*StepInset*i; #local d2 = D - 2*StepInset*i; #local hh = (H/StepCount)*0.72; #local y0 = 0.6 + i*(H/StepCount)*0.56; #if (w2 < 1) #local w2 = 1; #end #if (d2 < 1) #local d2 = 1; #end box { , texture { Mat_Concrete } } #local i = i + 1; #end // crown box { , texture { Mat_DarkMetal } } // antenna cylinder { , , W*0.06 texture { Mat_DarkMetal } } cone { , W*0.06, , 0.0 texture { Mat_LightCyan } } // window bands (procedural subtle variation) #local bandCount = 8; #local b = 0; #while (b < bandCount) #local yy = 0.6 + H*(0.08 + 0.105*b); box { , texture { pigment { bozo color_map { [0.00 color rgb <0.08, 0.09, 0.10>] [0.60 color rgb <0.11, 0.12, 0.13>] [1.00 color rgb <0.06, 0.07, 0.08>] } scale 1.0 } finish { diffuse 0.35 specular 0.20 roughness 0.03 } } } box { , texture { Mat_Glass } } #local b = b + 1; #end } #end #macro SignPanel(Cx, Cy, Cz, W, H, ColTex) box { , texture { ColTex } } #end #macro SkyBridge(X1,Z1, X2,Z2, Y, W) union { box { , texture { Mat_DarkMetal } } box { , texture { Mat_Glass } } } #end #macro TransitTube(P1, P2, R) union { cylinder { P1, P2, R texture { Mat_DarkMetal } } cylinder { P1, P2, R*0.78 texture { Mat_Glass } } cylinder { P1, P2, R*0.12 texture { Mat_LightAmber } } } #end #macro LowBlock(Cx,Cz,W,D,H, T) box { , texture { T } } #end // -------------------- City core -------------------- union { // main towers Building( 0, 0, 18, 18, 36, 6, 1.0) Building( 18, -8, 14, 12, 28, 5, 0.9) Building(-18, 6, 16, 14, 30, 6, 0.9) Building( 10, 18, 12, 12, 24, 5, 0.8) Building(-10, -18, 12, 16, 26, 5, 0.8) // secondary towers Building( 34, 10, 10, 10, 20, 4, 0.7) Building( 34, -18, 10, 14, 22, 4, 0.7) Building(-34, 16, 12, 10, 22, 4, 0.7) Building(-34, -12, 10, 12, 20, 4, 0.7) // skybridges SkyBridge(-18, 6, 0, 0, 16, 3.5) SkyBridge( 0, 0, 18, -8, 14, 3.5) SkyBridge(-10,-18, 10, 18, 12, 2.8) // transit tubes (kept above sightline) TransitTube(<-95, 12, -65>, < 95, 14, -15>, 1.8) TransitTube(<-90, 16, 55>, < 90, 17, 20>, 1.5) TransitTube(<-55, 20, -110>, < 25, 21, 110>, 1.35) // hover platforms #declare PlatTex = texture { pigment { granite color_map { [0 color rgb <0.10,0.11,0.13>] [1 color rgb <0.16,0.17,0.19>] } scale 1.4 } finish { diffuse 0.55 specular 0.25 roughness 0.03 } }; union { cylinder { <22, 9.5, 8>, <22, 10.0, 8>, 4.2 texture { PlatTex } } torus { 4.2, 0.25 rotate <90,0,0> translate <22,10.0, 8> texture { Mat_LightCyan } } } union { cylinder { <-26, 11.0, -6>, <-26, 11.5, -6>, 3.6 texture { PlatTex } } torus { 3.6, 0.22 rotate <90,0,0> translate <-26,11.5,-6> texture { Mat_LightMagenta } } } // neon signage SignPanel( 9, 9.5, 8.8, 5.5, 2.0, Mat_LightMagenta) SignPanel( -7, 13.0, -8.2, 6.0, 2.2, Mat_LightCyan) SignPanel( 18.8, 11.0, -8.0, 4.0, 1.8, Mat_LightAmber) } // -------------------- Broader city spread (mid/low-rise repetition) -------------------- #declare sx = -4; #while (sx <= 4) #declare sz = -4; #while (sz <= 4) #declare PX = sx*42; #declare PZ = sz*42; // keep center clearer #if (abs(PX) > 55 | abs(PZ) > 55) #declare w = 14 + mod(abs(sx*17 + sz*11), 10); #declare d = 12 + mod(abs(sx*13 + sz*19), 12); #declare h = 6 + mod(abs(sx*23 + sz*29), 10); LowBlock(PX, PZ, w, d, h, Mat_Concrete) // occasional taller mid-rise #if (mod(abs(sx*7 + sz*9), 4) = 0) Building(PX+8, PZ-6, 10, 10, 18 + mod(abs(sx*31+sz*17), 10), 4, 0.7) #end #end #declare sz = sz + 1; #end #declare sx = sx + 1; #end // -------------------- Elevated ring road (slightly larger for zoomed view) -------------------- union { torus { 78, 1.25 rotate <90,0,0> translate <0, 7.8, 0> texture { Mat_DarkMetal } } torus { 78, 0.72 rotate <90,0,0> translate <0, 7.8, 0> texture { Mat_Glass } } torus { 78, 0.18 rotate <90,0,0> translate <0, 7.8, 0> texture { Mat_LightAmber } } } // -------------------- Distant silhouettes for depth -------------------- #declare k = 0; #while (k < 26) #declare a = (360/26)*k; #declare rx = 160*cos(radians(a)); #declare rz = 160*sin(radians(a)); #declare hh = 14 + mod(k*19, 22); #declare ww = 18 + mod(k*13, 10); #declare dd = 16 + mod(k*17, 12); box { , texture { pigment { color rgb <0.09,0.10,0.12> } finish { diffuse 0.65 specular 0.05 roughness 0.08 } } } #declare k = k + 1; #end