Visualization, Spring'98, Yap

HOMEWORK 3:
AUTOMATIC MODEL GENERATION

STREETS

A city street is conceptually polylines
with the following attributes (or parameters):
  1. name of street
  2. explicit list of intersections with other streets
  3. conventional direction of street (thus allowing us to speak of left or right side of street)
  4. one-way or two way street
  5. default width of street
  6. local variation in street width
  7. street details such as placement of street signs
  8. trees
  9. center partition
  10. fire hydrants
  11. parking meters
  12. width of sidewalk of each side

[FILETYPE "Street Parameters"]

   [RECORD_TYPE] STREET_RECORD

	[STREET_ID] 1	// a ID unique in the neighborhood level
	[STREET_NAME] "Broadway" // the street name
	[STREET_WIDTH] 50 // the street width, including sidewalk
	[STREET_SIDEWALKWIDTH] 10 // the sidewalk width

	// The coordinates of start and end point of the mid-line
	// of the street. Use the coordinate system relative to
	// the neighborhood.

	[STREET_START] (100.0, 100.0)
	[STREET_END] (300.0, 500.0)

	// The divider type of the street
	[STREET_DIVIDER] CENTER_SOLID

	// The number of lanes in each direction
	[STREET_LANES] 2

	// Direction (two way or one way)
	[STREET_DIRECTION] TWO_WAY
	   // if one way, either ONE_WAY_FORWARD
	   // or ONE_WAY_BACKWARD.  Forward direction
	   // is from STREET_START to STREET_END

	[RECORD_TYPE] STREET_SEGMENT_RECORD

		[SEG_ID] 1 //unique within the cureent street
		/* (STREET_ID, SEG_ID) can uniquely locate
		a segment */

		// Same coordinates system as above
		[SEG_START] (100.0, 100.0)
		[SEG_END] (200.0, 350.0)

		// the begining and end intersections
		[INTERSECTIONS] 1, 2

		// the density of meters, in terms of number per
mile
		[SEG_NUM_PARKING_METERS] 100

		// block id are unique in a neoghborhood
		[LEFT_BLOCK] 101
		[RIGHT_BLOCK] 102

	[END_RECORD]

	...


	[STREET_INTERSECTION]
		1, 2, 3, 4 // a list of intersection id

   [END_RECORD]

   [RECORD_TYPE] STREET_INTERSECTION
	[INTERSECTION_ID] 1
	// two intersected streets
	[STREET_ID1] 1
	[STREET_ID2] 2
	// the intersection shape
	[POLYGON] (100, 100), (100, 105), (105, 105), (105, 100)
   [RECORD_END]
[ENDFILE]