The Texture2 Node

This node wraps a texture (a .gif or .jpg file) around your shapes. Here, we wrap a world texture (../world2.jpg) around our sphere. You may use any valid URL inside the quotation marks. This texture-mapping feature can really bring your worlds to life!

#VRML V1.0 ascii

....
       DEF Sphere1 Separator {
                
                Texture2 {
                        filename "../world2.jpg"
                }

                Translation {
                        translation 0 75 0
                } #Translation

                Sphere {
                        radius 15
                }#Sphere

        } #Sphere1 Separator
...

+ Texture2

Another texture

More texture

World


Next Table of contents