Robert Osfield wrote:
On 3/21/07, Christian Verbeek <[EMAIL PROTECTED]> wrote:
Dear osg-users,
I want to create a floor textured with a small image being repeated.
Thats what I am doing, but the texture is stretched (i.e shown only
once). What is wrong? I am using the latest OSG version from SVN.
>
ShapeDrawable doesn't support repeating of texture coordinates. The
closest you could get is to use osg::TexMat, but in the end I think
it'd be easier just to create the geometry yourslef as you need it.
To elaborate on that a bit, ShapeDrawable creates texture coordinates
only in the range of 0.0 to 1.0 i.e. the lower-left of the texture in
one corner (of your cube) and the upper-right of the texture in the
opposite corner.
If you place a texture matrix using scale 1000,1000,1 it should look as
you expect.
Cheers,
/ulrich
_______________________________________________
osg-users mailing list
[email protected]
http://openscenegraph.net/mailman/listinfo/osg-users
http://www.openscenegraph.org/