• DrawTexturedRectUV Issues.
    2 replies, posted
I have been trying to get the DrawTexturedRectUV to work properly, eg. rendering, but I cannot for the life of me figure it out. Code Snippet: [code] local bg1 = Material("bigmenu/bg1.png","noclamp") surface.SetMaterial(bg1) surface.SetDrawColor(255,255,255,255) surface.DrawTexturedRectUV( 62, 0, 1000, 80, 0, 0, 1000/3, 80/3 ) [/code] Comes out this this ugliness. [IMG]http://puu.sh/4CRqq.png[/IMG] I am using a simple 3x3px pattern, but it isn't rendering properly.
PNGs [B]MUST[/B] be power of 2 ( for Source ), so each side [B]MUST[/B] be on of these: 1, 2, 4, 8, 16, 32, 64, 128, 256, 512, 1024, etc. In your case, when a 3x3 png is loaded, it is being coverted into a 4x4 and the texture quality just fuckups.
You save the day once again Robotboy, keep up the solid support on FP.
Sorry, you need to Log In to post a reply to this thread.