Denmark
Joined: Jul 7, 2013
Post Count: 635
Status:
Offline
Re: Light & textures - rendering examples of this and that.
@okh If this is messing with my thread, you are welcome to mess as much as you like!
I suspect quite a few of us have struggled with getting a (mountainous) horizon right.
Me too! But there are, I assume, two reasons for wanting this:
One is the aesthetic reason – to get a nicer illustration.
The other is to make close to realistic predictions of the views framed by the windows – using a backdrop as aid when deciding placement and angle of a house.
Achieving the latter (accurately), I think, will not be possible with the simple template I have made, In fact I don't think it's possible to make any template that can be used to completely compensate for the equirectangular distortion. But to perform an inversion might be a possible compensation –at least to a certain extent.
Maybe, it is just me, but it would be a great help if 3D view and rendering were the same.
A matching view between the 3D preview and the rendered image would be great!
And even better if I could understand the projection and manage to make a reasonably accurate template... smile
Tsk tsk tsk... isn't it just a 4 by 1 rectangle projected on a hemisphere? So all we have to do is make an attempt to invert the distortion... right? Sounds easy... but I know it isn't. Anyway, let's try a quick & dirty inversion-method:
Example rendering:
It seems I could have curved the sky image bit a bit more. Try and fail is the name of the game. But it seems to work – to a certain extent
______________
For illustrational purposes, the challenge with using sky images containing mountainous formations or other sizeable objects, is to match light and shadows, exposure, tint and blurriness. A quick rendering shows that the sunlight is too bright. And I have noticed that the colour of the sunlight varies, not only by the time of day, but also by the time of year – and so do the shadows. So colour-matching by changing time and date will not work.
Since the colours and the exposure will be a complete mismatch with sunlight, IBL is the solution. Using IBL, I can colourize the upper part of the sky image to make a better colour-match. The drawback is that the shadow-map will be quite dull and render a lifeless image.
So if I have to use this sky image, I have to add shadows by using a fake sunlight – that I can create with light panels. Like this:
OK, so now the rendering is a bit closer to useable – a bit – but it's not quite there yet. If I put in a few hours of work, I just might make it work.
I will discuss lighting in a later post – and show examples.
Cec
----------------------------------------
[Edit 1 times,
last edit by Ceciliabr at Sep 5, 2018, 6:59:22 PM]
Norway
Joined: Apr 18, 2014
Post Count: 264
Status:
Offline
Re: Light & textures - rendering examples of this and that.
It seems I could have curved the sky image bit a bit more.
Are you sure you don't mean a little bit less? I just did a quick test, and I got the opposite result. Btv. this method is great for any kind of backdrop, not just skies and sceneries.
Denmark
Joined: Jul 7, 2013
Post Count: 635
Status:
Offline
Re: Light & textures - rendering examples of this and that.
Are you sure you don't mean a little bit less?
I'm pretty sure, but I have been sure before, only to find I was wrong.
Btv. this method is great for any kind of backdrop, not just skies and sceneries.
Absolutely! And the greatest advantage is that a sky image will always render a perfectly exposed image, no matter the lighting conditions. A backdrop affixed to a box or a wall will need lighting, and even then might not render at it's best.
Joined: May 12, 2013
Post Count: 1545
Status:
Offline
Re: Light & textures - rendering examples of this and that.
Maybe, it is just me, but it would be a great help if 3D view and rendering were the same.
A matching view between the 3D preview and the rendered image would be great!
And even better if I could understand the projection and manage to make a reasonably accurate template... smile
Tsk tsk tsk... isn't it just a 4 by 1 rectangle projected on a hemisphere? So all we have to do is make an attempt to invert the distortion... right? Sounds easy... but I know it isn't.
Quite, in theory it is easy, but as you say, making the perfect template is probably not possible. Since last post the (3D) perspective has changed: see fix in thread 8704 and SF-req 668. @Puybaret: Perfect. THANKS for the fix! The 3D sky now makes more sense.
Thanks for the many hints and alignment/distortions. Yet to find out how to save time with Hugin, but I remembered Stellarium (celestial software) which has customisable horizons and backgrounds and when viewing it is possible to use different projections. Testing default ground image (i.e. horizon panorama) + cylinder projection: a night sky for SH3D with grid match and correctly placed celestial objects (at N46.108° E4.78° at some time I cannot remember).
Works for my purposes and suggests that Stellarium could be of help when matching sky imagery, placing sun, but also, I guess for making distorts for alternative rendering perspectives as discussed by Cec above.
I love Cec' beautiful images, but as opposed to Cec' aesthetic approach, mine is simpler and just practical. Say you consider building a lodge in a given position. - Use a panorama of the skyline (real or with online tool), place in grid template. - Use some sun calculator to determine how high above the horizon the sun will be during normal holidays. - Use a satellite calculator to determine the position of you favourite information provider. - Check out other stuff, like nearby airports. - Find direction(/distance) to various points, summits for hiking, GSM transmitters for broadband, etc etc.
Place all of the above in the template and use as a Sky texture (starting at 90° in the plan, due East when compass points North). Place terrain, trees, buildings and other close obstacles in the plan. You now can visualise several things. Where to point the dish and broadband antenna. Where to place solar panels. How to orient the plan for sun conditions. Which views you will be able to see from your favourite chair through which windows. Whether the airport flight path could be a problem. In addition to all other stuff, of course: grid/water/road access, meteorological statistics, ground condition etc. Arguably too geeky for most plans, the example is based on a real project. It turned out that it would be near impossible to get decent sun conditions in the winter, we needed a different GSM provider for broadband, terrestrial TV would be difficult, but satellite should be ok, airport might be a problem as afternoon flights would often pass just above. All of this could easily have been discovered without the sky texture, but having the visual while drawing proved very useful: once the lodge was oriented for perfect afternoon sun, it turned out it would be difficult to place solar and dish, and the entire lodge had to be mirrored to avoid getting the entrance blocked by snow in the winter.
A higher resolution of mountain_cabin_texture.jpg renders like this (wide angle virtual visitor gives a distortion, of course): .
Sunlight simulation is a perfect way of playing with sun conditions at different times. Btw. rendering sunlight seems to consider (the silly concept of) daylight saving, but not equation of time I think. At least I think that is why there appears to be a very slight mismatch (<4°) certain times of the year - or it could just be me. But it makes absolutely no difference for my purposes. I suppose one could also consider elevation of viewpoint / plan and estimate distance to horizon for the template.
Cec' template is probably better and easier to use for most purposes and work with most graphic editors. However, for accuracy and editing I prefer an .svg template to position (and distort) elements on the sky texture. For instance a 360° panorama .svg file with a grid, sky- and ground gradients and with links to other files: skyline, clouds, sun. That way it is relatively easy to place (and transform/distort if need be) each item accurately (with manually/Inkscape). Like Cec, I use a 360×90 template, with a few degrees extra at the bottom to blend with ground texture. Once each item is placed (and grid removed), the image can be saved as .png/.jpg and used as a high resolution sky texture.
sky360_sh3d6.svg, with links to (files placed in same directory): - sky360.png (skyline with transparent sky from 3D terrain viewer) - clouds.png (generic clouds) - sun.png (simple sun created with the Gimp) - plane.png (plane silhouette)
Same .svg file was used as template for the panoramas, just changing the different backgrounds and elements.
Point of this exercise is 1) to illustrate another way of using sky texture, and 2) to explain an item in the wishlist:
The use described, may be useful but to a few, and not really what the sky texture is intended for. But what would be great, now that the 3D view is more predictable, is if it were possible to set or change the starting point of the sky texture so it can be adjusted with the compass. Just a value in Home.xml would suffice for my purposes.
Joined: May 12, 2013
Post Count: 1545
Status:
Offline
Re: Light & textures - rendering examples of this and that.
colour of the sunlight varies, not only by the time of day, but also by the time of year – and so do the shadows
Took a second look at your sundial illustration. Not sure how you generated the image, but if it was SH3D/Sunflow (with a non-daylight-saving time setting close to the middle of a time zone), it looks like it might actually be equation of time(?). In which case I was wrong in my last post and our Azure home banter. Interesting. ok
Denmark
Joined: Jul 7, 2013
Post Count: 635
Status:
Offline
Re: Light & textures - rendering examples of this and that.
it looks like it might actually be equation of time(?)
Probably. The images were ( of course ) created with SH3D/Sunflow. Time zone is GMT + 00:00 and physical placement is Greenwich Park.
So the equation of time is responsible for the wobbly shadows...
In other 3D-programs ( like f.i. Vue eXtream – where I got my first real 3D experience) the sun is just a directional light source used to create atmospheres, so you can grab it and move it about as much as you like. Even if it's a lot more complicated in SH3D, I try to use the sunlight the same way, so I often shift the date and time to change the colour and height of the sunlight. That's why I created the sundial – to observe how both the light and the shadow directions changed with time.
Here is my sundial Project-file, so you can inspect my setup.
Joined: May 12, 2013
Post Count: 1545
Status:
Offline
Re: Light & textures - rendering examples of this and that.
Thanks. After some experiments it certainly looks as if the rendering considers equation of time.
..more complicated in SH3D, I try to use the sunlight the same way, so I often shift the date and time to change the colour and height of the sunlight...
And you make it work nicely for your renderings. But for me it would only be confusing if I could shift the sun at random, so I am happy it is 'complicated' to 'cheat'.
Anyone coming across this thread and reading about the sky texture alignment, should also know that SH3D 6 (beta 7) introduces X offset for the sky texture so it can be rotated.
Denmark
Joined: Jul 7, 2013
Post Count: 635
Status:
Offline
Re: Light & textures - rendering examples of this and that.
@okh
Anyone coming across this thread and reading about the sky texture alignment, should also know that SH3D 6 (beta 7) introduces X offset for the sky texture so it can be rotated.
Your contributions here are boosting the value of this thread. Thank you!
Joined: May 12, 2013
Post Count: 1545
Status:
Offline
Re: Light & textures - rendering examples of this and that.
Oh well, I am just meddeling. Really appreciate your detailed guide. Meanwhile I am updating my .svg template. Not posted yet. Template works quite well for inserting own images, but when I try to use 3d matrix to recreate your backdrop distortion I run into all sorts of problems. In part it is not supported by Inkscape (and not all browsers), but more annoyingly, even if the image transforms well, it somehow gets so blurred that it is totally useless. But I am on the case. One day maybe a proper man-template will be available. Meanwhile I suppose we shall have to make do with the (better) upside down world. ok