• Welcome to SC4 Devotion Forum Archives.

Stretching Squashed Buildings

Started by RippleJet, November 06, 2008, 04:28:22 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

RippleJet

Due to the high viewing angle used in SC4, buildings usually look vertically squashed if they are made to scale.
Thus, in order not to look squashed, bats are usually made taller for the game than they would be in RL.

This has been particularly important for low-rise and mid-rise buildings.
Depending on whom you ask, the recommended scale factor varies a bit, between 1.25 and 1.50.
Obviously, the shorter the building, the higher the recommended scale factor would be.

However, the same phenomenon does apply to skyscrapers as well.
One well known example is the in-game model of the Empire State Building.

Now, what can be done to S3D models that are already rendered for the last time?
Following Chrisim's Tutorial: MODding rendered SC4Models it is possible to stretch models afterwards.

However, one has to be careful not to create unwanted effects.
This post by bap in Chrisim's tutorial got me later into investigating this and trying to stretch buildings vertically:

Quote from: bap on June 14, 2008, 03:44:00 PM
I am trying to reduce the height of a building with the techniques you described. I copied the 'y' column in the vert tab of the s3d file in ilive Reader's to Excel and scaled all values by 0.75, and copied the scaled values back to the s3d file and saved. It kind of work, but some of the vertices of the triangles (some of the borders/edges of the building) do not scale correctly and became distorted. I am keeping the full 6 digits precision in the conversion. Any idea of what I am doing wrong? Or, it this not the right way to change the height of a building?




In order to test this out, I took a recent upload of a really tall building, the Burj Al Alam by Orange_o.
That is a copy of a RL project, and modelled to exactly its RL height, 510.8 m.

I decided to stretch in vertically 125%, giving it a height in game of 638.5 m instead.
The image below shows five buildings, from left to right:

1. The in-game Empire State Building, squashed and unstretched, 480 m tall to the top of the spire.
2. Burj Al Alam, unstretched, 510 m tall.
3. Burj Al Alam, parabolically stretched, 638 m tall.
4. Burj Al Alam, linearly stretched, 638 m tall.
5. Burj Al Alam, evenly stretched, 638 m tall.

Note that I have plopped these with an empty plugins folder, so there are props missing. ::)



Before explaining the difference between the three stretched version, lets take a look at them from another direction as well.
In the following picture, the original one is on top, followed by the parabolically, linearly and evenly stretched ones:



The evenly stretched version was the first one I made.
In that, each Y-coordinate was multiplied by 1.25:

  • At street level (Y=0 m) the stretch factor is 1.250
  • Halfway up (at Y=255 m) the stretch factor is 1.250
  • At the top (Y=510 m) the stretch factor is 1.250
Looking at the base, you can clearly see the distortion bap was referring to.
You can also see that shadows appear under the model, which appears to have been raised.

The linearly stretched version was the second one I made.
In that one, the stretch is linearly varied depending on the height above the base:

  • At street level (Y=0 m) the stretch factor is 1.000
  • Halfway up (at Y=255 m) the stretch factor is 1.125
  • At the top (Y=510 m) the stretch factor is 1.250
The linearly stretched version is a huge improvement over the evenly stretched one.

The parabolically stretched version was the final one, and the one I'm most pleased with.
In that one, the stretch factor corresponds to the square of the height:

  • At street level (Y=0 m) the stretch factor is 1.000
  • Halfway up (at Y=255 m) the stretch factor is 1.0625
  • At the top (Y=510 m) the stretch factor is 1.250
In the first picture you can clearly see how the different methods give a different stretch on the dome on top of the skyscraper.
The more parabolic, the less the basement is stretched, and the taller the top floors become.

In order to give a final reason to why I prefer the parabolically stretched version, let's look at the towers from yet another direction.
In this picture I've left out the already discarded evenly stretched version.
The ones shown are, from left to right, the linear one, the parabolic one and the original one:



Note that there is a clear difference in the white planter protruding to the right from the basement.
The parabolically stretched tower is basically identical with the original one, but not the linear one.

Next I think I'll stretch the in-game Empire State Building parabolically... ::)




Now, can anyone do this?
In principle, yes. You only need to understand Chrisim's tutorial, and use Excel for the conversions.

The twenty S3D models included in the Al Alam SC4Model file had a total of some 5,000 vertices that individually had to be stretched.
Each vertex got its own stretch factor, depending on its height above the basement.
Without being able to copy these vertices from the model to Excel and v/v it wouldn't have been possible.




Now, the next step would of course be to give this stretched tower to Barby and let her make a stage 15 CAMeLot out of it. ()stsfd()

Finally a slight warning if you liked this tower; unfortunately the ploppable tower available on STEX grows on empty lots as well.
It is set to belong to the in-game CO§§§ family 0x400000AB, which grows on lots as small as 3x3.
The tower itself requires a lot sized 7x8, and would thus become immortal if it would grow on an in-game smaller lot.

Orange_o_

I'm impressed because your job is more important than mine.

It is evident that I agree so that the Burj Al Alam joins to the CAMeLOt, it's an honor for me.

Thanks

   °   °   °   °   °   °   °   °   °   °   °   °   °   °   °   °   °   °   °   °   °   °   °   °   °   °  


RippleJet

Thank you, Orange! :)
Barby has the parabolically stretched file now and will make the CAMeLot tomorrow. ;)

I'll be sending you another file tomorrow as well! ::)




Tonight I've been playing with the Empire State Building.
I've developed a number of different stretching techniques,
and I guess it's easier to explain them while showing a picture... ::)




  • 0 is the original, unstretched tower
  • 1 is stretched evenly all the way (power of 0)
  • 2 has a stretch that increases linearly from the bottom up (power of 1)
  • 3 has a stretch that increases parabolically from the bottom up (power of 2)
  • 4 has a stretch that increases parabolically from both ends (maximum stretch in the middle)
  • 5 has a stretch that increases cubically from both ends (power of 3, maximum stretch in the middle)
  • 6 has a stretch that increases cubically from the bottom and from a point 2/3 up (maximum stretch 1/3 up and at the top)

Note that all these towers have the same maximum height after stretching, 25% taller than the original one.
The even stretch can cause problems at the base, as we saw with Orange's Al Alam Tower above.

Distortion also easily appears at roof level, or where there are discontinuous steps along the tower.
Distortions appear more in the zooms farther away, but tend to be most visible at zoom 3.

For the Empire State Building I think I will opt for either #5 or #6.
#5 has the smallest stretch at street level and at the top of the mast, making the mast rather short.
#6 has the smallest stretch at street level and at roof level (beneath the mast), causing less distortion on that roof.

Final selection will always have to based on how it appears in the game though, in all zooms and view directions.

By stretching the Empire State Building 25%, it would now come out as a stage 15 R§§§ CAMeLot.
Before stretching it would stay as a stage 13 R§§§.

Andreas

Interesting idea! :) You should try to modify the Columbia Seafirst Center, it's one of the Maxis landmarks that always looked way too tiny compared to other buildings.
Andreas

RippleJet

Quote from: Andreas on November 08, 2008, 03:08:52 AM
You should try to modify the Columbia Seafirst Center, it's one of the Maxis landmarks that always looked way too tiny compared to other buildings.

Indeed, the model of that is a disgrace to Maxis... $%Grinno$%

The RL building stands 285 m tall, the model made by Maxis is 215 m tall.
Just to get it to the RL height would require it to be stretched by 133%.
Then, to get it 25% taller than the RL one, would require a total stretch of 166%.

With such a stretch it would be impossible to avoid all sorts of distortions.
Thus, we need to look at a number of alternatives again.

The vertical stretch is in all these cases cubical, both from the bottom and the top.
These are all shown at zoom 3, since that is the most difficult one.

The towers in the pictures below are, from the shortest to the tallest:

  • The unstretched in-game version, 215 m tall.
  • A version that's stretched 133%, 285 m tall. Same height as the RL one.
  • A version that's stretched 150% vertically and 115% horizontally, 322 m tall.
  • A version that's stretched 166%, 370 m tall.







It is quite obvious that the tallest version is unacceptable.
The 133% version looks a lot better, and could probably be used.

Since there seemed to be space sideways on the lot, I decided to try to scale the building in all directions.
The 150% version is scaled in both X- and Z- directions by 115%.
This would bring those steps closer to the sidewalk in front and the path in the rear.

RippleJet

Had to make one more... ::)
This one is stretched only 133% vertically, and 120% horizontally.



Now the steps both in front and in rear reach the sidewalk and the path:


JoeST

stretching the buildings hey..  ???


seriously though ..... Tage is crazy....  $%Grinno$%

Lovin it

Joe
Copperminds and Cuddleswarms

rooker1

Tage may be crazy, but it's definately in a great way.  &apls
I hope see these improvements uploaded very soon.  ::)

Robin  :thumbsup:
Call me Robin, please.

bap

Tage, this is a very interesting thread. My apologies for just noticing it quite recently.

As the S3D models are made as a series of triangles, stretching the model in the reader distorts the shape of the triangles and will most probably result in distorted images somehow. This is what was happening with the building the height of which I was trying to reduce. After a while I noticed that there was nothing wrong with exporting the new numbers from excel back to reader. I ended up realizing that the best thing to do was to perform a full scaling down of that building. Scaling the whole building by the same factor in all directions does not distort the triangles. The non-linear stretching sounds an interesting way to overcome the distortion problem, although it seems the best results are achieved when the scaling in horizontal and vertical directions are of the same order.

Bap