Pixel City
May 15, 2009 10:58 AM   Subscribe

Pixel City is a procedurally generated cityscape by Shamus Young. Procedurally generated graphics have a long history of producing attractive results with extremely small amounts of code, like Elevated, which was generated by just 4K of code, automatically generated video game content (also, Spore) or the generation of realistic water flows. Note the last demo reel may have been the test for a new film mentioned previously.
posted by GuyZero (42 comments total) 25 users marked this as a favorite
 
A lot of 3D render engines are, at their core, surprisingly small but furiously churning.
posted by bz at 11:21 AM on May 15, 2009 [1 favorite]


Are there any major procedurally generated games out there? It seems like something that would be majorly cool, but that the same time the opposite of the rails-between-setpieces/trying-to-be-a-movie that is the reigning philosophy right now.
posted by Artw at 11:21 AM on May 15, 2009


See also the procedurally generate city project Subversion, from the company responsible for Darwinia.
posted by Pastabagel at 11:27 AM on May 15, 2009 [1 favorite]


I saw the video and read some of the enormous list of posts and I was like "this isn't that hard, why hasn't it been done before". But I guess the devil's in the details and by that I mean frame rate. Although now that I say that, I'm not so sure. Once you have all your OpenGL objects created, the frame rate is the same whether you procedurally generated them or hand-created them. ?
posted by DU at 11:28 AM on May 15, 2009


would these be those same "small" 3d engines that require a multi-gig DirectX installation first?

/purist
posted by slater at 11:29 AM on May 15, 2009 [2 favorites]


Running on an OPERATING SYSTEM!
posted by Artw at 11:34 AM on May 15, 2009


This supports my theory that our universe is a simulation running on a Commodore PET 2001.
posted by ZenMasterThis at 11:48 AM on May 15, 2009


I would swear this is how they made the generic cityscapes in the last two big Spider-Man games (Spider-Man 3 and Web of Shadows). Except I don't think they look quite this good.
posted by straight at 11:53 AM on May 15, 2009


DU, I just think he's done a particularly nice job. It's probably been done plenty of times before. His addition of "cars" on the streets is a really great hack - they're just little partially transparent circles of white or red but the effect is great. Also, his camera work is pretty good IMO. If I wrote it the camera would be flying through buildings constantly.

I tried to find some videos of procedural graphics in old demoscene Amiga demos, but all I found were the original Amiga executables which are of limited appear to most MeFi readers . But certainly they've been doing it since Amiga-days which were, what, '88?

Also, widespread availability of a full-featured OpenGL stack is a relatively recent phenomenon. I may be stuck in my undergrad days though when $100K got you a SGI box that mostly implement OpenGL. Saying that you just fill the OpenGL scene and push a button is, well, true, yeah, but that's like saying painting is just putting paint on canvas.
posted by GuyZero at 11:55 AM on May 15, 2009 [1 favorite]


slater, in the case of Elevated, all the DirectX installation is responsible for is: 1. Mixing the audio generated by the softsynth, and 2: Getting the shaders and vertex data to the video card. Everything else is packed into 4k.
posted by zsazsa at 11:57 AM on May 15, 2009


The only thing missing is irregular street layouts. The grid imposes a subtle order on the city that makes it look slightly unreal. Also, if I were doing it, I would add some clumping to the buildings to make certain areas more built up than others. Still, pretty damn impressive for a week's work.

There actually is quite a lot of work being done in this area, for architects and movie studios.
posted by fatbird at 12:04 PM on May 15, 2009


CG water looks a bit too syrupy when it "splashes". It's kind of gross.
posted by potch at 12:09 PM on May 15, 2009


slater: "would these be those same "small" 3d engines that require a multi-gig DirectX installation first?"

Multi-GB Direct-X install? I believe the Direct-X runtime is under 200 MB, unless your talking about something else. I think textures are what take up the largest amounts of space in games.
posted by Sargas at 12:38 PM on May 15, 2009


That's my apartment building right there! And there! And there too!
posted by monospace at 12:49 PM on May 15, 2009 [1 favorite]


Metafilter: surprisingly small but furiously churning.

I know, I know, but it had to be done.
posted by poe at 1:04 PM on May 15, 2009 [1 favorite]


There's also the snazzy-looking procedurally-generated (though apparently stuck in vaporware) MMO called LOVE.
posted by blacksmithtb at 1:05 PM on May 15, 2009


Multi-GB Direct-X install? I believe the Direct-X runtime is under 200 MB

I think the argument could be made that you need windows for direct x.
Size of windows install versus some minimal linux install probably would tip the scales over into the multi GB range.

Not that this takes anything away from the accomplishment of elevated, IMO, but it might rile up the purists.
posted by juv3nal at 1:05 PM on May 15, 2009


fatbird, have a look at the "Part 12" video from PastaBagel's link. Its streets are not just irregular, but based on explicit "city center" placements that govern street orientation and building sizes.
posted by CaseyB at 1:21 PM on May 15, 2009


Once you have all your OpenGL objects created, the frame rate is the same whether you procedurally generated them or hand-created them.

Assuming you're rendering the exact same geometry, yes.
However, a non-trivial renderer will do some kind of culling to the scene, as to not waste time rendering invisible objects (for example, via portaling.) Hand-created geometry for such an engine (especially environments, not necessarily objects with in them so much) is created with the particulars of the engine in mind. Any automatically geometry generation scheme would have to be hip to the engine to take decent advantage of this, and, even then, humans are going to be better at balancing technical constraints with aesthetics.
There are numerous other constraints (texture memory size, etc.) for which artists are likely to be better than an algorithm as well.
posted by blenderfish at 1:45 PM on May 15, 2009


fatbird, have a look at the "Part 12" video from PastaBagel's link. Its streets are not just irregular, but based on explicit "city center" placements that govern street orientation and building sizes.

Wow. That looks amazing. I hope they actually get a game out of it.
posted by adamdschneider at 1:58 PM on May 15, 2009



I think the argument could be made that you need windows for direct x.
Not really. I've successfully played Portal on OSX with Crossover, which installs DirectX.


I said it could be made, not that it would hold up... ;P
posted by juv3nal at 1:58 PM on May 15, 2009


Actually, I was thinking about 3D engines such as splutterfish brazil, renderman, povray and the like rather than the realtime engines whose dependency upon libraries does make them just furiously churning.
posted by bz at 2:01 PM on May 15, 2009


DU writes: "
I saw the video and read some of the enormous list of posts and I was like "this isn't that hard, why hasn't it been done before".
"

It has. I distinctly recall a playable 4k game involving generated city scape. Buildings weren't quite as detailed as this one, but I guess you gotta sacrifice something if you want playability.
posted by pwnguin at 2:08 PM on May 15, 2009


I read his whole blog series yesterday, it's really interesting reading how someone like him does work like this. BTW, in part 13 he links to a code release: both a Windows binary and source.
posted by Nelson at 2:17 PM on May 15, 2009


The grid imposes a subtle order on the city that makes it look slightly unreal.

The generated cities all look like the state capital of the Uncanny Valley, but that just makes me love them more.
posted by GuyZero at 2:29 PM on May 15, 2009


The greatest procedural generated game i've seen so far: Dwarf Fortress.
posted by CautionToTheWind at 2:31 PM on May 15, 2009


I totally forgot about Dwarf Fortress. BECAUSE IT CREATES INSANITY AND LEAVES MADNESS IN IT WAKE. It's seriously too much game for any human mind.
posted by GuyZero at 2:32 PM on May 15, 2009 [1 favorite]


Cyberspace. A consensual hallucination experienced daily by billions of legitimate operators, in every nation, by children being taught mathematical concepts... A graphic representation of data abstracted from banks of every computer in the human system. Unthinkable complexity. Lines of light ranged in the nonspace of the mind, clusters and constellations of data. Like city lights, receding.
posted by empath at 2:38 PM on May 15, 2009


I love this stuff, but am always frustrated when those lovely 4k demos won't run on my PC (in the case of Elevated, throwing up an "invalid executable" error).
posted by Jimbob at 2:42 PM on May 15, 2009


Are you sure you have 4k of memory?
posted by GuyZero at 3:07 PM on May 15, 2009 [1 favorite]


Shamus Young was also the genius that brought us DM of the Rings.
posted by xorry at 4:48 PM on May 15, 2009 [1 favorite]


Not released yet (and at the present rate, no time soon,) but the most impressive procedural game I've seen is Inifinity. Watch some of the video; procedural planet , nebula, asteroid belts (the end of that last video in particular.)
posted by Luddite at 4:50 PM on May 15, 2009


Was it just me that expected the screen to pan, after when all the different buildings started to flash faster and faster, to a shocked looking Keanu Reeves saying "I...know architecture"?
posted by lalochezia at 5:46 PM on May 15, 2009 [3 favorites]


Awesome. Check out Procedural's CityEngine, as well.
posted by signal at 6:38 PM on May 15, 2009


Ooh, it's like it's 1985 and I'm watching the opening to Night Flight on USA.
posted by Horace Rumpole at 7:59 PM on May 15, 2009


I really love synthetic environments. I just like zooming around them - it is just really pleasing to move through space with super-powered freedom (not just flying but translating in co-ordinate space). Seeing stuff like this makes me want to turn the study into a VR space but I think I'll wait for the first procedural sandbox game. (spore does not count)
posted by vicx at 9:00 PM on May 15, 2009


This was an excellent post. His build blog is worthwile as a walkthrough of the modelling process to discover what a cityscape is visually.

One critical aspect missing: light polllution. It would seriously mark cloud cover, buidings and distance.
posted by Ogre Lawless at 1:07 AM on May 16, 2009


I've been following all of Shamus' posts on Twenty Sided about developing his procedural city for the last month or so, and somehow managed not to see the final outcome, which is fantastic. It's also a very pleasant piece of simple videomaking to watch.

One critical aspect missing: light polllution. It would seriously mark cloud cover, buidings and distance.

I attributed it to light pollution that the lowest portion of the horizon is illuminated.
posted by Halle at 3:33 AM on May 16, 2009


blenderfish--

If you can fit geometry generation onto a GPU, you can get far higher framerates -- you're not spewing vertices over the system bus.
posted by effugas at 12:12 PM on May 16, 2009


If you can fit geometry generation onto a GPU, you can get far higher framerates -- you're not spewing vertices over the system bus.

Interesting. Here are my initial thoughts.

Typically you'd have scene vertices live in the GPU, so they wouldn't have to go over the system bus more than once (or when they're streamed.) Also, typically vertex fetch isn't your bottleneck (certainly not moreso than a heap of ALU ops to generate geometry from thin air.) So you'd really just be saving GPU ram, which is going to be dominated by textures anyway.

Current geometry work on GPUs seems to be centered around dynamic things (like shadow volumes or displacement mapping,) [to avoid sending lots of dynamic verts over the system bus], vertex amplification (sub-d surfaces, NURBs) [to avoid storing many verts] and LODding [to reduce transform and tesselation work.] Wholesale generation of geometry from scratch isn't really that prominent right now/yet. But there is, for sure, a lot of interesting future work to be done in this direction.
posted by blenderfish at 1:24 PM on May 16, 2009


If you can fit geometry generation onto a GPU, you can get far higher framerates

That's what the game I linked to is doing; real-time terrain generation on the GPU
posted by Luddite at 5:59 AM on May 17, 2009


If you can fit geometry generation onto a GPU, you can get far higher framerates
OpenCL and the DX11 Compute shaders should make all that much simpler. Some work has already been done on a REYES implementation, and terrain is more constrained.
posted by Z303 at 9:13 AM on May 19, 2009


« Older A Scout respects those with ideas and customs...   |   Beanie Madoffs Newer »


This thread has been archived and is closed to new comments