2016년 2월 18일 목요일

CString to wchar_t on MFC

first ansi to uncode

#include <atlbase.h>

...
CString path = m_filename;
pfile = _wfopen(CT2W(path) , L"wb");

2016년 2월 17일 수요일

shutdown with remote desktop ( windows 7 )

shutdown : command prompt > shutdown /p
reboot : command prompt > shutdown /r

2016년 2월 4일 목요일

gateway setting with dual nic

eth0
111.111.111.111
255.255.255.0

eth1
222.222.222.222
255.255.255.0
222.222.222.254

list for route
111.111.12.0
111.111.22.0
111.111.32.0
111.111.42.0

cmd prompt ( administrator )
route print
route -p add 111.111.0.0 mask 255.255.0.0 111.111.111.254

2016년 2월 2일 화요일

YUV Format

YUY2 = YUYV = V422 = Y0, U0, Y1, V0 = Packet Format

Component Range
Y' 16–235
Cb/Cr 16–240, with 128 representing zero

Color R G B Y' Cb Cr
Black 0 0 0 16 128 128
Red 255 0 0 81 90 240
Green 0 255 0 145 54 34
Blue 0 0 255 41 240 110
Cyan 0 255 255 170 166 16
Magenta 255 0 255 106 202 222
Yellow 255 255 0 210 16 146
White 255 255 255 235 128 128