Tuesday, December 9, 2014

Minimal City - Final project breakdown

Minimal City : This is a procedural game completely generated by using Geo Spatial data, L Systems and Rules based modelling. The final product is a game playable on Mac or Windows, made using Unity.

This is a detailed description of what went into my final project for the class. Here are some links to all the good stuff.

Link to download game for Windows http://tinyurl.com/p8rw92v
http://tinyurl.com/lmd44br
Breakdown video Coming Soon
Screen Grabs Coming Soon


There were mainly 4 types of models that I generated for the game

  1. Buildings
    I relied on  Map data from Openstreetmaps.org to get the shapes of buildings. I extruded the building shapes to random heights. (This was not ideal, but there is absolutely no information about the height of the buildings in Openstreetmaps data.) After this I poke holes in the building based on how many windows are specified. Having a lot of Windows caused many Z fighting issues in the building corners and also increased the poly count. So I kept the number of windows to minimum.
  2. Roads
    There is no information about the width of the road in the data. So I had to guess the width of the road by the type of road. (Highway, walkway etc) The hardest challenge when dealing with roads was the intersections. I even wrote an email to openstreetmaps asking them how to interpret lane information in their data. Some roads have multiple lines for lanes, some roads have them all merged into one line.This becomes an issue since I am doing 3D and have plans to extrude roads as well. I couldn't resolve this issue, So I decided to lay all the roads as a Flat plane. This leaves me only Z fighting between primitives to deal with. To prevent Z fight between different roads, I used a for loop to loop through all the patches of roads and translate them in Y axis. It took me 4 weeks to figure this out!

    Here's an example of pretty data and Ugly data from maps. How would I go about converting those choppy lines into one continuous line? :O
  3. Car
    I didn't plan to model everything procedurally until I figured Cars could be modeled using rules based systems. This tool takes a parameterized cube as input and reduces the number of polygons and creates wheels for the car. Here's a test render of the Car that I ended up using.
  4. Trees, Lamppost, Cloud etc.  I have talked about L System rules for the Trees in my previous post. Here's a Gif showing different Trees that I had generated. This is only 1/3 of what's in the game.





Lessons learnt

  1. I didn't have the idea of creating everything in City procedurally. So I ended up with 4 different tools that generates Geometry. Ideally, I should have one tool that does all this.
  2. Never figured out how to best use Location data, even though I had it!
  3. This was way too much work for 2 weeks. But it was time well spent.
Future plans 
  1.  These are the games that are ruling the App store and making some noise.
    https://everyplay.com/videos/11914792
    https://everyplay.com/crossy-road/home
    It means that this art style definitely has some opportunities in Mobile/Tablet market .
  2. Overlay Openstreet map in the mini map?
  3. Unless you are into Racing games, this game doesn't particularly offer anything unique to hook the players! I need to talk to people and figure out the best Gameplay to best use location based maps. This either needs Multiplayer or something else. 
  4. Have a library of assets that replace generic buildings with something more specific. For example , I could search for "McDonald's" and generate a suitable building that looks like McDonalds, instead of just Boxes.

Thursday, December 4, 2014

Houdini tesselation

I am already behind schedule to finish my City Game. I was searching for more reference online for low poly images. I saw some more fascinating images online and the most intriguing part was that they were pretty simple to do! Even though I should be working in Unity right now, I spent the night playing with renders in Houdini. Pretty happy with the results. I started learning Houdini during Christmas break last year. I have been enslaved by this software. The more I know it, the more I love it!

I began messing with the polygon arrangement on a Grid and applied a color palette on it. I tried Quads, Triangles, Sub divided quads.





 

Then I started trying paintings as textures on top of these polygons.
But I thought I striked Gold when I tried a photograph. I changed the Polygon count to get this neat animation effect! Depending on whether you watch these images from 1st to last or last to 1st, it could mean different things. I feel if you watch from low poly face to high poly face, it could be interpreted as "The more I know you the more I love you!". If you watch it from high poly to low poly face, it could mean that "everything fades over time!". Here are the images.












Sunday, November 30, 2014

Minimal City - Update

I spent about 3 straight days to get the model and generate items that I needed for my game. Here's a breakdown of what I did. Since I needed low poly versions of clouds, cars, buildings.
  1. Clouds : I used 2-3 metaball spheres in Houdini to combine and reduce polygon count. 
  2. Trees : here's the L System that I used to generate the trees. I needed the L System generation count just at 1! Because most of the reference that I found had very minimalistic trees with 1-2 branches. Here's the LSystem Rules list that I used.
    Premise : F=FFX
    Rules
    X=~(10)T(10)/(137.5)!(d);"[--F+F(c*r)J]F(r*0.1)[++F-F(c*0.5)J]FXJ:0.25
    X=~(10)T(10)/(137.5)!(d);"[--F+F(c*r)J][++F-F(c*0.5)J]X:0.25
    X=~(10)T(10)/(137.5)!(d);"[--F+F(c*r)J]F(r*0.1)FXJ:0.25
    X=~(10)T(10)/(137.5)!(d);"F(r*0.1)[++F-F(c*0.5)J]FXJ:0.25

    I also spent about an hour making simple Pine trees. I am not completely sure if that would fit well for the low poly aesthetic. But I did that anyway. 
  3. I spent most time wrangling with the data. I found the ugly truth about using an open source data. There are many rules that could be broken when a user is collecting data. Intersections was a huge problem. Openstreetmaps doesn't set very clear guidelines on data collection for intersections. So my Python code cannot identify intersections at all. In the end I just decided to avoid the intersection problem completely.
  4. Car : I didn't know that modeling Car in Houdini could be so much fun! I have a setup that can let you create procedural Low Poly Cars. Since these Cars are really difficult to get perfect looking, it's really useful to have options for your car. (I want to demo this in class)  


Questions/ Concerns :
  1. This is NOT College Station. Yet! There are multiple things that I could do to  fix it. I could manually model some monuments and place them. Or I can display TEXT in the game with the building/Road data. 
  2. Unity integration : This is just a lot of work.





Here are some quick renders.

Sunday, November 23, 2014

Minimal City

I thought a lot about getting my abandoned city idea to real time which was one of the critiques in class. If I proceed with the idea of making images of abandoned city using the map data, most people won't even notice that I used map data! So I decided to do an animation or a game to demonstrate that. (May be Gen art 2015?)! 

Inspired by these images

I made this in Houdini in one sitting. This is a really big image, n then I composited into a spritesheet. It has some issues. But I was amazed how quickly low polygonal Art could be made in Houdini! I hope to make an animation of a paper car driving through College Station. The goal is to match the style of the images above.

Thursday, November 13, 2014

Abandoned city




Final Project - Update

This is what I was working on yesterday. making a lot of window placeholders from a building.
Goals:
Modelling the Windows
Modelling Trees
Texture the roads,
Texture Buildings
Animating city

Presentation goals :
Have a 30 second animation of showing different parts of the city.
Have a 30 second demonstration of how the tool works. (Maybe?)

Friday, November 7, 2014

Choregraphing chaos - Project 3

I was a really late started for this project. Initially I began with the idea of creating multiple pendulums in Harmony to create a wave like motion. But that didn't fully meet the requirements of the project. Then I began looking at mandelbulbs. These beautiful fractals can easily be created using recursion. My initial plan was to create this using Javascript. But after testing my code in HVS I realized how difficult running recursive functions on big screen is. Also it doesn't really help that Javascript is single threaded! I began trying out double pendulums, which I showed in class, but after realizing that two more students are planning to use double pendulums, I started looking for some other topics.

I read about Lorenz attractors and how combination of Sigma, Rho and Beta can control the overall look of the attractors. I initially had the idea of Lorenz attractors reacting to the music. I downloaded minim library for using music with Processing. I had the worst experience with that library! In no other programming language had I found same code running properly in one machine and not running in another! After wasting about 5 hours, I decided to manually choreograph the attractors. I was happy that I could produce such a beautiful patterns in an hour before class. Overall I felt that the project was successful. For a first ever processing program, the result that I had was really good.