Skip to content

Instantly share code, notes, and snippets.

@cecilemuller
Created March 28, 2012 14:57
Show Gist options
  • Save cecilemuller/2226868 to your computer and use it in GitHub Desktop.
Save cecilemuller/2226868 to your computer and use it in GitHub Desktop.
Stretch an image to cover the whole screen regardless of screen size or ratio, in VRML or X3D
Layer3D {
size 1 1
translation 0 0
viewpoint ViewVolume {
position 0 0 0.725
size 4 3
aspectMode "STRETCH"
}
children Shape {
appearance Appearance {
texture ImageTexture {
url "image.png"
repeatS FALSE
repeatT FALSE
}
}
geometry Rectangle{size 0.8 0.6}
}
}
@cecilemuller
Copy link
Author

It crashes the iPhone and iPad viewer however :-(

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment