HSP¥Ý¡¼¥¿¥ë
¥µ¥¤¥È¥Þ¥Ã¥× ¤ªÌ䤤¹ç¤ï¤»


HSPTV!·Ç¼¨ÈÄ


̤²ò·è ²ò·è Ää»ß ºï½üÍ×ÀÁ

2013
0320
¤¢¤¤¤¦¤¨»Ò¥Þ¥ë¥Á¥â¥Ë¥¿´Ä¶­¤Î¥Ç¥¹¥¯¥È¥Ã¥×¥­¥ã¥×¥Á¥ã¤Ë¤Ä¤¤¤Æ¡£23²ò·è


¤¢¤¤¤¦¤¨»Ò

¥ê¥ó¥¯

2013/3/20(Wed) 23:55:19|NO.53117

4²èÌ̤Υޥë¥Á¥â¥Ë¥¿´Ä¶­¤ò½êÍ­¤·¤Æ¤ª¤ê¤Þ¤¹¡£
³Æ¥â¥Ë¥¿¤¬¤½¤ì¤¾¤ì¥Ð¥é¥Ð¥é¤Ê¾ì½ê¤Ë¤¢¤ë¤¿¤á¡¢°ì¤Ä¤Î¥¦¥£¥ó¥É¥¦¤«¤éÁ´ÂΤξõÂÖ¤òÇÄ°®¤Ç¤­¤¿¤é¤È»×¤¤¤Þ¤·¤Æ¡¢
¥Ç¥¹¥¯¥È¥Ã¥×Á´ÂΤò¥­¥ã¥×¥Á¥ã¤·¤Æ½Ì¾®É½¼¨¤¹¤ë¥½¥Õ¥È¤òºî¤Ã¤Æ¤ß¤Þ¤·¤¿¡£
¡Êhttp://chokuto.ifdef.jp/advanced/capturescreen.html¤ò»²¹Í¤Ë¤µ¤»¤Æ¤¤¤¿¤À¤­¤Þ¤·¤¿¡Ë


#uselib "gdi32.dll" #cfunc CreateDC "CreateDCA" sptr,sptr,sptr,int #func DeleteDC "DeleteDC" int #func BitBlt "BitBlt" int,int,int,int,int,int,int,int,int #define NULL 0 #define SRCCOPY 0x00CC0020 #define CAPTUREBLT 0x40000000 wait 50 /* ¥Þ¥ë¥Á¥â¥Ë¥¿´Ä¶­¤Î¾ì¹çsx¤Ë¤Ï²£²òÁüÅ٤ιç·×¡¢sy¤Ë¤ÏºÇÂç¤Î½Ä²òÁüÅÙ¤òÆþÎÏ¡£ ¡¡ ¤½¤ì°Ê³°¤Ê¤é ginfo_dispx ¤È ginfo_dispy ¤òÆþÎÏ¡£ */ sx = ginfo_dispx : sy = ginfo_dispy /* ¥Þ¥ë¥Á¥â¥Ë¥¿´Ä¶­¤Î¾ì¹ç¥á¥¤¥ó¥â¥Ë¥¿¤Îº¸¾åºÂɸ¤ò0,0¤È¤·¤Æº¸Ã¼¤Î¥â¥Ë¥¿¡¼¤Îº¸¾åºÂɸ¤òÆþÎÏ ¡¡ ¤½¤ì°Ê³°¤Ê¤é 0 ¤òÆþÎÏ¡£ */ mlef = 0 /* ½Ì¾®¤Î³ä¹ç¡£1 ¤ÇÅùÇÜ¡£2 ¤Ç1/2¤Î¥µ¥¤¥º */ rs = 5 ; ¥Ç¥¹¥¯¥È¥Ã¥×²èÌ̤Υµ¥¤¥º¤Ç¥Ð¥Ã¥Õ¥¡²èÌ̤òºîÀ® buffer 0 , sx, sy ; ¥¹¥¯¥ê¡¼¥ó(1)¤òºîÀ® screen 1, sx/rs ,sy/rs repeat gsel 0 ; ¥Ç¥¹¥¯¥È¥Ã¥×²èÌ̤ΥǥХ¤¥¹¥³¥ó¥Æ¥­¥¹¥È¼èÆÀ hdcScreen = CreateDC("DISPLAY", NULL, NULL, NULL) ; ¥Ç¥¹¥¯¥È¥Ã¥×²èÌ̤βèÁü¤ò¥³¥Ô¡¼ BitBlt hdc, 0, 0, sx, sy, hdcScreen, mlef, 0, SRCCOPY | CAPTUREBLT ; ¥Ç¥Ð¥¤¥¹¥³¥ó¥Æ¥­¥¹¥Èºï½ü DeleteDC hdcScreen ; µ¼»÷¥Þ¥¦¥¹¥«¡¼¥½¥ë¤òɽ¼¨ mx = ginfo_mx - mlef my = ginfo_my color 255,0,0 boxf mx,my,mx+10,my+10 ; ¥¹¥¯¥ê¡¼¥ó(1)¤Ë½Ì¾®¤·¤ÆÉÁ¼Ì gsel 1 gzoom sx/rs ,sy/rs ,0, 0, 0 ,sx ,sy,1 await 100 loop

¤³¤³¤ÇÆó¤Ä¼ÁÌ䤬¤¢¤ê¤Þ¤¹¡£

­¡¥¹¥¯¥ê¥×¥È¤ò¼Â¹Ô¤¹¤ë¤È¥Þ¥¦¥¹¥«¡¼¥½¥ë¤¬ÅÀÌǤ·¤Æ¤·¤Þ¤¤¤Þ¤¹¡£²þÁ±¤¹¤ëÊýË¡¤Ï¤Ê¤¤¤Ç¤·¤ç¤¦¤«¡©

­¢¼Â¹ÔÃæ¤Î¥¹¥¯¥ê¥×¥È¤â¥­¥ã¥×¥Á¥ã¤µ¤ì¤ë¤Î¤ÇÌܤ¶¤ï¤ê¤Ë¤Ê¤Ã¤Æ¤·¤Þ¤¤¤Þ¤¹¡£¥­¥ã¥×¥Á¥ã¤ò²óÈò¤¹¤ëÊýË¡¤Ï¤¢¤ê¤Þ¤¹¤Ç¤·¤ç¤¦¤«¡©

¤Þ¤¿¡¢¤³¤Î¥¹¥¯¥ê¥×¥È¤è¤ê´ÊÁǤǷÚÎ̤ʥ¹¥¯¥ê¥×¥È¤ä¡¢ÌµÂ̤ÊÉôʬ¤Ê¤É¤¬¤¢¤ê¤Þ¤·¤¿¤éÀ§È󤪶µ¤¨¤¯¤À¤µ¤¤¡£



¤³¤Îµ­»ö¤ËÊÖ¿®¤¹¤ë


_hamyuu

¥ê¥ó¥¯

2013/3/22(Fri) 08:37:15|NO.53142

¥Þ¥¦¥¹¥«¡¼¥½¥ë¤¬ÅÀÌǤ¹¤ë¸½¾Ý¤Ï¡ÖBitBit¡×¤Î¥Ñ¥é¥á¡¼¥¿¡ÖCAPTUREBLT¡×¤¬±Æ¶Á¤·¤Æ¤¤¤Þ¤¹¡£
¡Ö | CAPTUREBLT¡×¤ò¾Ã¤»¤ÐÅÀÌǤϤʤ¯¤Ê¤ê¤Þ¤¹¡£

¢­¤ò»²¹Í¤Ë¤·¤Þ¤·¤¿¡£
http://technet.microsoft.com/ja-jp/magazine/2009.02.windowsconfidential.aspx

¤µ¤é¤Ë¥ì¥¤¥ä¡¼¥É¥¦¥¤¥ó¥É¥¦¡ÊȾƩÌÀ¥¦¥£¥ó¥É¥¦¤Ê¤É¡Ë¤¬¥­¥ã¥×¥Á¥ã¤µ¤ì¤Ê¤¯¤Ê¤ë¤È»×¤¦¤Î¤Ç
HSP¤Î¥¦¥£¥ó¥É¥¦¤ò¥ì¥¤¥ä¡¼¥É¥¦¥£¥ó¥É¥¦²½¤¹¤ì¤ÐHSP¤Î¥¦¥£¥ó¥É¥¦¤Ï¥­¥ã¥×¥Á¥ã¤µ¤ì¤Ê¤¤¤È»×¤¤¤Þ¤¹¡£

¼Â¸³¤·¤Æ¤¤¤Ê¤¤¤Î¤Ç¤â¤·´Ö°ã¤Ã¤Æ¤¤¤¿¤é¤¹¤ß¤Þ¤»¤ó¡£



²Ë¿Í

¥ê¥ó¥¯

2013/3/22(Fri) 20:05:03|NO.53153

>¥¹¥¯¥ê¥×¥È¤ò¼Â¹Ô¤¹¤ë¤È¥Þ¥¦¥¹¥«¡¼¥½¥ë¤¬ÅÀÌǤ·¤Æ¤·¤Þ¤¤¤Þ¤¹¡£²þÁ±¤¹¤ëÊýË¡¤Ï¤Ê¤¤¤Ç¤·¤ç¤¦¤«¡©
NO.53142¤Ç¸À¤ï¤ì¤Æ¤ë¤è¤¦¤ËWin2000°Ê¹ß¤ÎBitBit¤Î»ÅÍͤäƻö¤é¤·¤¤
¤Ç¤¹¤¬¡¢¾Ã¤¨¤ë¥¿¥¤¥ß¥ó¥°¼¡Âè¤Ç¤Ï¸«¤¿Ìܾå¤Ïʬ¤«¤é¤Ê¤¯½ÐÍè¤ë

¿§¡¹»î¤·¤Æ¤ß¤¿¤éCAPTUREBLT»ØÄꤷ¤¿¾ì¹çBitBitÃæ¤ËÁöººÀþ¤¬VBlank¥¿¥¤¥ß¥°¤Ë¤Ê¤ë¤È
¥«¡¼¥½¥ë¤¬²èÌ̤«¤é¾Ã¤¨¤Æ¤ë¤Î¤¬¸«¤¨¤Æ¤·¤Þ¤¦¤Ã¤Æ»ö¤¬Ê¬¤«¤Ã¤¿

BitBit¤Î½èÍý»þ´Ö¤¬Ã»¤¯¤Ê¤ë¤è¤¦¤Ëʬ³ä¤·¤Æ¼Â¹Ô¤·
ÀäÂФËVBlankÁ°¤Ë¥³¥Ô¡¼½èÍý¤¬½ª¤ë¤è¤¦¤Ë¤¹¤ì¤ÐÎɤ¤

>¼Â¹ÔÃæ¤Î¥¹¥¯¥ê¥×¥È¤â¥­¥ã¥×¥Á¥ã¤µ¤ì¤ë¤Î¤ÇÌܤ¶¤ï¤ê¤Ë¤Ê¤Ã¤Æ¤·¤Þ¤¤¤Þ¤¹¡£¥­¥ã¥×¥Á¥ã¤ò²óÈò¤¹¤ëÊýË¡¤Ï¤¢¤ê¤Þ¤¹¤Ç¤·¤ç¤¦¤«¡©
NO.53142¤Ç¸À¤ï¤ì¤Æ¤ëÊýË¡¤Ç½ÐÍè¤Þ¤¹
¤¬¡¢Vista°Ê¹ß¤Ï̵Íý¤ß¤¿¤¤¡¦¡¦

WinXP´Ä¶­¤Î¥¦¥£¥ó¥É¥¦ÉÁ²è¤Ç¥Æ¥£¥¢¥ê¥ó¥°¡Ê¥Á¥é¥Ä¥­¤äÇÈÂǤĸ½¾Ý¡Ë¤ò̵¤¯¤¹¥â¥¸¥å¡¼¥ë
http://hsp.tv/play/pforum.php?mode=pastwch&num=46392
¢­¤Î¥¹¥¯¥ê¥×¥È¤Ï¢¬¤Î¥â¥¸¥å¡¼¥ë¤ò»È¤Ã¤Æ¤Þ¤¹

#include "mod_d3d9vsync.hsp" #uselib "gdi32.dll" #cfunc CreateDC "CreateDCA" sptr,sptr,sptr,int #func DeleteDC "DeleteDC" int #func BitBlt "BitBlt" int,int,int,int,int,int,int,int,int #define NULL 0 #define SRCCOPY 0x00CC0020 #define CAPTUREBLT 0x40000000 #uselib "user32.dll" #func GetWindowLongA "GetWindowLongA" int , int #func SetWindowLongA "SetWindowLongA" int , int , int #func SetLayeredWindowAttributes "SetLayeredWindowAttributes" int , int , int , int #define WS_EX_LAYERED 0x00080000 #define LWA_COLORKEY 1 #define LWA_ALPHA 2 #define GWL_EXSTYLE -20 wait 50 /* ¥Þ¥ë¥Á¥â¥Ë¥¿´Ä¶­¤Î¾ì¹çsx¤Ë¤Ï²£²òÁüÅ٤ιç·×¡¢sy¤Ë¤ÏºÇÂç¤Î½Ä²òÁüÅÙ¤òÆþÎÏ¡£ ¡¡ ¤½¤ì°Ê³°¤Ê¤é ginfo_dispx ¤È ginfo_dispy ¤òÆþÎÏ¡£ */ sx = ginfo_dispx : sy = ginfo_dispy dvsxmax=limit(sx/ginfo_dispx,1,10)+((sx\ginfo_dispx)>0) dvsymax=limit(sy/ginfo_dispy,1,10)+((sy\ginfo_dispy)>0) /* ¥Þ¥ë¥Á¥â¥Ë¥¿´Ä¶­¤Î¾ì¹ç¥á¥¤¥ó¥â¥Ë¥¿¤Îº¸¾åºÂɸ¤ò0,0¤È¤·¤Æº¸Ã¼¤Î¥â¥Ë¥¿¡¼¤Îº¸¾åºÂɸ¤òÆþÎÏ ¡¡ ¤½¤ì°Ê³°¤Ê¤é 0 ¤òÆþÎÏ¡£ */ mlef = 0 /* ½Ì¾®¤Î³ä¹ç¡£1 ¤ÇÅùÇÜ¡£2 ¤Ç1/2¤Î¥µ¥¤¥º */ rs = 5 ; ¥Ç¥¹¥¯¥È¥Ã¥×²èÌ̤Υµ¥¤¥º¤Ç¥Ð¥Ã¥Õ¥¡²èÌ̤òºîÀ® buffer 0 , sx, sy ; ¥¹¥¯¥ê¡¼¥ó(1)¤òºîÀ® screen 1, sx/rs ,sy/rs //¥ì¥¤¥ä¡¼¥¦¥£¥ó¥É¥¦¤òÀßÄê GetWindowLongA hwnd , GWL_EXSTYLE SetWindowLongA hwnd , GWL_EXSTYLE , stat | WS_EX_LAYERED SetLayeredWindowAttributes hwnd, 0, 255, LWA_ALPHA //ALPHA¥â¡¼¥É¤ÇÉÔÆ©ÌÀÀßÄê width sx/rs ,sy/rs,0,0 //¥¦¥£¥ó¥É¥¦ºÆÉÁ²è¤ÎÂå¤ï¤ê //¥ì¥¤¥ä¡¼¥¦¥£¥ó¥É¥¦¤Îº¸¾åºÂɸ¤È¥¿¥¤¥È¥ëÏȤò´Þ¤á¤¿¥µ¥¤¥º¤ò¼èÆÀ wx1=ginfo_wx1 wy1=ginfo_wy1 wsx=ginfo_sizex wsy=ginfo_sizey //¥ì¥¤¥ä¡¼¥¦¥£¥ó¥É¥¦¤Î²¼¤Î²èÁü°ì»þ¥³¥Ô¡¼ÍѥХåե¡ buffer 2 ,wsx ,wsy //¥ì¥¤¥ä¡¼¥¦¥£¥ó¥É¥¦¤ÈƱ¥µ¥¤¥º¤Î¥Ð¥Ã¥Õ¥¡¤ò³ÎÊÝ hdc2=hdc //¥Ç¥Ð¥¤¥¹¥³¥ó¥Æ¥­¥¹¥È ; ¥Ç¥¹¥¯¥È¥Ã¥×²èÌ̤ΥǥХ¤¥¹¥³¥ó¥Æ¥­¥¹¥È¼èÆÀ hdcScreen = CreateDC("DISPLAY", NULL, NULL, NULL) onexit *ext d3d9vsync_init if stat < 0 { if -5 ! stat {dialog "GetRasterStatus¤ò»ÈÍѤǤ­¤Ê¤¤´Ä¶­¤Ç¤¹":end} } dvymax=limit(int(((1.0*sx*sy)/(1920*1080))*4),1,100) //1920*1080¤ò4ʬ³ä¤Ç¥³¥Ô¡¼¤¹¤ë¤Î¤ò´ð½à¤Ë¤·¤Æ¡¢Ê¬³ä¿ô¤ò»»½Ð dvy=sy/dvymax dvymax+=(sy\dvy)>0 //¤¢¤Þ¤ê¤¬½Ð¤¿¤éʬ³ä¿ô+1 repeat gsel 0 mcnt=0 _dvy=0 repeat dvymax repeat _Sleep@mod_d3d9vsync 1 GetRasterStatus v,r //VBlank¤È¥é¥¹¥¿¡¼°ÌÃÖ¼èÆÀ if r<(ginfo_dispy/2) {break} //¥é¥¹¥¿¡¼¤¬¥Ç¥¹¥¯¥È¥Ã¥×Y¥µ¥¤¥º¤ÎȾʬ¤è¤ê¾å¤Ê¤éÈ´¤±¤ë loop if v{_Sleep@mod_d3d9vsync 1} //VBlankÃæ¤Ê¤é¥¹¥ê¡¼¥×1ms¡Ê1ms¤¢¤ì¤ÐVBlank¤òÈ´¤±¤é¤ì¤ë¤À¤í¤¦¤«¤é¡Ë mx(mcnt)=ginfo_mx - mlef my(mcnt)=ginfo_my mcnt++ ; ¥Ç¥¹¥¯¥È¥Ã¥×²èÌ̤βèÁü¤ò¥³¥Ô¡¼(sy¤òdvymaxʬ³ä¤·¤Æ¥³¥Ô¡¼) BitBlt hdc, 0, _dvy, sx, dvy, hdcScreen, mlef, _dvy, SRCCOPY | CAPTUREBLT _dvy+dvy loop //Vista°Ê¹ß¤ÏCAPTUREBLT´Ø·¸¤Ê¤¯¥ì¥¤¥ä¡¼¥¦¥£¥ó¥É¥¦¤â¥³¥Ô¡¼¤µ¤ì¤Æ¤·¤Þ¤¦¤é¤·¤¤¡¦¡¦¡¦ //¥ì¥¤¥ä¡¼¥¦¥£¥ó¥É¥¦²¼¤Î²èÁü¤ò¥Ð¥Ã¥Õ¥¡2¤Ë¥³¥Ô¡¼ BitBlt hdc2, 0, 0, wsx, wsy, hdcScreen, wx1, wy1, SRCCOPY //¥Ð¥Ã¥Õ¥¡2¤«¤é¥Ð¥Ã¥Õ¥¡0¤Ë¥³¥Ô¡¼ BitBlt hdc, wx1-mlef, wy1, wsx, wsy, hdc2, 0, 0, SRCCOPY mx(mcnt)=ginfo_mx - mlef my(mcnt)=ginfo_my mcnt++ ; µ¼»÷¥Þ¥¦¥¹¥«¡¼¥½¥ë¤òɽ¼¨ color 255 repeat mcnt boxf mx(cnt),my(cnt),mx(cnt)+10,my(cnt)+10 loop ; ¥¹¥¯¥ê¡¼¥ó(1)¤Ë½Ì¾®¤·¤ÆÉÁ¼Ì gsel 1 //gzoom¤Ï½Å¤¤¤Î¤Ç¥Ç¥¹¥¯¥È¥Ã¥×¤è¤êÂ礭¤¤Ê¬¤Ïʬ³ä¤·¤Æ¥³¥Ô¡¼ repeat dvsymax cnty=cnt repeat dvsxmax pos cnt*sx/rs/dvsxmax,cnty*sy/rs/dvsymax gzoom sx/rs/dvsxmax ,sy/rs/dvsymax ,0, cnt*sx/dvsxmax, cnty*sy/dvsymax ,sx/dvsxmax ,sy/dvsymax,1 redraw 1 redraw 0 await 100 loop loop wx1=ginfo_wx1 wy1=ginfo_wy1 wsx=ginfo_sizex wsy=ginfo_sizey loop *ext ; ¥Ç¥Ð¥¤¥¹¥³¥ó¥Æ¥­¥¹¥Èºï½ü DeleteDC hdcScreen end
XPsp3¤Î´Ä¶­¤À¤È¥«¡¼¥½¥ë¤ÎÅÀÌǤâ¼Â¹Ô¥¦¥£¥ó¥É¥¦¤¬¼Ì¤ê¤³¤à¤³¤È¤â¤Ê¤¯À®¸ù¤¹¤ë¤ó¤Ç¤¹¤¬¡¦¡¦¡¦
Vista°Ê¹ß¤À¤È¤É¤¦¤Ê¤ë¤«¡¦¡¦¡¦
DWM ¥µ¥à¥Í¥¤¥ë API¤¬¤É¤¦¤³¤¦¤Ã¤Æ½ê¤Þ¤ÇÄ´¤Ù¤¿¤±¤ÉVista°Ê¹ß¤Ï»ý¤Ã¤Æ̵¤¤¤«¤é¤³¤ì°Ê¾å¤Ïʬ¤«¤é¤Ê¤¤¡¦¡¦¡¦



²Ë¿Í

¥ê¥ó¥¯

2013/3/22(Fri) 23:17:04|NO.53158

¤¢¡¢¥Ð¥Ã¥Õ¥¡2¤ÏÉÔÍפÀ¤Ã¤¿(´Ö°ã¤¤¤¬¤¢¤Ã¤¿¤Î¤Çºï½ü½¤Àµ¤·¤ÆºÆ·ÇºÜ)
>//¥ì¥¤¥ä¡¼¥¦¥£¥ó¥É¥¦²¼¤Î²èÁü¤ò¥Ð¥Ã¥Õ¥¡2¤Ë¥³¥Ô¡¼
> BitBlt hdc2, 0, 0, wsx, wsy, hdcScreen, wx1, wy1, SRCCOPY
>//¥Ð¥Ã¥Õ¥¡2¤«¤é¥Ð¥Ã¥Õ¥¡0¤Ë¥³¥Ô¡¼
> BitBlt hdc, wx1-mlef, wy1, wsx, wsy, hdc2, 0, 0, SRCCOPY
¤³¤ì¤ò


//¥ì¥¤¥ä¡¼¥¦¥£¥ó¥É¥¦²¼¤Î²èÁü¤ò¥Ð¥Ã¥Õ¥¡0¤Ë¥³¥Ô¡¼ BitBlt hdc, wx1-mlef, wy1, wsx, wsy, hdcScreen, wx1, wy1, SRCCOPY ¤ËÊѹ¹



¤¢¤¤¤¦¤¨»Ò

¥ê¥ó¥¯

2013/3/23(Sat) 07:46:48|NO.53161

¤ªÆó¿Í¤È¤â¤¢¤ê¤¬¤È¤¦¤´¤¶¤¤¤Þ¤¹¡£

>_hamyuuÍÍ

¥Þ¥¦¥¹¥«¡¼¥½¥ë¤ÎÅÀÌǤÏ̵¤¯¤Ê¤ê¤Þ¤·¤¿¡£¤¢¤ê¤¬¤È¤¦¤´¤¶¤¤¤Þ¤¹¡£
¤Ç¤¹¤¬¡¢Windows7¤Î´Ä¶­¤Ç¤¹¤È¥ì¥¤¥ä¡¼¥¦¥£¥ó¥É¥¦¤â¥­¥ã¥×¥Á¥ã¤µ¤ì¤Æ¤·¤Þ¤¦¤è¤¦¤Ç¤¹¡£

>²Ë¿ÍÍÍ

¥¹¥¯¥ê¥×¥È¤ò¼Â¹Ô¤·¤Æ¤·¤Þ¤·¤¿¤¬¡¢¤ä¤Ï¤êÁ´¤Æ¥­¥ã¥×¥Á¥ã¤µ¤ì¤Æ¤·¤Þ¤¤¤Þ¤¹¡Ä



²Ë¿Í

¥ê¥ó¥¯

2013/3/23(Sat) 16:25:39|NO.53169

>¥¹¥¯¥ê¥×¥È¤ò¼Â¹Ô¤·¤Æ¤·¤Þ¤·¤¿¤¬¡¢¤ä¤Ï¤êÁ´¤Æ¥­¥ã¥×¥Á¥ã¤µ¤ì¤Æ¤·¤Þ¤¤¤Þ¤¹¡Ä
¤ä¤Ã¤Ñ¤ê¤Í¡¦¡¦¡¦

¤â¤¦°ì¤ÄÊýË¡¤¬¤¢¤ë¤«¤é¸å¤Ç½ñ¤¤¤Æ¤ß¤ë¡Êº£¼Â¸³Ãæ¤À¤±¤É¼Â¹Ô¥¦¥£¥ó¥É¥¦¤Î¥µ¥¤¥º¤¬Â礭¤¤¤È»È¤¨¤Ê¤¤¤«¤â¡¦¡¦¡¦¡Ë
XP¤À¤ÈSRCCOPY | CAPTUREBLT¡¡¤è¤êSRCCOPY¤À¤±¤ÎÊý¤¬¤«¤Ê¤ê·Ú¤¤¤ó¤À¤±¤ÉVista°Ê¹ß¤âƱ¤¸¤«¤Ê¡©
Ʊ¤¸¤Ê¤éVista°Ê¹ßÍѤËSRCCOPY¤À¤±»È¤Ã¤¿Êý¤¬Îɤ¤¤Ê¡¦¡¦¡¦



²Ë¿Í

¥ê¥ó¥¯

2013/3/23(Sat) 22:21:06|NO.53186

½ÐÍ褿¤Ã¤¿¤Ý¤¤¡©
¼Â¹Ô¥¦¥£¥ó¥É¥¦¤è¤ê²¼¤ËÁöººÀþ¤¬Í褿¤éÆ©ÌÀ¥¦¥£¥ó¥É¥¦¤Ë¤·¤Æ
¥³¥Ô¡¼½ª¤Ã¤¿¤éÉÔÆ©ÌÀ¤Ë¤¹¤ë¤Ã¤ÆÊýË¡¤ÇXP´Ä¶­¤Ç¤ÏÌäÂê¤Ê¤¯Æ°¤¤¤¿
¥¿¥¤¥ß¥ó¥°¤¬¥·¥Ó¥¢¤À¤«¤é·ë¶ÉVista°Ê¹ß¤Ç¤É¤¦¤Ê¤ë¤«Ê¬¤«¤é¤Ê¤¤¤±¤É¡¦¡¦¡¦

Vista°Ê¹ßÍѤËCAPTUREBLT¤ò¤Ê¤¯¤·¤¿¤Î¤Ç
¥«¡¼¥½¥ëÅÀÌDzóÈò½èÍý¤Ï¾Ê¤¤¤Æ¤ë

#include "mod_d3d9vsync.hsp" #uselib "gdi32.dll" #cfunc CreateDC "CreateDCA" sptr,sptr,sptr,int #func DeleteDC "DeleteDC" int #func BitBlt "BitBlt" int,int,int,int,int,int,int,int,int #define NULL 0 #define SRCCOPY 0x00CC0020 #define CAPTUREBLT 0x40000000 #uselib "user32.dll" #func GetWindowLongA "GetWindowLongA" int , int #func SetWindowLongA "SetWindowLongA" int , int , int #func SetLayeredWindowAttributes "SetLayeredWindowAttributes" int , int , int , int #define WS_EX_LAYERED 0x00080000 #define LWA_COLORKEY 1 #define LWA_ALPHA 2 #define GWL_EXSTYLE -20 wait 50 /* ¥Þ¥ë¥Á¥â¥Ë¥¿´Ä¶­¤Î¾ì¹çsx¤Ë¤Ï²£²òÁüÅ٤ιç·×¡¢sy¤Ë¤ÏºÇÂç¤Î½Ä²òÁüÅÙ¤òÆþÎÏ¡£ ¡¡ ¤½¤ì°Ê³°¤Ê¤é ginfo_dispx ¤È ginfo_dispy ¤òÆþÎÏ¡£ */ sx = ginfo_dispx : sy = ginfo_dispy dv_sxmax=limit(sx/ginfo_dispx,1,10) //ʬ³ä¿ô dv_symax=limit(sy/ginfo_dispy,1,10) dv_sxsize=sx/dv_sxmax //ʬ³ä¥µ¥¤¥º dv_sysize=sy/dv_symax /* ¥Þ¥ë¥Á¥â¥Ë¥¿´Ä¶­¤Î¾ì¹ç¥á¥¤¥ó¥â¥Ë¥¿¤Îº¸¾åºÂɸ¤ò0,0¤È¤·¤Æº¸Ã¼¤Î¥â¥Ë¥¿¡¼¤Îº¸¾åºÂɸ¤òÆþÎÏ ¡¡ ¤½¤ì°Ê³°¤Ê¤é 0 ¤òÆþÎÏ¡£ */ mlef = 0 /* ½Ì¾®¤Î³ä¹ç¡£%¤ÇÀßÄê¡¢100¤ÇÅùÇÜ¡£50 ¤Ç1/2¤Î¥µ¥¤¥º */ percent = 20.0 rs = 100.0/percent rsx=int((double(percent)/100)*sx) rsy=int((double(percent)/100)*sy) dv_rsxsize=rsx/dv_sxmax //ʬ³ä¥µ¥¤¥º(ʬ³ä¿ô¤Ïsx,sy¤Î¤ò»ÈÍÑ) dv_rsysize=rsy/dv_symax dv_sxmax+=((sx\ginfo_dispx)>0) //;¤Ã¤Æ¤ëʬ¤¬¤¢¤Ã¤¿¤éʬ³ä¿ô+1(¤³¤ì¤Ïsx,sy¤ËÂФ·¤Æ¤Ê¤Î¤ÇÃí°Õ) dv_symax+=((sy\ginfo_dispy)>0) ; ¥Ç¥¹¥¯¥È¥Ã¥×²èÌ̤Υµ¥¤¥º¤Ç¥Ð¥Ã¥Õ¥¡²èÌ̤òºîÀ® buffer 0 , sx, sy hdc0=hdc ; ¥¹¥¯¥ê¡¼¥ó(1)¤òºîÀ® screen 1, rsx ,rsy //¥ì¥¤¥ä¡¼¥É¥¦¥£¥ó¥É¥¦¤òÀßÄê GetWindowLongA hwnd , GWL_EXSTYLE SetWindowLongA hwnd , GWL_EXSTYLE , stat | WS_EX_LAYERED SetLayeredWindowAttributes hwnd, 0, 255, LWA_ALPHA //ALPHA¥â¡¼¥É¤ÇÉÔÆ©ÌÀÀßÄê hwnd1=hwnd width rsx ,rsy,0,0 //¥¦¥£¥ó¥É¥¦ºÆÉÁ²è¤ÎÂå¤ï¤ê //¥ì¥¤¥ä¡¼¥É¥¦¥£¥ó¥É¥¦¤Îº¸¾åºÂɸ¤È¥¿¥¤¥È¥ëÏȤò´Þ¤á¤¿¥µ¥¤¥º¤ò¼èÆÀ wx1=ginfo_wx1 wy1=ginfo_wy1 wsx=ginfo_sizex wsy=ginfo_sizey dv_rsymax=limit(int(((1.0*wsx*wsy)/(ginfo_dispx*ginfo_dispy/10))),1,100) //1920*1080/10¤Î¥µ¥¤¥º¤Ê¤é¥³¥Ô¡¼¤·¤ÆÂç¾æÉפÀ¤Ã¤¿¤Î¤Ç¡¢¤½¤ì°Ê¾å¤Ïʬ³ä¡Ê¤Á¤é¤Ä¤¯¾ì¹ç¤ÏÍ×Ä´À°¡Ë dv_sizey=wsy/dv_rsymax dv_rsymax+=(wsy\dv_rsymax)>0 //¤¢¤Þ¤ê¤¬½Ð¤¿¤éʬ³ä¿ô+1 //adjust ¼Â¹Ô¥¦¥£¥ó¥É¥¦¤¬Â礭¤¤¤È¥Á¥é¤Ä¤¯¤Î¤Ç¥é¥¹¥¿¡¼´Æ»ë°ÌÃÖ¤ò¤º¤é¤¹ adjust=0 //¼«Ê¬¤Î´Ä¶­¤Ç¤ÏY¥µ¥¤¥º¤¬500Ķ¤¨¤ë¤°¤é¤¤¤À¤È100ÄøÅ٤Ǽý¤Þ¤ë(´°Á´¤¸¤ã¤Ê¤¤¤±¤É¡¦¡¦¡¦) pos 0,0 input adjust,32,20 //¥ì¥¤¥ä¡¼¥É¥¦¥£¥ó¥É¥¦¤Î²¼¤Î²èÁü°ì»þ¥³¥Ô¡¼ÍѥХåե¡ buffer 2 , wsx, wsy hdc2=hdc ; ¥Ç¥¹¥¯¥È¥Ã¥×²èÌ̤ΥǥХ¤¥¹¥³¥ó¥Æ¥­¥¹¥È¼èÆÀ hdcScreen = CreateDC("DISPLAY", NULL, NULL, NULL) onexit *ext d3d9vsync_init if stat < 0 { if -5 ! stat {dialog "GetRasterStatus¤ò»ÈÍѤǤ­¤Ê¤¤´Ä¶­¤Ç¤¹":end} } mcntmax=4 dim mx,mcntmax dim my,mcntmax repeat repeat dv_sxmax*dv_symax _dvx=(cnt\dv_sxmax)*dv_sxsize _dvy=(cnt/dv_sxmax)*dv_sysize mx(mcnt\mcntmax)=ginfo_mx - mlef my(mcnt\mcntmax)=ginfo_my mcnt++ ; ¥Ç¥¹¥¯¥È¥Ã¥×²èÌ̤βèÁü¤ò¥³¥Ô¡¼(sy¤òdv_sxmax*dv_sxmaxʬ³ä¤·¤Æ¥³¥Ô¡¼) BitBlt hdc0, _dvx, _dvy, dv_sxsize, dv_sysize, hdcScreen, mlef+_dvx, _dvy, SRCCOPY repeat _Sleep@mod_d3d9vsync 1 GetRasterStatus v,r //VBlank¤È¥é¥¹¥¿¡¼°ÌÃÖ¼èÆÀ if v{break} //VBlankÃæ loop repeat GetRasterStatus v,r //VBlank¤È¥é¥¹¥¿¡¼°ÌÃÖ¼èÆÀ if r>(wy1+wsy-adjust) or ((wy1+wsy)>ginfo_dispy){break} //¥é¥¹¥¿¡¼¤¬¼Â¹Ô¥¦¥£¥ó¥É¥¦¤è¤ê²¼¤Ê¤éÈ´¤±¤ë if ((wy1+wsy-adjust)-r)>150 {_Sleep@mod_d3d9vsync 1} //ÌÜŪ¤Î°ÌÃÖ¤Þ¤Ç150°Ê¾åÍ­¤Ã¤¿¤é1ms¥¹¥ê¡¼¥× loop //¼Â¹Ô¥¦¥£¥ó¥É¥¦¤è¤ê²¼¤ËÁöººÀþ¤¬Í­¤ë»þ¤Ë¼Â¹Ô¥¦¥£¥ó¥É¥¦¤òÆ©ÌÀ¤Ë¤·¤Æ¥³¥Ô¡¼¤·¤Æľ¤°¤ËÉÔÆ©ÌÀ¤ËÌ᤹ SetLayeredWindowAttributes hwnd1, 0, 100, LWA_ALPHA //ALPHA¥â¡¼¥É¤ÇÆ©ÌÀ¤ËÀßÄê BitBlt hdc2, 0, (loopcnt\dv_rsymax)*dv_sizey, wsx, dv_sizey, hdcScreen, wx1, wy1+(loopcnt\dv_rsymax)*dv_sizey, SRCCOPY SetLayeredWindowAttributes hwnd1, 0, 255, LWA_ALPHA //ALPHA¥â¡¼¥É¤ÇÉÔÆ©ÌÀÀßÄê mx(mcnt\mcntmax)=ginfo_mx - mlef my(mcnt\mcntmax)=ginfo_my mcnt++ await 0 gsel 0 //¥Ð¥Ã¥¯¥Ð¥Ã¥Õ¥¡2¤«¤é¥Ð¥Ã¥Õ¥¡0¤Ë¥³¥Ô¡¼ if (cnt=((wx1-mlef)/dv_sxsize)+((wy1/dv_sysize)*dv_sxmax)) or (cnt=((wx1+wsx-mlef-1)/dv_sxsize)+(((wy1+wsy-1)/dv_sysize)*dv_sxmax)) { gmode 0:pos wx1-mlef, wy1:gcopy 2, 0, 0, wsx, wsy //¼Â¹Ô¥¦¥£¥ó¥É¥¦¤¬¤¢¤ëʬ³äÉôʬ¤Î½èÍý¤Î»þ¤À¤±¥³¥Ô¡¼¡Ê¥Ç¥¹¥¯¥È¥Ã¥×¥µ¥¤¥º¤è¤êÂ礭¤¤¤Î¤ÏÁÛÄꤷ¤Æ¤Ê¤¤¡Ë } ; ¥¹¥¯¥ê¡¼¥ó(1)¤Ë½Ì¾®¤·¤ÆÉÁ¼Ì gsel 1 //gzoom¤Ï½Å¤¤¤Î¤Ç¥Ç¥¹¥¯¥È¥Ã¥×¤è¤êÂ礭¤¤Ê¬¤Ïʬ³ä¤·¤Æ¥³¥Ô¡¼ pos (cnt\dv_sxmax)*dv_rsxsize,(cnt/dv_sxmax)*dv_rsysize gzoom dv_rsxsize ,dv_rsysize ,0, _dvx, _dvy ,dv_sxsize ,dv_sysize,1 ; µ¼»÷¥Þ¥¦¥¹¥«¡¼¥½¥ë¤òɽ¼¨ color 255 repeat 4,mcnt\mcntmax boxf (mx(cnt\mcntmax))/rs,my(cnt\mcntmax)/rs,(mx(cnt\mcntmax))/rs+2,my(cnt\mcntmax)/rs+2 loop redraw 1 redraw 0 await 100 wx1=ginfo_wx1 wy1=ginfo_wy1 if wsx ! ginfo_sizex { //¥¦¥£¥ó¥É¥¦¤Î¤ê¥µ¥¤¥º¤ËÂбþ //x¤ò¥ê¥µ¥¤¥º¤¹¤ë¤ÈÈæΨ¤òÊѤ¨¤º¤Ë¥µ¥¤¥º¤òÊѹ¹¤Ç¤­¤ë dv_rsxsize=ginfo_winx/dv_sxmax dv_rsysize=int(double(dv_rsxsize)/(double(sx)/sy)) width dv_rsxsize,dv_rsysize wsx=ginfo_sizex wsy=ginfo_sizey }else{ if wsy ! ginfo_sizey {//y¤Î¥ê¥µ¥¤¥º¤Ïx¤Î¥µ¥¤¥º¤òÊѤ¨¤Ê¤¤ dv_rsysize=ginfo_winy/dv_symax //¥¦¥£¥ó¥É¥¦¤Î¤ê¥µ¥¤¥º¤ËÂбþ wsy=ginfo_sizey } } loopcnt++ loop loop *ext ; ¥Ç¥Ð¥¤¥¹¥³¥ó¥Æ¥­¥¹¥Èºï½ü DeleteDC hdcScreen end
¥­¥ã¥×¥Á¥ã¸µ¤¬Â礭¤¯¤Ê¤Ã¤Æ¤âÉé²Ù¤¬Áý¤¨¤Ê¤¤¤è¤¦¤Ë¤·¤¿¤é¤ï¤«¤êÆñ¤¯¤Ê¤Ã¤¿¤Ê¡¦¡¦¡¦



²Ë¿Í

¥ê¥ó¥¯

2013/3/24(Sun) 19:29:32|NO.53217

¾¯¤·²èÌ̹¹¿·¤¬Áý¤¨¤ë¤è¤¦¤Ë¤·¤Æ¤ß¤¿

> if v{break} //VBlankÃæ
¤³¤ì¤ò

if v or (r<(wy1+wsy-adjust)){break} //VBlankÃæ
¤ËÃÖ¤­´¹¤¨
̵Â̤Ë1¥Õ¥ì¡¼¥àÂԤäƤ¿¤Î¤ò̵¤¯¤»¤ë¤Î¤È
Sleep 1¤Ç¤âVBlank¤ä¤ê²á¤´¤¹»ö¤âÍ­¤ê¤½¤¦¤Ê¤Î¤Ç¡¦¡¦¡¦



¤¢¤¤¤¦¤¨»Ò

¥ê¥ó¥¯

2013/3/24(Sun) 21:32:25|NO.53224

¤ª¤ª¡¢¾Ã¤¨¤Æ¤¤¤Þ¤¹¡ª¤¹¤´¤¤¡ª
¤·¤«¤·¤ä¤Ï¤ê²èÌ̤¬¤Á¤é¤Ä¤¤¤Æ¤·¤Þ¤¤¤Þ¤¹¤Í¡Ä
XP¤È7¤Ïº¬¤Ã¤«¤é¹½Â¤¤¬°ã¤¦¤Î¤Ç¤·¤ç¤¦¤«¡Ä



²Ë¿Í

¥ê¥ó¥¯

2013/3/24(Sun) 22:57:02|NO.53228

>¤ª¤ª¡¢¾Ã¤¨¤Æ¤¤¤Þ¤¹¡ª¤¹¤´¤¤¡ª
¤ª¤©

>¤·¤«¤·¤ä¤Ï¤ê²èÌ̤¬¤Á¤é¤Ä¤¤¤Æ¤·¤Þ¤¤¤Þ¤¹¤Í¡Ä
¤¢¤é¡¦¡¦¡¦
¼Â¹Ô¥¦¥£¥ó¥É¥¦¤ÎƱ¤¸¤è¤¦¤Ê¾ì½ê¤¬¤Á¤é¤Ä¤¯¤Ê¤é
adjust¤ÎÄ´Àá¤ä¼Â¹Ô¥¦¥£¥ó¥É¥¦¤Î°ÌÃÖ¤òÆ°¤«¤·¤Æ¤Ê¤ó¤È¤«¤Ê¤ê¤½¤¦¤À¤±¤É¡¦¡¦¡¦

> repeat
> _Sleep@mod_d3d9vsync 1
> GetRasterStatus v,r //VBlank¤È¥é¥¹¥¿¡¼°ÌÃÖ¼èÆÀ
> if v{break} //VBlankÃæ
> loop
>
> repeat
> GetRasterStatus v,r //VBlank¤È¥é¥¹¥¿¡¼°ÌÃÖ¼èÆÀ
> if r>(wy1+wsy-adjust) or ((wy1+wsy)>ginfo_dispy){break} //¥é¥¹¥¿¡¼¤¬¼Â¹Ô¥¦¥£¥ó¥É¥¦¤è¤ê²¼¤Ê¤éÈ´¤±¤ë
> if ((wy1+wsy-adjust)-r)>150 {_Sleep@mod_d3d9vsync 1} //ÌÜŪ¤Î°ÌÃÖ¤Þ¤Ç150°Ê¾åÍ­¤Ã¤¿¤é1ms¥¹¥ê¡¼¥×
> loop
¤³¤ÎÉôʬ¤ò

repeat GetRasterStatus v,r //VBlank¤È¥é¥¹¥¿¡¼°ÌÃÖ¼èÆÀ if v or (r<limit((wy1+wsy-adjust),1,ginfo_dispy)){break} //VBlankÃæ _Sleep@mod_d3d9vsync 1 loop repeat GetRasterStatus v,r //VBlank¤È¥é¥¹¥¿¡¼°ÌÃÖ¼èÆÀ if r>=limit((wy1+wsy-adjust),1,ginfo_dispy-wsy) or ((wy1+wsy)>ginfo_dispy){break} //¥é¥¹¥¿¡¼¤¬¼Â¹Ô¥¦¥£¥ó¥É¥¦¤è¤ê²¼¤Ê¤éÈ´¤±¤ë if ((wy1+wsy-adjust)-r)>250 {_Sleep@mod_d3d9vsync 1} //ÌÜŪ¤Î°ÌÃÖ¤Þ¤Ç250°Ê¾åÍ­¤Ã¤¿¤é1ms¥¹¥ê¡¼¥× loop
¤ËÃÖ¤­´¹¤¨¤Æ¡ÊÃÖ¤­´¹¤¨¤Ê¤¤¤ÈÉé¿ôÆþÎϤ¹¤ë¤È̵¸Â¥ë¡¼¥×¤Ë¡¦¡¦¡¦¡Ë
adjust¤Îinput¤Ë-ginfo_dispy¡Áginfo_dispy¤òÆþ¤ì¤Æ
¥¦¥£¥ó¥É¥¦¤Î°ÌÃÖ¤òÊѤ¨¤¿¤ê¤·¤ÆÊѲ½¤¬¤¢¤ë¤«»î¤·¤ÆÍߤ·¤¤
input¤¬Éé¿ô¤Þ¤Ç¤ÎÆþÎϤò¹Í¤¨¤Æ̵¤¯¤Æ¾®¤µ¤¤¤«¤é²£64¤°¤é¤¤¤Ë¤·¤¿Êý¤¬Îɤ¤¤«¤â



¤¢¤¤¤¦¤¨»Ò

¥ê¥ó¥¯

2013/3/24(Sun) 23:18:16|NO.53230

¤·¤Ð¤é¤¯¼Â¹Ô¤·¤Æ¤¤¤ë¤È¡¢¥Á¥é¤Ä¤­¤¬»ß¤Þ¤ë»þ¤¬¤¢¤ê¤Þ¤¹¤¬¡¢¤Þ¤¿¤·¤Ð¤é¤¯¤¹¤ë¤È¤Á¤é¤Ä¤¤¤Æ¤·¤Þ¤¤¤Þ¤¹¤Í¡Ä¡£

¤¦¡¼¤ó



²Ë¿Í

¥ê¥ó¥¯

2013/3/24(Sun) 23:49:33|NO.53232

Êó¹ð¤¢¤ê¤¬¤È¤¦
>¥Á¥é¤Ä¤­¤¬»ß¤Þ¤ë»þ¤¬¤¢¤ê¤Þ¤¹¤¬¡¢¤Þ¤¿¤·¤Ð¤é¤¯¤¹¤ë¤È¤Á¤é¤Ä¤¤¤Æ¤·¤Þ¤¤¤Þ¤¹¤Í¡Ä¡£
¤ä¤Ã¤Ñ¤êVista°Ê¹ß¤ÏOS¤¬¿§¡¹¤ä¤Ã¤Æ¤Æ¤ä¤Ã¤«¤¤¤À¤Ê¤¡
DWM¤¢¤¿¤ê¤¤¤¸¤ì¤Ð²¿¤È¤«¤Ê¤ê¤½¤¦¤Ê¤Ê¤é¤Ê¤¤¤è¤¦¤Ê
¼«Ê¬¤¸¤ã»î¤»¤Ê¤¤¤«¤é¼êµÍ¤Þ¤ê¡¦¡¦¡¦

Vista°Ê¹ß¤ÏMagnification API»È¤¨¤Ã¤Æ»ö¤«¤â
¿§¡¹½ÐÍè¤ë¤ß¤¿¤¤¤À¤¬¡¢Direct3D¤Î²èÌ̤ϥ­¥ã¥×¥Á¥ã¤Ç¤­¤Ê¤¤¤é¤·¤¤¡¦¡¦¡¦



¤¢¤¤¤¦¤¨»Ò

¥ê¥ó¥¯

2013/3/25(Mon) 21:48:20|NO.53250

¤ä¤Ï¤êÆñ¤·¤¤¤Ç¤¹¤«¡ÄÆ©²á¤ÏÄü¤á¤Þ¤¹¡£
¤Ê¤ó¤À¤«ÌµÂ̤ʤ³¤È¤ËÉÕ¤­¹ç¤ï¤»¤Æ¤·¤Þ¤Ã¤Æ¤¹¤ß¤Þ¤»¤ó¡£
¤¢¤ê¤¬¤È¤¦¤´¤¶¤¤¤Þ¤·¤¿¡£



²Ë¿Í

¥ê¥ó¥¯

2013/3/27(Wed) 23:50:13|NO.53291

¤Þ¤À¤ä¤Ã¤Æ¤¿¤ê¡¦¡¦¡¦

ÂŶ¨°Æ¤Ã¤Æ¸À¤¦¤«¥¤¥ó¥Á¥­¤È¸À¤¦¤«¡¢¤½¤ó¤ÊÊýË¡¤Ç¤ä¤Ã¤Æ¤ß¤¿
ÁᤤÏÃÄê´üŪ¤Ë½ñ¤­´¹¤¨¤ë¤ó¤¸¤ã¤Ê¤¯ÊѲ½¤¬¤¢¤Ã¤¿¤é½ñ¤­´¹¤¨¤ë¤è¤¦¤Ë¤·¤Æ
¤Ê¤ë¤Ù¤¯¥¦¥£¥ó¥É¥¦²¼¤ÎºÆ¥³¥Ô¡¼¤ò¸º¤é¤¹ÊýË¡
¼Â¹Ô¥¦¥£¥ó¥É¥¦¤Î²¼¤Ë²¿¤âÃÖ¤«¤Ê¤±¤ì¤Ð¥¦¥£¥ó¥É¥¦¤Ë
¥Þ¥¦¥¹¤ò¾è¤»¤ë¤Þ¤ÇºÆ¥³¥Ô¡¼¤·¤Ê¤¤¤«¤éÉáÃʤϤé¤Á¤é¤Ä¤«¤Ê¤¤

NO.53186¤Î¤Ï·×»»´Ö°ã¤¤¤È¤«¿§¡¹¤·¤Æ¤ë¤«¤é¤½¤ì¤â½¤Àµ¡¦¡¦¡¦
ÉÁ²è¥¨¥ê¥¢Æâ¤Ë¥Þ¥¦¥¹¤¬Æþ¤ë¤È¥Þ¥¦¥¹Æ©²á¤¹¤ëȾƩÌÀ
¥¿¥¤¥È¥ë¥À¥Ö¥ë¥¯¥ê¥Ã¥¯¤ÇÀßÄꥦ¥£¥ó¥É¥¦É½¼¨
alphamin¤Ï¥Þ¥¦¥¹¤òÉÁ²è¥¨¥ê¥¢¤Ë¾è¤»¤¿¤È¤­¤ÎȾƩÌÀÃÍ
alphamax¤ÏÄ̾ï»þ¤ÎȾƩÌÀÃÍ

#include "mod_d3d9vsync.hsp" #uselib "gdi32.dll" #cfunc CreateDC "CreateDCA" sptr,sptr,sptr,int #func DeleteDC "DeleteDC" int #func BitBlt "BitBlt" int,int,int,int,int,int,int,int,int #cfunc getPixel "GetPixel" int,int,int #define NULL 0 #define SRCCOPY 0x00CC0020 #define CAPTUREBLT 0x40000000 #uselib "user32.dll" #cfunc GetWindowLongA "GetWindowLongA" int , int #func SetWindowLongA "SetWindowLongA" int , int , int #func SetLayeredWindowAttributes "SetLayeredWindowAttributes" int , int , int , int #func SetWindowPos "SetWindowPos" int, int, int, int, int, int, int #define WS_EX_LAYERED 0x00080000 #define LWA_COLORKEY 1 #define LWA_ALPHA 2 #define GWL_EXSTYLE -20 #define GWL_STYLE -16 #define WM_NULL 0x0000 #define WM_CREATE 0x0001 #define WM_DESTROY 0x0002 #define WM_MOVE 0x0003 #define WM_SIZE 0x0005 #define WM_PAINT 0x000F #define WM_QUERYNEWPALETTE 0x030F #define WM_SETREDRAW 0x000B #define WM_NCLBUTTONDBLCLK 0x00A3 #const SWP_NOMOVE 0x02 #const SWP_NOSIZE 0x0001 #const SWP_NOZORDER 0x0004 #const SWP_NOACTIVATE 0x0010 #const SWP_FRAMECHANGED 0x020 #const SWP_SHOWWINDOW 0x040 #const SWP_HIDEWINDOW 0x080 #const SWP_NOCOPYBITS 0x0100 #const SWP_NOOWNERZORDER 0x0200 /* ¥Þ¥ë¥Á¥â¥Ë¥¿´Ä¶­¤Î¾ì¹çsx¤Ë¤Ï²£²òÁüÅ٤ιç·×¡¢sy¤Ë¤ÏºÇÂç¤Î½Ä²òÁüÅÙ¤òÆþÎÏ¡£ ¡¡ ¤½¤ì°Ê³°¤Ê¤é ginfo_dispx ¤È ginfo_dispy ¤òÆþÎÏ¡£ */ sx = ginfo_dispx: sy = ginfo_dispy dv_sxmax=limit(sx/ginfo_dispx,1,10) //ʬ³ä¿ô dv_symax=limit(sy/ginfo_dispy,1,10) dv_sxsize=sx/dv_sxmax //ʬ³ä¥µ¥¤¥º dv_sysize=sy/dv_symax /* ¥Þ¥ë¥Á¥â¥Ë¥¿´Ä¶­¤Î¾ì¹ç¥á¥¤¥ó¥â¥Ë¥¿¤Îº¸¾åºÂɸ¤ò0,0¤È¤·¤Æº¸Ã¼¤Î¥â¥Ë¥¿¡¼¤Îº¸¾åºÂɸ¤òÆþÎÏ ¡¡ ¤½¤ì°Ê³°¤Ê¤é 0 ¤òÆþÎÏ¡£ */ mlef = 0 /* ½Ì¾®¤Î³ä¹ç¡£%¤ÇÀßÄê¡¢100¤ÇÅùÇÜ¡£50 ¤Ç1/2¤Î¥µ¥¤¥º */ percent = 40.0 rs = 100.0/percent rsx=int((double(percent)/100)*sx) rsy=int((double(percent)/100)*sy) dv_rsxsize=rsx/dv_sxmax //ʬ³ä¥µ¥¤¥º(ʬ³ä¿ô¤Ïsx,sy¤Î¤ò»ÈÍÑ) dv_rsysize=rsy/dv_symax _dv_sxmax=dv_sxmax _dv_symax=dv_symax dv_sxmax+=((sx\ginfo_dispx)>0) //;¤Ã¤Æ¤ëʬ¤¬¤¢¤Ã¤¿¤éʬ³ä¿ô+1(¤³¤ì¤Ïsx,sy¤ËÂФ·¤Æ¤Ê¤Î¤ÇÃí°Õ) dv_symax+=((sy\ginfo_dispy)>0) ; ¥Ç¥¹¥¯¥È¥Ã¥×²èÌ̤Υµ¥¤¥º¤Ç¥Ð¥Ã¥Õ¥¡²èÌ̤òºîÀ® buffer 0 , sx, sy hdc0=hdc wait 1 ; ¥¹¥¯¥ê¡¼¥ó(1)¤òºîÀ® screen 1, rsx ,rsy,2,0,0 hdc1=hdc hwnd1=hwnd //¥ì¥¤¥ä¡¼¥É¥¦¥£¥ó¥É¥¦¤òÀßÄê // STYLE(hwnd,ÄɲÃSTYLE,ºï½üSTYLE) #define ctype STYLE(%1,%2,%3=0) %1,GWL_STYLE,((GetWindowLongA(%1,GWL_STYLE) | (%2)) | (%3)) ^ (%3) #define ctype EXSTYLE(%1,%2=0,%3=0) %1,GWL_EXSTYLE,((GetWindowLongA(%1,GWL_EXSTYLE) | (%2)) | (%3)) ^ (%3) #define WS_EX_TRANSPARENT $20 SetWindowLongA EXSTYLE(hwnd1,WS_EX_LAYERED) alphamin=100 alphamax=255 ALPHA=alphamax SetLayeredWindowAttributes hwnd1, 0, ALPHA, LWA_ALPHA //ALPHA¥â¡¼¥É¤ÇÉÔÆ©ÌÀÀßÄê SetWindowPos hwnd1,0 ,0,0 ,0,0 ,SWP_NOMOVE | SWP_NOSIZE | SWP_NOZORDER | SWP_FRAMECHANGED | SWP_SHOWWINDOW wait 1 //¥ì¥¤¥ä¡¼¥É¥¦¥£¥ó¥É¥¦¤Îº¸¾åºÂɸ¤È¥¿¥¤¥È¥ëÏȤò´Þ¤á¤¿¥µ¥¤¥º¤ò¼èÆÀ wx1=ginfo_wx1 wy1=ginfo_wy1 wx2=ginfo_wx2 wy2=ginfo_wy2 wsx=ginfo_sizex wsy=ginfo_sizey dv_rsymax=limit(int(((1.0*wsx*wsy)/(ginfo_dispx*ginfo_dispy/10))),1,wsy) //1920*1080/20¤Î¥µ¥¤¥º¤Ê¤é¥³¥Ô¡¼¤·¤ÆÂç¾æÉפÀ¤Ã¤¿¤Î¤Ç¡¢¤½¤ì°Ê¾å¤Ïʬ³ä,NO.53186¤ÎȾʬ¤Ë¤·¤¿¡Ê¤Á¤é¤Ä¤¯¾ì¹ç¤ÏÍ×Ä´À°¡Ë dv_sizey=wsy/dv_rsymax o=dv_rsymax dv_rsymax=wsy/dv_sizey+((wsy\dv_sizey)>0) //³Î¼Â¤Ëdv_sizey*dv_sizey¤¬wsy°Ê¾å¤Ë¤Ê¤ë¤è¤¦¤Ë¤¹¤ë //adjust ¼Â¹Ô¥¦¥£¥ó¥É¥¦¤¬Â礭¤¤¤È¥Á¥é¤Ä¤¯¤Î¤Ç¥é¥¹¥¿¡¼´Æ»ë°ÌÃÖ¤ò¤º¤é¤¹ adjust=0 //¼«Ê¬¤Î´Ä¶­¤Ç¤ÏY¥µ¥¤¥º¤¬500Ķ¤¨¤ë¤°¤é¤¤¤À¤È100ÄøÅ٤Ǽý¤Þ¤ë(´°Á´¤¸¤ã¤Ê¤¤¤±¤É¡¦¡¦¡¦) //ÀßÄꥦ¥£¥ó¥É¥¦Èóɽ¼¨¤ÇÀßÃÖ conf_id=100 screen conf_id, 220,80 ,8+2 title "ÀßÄê" pos 8,8 mes "adjust" mes "alphamin" mes "alphamax" _alphamin=alphamin _alphamax=alphamax pos 80,16 input adjust,64,16 input _alphamin,64,16 alphamin_id=stat input _alphamax,64,16 alphamax_id=stat pos 145,16+19 button gosub "ŬÍÑ",*conf_set //¥ì¥¤¥ä¡¼¥É¥¦¥£¥ó¥É¥¦¤Î²¼¤Î²èÁü°ì»þ¥³¥Ô¡¼ÍѥХåե¡ buffer 2 , wsx, wsy hdc2=hdc gsel 1,2 ; ¥Ç¥¹¥¯¥È¥Ã¥×²èÌ̤ΥǥХ¤¥¹¥³¥ó¥Æ¥­¥¹¥È¼èÆÀ hdcScreen = CreateDC("DISPLAY", NULL, NULL, NULL) onexit gosub *exit d3d9vsync_init if stat < 0 { if -5 ! stat {dialog "GetRasterStatus¤ò»ÈÍѤǤ­¤Ê¤¤´Ä¶­¤Ç¤¹":end} } mcntmax=4 dim mx,mcntmax dim my,mcntmax oncmd gosub *wm_sub,WM_SIZ oncmd gosub *wm_sub,WM_MOVE oncmd gosub *wm_sub,WM_QUERYNEWPALETTE oncmd gosub *wm_sub,WM_NCLBUTTONDBLCLK copy_f=1 //¼Â¹Ô¥¦¥£¥ó¥É¥¦¤Î²¼¤ò¥³¥Ô¡¼¤µ¤»¤ë¥Õ¥é¥° repeat repeat dv_sxmax*dv_symax if ((wx1+4)<ginfo_mx) and ((wy1+22)<ginfo_my) and ((wx1-4+wsx)>ginfo_mx) and ((wy1-4+wsy)>ginfo_my) {//¥Þ¥¦¥¹¤¬¼Â¹Ô¥¦¥£¥ó¥É¥¦¤ÎÉÁ²è¥¨¥ê¥¢Æâ¤ËÆþ¤Ã¤¿ if ALPHA ! alphamin {//ȾƩÌÀ¤Ë¤·¤Æ¥Þ¥¦¥¹Áàºî¤â²¼¤ËÆ©²á¤¹¤ë(WS_EX_TRANSPARENT) copy_f++ ALPHA=alphamin SetLayeredWindowAttributes hwnd1, 0, ALPHA, LWA_ALPHA SetWindowLongA EXSTYLE(hwnd1,WS_EX_TRANSPARENT) SetWindowPos hwnd1,0 ,0,0 ,0,0 ,SWP_NOMOVE | SWP_NOSIZE | SWP_NOZORDER | SWP_FRAMECHANGED | SWP_SHOWWINDOW } }else{ ///¥Þ¥¦¥¹¤¬¼Â¹Ô¥¦¥£¥ó¥É¥¦ÉÁ²è¥¨¥ê¥¢³° if ALPHA ! alphamax {//ȾƩÌÀ¤òÌᤷ¥¿¥¤¥È¥ëÏȤò¥¯¥ê¥Ã¥¯½ÐÍè¤ëÍͤËWS_EX_TRANSPARENT¤òºï½ü copy_f++ ALPHA=alphamax SetWindowLongA EXSTYLE(hwnd1,0,WS_EX_TRANSPARENT) SetWindowPos hwnd1,0 ,0,0 ,0,0 ,SWP_NOMOVE | SWP_NOSIZE | SWP_NOZORDER | SWP_FRAMECHANGED | SWP_SHOWWINDOW } } _dvx=(cnt\dv_sxmax)*dv_sxsize _dvy=(cnt/dv_sxmax)*dv_sysize mx(mcnt\mcntmax)=ginfo_mx - mlef my(mcnt\mcntmax)=ginfo_my mcnt++ //¼Â¹Ô¥¦¥£¥ó¥É¥¦¤ËÎÙÀܤ¹¤ë¥É¥Ã¥È¤ËÊѲ½¤¬¤¢¤Ã¤¿¤«¥Á¥§¥Ã¥¯(4¥É¥Ã¥ÈËè) if (cnt=((wx1-mlef-1)/dv_sxsize)+((wy1/dv_sysize)*dv_sxmax)) or (cnt=((wx1+wsx-mlef)/dv_sxsize)+(((wy1+wsy)/dv_sysize)*dv_sxmax)) and (test=0) { if (wx2-mlef)<sx{ repeat (wsy-1)/4,1 if (getPixel(hdc0,wx2-mlef, wy1+cnt*4) ! getPixel(hdcScreen,wx2,wy1+cnt*4)) { copy_f++ break } loop } if (wx1-mlef)>0 and (test=0){ repeat (wsy-1)/4,1 if (getPixel(hdc0,wx1-mlef-1, wy1+cnt*4) ! getPixel(hdcScreen,wx1-1,wy1+cnt*4)) { copy_f++ break } loop } if (wy1>0) and (test=0){ repeat (wsx-1)/4,1 if (getPixel(hdc0,wx1-mlef+cnt*4,wy1-1) ! getPixel(hdcScreen,wx1+cnt*4,wy1-1)){ copy_f++ break } loop } if (wy2<sy) and (test=0) { repeat (wsx-1)/4,1 if (getPixel(hdc0,wx1-mlef+cnt*4,wy2) ! getPixel(hdcScreen,wx1+cnt*4,wy2)) { copy_f++ break } loop } } ; ¥Ç¥¹¥¯¥È¥Ã¥×²èÌ̤βèÁü¤ò¥³¥Ô¡¼(sy¤òdv_sxmax*dv_sxmaxʬ³ä¤·¤Æ¥³¥Ô¡¼) BitBlt hdc0, _dvx, _dvy, dv_sxsize, dv_sysize, hdcScreen, mlef+_dvx, _dvy, SRCCOPY if copy_f {//¼Â¹Ô¥¦¥£¥ó¥É¥¦´Þ¤à¼þÊդDz¿¤«ÊѲ½¤¬¤¢¤Ã¤¿ if copy_f_bak=copy_f{//ÊѲ½¤¬½ª¤Ã¤¿¤é¼Â¹Ô¥¦¥£¥ó¥É¥¦¤Î²¼¤ò²èÁü¤òhdc2¤Ë¥³¥Ô¡¼ repeat GetRasterStatus v,r //VBlank¤È¥é¥¹¥¿¡¼°ÌÃÖ¼èÆÀ if v or (r<limit((wy1+wsy-adjust),1,ginfo_dispy))*0{break} //VBlankÃæ _Sleep@mod_d3d9vsync 1 loop repeat GetRasterStatus v,r //VBlank¤È¥é¥¹¥¿¡¼°ÌÃÖ¼èÆÀ if r>=limit((wy1+wsy-adjust),1,ginfo_dispy-50) or ((wy1+wsy)>ginfo_dispy){break} //¥é¥¹¥¿¡¼¤¬¼Â¹Ô¥¦¥£¥ó¥É¥¦¤è¤ê²¼¤Ê¤éÈ´¤±¤ë if (limit((wy1+wsy-adjust),1,ginfo_dispy))>250 {_Sleep@mod_d3d9vsync 1} //ÌÜŪ¤Î°ÌÃÖ¤Þ¤Ç250°Ê¾åÍ­¤Ã¤¿¤é1ms¥¹¥ê¡¼¥× loop //¼Â¹Ô¥¦¥£¥ó¥É¥¦¤è¤ê²¼¤ËÁöººÀþ¤¬Í­¤ë»þ¤Ë¼Â¹Ô¥¦¥£¥ó¥É¥¦¤òÆ©ÌÀ¤Ë¤·¤Æ¥³¥Ô¡¼¤·¤Æľ¤°¤ËÉÔÆ©ÌÀ¤ËÌ᤹ SetLayeredWindowAttributes hwnd1, 0, 0, LWA_ALPHA //ALPHA¥â¡¼¥É¤ÇÆ©ÌÀ¤ËÀßÄê BitBlt hdc2, 0, ((wcnt-wcnt_bak)\dv_rsymax)*dv_sizey, wsx, dv_sizey, hdcScreen, wx1, wy1+((wcnt-wcnt_bak)\dv_rsymax)*dv_sizey, SRCCOPY SetLayeredWindowAttributes hwnd1, 0, ALPHA, LWA_ALPHA //ALPHA¥â¡¼¥É¤ÇÉÔÆ©ÌÀÀßÄê wcnt++ if (wcnt-wcnt_bak)>=dv_rsymax{copy_f=0:copy_f_bak=0:wcnt_bak=wcnt}//Á´¤Æ¥³¥Ô¡¼¤µ¤ì¤¿ }else{//¤Þ¤ÀÊѲ½Ãæ¤Ê¤Î¤Ç°ìöȴ¤±¤ë wcnt_bak=wcnt } copy_f_bak=copy_f } mx(mcnt\mcntmax)=ginfo_mx - mlef my(mcnt\mcntmax)=ginfo_my mcnt++ await 0 gsel 0 //¥Ð¥Ã¥¯¥Ð¥Ã¥Õ¥¡2¤«¤é¥Ð¥Ã¥Õ¥¡0¤Ë¥³¥Ô¡¼ if (cnt=((wx1-mlef)/dv_sxsize)+((wy1/dv_sysize)*dv_sxmax)) or (cnt=((wx1+wsx-mlef-1)/dv_sxsize)+(((wy1+wsy-1)/dv_sysize)*dv_sxmax)) { gmode 0:pos wx1-mlef, wy1:gcopy 2, 0, 0, wsx, wsy //¼Â¹Ô¥¦¥£¥ó¥É¥¦¤¬¤¢¤ëʬ³äÉôʬ¤Î½èÍý¤Î»þ¤À¤±¥³¥Ô¡¼¡Ê¥Ç¥¹¥¯¥È¥Ã¥×¥µ¥¤¥º¤è¤êÂ礭¤¤¤Î¤ÏÁÛÄꤷ¤Æ¤Ê¤¤¡Ë } ; ¥¹¥¯¥ê¡¼¥ó(1)¤Ë½Ì¾®¤·¤ÆÉÁ¼Ì gsel 1 //gzoom¤Ï½Å¤¤¤Î¤Ç¥Ç¥¹¥¯¥È¥Ã¥×¤è¤êÂ礭¤¤Ê¬¤Ïʬ³ä¤·¤Æ¥³¥Ô¡¼ pos (cnt\dv_sxmax)*dv_rsxsize,(cnt/dv_sxmax)*dv_rsysize gzoom dv_rsxsize ,dv_rsysize ,0, _dvx, _dvy ,dv_sxsize ,dv_sysize,1 ; µ¼»÷¥Þ¥¦¥¹¥«¡¼¥½¥ë¤òɽ¼¨ perx=(1.0*ginfo_winx)/sx pery=(1.0*ginfo_winy)/sy color 255 repeat 4,mcnt\mcntmax boxf perx*(mx(cnt\mcntmax)),pery*my(cnt\mcntmax),perx*(mx(cnt\mcntmax))+2,pery*my(cnt\mcntmax)+2 loop redraw 1 redraw 0 await 100 gsel 1 if wsx ! ginfo_sizex { //¥¦¥£¥ó¥É¥¦¤Î¤ê¥µ¥¤¥º¤ËÂбþ //x¤ò¥ê¥µ¥¤¥º¤¹¤ë¤ÈÈæΨ¤òÊѤ¨¤º¤Ë¥µ¥¤¥º¤òÊѹ¹¤Ç¤­¤ë dv_rsxsize=ginfo_winx/_dv_sxmax dv_rsysize=int(double(dv_rsxsize*_dv_sxmax)/(double(sx)/sy))/_dv_symax width dv_rsxsize*_dv_sxmax,dv_rsysize*_dv_symax wsx=ginfo_sizex wsy=ginfo_sizey }else{ if wsy ! ginfo_sizey {//y¤Î¥ê¥µ¥¤¥º¤Ïx¤Î¥µ¥¤¥º¤òÊѤ¨¤Ê¤¤ dv_rsysize=ginfo_winy/_dv_symax //¥¦¥£¥ó¥É¥¦¤Î¤ê¥µ¥¤¥º¤ËÂбþ width ginfo_winx,dv_rsysize*_dv_symax wsy=ginfo_sizey wsx=ginfo_sizex } } wx1=ginfo_wx1 wy1=ginfo_wy1 wx2=ginfo_wx2 wy2=ginfo_wy2 loopcnt++ loop loop *wm_sub if (WM_NCLBUTTONDBLCLK=iparam) and (wparam=2) and ((((lparam>>16)&$ffff)-wy1)<25){//¥¿¥¤¥È¥ë¥À¥Ö¥ë¥¯¥ê¥Ã¥¯ //ÀßÄꥦ¥£¥ó¥É¥¦É½¼¨ gsel conf_id,1 width ,,wx1+wsx+8,wy1 }else{ copy_f++ } return //ÀßÄêŬÍÑ *conf_set gsel conf_id alphamin=limit(_alphamin,0,limit(_alphamax-1,0,_alphamax)) alphamax=limit(_alphamax,alphamin+1,255) objprm alphamin_id,alphamin objprm alphamax_id,alphamax gsel 1 return *exit if wparam =conf_id{//ÀßÄꥦ¥£¥ó¥É¥¦ÊĤ¸¤ë _alphamin=alphamin _alphamax=alphamax gsel conf_id objprm alphamin_id,alphamin objprm alphamax_id,alphamax gsel conf_id,-1 return } ; ¥Ç¥Ð¥¤¥¹¥³¥ó¥Æ¥­¥¹¥Èºï½ü DeleteDC hdcScreen end

getPixel¤ÎÆ°ºî¤¬BitBlt¤ÈƱ¤¸¤«Ê¬¤«¤é¤Ê¤¤¤«¤éÎÙÀܥɥåȤΥÁ¥§¥Ã¥¯¤¬¤É¤¦¤Ê¤ë¤«
BitBlt¤ÈƱ¤¸¤Ç¥ì¥¤¥ä¡¼¥É¥¦¥£¥ó¥É¥¦¤â¼èÆÀ¤Ç¤­¤ë¤È¤·¤Æ¤ä¤Ã¤Æ¤ë¤¬¡¦¡¦¡¦



¥ì¥¤¥ä¡¼¥É¥¦¥£¥ó¥É¥¦¤ògetPixel¤¹¤ë¤È¤É¤¦¤Ê¤ë¤«»î¤·¤ÆÍߤ·¤¤

#uselib "gdi32.dll" #cfunc global CreateDC "CreateDCA" sptr,sptr,sptr,int #func global DeleteDC "DeleteDC" int #cfunc global getPixel "GetPixel" int,int,int #uselib "user32.dll" #cfunc GetWindowLongA "GetWindowLongA" int , int #func SetWindowLongA "SetWindowLongA" int , int , int #func SetLayeredWindowAttributes "SetLayeredWindowAttributes" int , int , int , int #func ReleaseDC "ReleaseDC" int,int #define WS_EX_LAYERED 0x00080000 #define LWA_COLORKEY 1 #define LWA_ALPHA 2 #define GWL_EXSTYLE -20 #define GWL_STYLE -16 // STYLE(hwnd,ÄɲÃSTYLE,ºï½üSTYLE) #define ctype STYLE(%1,%2,%3=0) %1,GWL_STYLE,((GetWindowLongA(%1,GWL_STYLE) | (%2)) | (%3)) ^ (%3) #define ctype EXSTYLE(%1,%2=0,%3=0) %1,GWL_EXSTYLE,((GetWindowLongA(%1,GWL_EXSTYLE) | (%2)) | (%3)) ^ (%3) #define WS_EX_TRANSPARENT $20 SetWindowLongA EXSTYLE(hwnd,WS_EX_LAYERED) SetLayeredWindowAttributes hwnd, 0, 255, LWA_ALPHA width 640 ,480,0,0 //¥¦¥£¥ó¥É¥¦ºÆÉÁ²è¤ÎÂå¤ï¤ê repeat dc=CreateDC("DISPLAY", 0,0,0) col=GetPixel( dc,ginfo_mx,ginfo_my) color col&$ff,(col>>8)&$ff,(col>>16) DeleteDC dc boxf 0,0,32,32 redraw wait 1 loop
XP¤Ï¿¿¤ÃÇò¤Ê¥¦¥£¥ó¥É¥¦¤òÆ©²á¤·¤Æ²¼¤Î¿§¤ò½¦¤¦
¤Þ¤¡¡¢BitBlt¤ÎÍý¶þ¤ÈƱ¤¸¤Ê¤ó¤À¤í¤¦¤±¤É¡¦¡¦¡¦



_hamyuu

¥ê¥ó¥¯

2013/3/28(Thu) 14:26:36|NO.53307

¥¹¥ì¼ç¤ÏÉÔºß..¡Ê?¡Ë¤Êµ¤¤¬¤·¤¿¤Î¤Ç¡¢¤ä¤¿¤é¤È¼Â¸³¹¥¤­¤Ê¼«Ê¬¤¬Âå¤ï¤ê¤Ë»î¤·¤Æ¤ß¤Þ¤·¤¿¡£

¥ì¥¤¥ä¡¼¥É¥¦¥£¥ó¥É¥¦¤òGetPixel¤¹¤ë¤È¡¦¡¦
Aero¤¢¤ê¤Î¾ì¹ç¤ÏÆ©²á¤µ¤ì¤º¥¦¥£¥ó¥É¥¦¤Î¿§¤¬É½¼¨¤µ¤ì¤Þ¤¹¡£
Aero¤òÀÚ¤ë¤È¥¦¥£¥ó¥É¥¦¤òÆ©²á¤·¤Æ²¼¤Î¿§¤¬É½¼¨¤µ¤ì¤Þ¤·¤¿¡£

¤ä¤Ã¤Ñ¤êAero¤¬¥Í¥Ã¥¯¤Ê¤è¤¦¤Ç¡¦¡¦¡¦



²Ë¿Í

¥ê¥ó¥¯

2013/3/28(Thu) 19:05:50|NO.53309

Êó¹ð¤¢¤ê¤¬¤È¤¦
>Aero¤¢¤ê¤Î¾ì¹ç¤ÏÆ©²á¤µ¤ì¤º¥¦¥£¥ó¥É¥¦¤Î¿§¤¬É½¼¨¤µ¤ì¤Þ¤¹¡£
>Aero¤òÀÚ¤ë¤È¥¦¥£¥ó¥É¥¦¤òÆ©²á¤·¤Æ²¼¤Î¿§¤¬É½¼¨¤µ¤ì¤Þ¤·¤¿¡£
ͽÁÛÄ̤ê¤ÎÆ°ºî¤«¡¦¡¦¡¦


º£¤Þ¤Ç¤¿¤À¤Î¥Þ¥ë¥Á¥Ç¥£¥¹¥×¥ì¥¤¤È¿åÊ¿¿âľ³ÈÄ¥¥Ç¥¹¥¯¥È¥Ã¥×¤Î°ã¤¤¤òµ¤¤Ë¤·¤Æ¤Ê¤«¤Ã¤¿¤±¤É
ginfo_dispx(y)¤ÎÃͤ˱ƶÁ¤¢¤ë»ö¤ò˺¤ì¤Æ¤¿¡¦¡¦¡¦

NO.53291¤Î¤â´Þ¤á¤Æginfo_disp¤Î¥µ¥¤¥º¤Ï¥á¥¤¥ó¤Î¥Ç¥£¥¹¥×¥ì¥¤¤Î²òÁüÅÙ¤À¤È»×¤Ã¤Æºî¤Ã¤Æ¤¿¤«¤é
³ÈÄ¥¥Ç¥¹¥¯¥È¥Ã¥×¤ÇÁ´Éô¤Î¹ç·×¤¬Æþ¤Ã¤Æ¤¿¤éʬ³ä½èÍý¤µ¤ì¤Ê¤¤¡¦¡¦¡¦



²Ë¿Í

¥ê¥ó¥¯

2013/3/30(Sat) 03:40:39|NO.53342

NO.53291¤Î¤Ï¿âľÊý¸þ¤Ë³ÈÄ¥¤·¤Æ¤ë¾ì¹ç
¥¦¥£¥ó¥É¥¦¤ò²¼¤Î²èÌ̤ˤϤ߽Ф¹¤È̵¸Â¥ë¡¼¥×(sleep 1¤ÏÆþ¤ë¤¬)¤Ë
´Ù¤ë¤Î¤Ç½¤ÀµÈÇ¡Ê¿ʬ¤³¤ì¤ÇºÇ¸å¡Ë
¾¤Ë¤â¾¯¤·½¤Àµ¤·¤Æµ¯Æ°¤·¤Æ¤«¤éÀßÄê¤Ç¤­¤ë¹àÌÜÄɲÃ
¹¹¤Ëµ¯Æ°»þ¤Ë¥Ç¥¹¥¯¥È¥Ã¥×Îΰè¤È³«»Ï°ÌÃÖ¤ò¼èÆÀ¤·¤ÆÀßÄꤹ¤ë¤è¤¦¤Ë¤·¤¿

capsizex ¥­¥ã¥×¥Á¥ã¡¼¤¹¤ë²£¥µ¥¤¥º
capsizey ¥­¥ã¥×¥Á¥ã¡¼¤¹¤ë½Ä¥µ¥¤¥º
left¡¡¡¡ ¥­¥ã¥×¥Á¥ã¡¼¤¹¤ëº¸Â¦ºÂɸ
top¡¡¡¡ ¥­¥ã¥×¥Á¥ã¡¼¤¹¤ë¾å¦ºÂɸ
ɽ¼¨ÇÜΨ ¥­¥ã¥×¥Á¥ã¡¼¥µ¥¤¥º¤ò²¿¡ó¤Çɽ¼¨¤¹¤ë¤«¡Ê¼Â¸ú¥¦¥£¥ó¥É¥¦¤Î¥µ¥¤¥º¤Ë±Æ¶Á¤¹¤ë¤Î¤ÇÂ礭¤¤¤È½èÍý¤¬½Å¤¯¤Ê¤ë¡Ë
²£Ê¬³ä¿ô ¥­¥ã¥×¥Á¥ã¡¼¤ò²£²¿Ê¬³ä¤Ç¤¹¤ë¤«¡Ê¥­¥ã¥×¥Á¥ã¡¼¸å¤Îɽ¼¨¤âƱ¤¸¤¯Ê¬³ä¤µ¤ì¤ë¤Î¤Ç¿¤±¤ì¤Ð½èÍý¤¬·Ú¤¯¤Ê¤ë¡Ë
½Äʬ³ä¿ô ¥­¥ã¥×¥Á¥ã¡¼¤ò½Ä²¿Ê¬³ä¤Ç¤¹¤ë¤«

#include "mod_d3d9vsync.hsp" #uselib "gdi32.dll" #cfunc CreateDC "CreateDCA" sptr,sptr,sptr,int #func DeleteDC "DeleteDC" int #func BitBlt "BitBlt" int,int,int,int,int,int,int,int,int #cfunc getPixel "GetPixel" int,int,int #cfunc CreateRectRgn "CreateRectRgn" int, int, int, int #func DeleteObject "DeleteObject" int #cfunc GetRegionData "GetRegionData" int, int, int #func GetClipRgn "GetClipRgn" int, int #func GetClipBox "GetClipBox" int,int #define NULL 0 #define SRCCOPY 0x00CC0020 #define CAPTUREBLT 0x40000000 #uselib "user32.dll" #cfunc GetWindowLongA "GetWindowLongA" int , int #func SetWindowLongA "SetWindowLongA" int , int , int #func SetLayeredWindowAttributes "SetLayeredWindowAttributes" int , int , int , int #func SetWindowPos "SetWindowPos" int, int, int, int, int, int, int #define WS_EX_LAYERED 0x00080000 #define LWA_COLORKEY 1 #define LWA_ALPHA 2 #define GWL_EXSTYLE -20 #define GWL_STYLE -16 #define WM_NULL 0x0000 #define WM_CREATE 0x0001 #define WM_DESTROY 0x0002 #define WM_MOVE 0x0003 #define WM_SIZE 0x0005 #define WM_PAINT 0x000F #define WM_QUERYNEWPALETTE 0x030F #define WM_SETREDRAW 0x000B #define WM_NCLBUTTONDBLCLK 0x00A3 #const SWP_NOMOVE 0x02 #const SWP_NOSIZE 0x0001 #const SWP_NOZORDER 0x0004 #const SWP_NOACTIVATE 0x0010 #const SWP_FRAMECHANGED 0x020 #const SWP_SHOWWINDOW 0x040 #const SWP_HIDEWINDOW 0x080 #const SWP_NOCOPYBITS 0x0100 #const SWP_NOOWNERZORDER 0x0200 // STYLE(hwnd,ÄɲÃSTYLE,ºï½üSTYLE) #define ctype STYLE(%1,%2,%3=0) %1,GWL_STYLE,((GetWindowLongA(%1,GWL_STYLE) | (%2)) | (%3)) ^ (%3) #define ctype EXSTYLE(%1,%2=0,%3=0) %1,GWL_EXSTYLE,((GetWindowLongA(%1,GWL_EXSTYLE) | (%2)) | (%3)) ^ (%3) #define WS_EX_TRANSPARENT $20 d3d9vsync_init //d3d9vsync¤Ï¥×¥é¥¤¥Þ¥ê ¥Ç¥£¥¹¥×¥ì¥¤ ¥¢¥À¥×¥¿¸ÇÄê if stat < 0 { if -5 ! stat {dialog "GetRasterStatus¤ò»ÈÍѤǤ­¤Ê¤¤´Ä¶­¤Ç¤¹":end} } Raster=0 repeat GetRasterStatus v,r //VBlank¤È¥é¥¹¥¿¡¼°ÌÃÖ¼èÆÀ if r>=Raster {Raster=r}else{if v=0{break}}//¥×¥é¥¤¥Þ¥ê¥Ç¥£¥¹¥×¥ì¥¤¤Î¥é¥¹¥¿¡¼¿ô¼èÆÀ(¥¢¥À¥×¥¿Ì¾¼èÆÀ¤·¤Æ¤É¤¦¤³¤¦¤¬ÌÌÅݤÀ¤Ã¤¿¤Î¤Ç¡¦¡¦¡¦) loop ; ¥Ç¥¹¥¯¥È¥Ã¥×²èÌ̤ΥǥХ¤¥¹¥³¥ó¥Æ¥­¥¹¥È¼èÆÀ hdcScreen = CreateDC("DISPLAY", NULL, NULL, NULL) dim ClipBox,4 GetClipBox hdcScreen,varptr(ClipBox) //¥×¥é¥¤¥Þ¥ê¥Ç¥£¥¹¥×¥ì¥¤¤«¤é¤Î¥Ç¥¹¥¯¥È¥Ã¥×Á´ÂΤζë·Á¼èÆÀ¡Ê½Ä²£¤Ë¤º¤ì¤Æ¤ë¤Î¤Ë¤âÂбþ¤Ç¤­¤ë¡Ë /* ¥Þ¥ë¥Á¥â¥Ë¥¿´Ä¶­¤Î¾ì¹çsx¤Ë¤Ï²£²òÁüÅ٤ιç·×¡¢sy¤Ë¤ÏºÇÂç¤Î½Ä²òÁüÅÙ¤òÆþÎÏ¡£ ¡¡ ¤½¤ì°Ê³°¤Ê¤é ginfo_dispx ¤È ginfo_dispy ¤òÆþÎÏ¡£ */ sx = ClipBox(2)-ClipBox : sy = ClipBox(3)-ClipBox(1) _sx=sx : _sy=sy /* ¥Þ¥ë¥Á¥â¥Ë¥¿´Ä¶­¤Î¾ì¹ç¥á¥¤¥ó¥â¥Ë¥¿¤Îº¸¾åºÂɸ¤ò0,0¤È¤·¤Æº¸Ã¼¤Î¥â¥Ë¥¿¡¼¤Îº¸¾åºÂɸ¤òÆþÎÏ ¡¡ ¤½¤ì°Ê³°¤Ê¤é 0 ¤òÆþÎÏ¡£ */ mlef = ClipBox ,ClipBox(1) _mlef=mlef ,mlef(1) /* ½Ì¾®¤Î³ä¹ç¡£%¤ÇÀßÄê¡¢100¤ÇÅùÇÜ¡£50 ¤Ç1/2¤Î¥µ¥¤¥º */ percent = 20 _percent=percent //Æ©ÌÀÅ٤νé´üÃÍ _alphamin=100 //¥Þ¥¦¥¹¤¬¼Â¹Ô¥¦¥£¥ó¥É¥¦¤ÎÉÁ²è¥¨¥ê¥¢Æâ¤Î»þ _alphamax=255 //¥Þ¥¦¥¹¤¬¼Â¹Ô¥¦¥£¥ó¥É¥¦ÉÁ²è¥¨¥ê¥¢³°¤Î»þ //adjust ¼Â¹Ô¥¦¥£¥ó¥É¥¦¤¬Â礭¤¤¤È¥Á¥é¤Ä¤¯¤Î¤Ç¥é¥¹¥¿¡¼´Æ»ë°ÌÃÖ¤ò¤º¤é¤¹ adjust=0 //¼«Ê¬¤Î´Ä¶­¤Ç¤ÏY¥µ¥¤¥º¤¬500Ķ¤¨¤ë¤°¤é¤¤¤À¤È100ÄøÅ٤Ǽý¤Þ¤ë(´°Á´¤¸¤ã¤Ê¤¤¤±¤É¡¦¡¦¡¦) //ʬ³ä¥µ¥¤¥º¤«¤éʬ³ä¿ô¤ò½Ð¤¹ divsizx=1920 divsizy=1080 _divsizx=divsizx _divsizy=divsizy dv_sxmax=limit(sx/divsizx,1,100) //ʬ³ä¿ô dv_symax=limit(sy/divsizy,1,100) wt=100 _wt=wt gosub *init gsel 1,2 if mcntmax=0{ onexit gosub *exit mcntmax=4 dim mx,mcntmax dim my,mcntmax oncmd gosub *wm_sub,WM_SIZ oncmd gosub *wm_sub,WM_MOVE oncmd gosub *wm_sub,WM_QUERYNEWPALETTE oncmd gosub *wm_sub,WM_NCLBUTTONDBLCLK } copy_f=1 //¼Â¹Ô¥¦¥£¥ó¥É¥¦¤Î²¼¤ò¥³¥Ô¡¼¤µ¤»¤ë¥Õ¥é¥° repeat repeat dv_sxmax*dv_symax if ((wx1+4)<ginfo_mx) and ((wy1+22)<ginfo_my) and ((wx1-4+wsx)>ginfo_mx) and ((wy1-4+wsy)>ginfo_my) {//¥Þ¥¦¥¹¤¬¼Â¹Ô¥¦¥£¥ó¥É¥¦¤ÎÉÁ²è¥¨¥ê¥¢Æâ¤ËÆþ¤Ã¤¿ if ALPHA ! alphamin {//ȾƩÌÀ¤Ë¤·¤Æ¥Þ¥¦¥¹Áàºî¤â²¼¤ËÆ©²á¤¹¤ë(WS_EX_TRANSPARENT) copy_f++ ALPHA=alphamin SetWindowLongA EXSTYLE(hwnd1,WS_EX_TRANSPARENT) SetWindowPos hwnd1,0 ,0,0 ,0,0 ,SWP_NOMOVE | SWP_NOSIZE | SWP_NOZORDER | SWP_FRAMECHANGED | SWP_SHOWWINDOW SetLayeredWindowAttributes hwnd1, 0, ALPHA, LWA_ALPHA } }else{ //¥Þ¥¦¥¹¤¬¼Â¹Ô¥¦¥£¥ó¥É¥¦ÉÁ²è¥¨¥ê¥¢³° if ALPHA ! alphamax {//ȾƩÌÀ¤òÌᤷ¥¿¥¤¥È¥ëÏȤò¥¯¥ê¥Ã¥¯½ÐÍè¤ëÍͤËWS_EX_TRANSPARENT¤òºï½ü copy_f++ ALPHA=alphamax SetWindowLongA EXSTYLE(hwnd1,0,WS_EX_TRANSPARENT) SetWindowPos hwnd1,0 ,0,0 ,0,0 ,SWP_NOMOVE | SWP_NOSIZE | SWP_NOZORDER | SWP_FRAMECHANGED | SWP_SHOWWINDOW } } _dvx=(cnt\dv_sxmax)*dv_sxsize _dvy=(cnt/dv_sxmax)*dv_sysize //¼Â¹Ô¥¦¥£¥ó¥É¥¦¤ËÎÙÀܤ¹¤ë¥É¥Ã¥È¤ËÊѲ½¤¬¤¢¤Ã¤¿¤«¥Á¥§¥Ã¥¯(4¥É¥Ã¥ÈËè»ÍÊÕ¤À¤±Èæ³Ó¤À¤«¤é¥Æ¥­¥¹¥È¥¹¥¯¥í¡¼¥ë¤È¤«¤Ï¸«Æ¨¤¹²ÄǽÀ­¤¢¤ê) if ((wx2)>(mlef)) and ((wx1)<(mlef+sx)) and ((wy2)>(mlef(1))) and ((wy1)<(mlef(1)+sy)){ if (cnt=((wx1-mlef-1)/dv_sxsize)+(((wy1-mlef(1))/dv_sysize)*dv_sxmax)) or (cnt=((wx2-mlef)/dv_sxsize)+(((wy2-mlef(1))/dv_sysize)*dv_sxmax)) { if ((wy1)<(mlef(1)+sy)) { repeat (wsx-1)/4,1 Pixel=getPixel(hdcScreen,wx1+cnt*4,wy1-1) if Pixel>=0{ if (getPixel(hdc10,cnt*4,0) ! Pixel){ copy_f++ break } } loop } if ((wx1)<(mlef+sx)){ repeat (wsy-1)/4,1 Pixel=getPixel(hdcScreen,wx1-1,wy1+cnt*4) if Pixel>=0{ if (getPixel(hdc11,1, cnt*4) ! Pixel) { copy_f++ break } } loop } if ((wy2)>(mlef(1))) { repeat (wsx-1)/4,1 Pixel=getPixel(hdcScreen,wx1+cnt*4,wy2) if Pixel>=0{ if (getPixel(hdc10,cnt*4,1) ! Pixel) { copy_f++ break } } loop } if ((wx2)>=(mlef)) { repeat (wsy-1)/4,1 Pixel=getPixel(hdcScreen,wx2,wy1+cnt*4) if Pixel>=0{ if (getPixel(hdc11,0, cnt*4) ! Pixel) { copy_f++ break } } loop } //¥­¥ã¥×¥Á¥ã¡¼Èϰϳ°¤Ë¥Ç¥¹¥¯¥È¥Ã¥×¤¬¤¢¤Ã¤¿¾ì¹ç¤Ç¤âÈæ³Ó¤Ç¤­¤ë¤è¤¦¤Ë¼Â¹Ô¥¦¥£¥ó¥É¥¦¤Î¼þÊÕ1¥É¥Ã¥È¤ò¥³¥Ô¡¼ BitBlt hdc10, 0, 0, wsx, 1, hdcScreen, wx1,wy1-1, SRCCOPY BitBlt hdc10, 0, 1, wsx, 1, hdcScreen, wx1,wy2, SRCCOPY BitBlt hdc11, 1, 0, 1, wsy, hdcScreen, wx1-1,wy1, SRCCOPY BitBlt hdc11, 0, 0, 1, wsy, hdcScreen, wx2,wy1, SRCCOPY } } ; ¥Ç¥¹¥¯¥È¥Ã¥×²èÌ̤βèÁü¤ò¥³¥Ô¡¼(sy¤òdv_sxmax*dv_sxmaxʬ³ä¤·¤Æ¥³¥Ô¡¼) BitBlt hdc0, _dvx, _dvy, dv_sxsize, dv_sysize, hdcScreen, mlef+_dvx, mlef(1)+_dvy, SRCCOPY if copy_f {//¼Â¹Ô¥¦¥£¥ó¥É¥¦´Þ¤à¼þÊդDz¿¤«ÊѲ½¤¬¤¢¤Ã¤¿ if copy_f_bak=copy_f{//ÊѲ½¤¬½ª¤Ã¤¿¤é¼Â¹Ô¥¦¥£¥ó¥É¥¦¤Î²¼¤ò²èÁü¤òhdc2¤Ë¥³¥Ô¡¼ repeat GetRasterStatus v,r //VBlank¤È¥é¥¹¥¿¡¼°ÌÃÖ¼èÆÀ if v or (r>(Raster-100)){break} //VBlankÃæ _Sleep@mod_d3d9vsync 1 loop if r>(Raster-100){ _Sleep@mod_d3d9vsync 1 GetRasterStatus v,r //VBlank¤È¥é¥¹¥¿¡¼°ÌÃÖ¼èÆÀ if r>(Raster-100){ repeat GetRasterStatus v,r //VBlank¤È¥é¥¹¥¿¡¼°ÌÃÖ¼èÆÀ if v {break} //VBlankÃæ loop } } repeat GetRasterStatus v,r //VBlank¤È¥é¥¹¥¿¡¼°ÌÃÖ¼èÆÀ if r>=limit((ginfo_wy2-adjust),1,Raster-50) or ((ginfo_wy2)>Raster){break} //¥é¥¹¥¿¡¼¤¬¼Â¹Ô¥¦¥£¥ó¥É¥¦¤è¤ê²¼¤Ê¤éÈ´¤±¤ë if (limit((ginfo_wy2-adjust),1,Raster))>150 {_Sleep@mod_d3d9vsync 1} //ÌÜŪ¤Î°ÌÃÖ¤Þ¤Ç150°Ê¾åÍ­¤Ã¤¿¤é1ms¥¹¥ê¡¼¥× loop //¼Â¹Ô¥¦¥£¥ó¥É¥¦¤è¤ê²¼¤ËÁöººÀþ¤¬Í­¤ë»þ¤Ë¼Â¹Ô¥¦¥£¥ó¥É¥¦¤òÆ©ÌÀ¤Ë¤·¤Æ¥³¥Ô¡¼¤·¤Æľ¤°¤ËÉÔÆ©ÌÀ¤ËÌ᤹(¤â¤·¤«¤·¤¿¤é¾¤ÎÊýË¡¤Ç¸«¤¨¤Ê¤¯¤·¤¿¤Û¤¦¤¬·Ú¤¤¤Î¤«¤â¤·¤ì¤Ê¤¤¡¦¡¦¡¦) //SetLayeredWindowAttributes¤¬¥¦¥£¥ó¥É¥¦¤ÎÂ礭¤µ¤ÇÀ¨¤¯½èÍý»þ´Ö¤¬Áý¤¨¤ë¡¦¡¦¡¦ SetLayeredWindowAttributes hwnd1, 0, 0, LWA_ALPHA //ALPHA¥â¡¼¥É¤ÇÆ©ÌÀ¤ËÀßÄê BitBlt hdc2, 0, ((wcnt-wcnt_bak)\dv_rsymax)*dv_sizey, wsx, dv_sizey, hdcScreen, wx1, wy1+((wcnt-wcnt_bak)\dv_rsymax)*dv_sizey, SRCCOPY SetLayeredWindowAttributes hwnd1, 0, ALPHA, LWA_ALPHA //ALPHA¥â¡¼¥É¤ÇÉÔÆ©ÌÀÀßÄê wcnt++ if (wcnt-wcnt_bak)>=dv_rsymax{copy_f=0:copy_f_bak=0:wcnt_bak=wcnt}//Á´¤Æ¥³¥Ô¡¼¤µ¤ì¤¿ }else{//¤Þ¤ÀÊѲ½Ãæ¤Ê¤Î¤Ç°ìöȴ¤±¤ë wcnt_bak=wcnt } copy_f_bak=copy_f } mx(mcnt\mcntmax)=ginfo_mx - mlef my(mcnt\mcntmax)=ginfo_my - mlef(1) mcnt++ await 0 gsel 0 //¥Ð¥Ã¥¯¥Ð¥Ã¥Õ¥¡2¤«¤é¥Ð¥Ã¥Õ¥¡0¤Ë¥³¥Ô¡¼ if (cnt=((wx1-mlef)/dv_sxsize)+(((wy1-mlef(1))/dv_sysize)*dv_sxmax)) or (cnt=((wx1+wsx-mlef-1)/dv_sxsize)+((((wy1-mlef(1))+wsy-1)/dv_sysize)*dv_sxmax)) { gmode 0:pos wx1-mlef, wy1-mlef(1):gcopy 2, 0, 0, wsx, wsy //¼Â¹Ô¥¦¥£¥ó¥É¥¦¤¬¤¢¤ëʬ³äÉôʬ¤Î½èÍý¤Î»þ¤À¤±¥³¥Ô¡¼¡Ê¥Ç¥¹¥¯¥È¥Ã¥×¥µ¥¤¥º¤è¤êÂ礭¤¤¤Î¤ÏÁÛÄꤷ¤Æ¤Ê¤¤¡Ë } ; ¥¹¥¯¥ê¡¼¥ó(1)¤Ë½Ì¾®¤·¤ÆÉÁ¼Ì gsel 1 //gzoom¤Ï½Å¤¤¤Î¤Ç¥Ç¥¹¥¯¥È¥Ã¥×¤¬dv_sxsize*dv_sysize¤è¤êÂ礭¤¤Ê¬¤Ïʬ³ä¤·¤Æ¥³¥Ô¡¼ pos (cnt\dv_sxmax)*dv_rsxsize,(cnt/dv_sxmax)*dv_rsysize gzoom dv_rsxsize ,dv_rsysize ,0, _dvx, _dvy ,dv_sxsize ,dv_sysize,1 ; µ¼»÷¥Þ¥¦¥¹¥«¡¼¥½¥ë¤òɽ¼¨ perx=(1.0*ginfo_winx)/sx pery=(1.0*ginfo_winy)/sy color 255 repeat mcnt,mcnt\mcntmax boxf perx*(mx(cnt\mcntmax)),pery*my(cnt\mcntmax),perx*(mx(cnt\mcntmax))+2,pery*my(cnt\mcntmax)+2 loop redraw 1 redraw 0 await wt gsel 1 if wsx ! ginfo_sizex { //¥¦¥£¥ó¥É¥¦¤Î¤ê¥µ¥¤¥º¤ËÂбþ //²£¤ò¥ê¥µ¥¤¥º¤¹¤ë¤ÈÈæΨ¤òÊѤ¨¤º¤Ë¥µ¥¤¥º¤òÊѹ¹¤Ç¤­¤ë dv_rsxsize=ginfo_winx/dv_sxmax dv_rsysize=int(double(dv_rsxsize*dv_sxmax)/(double(sx)/sy))/dv_symax width dv_rsxsize*dv_sxmax,dv_rsysize*dv_symax wsx=ginfo_sizex wsy=ginfo_sizey }else{ if wsy ! ginfo_sizey {//½Ä¤Î¥ê¥µ¥¤¥º¤Ï²£¤Î¥µ¥¤¥º¤òÊѤ¨¤Ê¤¤ dv_rsysize=ginfo_winy/dv_symax //¥¦¥£¥ó¥É¥¦¤Î¤ê¥µ¥¤¥º¤ËÂбþ width ginfo_winx,dv_rsysize*dv_symax wsy=ginfo_sizey wsx=ginfo_sizex } } wx1=ginfo_wx1 wy1=ginfo_wy1 wx2=ginfo_wx2 wy2=ginfo_wy2 loopcnt++ loop loop *wm_sub if init_f=0 { if (WM_NCLBUTTONDBLCLK=iparam) and (wparam=2) and ((((lparam>>16)&$ffff)-wy1)<25){//¥¿¥¤¥È¥ë¥À¥Ö¥ë¥¯¥ê¥Ã¥¯ //ÀßÄꥦ¥£¥ó¥É¥¦É½¼¨ gsel conf_id,0 width ,,wx1+wsx+8,wy1 gsel conf_id,1 }else{ copy_f++ } } return //ÀßÄêŬÍÑ *conf_set stat_id=stat gsel conf_id alphamin=limit(_alphamin,0,limit(_alphamax-1,0,_alphamax)) alphamax=limit(_alphamax,alphamin+1,255) objprm alphamin_id,alphamin objprm alphamax_id,alphamax if stat_id=ALL_id { sx=limit(_sx,128,ClipBox(2)-ClipBox) sy=limit(_sy,128,ClipBox(3)-ClipBox(1)) mlef=limit(_mlef,-(ClipBox(2)-ClipBox),ClipBox(2)-ClipBox) mlef(1)=limit(_mlef(1),-(ClipBox(3)-ClipBox(1)),ClipBox(3)-ClipBox(1)) percent=limit(_percent,1,1000) dv_sxmax=limit(_dv_sxmax,1,100) dv_symax=limit(_dv_symax,1,100) objprm sx_id,sx objprm sy_id,sy objprm mlef_id,mlef objprm mlef_id(1),mlef(1) objprm percent_id,percent objprm dv_sxmax_id,dv_sxmax objprm dv_symax_id,dv_symax gosub *init } gsel 1 return *exit if wparam =conf_id {//ÀßÄꥦ¥£¥ó¥É¥¦ÊĤ¸¤ë if init_f=0 { gsel conf_id objprm alphamin_id,alphamin objprm alphamax_id,alphamax objprm sx_id,sx objprm sy_id,sy objprm mlef_id,mlef objprm mlef_id(1),mlef(1) objprm percent_id,percent objprm dv_sxmax_id,dv_sxmax objprm dv_symax_id,dv_symax gsel conf_id,-1 } return } ; ¥Ç¥Ð¥¤¥¹¥³¥ó¥Æ¥­¥¹¥Èºï½ü DeleteDC hdcScreen end *init init_f=1 dv_sxsize=sx/dv_sxmax //ʬ³ä¥µ¥¤¥º dv_sysize=sy/dv_symax dv_sxmax+=((sx-dv_sxsize*dv_sxmax)>0) //;¤Ã¤Æ¤ëʬ¤¬¤¢¤Ã¤¿¤éʬ³ä¿ô+1 dv_symax+=((sy-dv_sysize*dv_symax)>0) dv_sxsize=sx/dv_sxmax //ʬ³ä¥µ¥¤¥º dv_sysize=sy/dv_symax percent=int(percent) _percent=percent rs = 100.0/percent rsx=int((double(percent)/100)*sx) rsy=int((double(percent)/100)*sy) dv_rsxsize=rsx/dv_sxmax //ʬ³ä¥µ¥¤¥º(ʬ³ä¿ô¤Ïsx,sy¤Î¤ò»ÈÍÑ) dv_rsysize=rsy/dv_symax _dv_sxmax=dv_sxmax _dv_symax=dv_symax ; ¥Ç¥¹¥¯¥È¥Ã¥×²èÌ̤Υµ¥¤¥º¤Ç¥Ð¥Ã¥Õ¥¡²èÌ̤òºîÀ® buffer 0 , sx, sy hdc0=hdc syscolor 15 boxf wait 1 ; ¥¹¥¯¥ê¡¼¥ó(1)¤òºîÀ® screen 1, rsx ,rsy,2,wx1,wy1 hdc1=hdc hwnd1=hwnd //¥ì¥¤¥ä¡¼¥É¥¦¥£¥ó¥É¥¦¤òÀßÄê SetWindowLongA EXSTYLE(hwnd1,WS_EX_LAYERED) alphamin=_alphamin alphamax=_alphamax ALPHA=alphamax SetLayeredWindowAttributes hwnd1, 0, ALPHA, LWA_ALPHA //ALPHA¥â¡¼¥É¤ÇÉÔÆ©ÌÀÀßÄê SetWindowPos hwnd1,0 ,0,0 ,0,0 ,SWP_NOMOVE | SWP_NOSIZE | SWP_NOZORDER | SWP_FRAMECHANGED | SWP_SHOWWINDOW wait 1 //¥ì¥¤¥ä¡¼¥É¥¦¥£¥ó¥É¥¦¤Îº¸¾åºÂɸ¤È¥¿¥¤¥È¥ëÏȤò´Þ¤á¤¿¥µ¥¤¥º¤ò¼èÆÀ wx1=ginfo_wx1 wy1=ginfo_wy1 wx2=ginfo_wx2 wy2=ginfo_wy2 wsx=ginfo_sizex wsy=ginfo_sizey dv_rsymax=limit(int(((1.0*wsx*wsy)/(1920*1080/5))),1,wsy) //BitBlt¤è¤êALPHAÃÍÊѹ¹¤ÎÊý¤¬½Å¤«¤Ã¤¿¤Î¤ÇºÙ¤«¤¤Ê¬³ä¤Ï°Ọ̵̃¤¤¤«¤â¡¦¡¦¡¦ dv_sizey=wsy/dv_rsymax dv_rsymax=wsy/dv_sizey+((wsy-dv_sizey*dv_rsymax)>0) //³Î¼Â¤Ëdv_sizey*dv_sizey¤¬wsy°Ê¾å¤Ë¤Ê¤ë¤è¤¦¤Ë¤¹¤ë // getPixel¥Á¥§¥Ã¥¯ÍѥХåե¡ buffer 10,wsx ,2 //²£¾å²¼¥é¥¤¥óÍÑ hdc10=hdc buffer 11,2 ,wsy //½Äº¸±¦¥é¥¤¥óÍÑ hdc11=hdc //ÀßÄꥦ¥£¥ó¥É¥¦Èóɽ¼¨¤ÇÀßÃÖ if conf_id=0 { conf_id=100 screen conf_id, 220,256 ,8+2,wx1+wsx+8,wy1 syscolor 15 boxf color title "ÀßÄê" pos 8,8 mes " adjust" mes " await" mes mes "alphamin" mes "alphamax" mes mes "capsizex" mes "capsizey" mes " left" mes " top" mes "ɽ¼¨ÇÜΨ" mes "²£Ê¬³ä¿ô" mes "½Äʬ³ä¿ô" _alphamin=alphamin _alphamax=alphamax pos 80,12 input adjust,64,16 input wt,64,16 pos 80,ginfo_cy+20 input _alphamin,64,16 alphamin_id=stat input _alphamax,64,16 alphamax_id=stat gcy=ginfo_cy pos 153,ginfo_cy-26 button gosub "ALPHŬÍÑ",*conf_set ALPH_id=stat objsize 64,18,18 pos 80,gcy+22 input _sx,64,16 sx_id=stat input _sy,64,16 sy_id=stat input _mlef,64,16 mlef_id=stat input _mlef(1),64,16 mlef_id(1)=stat input _percent,64,16 percent_id=stat input _dv_sxmax,64,16 dv_sxmax_id=stat input _dv_symax,64,16 dv_symax_id=stat pos 156,ginfo_cy-8 button gosub "ALLŬÍÑ",*conf_set ALL_id=stat }else{ gsel conf_id width ,,wx1+wsx+8,wy1 } //¥ì¥¤¥ä¡¼¥É¥¦¥£¥ó¥É¥¦¤Î²¼¤Î²èÁü°ì»þ¥³¥Ô¡¼ÍѥХåե¡ buffer 2 , wsx, wsy hdc2=hdc init_f=0 return



_hamyuu

¥ê¥ó¥¯

2013/3/30(Sat) 21:45:14|NO.53350

¼Â¹Ô¤·¤¿¤é¤³¤ó¤Ê´¶¤¸¤Ë¤Ê¤ê¤Þ¤·¤¿¡£
https://www.dropbox.com/s/l2glowm8wnrodrf/capture.mp4

²¿¤«¡¦¡¦¥Ð¥°¤Ã¤Æ¤ë¡©



²Ë¿Í

¥ê¥ó¥¯

2013/3/30(Sat) 22:57:19|NO.53352

Êó¹ð¤¢¤ê¤¬¤È¤¦
¤Ê¤ó¤«¥¦¥£¥ó¥É¥¦¤Î±Æ¤ÎÉôʬ¤¬²¿¤«±Æ¶Á¤·¤Æ¤½¤¦¡¦¡¦¡¦

¤â¤·½ÐÍ褿¤é¤ÇÎɤ¤¤ó¤Ç
> ; ¥¹¥¯¥ê¡¼¥ó(1)¤Ë½Ì¾®¤·¤ÆÉÁ¼Ì
> gsel 1
¤³¤Îgsel¤Î²¼¤¢¤¿¤ê¤Ë

title strf("%d %d %d %d ",loopcnt ,copy_f ,ALPHA ,r)
¤òÁÞÆþ¤·¤Æ¿ôÃͤò¸«¤ÆÍߤ·¤¤
ȾƩÌÀ¤Ç¸«Æñ¤¤¤À¤í¤¦¤«¤é
>//Æ©ÌÀÅ٤νé´üÃÍ
> _alphamin=100 //¥Þ¥¦¥¹¤¬¼Â¹Ô¥¦¥£¥ó¥É¥¦¤ÎÉÁ²è¥¨¥ê¥¢Æâ¤Î»þ
¤³¤ì¤ò200¤°¤é¤¤¤Ë¤·¤Æ


¥«¡¼¥½¥ë¤ò¥¦¥£¥ó¥É¥¦³°¤Ë°ÜÆ°¤·¤Æ¤ë¾õÂÖ¤Ç
loopcnt¤ÏƱ¤¸Â®ÅÙ¤ÇÆ°¤­Â³¤±¤Æcopy_f¤âÁý¤¨Â³¤±¤ÆALPHA¤Ï255¤Î¾ì¹ç
getPixel¤ÎÆ°ºî¤¬ÁÛÄê¤È°ã¤Ã¤Æ¤ë²ÄǽÀ­¤¬¹â¤¤¡¦¡¦¡¦

¤½¤Î¾ì¹ç
¢­¤Î¹Ô¤«¤é
>
>//¼Â¹Ô¥¦¥£¥ó¥É¥¦¤ËÎÙÀܤ¹¤ë¥É¥Ã¥È¤ËÊѲ½¤¬¤¢¤Ã¤¿¤«¥Á¥§¥Ã¥¯(4¥É¥Ã¥ÈËè»ÍÊÕ¤À¤±Èæ³Ó¤À¤«¤é¥Æ¥­¥¹¥È¥¹¥¯¥í¡¼¥ë¤È¤«¤Ï¸«Æ¨¤¹²ÄǽÀ­¤¢¤ê)
> if ((wx2)>(mlef)) and ((wx1)<(mlef+sx)) and ((wy2)>(mlef(1))) and ((wy1)<(mlef(1)+sy)){
¡¦
¡¦
¡¦
> BitBlt hdc11, 0, 0, 1, wsy, hdcScreen, wx2,wy1, SRCCOPY
> }
> }
>
¢¬¤Þ¤Ç¤ò/**/¤Ç¥³¥á¥ó¥È¥¢¥¦¥È¤·¤Æ»î¤·¤ÆÍߤ·¤¤


title¤¬¹¹¿·¤µ¤ì¤Ê¤¤¤È¤«À¨¤¯ÃÙ¤¤¾ì¹çÁöººÀþÂÔ¤Á¤¬¾å¼ê¤¯¤¤¤Ã¤Æ¤Ê¤¤²ÄǽÀ­¡¦¡¦¡¦



_hamyuu

¥ê¥ó¥¯

2013/4/3(Wed) 22:12:40|NO.53412

¤«¤Ê¤êÊÖ»öÃÙ¤ì¤Á¤ã¤Ã¤Æ¤¹¤ß¤Þ¤»¤ó¡ª
¤ä¤Ã¤Æ¤ß¤Þ¤·¤¿¡£

¤È¤ê¤¢¤¨¤º¥¿¥¤¥È¥ëÆþ¤ì¤¿¤À¤±¢­
https://www.dropbox.com/s/3a0pqnn1hwow350/capture2-a.mp4
Æ°¤­¤¬¡¦¡¦£÷

¥³¥á¥ó¥È¥¢¥¦¥È¤¹¤ë¤È¤³¤ó¤Ê´¶¤¸¤Ë¢­
https://www.dropbox.com/s/oq0qwilblce7611/capture2-b.mp4
¥¹¥à¡¼¥º¤Ë¤Ê¤Ã¤¿¡ª



²Ë¿Í

¥ê¥ó¥¯

2013/4/3(Wed) 22:58:46|NO.53416

Êó¹ð¤¢¤ê¤¬¤È¤¦
>¤È¤ê¤¢¤¨¤º¥¿¥¤¥È¥ëÆþ¤ì¤¿¤À¤±¢­
¥¦¥£¥ó¥É¥¦ÎÙÀܤ¹¤ë¥É¥Ã¥È¤Î¥Á¥§¥Ã¥¯¤¬¾å¼ê¤¯Æ°¤¤¤Æ¤Ê¤¤¤Î¤Ï³Î¼Â¤«¤Ê¡¦¡¦¡¦
¸åloopcnt¤ÎÁý²Ã¤âÃÙ¤¤¤«¤éGetRasterStatus¤Î¤È¤³¤í¤Ç¾å¼ê¤¯¤¤¤Ã¤Æ¤Ê¤¤¤Ê¡¦¡¦¡¦

>¥³¥á¥ó¥È¥¢¥¦¥È¤¹¤ë¤È¤³¤ó¤Ê´¶¤¸¤Ë¢­
ȾƩÌÀ¤ÎÇ»Å٤DZƤÎÇ»¤µ¤âÊѤ뤷
¥¦¥£¥ó¥É¥¦¤Î±Æ¤Î³°Â¦¤ò¥Á¥§¥Ã¥¯¤¹¤ë¤°¤é¤¤¤·¤«¤Ê¤¤¤«¡¦¡¦¡¦
¤Æ¤«¡¢¥¦¥£¥ó¥É¥¦ÈϰϤ­¤Ã¤Á¤êÀÚ¤ê¼è¤Ã¤Æ¤â±Æ¤¬»Ä¤Ã¤Á¤ã¤¦¤·¡¦¡¦¡¦

¤½¤¦¤¤¤ä±Æ¤ÎÉôʬ¤òGetPixel¤¹¤ë¤È±Æ¤ò´Þ¤Þ¤Ê¤¤¤Î¤«¤Ê¡©



_hamyuu

¥ê¥ó¥¯

2013/4/4(Thu) 00:48:31|NO.53418

GetPixel¤¹¤ë¤È±Æ¤Î¿§¤â¼èÆÀ¤·¤Á¤ã¤¤¤Þ¤¹¤Í¡£
¼«Ê¬¤Ë¤Ï¼Â¸³¤¹¤ë¤³¤È¤¯¤é¤¤¤·¤«¤Ç¤­¤½¤¦¤Ë¤Ê¤¤...



¤¢¤¤¤¦¤¨»Ò

¥ê¥ó¥¯

2013/4/4(Thu) 03:39:03|NO.53420

¤ª¤ª¡Ä¤Ê¤ó¤À¤«´èÄ¥¤Ã¤Æ¤¤¤¿¤À¤¤¤Æ¤Þ¤¹¤Í
ÀµÄ¾¤Ê¤Ë¤¬¤Ê¤ó¤À¤«¥µ¥Ã¥Ñ¥ê¤Ç¤¹£÷

NO.53342¤ËNO.53352¤òŬÍѤµ¤»¤Æ¼Â¹Ô¤·¤¿¤È¤³¤íÈæ³ÓŪ¥¹¥à¡¼¥º¤ËÆ°ºî¤¤¤¿¤·¤Þ¤·¤¿¡£



²Ë¿Í

¥ê¥ó¥¯

2013/4/4(Thu) 22:15:55|NO.53444

Êó¹ð¤¢¤ê¤¬¤È¤¦

>GetPixel¤¹¤ë¤È±Æ¤Î¿§¤â¼èÆÀ¤·¤Á¤ã¤¤¤Þ¤¹¤Í¡£
¼þÊդΥɥåȤò¥³¥Ô¡¼¤·¤¿¤È¤­¤ÈGetPixel¤Ç¥Á¥§¥Ã¥¯¤·¤¿¤È¤­¤Ç¿§¤¬ÊѤäƤë¤Î¤«¤Ê¡¦¡¦¡¦

>NO.53342¤ËNO.53352¤òŬÍѤµ¤»¤Æ¼Â¹Ô¤·¤¿¤È¤³¤íÈæ³ÓŪ¥¹¥à¡¼¥º¤ËÆ°ºî¤¤¤¿¤·¤Þ¤·¤¿¡£
¤ä¤Ã¤Ñ¤ê±Æ¤ÎÉôʬ¤â¥¦¥£¥ó¥É¥¦¤È¤·¤Æ½èÍý¤·¤Ê¤¤¤È¥À¥á¤Ê¤ó¤À¤Í¤§

¤Ç¤â¡¢·ë¶ÉDWM¤ÎƱ´ü¤Î¥¿¥¤¥ß¥ó¥°¤È²èÌ̤¬³ÎÄꤹ¤ëÍ×ÁǤ¬Ê¬¤«¤é¤Ê¤¤¤«¤é
¤³¤ÎÊýË¡¤¸¤ãÅÀÌǤòËɤ°¤Î¤Ï̵Íý¤À¤Ê¡¦¡¦¡¦



ONION software Copyright 1997-2023(c) All rights reserved.