simple draw2dline rendertarget

You are an experienced programmer and have a problem with the engine, shaders, or advanced effects? Here you'll get answers.
No questions about C++ programming or topics which are answered in the tutorials!
Post Reply
Scarabol
Posts: 167
Joined: Sat Jan 03, 2009 5:26 pm
Location: Aachen, Germany

simple draw2dline rendertarget

Post by Scarabol »

Hey guys,

why does driver->draw2dline() disable all textures and how can i draw a 2dline on a render target texture?

Thanks in advance
Scarabol
Irrlicht 1.7.2
Eclipse
Boost
hybrid
Admin
Posts: 14143
Joined: Wed Apr 19, 2006 9:20 pm
Location: Oldenburg(Oldb), Germany
Contact:

Re: simple draw2dline rendertarget

Post by hybrid »

Well, lines are intended to be untextured. Since d3d also does not support thick lines, there's no reason to have textures on them as it's barely visible anyway. But you can always use drawVertexPrimitiveList, which is far better performing anyway. Using 2d lines on a render target should work as expected.
Scarabol
Posts: 167
Joined: Sat Jan 03, 2009 5:26 pm
Location: Aachen, Germany

Re: simple draw2dline rendertarget

Post by Scarabol »

Ok, what im talking about is this crazy output i got when drawing a draw2dline with a draw2dimage to one render texture target:

I don't get this mistake each time i run the application, but 50%.

Thats the way it should look:
Image

As you can see the texture ist wrong scaled (llower right) and you cant see the white strip:
Image

I ve got wild pointers in mind, but i got the mistake only with opengl driver, so i switched to the driver.

Any other ideas?

Thanks in advance
Scarabol
Irrlicht 1.7.2
Eclipse
Boost
Post Reply