Problems with 'draw2Dline'

If you are a new Irrlicht Engine user, and have a newbie-question, this is the forum for you. You may also post general programming questions here.
Post Reply
JDaM

Problems with 'draw2Dline'

Post by JDaM »

Code: Select all

while(device->run() && driver)
      if (device->isWindowActive())
      {


	driver->beginScene(true, true, SColor(0,0,0,0));

	driver->draw2DLine(position2d<s32>(0,0),position2d<s32>(500,500),SColor(255,255,255,255));

	driver->draw2DRectangle(SColor(255,255,255,255),rect<s32>(10,10,54,54));

	driver->endScene();

	}
}
When i try this code the rectangle is draw but not the line ! I try differents alpha values and other things but nothing apears to work ! I really need help ...[/code]
Xception
Posts: 22
Joined: Tue Feb 24, 2004 10:05 am

Post by Xception »

Try it with the software renderer, I think only the software renderer supports this method.
JDaM

Post by JDaM »

Excellent ! It works now !
Thx
deps
Posts: 115
Joined: Sat Jan 10, 2004 5:22 pm
Location: Tranås, Sweden

Post by deps »

lines works with opengl and driectx too.
You just have to set a material. iirc
Post Reply