明るさの調整がうまく行きません。
キーボード E/R で明るさを下げ/上げするようにコマンドを送っていますが、
手持ちのAVIファイルでテストしていますが、変化がありません。
というか明るさの取得もできていないです。なので値の範囲もわかりません。
mciコマンドが違うのか、対応していないのか…
以下テストスクリプトです。
よろしくお願いします。
//mciテスト new_winx = 320 : new_winy = 240 screen 2,ginfo_dispx,ginfo_dispy,,,,new_winx,new_winy oncmd gosub *win_resize , 0x00005 //ウィンドウサイズ変更 onkey gosub *key_input onexit *BeforeClose keycode1 = 0 : key_shift = 0 : key_ctrl = 0 val_brightness = 1000 *open1 dialog "",16,"" if stat!=1 : stop filenm=refstr *open2 mci "open "+filenm+" alias abc style child parent "+hwnd mes "open stat : " + stat mci "put abc window at 10 20 "+(new_winx-20)+" "+(new_winy-30) mci "play abc" mci "set abc time format milliseconds" mci "status abc length" : time_length = stat wait 250 repeat mci "status abc position" color 255,255,255 : boxf 0,0,200,18 color 0,0,0 : pos 0,0 : mes "" + (double(stat)/1000) + " / " + (double(time_length)/1000) mci "status abc mode" : if refstr="playing" : stat_play=1 : else : stat_play=0 mci "status abc brightness" title "brightness : " + stat + refstr wait 10 loop stop *win_resize new_winx = ginfo_winx : new_winy = ginfo_winy mci "put abc window at 10 20 "+(new_winx-20)+" "+(new_winy-30) return *key_input keycode1 = wparam getkey key_shift,16 : getkey key_ctrl,17 if keycode1=37 : time_seek=-5000-(key_shift*10000 + key_ctrl*5000) : gosub *seek1 if keycode1=39 : time_seek=5000+(key_shift*10000 + key_ctrl*5000) : gosub *seek1 if keycode1=32 : gosub *playpause if keycode1=82 : val_brightness += 10 : mci "setvideo abc brightness to "+val_brightness if keycode1=69 : val_brightness -= 10 : mci "setvideo abc brightness to "+val_brightness return *playpause mci "status abc mode" if refstr="playing" { mci "stop abc" } else { mci "play abc" } return *seek1 mci "status abc position" time_seek += stat if time_seek < 0 : time_seek = 0 mci "seek abc to " + time_seek if stat_play=1 : mci "play abc" ;再生状態の復帰(seekすると止まる) return *BeforeClose mci "close all" end