I've come this far, but what I want to achieve is:
*I want to get Pixel Position(XY) of Cursor(NOT MOUSE) position in console and then draw a line to that position ...
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18
HWND console_handle = GetConsoleWindow();
HDC device_context = GetDC(console_handle);
//int x = 0; int y = 0;
//Here's a 5 pixels wide RED line [from initial 0,0] to 300,300
HPEN pen = CreatePen(PS_SOLID, 5, RGB(255, 0, 0));
POINT p1;
POINT p2;
GetCursorPos(&p1); // But this get MOUSE CURSOR POS I DONT WANT THAT.
GetCursorPos(&p1); // But this get MOUSE CURSOR POS I DONT WANT THAT.
SelectObject(device_context, pen);
LineTo(device_context, p2.x, p2.y);
ReleaseDC(console_handle, device_context);