I want to draw a simple 2D line.
Code: Select all
int main()
{
IrrlichtDevice *device = createDevice(video::EDT_SOFTWARE,core::dimension2d<s32>(512, 384));
device->setWindowCaption(L"Irrlicht Engine - 2D Graphics Demo");
IVideoDriver* driver = device->getVideoDriver();
while(device->run() && driver) {
if (device->isWindowActive()) {
driver->beginScene(true, true, video::SColor(0,122,65,171));
SColor color = SColor(0,255,0,0);
driver->draw2DLine(core::position2d<s32>(50,50), core::position2d<s32>(164, 125), video::SColor(0,255,0,0));
driver->endScene();
}
}
device->drop();
return 0;
}
Criamon
GForce MX200, current NVidia Drivers, Windows 2000