Create your own sky and ground?
-
I don't think there is a was to do this with SU out-of-the-box so perhaps it could be done with Ruby?
Is there a way to use bitmaps (Transparent PNGs hopefully) for the Sky and/or Ground?.
I did try the watermark feature but, of course, once you orbit off the horizontal plane ....
My objective is to use my on Sky with clouds images and ground textures.
-
Yes, I've used this method ... that's why I has hoping for a ruby solution.
-
John,
There is no way to set the sky or ground from Ruby.
-
John
There may be a solution, if you can be patient for a few weeks (sorry) I may have an easy fix for this. I would like to expand on this but until I have a fully working solution, I do not want to jinx myself.
-
Jim, thanks for the reply.
Maybe SU7 will add a dialog (similar to the watermark dialog) to use a bitmap for the sky.
If they are really generous maybe a hook into to Google Earth's constellations for nightime scenes ... wouldn' that be fun.
-
Towards the end it shows a complete skybox all done within Sketchup.
-
Very cool!
Did you have to use a special photo or technique so it would map seamlessly? I am assuming the photo is mapped to the inside of a cylinder.
-
@jclements said:
Very cool!
Did you have to use a special photo or technique so it would map seamlessly? I am assuming the photo is mapped to the inside of a cylinder.
No, its a technique commonly used in video games called a "skybox". There are 6 photos (left,right,back,front,up,down) mapped to 6 faces of a inverted cube. If you google "skybox" you should find some examples. In the plugin you just choose the file you want in the preferences.
Adam
-
Skyboxes don't work at all well in SU...the corners are way too obvious. Skydomes are a much better alternative, or you can even go with simple cylinders if you don't look up too much. I have created a number of skydomes for SU. There is a quick example of one here.
The quality of the YouTube video is pretty awful, but it gives a rough idea of the kind of immersive environment that is possible in SU. -
It's possible to remap a dome/globe/sphere with your own image http://www.barnabu.co.uk/sketchup-skydome/
-
@alan fraser said:
Skyboxes don't work at all well in SU...the corners are way too obvious. Skydomes are a much better alternative, or you can even go with simple cylinders if you don't look up too much. I have created a number of skydomes for SU. There is a quick example of one here.
The quality of the YouTube video is pretty awful, but it gives a rough idea of the kind of immersive environment that is possible in SU.Well if you do it "right" you cannot see any seams using a skybox. (Watch the video link I posted to confirm this)
Adam
-
Adam,
Is the sky box a feature built into your app or are you using another application and then importing the result into SU?
-
Texture Maker will generate a cgi landscape and sky and export it in a variety of formats...including a skybox. Screenshot and result attached below.
Sky boxes are used extensively in games and work very well. They can be used well in SU, as Adam says, but only really from a very fixed viewpoint....that being the centre of the cube.
Games get around this by locking the skybox to the viewer. As you move through a first person perspective shoot-em-up the skybox moves with you, so always appears in the correct perspective and always infinitely distant. This obviously isn't the case in SU.
I realise this thread has drifted slightly away from Ruby, but there's a challenge for somebody.
Skyboxes can work well in SU, but generally only if you move a few feet...or catch a glimpse out of a window, not up and down streets. Of course you can make them really huge, so that any novement by the viewer is very slight in comparison...but then you get clipping problems.The simplest solution is simply to map a panoramic image around a cylinder. Here is a very old thread from the old forum, now transferred to Google Groups. So old, in fact, that it predates SU's ability to map around cylinders, so I had to do it by slicing the image into sections...but the resulting skps still work ok for most situations.
-
I initially implemented skyboxes in pure Ruby in SU.
# skybox functionality class MyViewObserver < Sketchup;;ViewObserver def initialize(stub) .. build a definition using 'stub' as filepath skybox = Sketchup.active_model.definitions[dname] @skybox = Sketchup.active_model.entities.add_instance skybox, Geom;;Transformation.new @skybox.locked= true end def onViewChanged (view) @skybox.locked= false @skybox.move! view.camera.eye @skybox.locked= true end def remove @skybox.locked= false Sketchup.active_model.entities.erase_entities @skybox end end def add_skybox $skybox = MyViewObserver.new("~projects/Ruby/skybox/space1") Sketchup.active_model.active_view.add_observer($skybox) end
ie Sketchup will move the skybox along with your camera. Works OK - only let down by SU crazily aggressive bounds on Z when it draws.
Adam
@alan fraser said:
Texture Maker will generate a cgi landscape and sky and export it in a variety of formats...including a skybox. Screenshot and result attached below.
Sky boxes are used extensively in games and work very well. They can be used well in SU, as Adam says, but only really from a very fixed viewpoint....that being the centre of the cube.
Games get around this by locking the skybox to the viewer. As you move through a first person perspective shoot-em-up the skybox moves with you, so always appears in the correct perspective and always infinitely distant. This obviously isn't the case in SU.
I realise this thread has drifted slightly away from Ruby, but there's a challenge for somebody.
Skyboxes can work well in SU, but generally only if you move a few feet...or catch a glimpse out of a window, not up and down streets. Of course you can make them really huge, so that any novement by the viewer is very slight in comparison...but then you get clipping problems.The simplest solution is simply to map a panoramic image around a cylinder. Here is a very old thread from the old forum, now transferred to Google Groups. So old, in fact, that it predates SU's ability to map around cylinders, so I had to do it by slicing the image into sections...but the resulting skps still work ok for most situations.
Advertisement