PanoramaCube3D - how to show a skybox

Feb 26, 2013 at 12:16 PM
I'm creating a simple game and want to use a PanoramaCube3D as a skybox for the background.

I know that there's a sample included in the source code but I just can't get it to work using my own skybox images. the problem is the cube always looks like - well - a cube, and there are thin black lines where the sides of the cube meet.

Has anyone ever used the PanoramaCube3D for skyboxing and could provide a sample source code? FYI, there are some free skyboxes over here
Mar 25, 2013 at 7:54 AM
I have recently encountered the same problem as well, and finally solved it.

The solution is as follows:

In your XAML, add this to your HelixViewPort3D:
RenderOptions.BitmapScalingMode="HighQuality" RenderOptions.EdgeMode="Aliased"
Your code should end up looking something like this:
        <ht:HelixViewport3D x:Name="viewPort"  CameraMode="FixedPosition" RenderOptions.BitmapScalingMode="HighQuality" RenderOptions.EdgeMode="Aliased">
                    <AmbientLight Color="White"/>

            <ht:PanoramaCube3D Source="Models\GrandHotel\"  >
That should fix the problem. The black lines will disappear completely. You MUST have both the BitmapScalingMode and the EdgeMode set for this to work.

All the best.

Mar 25, 2013 at 7:58 AM
wow. you just so much saved my day .... .i can't believe your awesomenes. thank you so much!!!
Mar 25, 2013 at 9:06 AM
No problem. I'm happy to have helped.

All the best for your project!