#module
#deffunc mciload str, int
mref file, 32 : mref no, 1
cntno = no
mci "close _" + cntno
strmid i, file, , 2 : int i
if i {
file = "cdaudio!?"
poke file, 8, i + 64
}
mci "open \"" + file + "\" alias _" + cntno
return
#deffunc mciplay str, str, int
mref start, 32 : mref finish, 33 : mref re, 2
if start ! "" : s = " from " + start : else : s = ""
if finish ! "" : s += " to " + finish
if re : s += " repeat"
mci "play _" + cntno + s
return
#deffunc mciend onexit
mci "stop all"
mci "close all"
return
#deffunc mciwinset int
mref id, 0
mref bmscr, 96 + id
mci "window _" + cntno + " handle " + bmscr.13
return
#deffunc mcigetrect val
mref rect, 48
mci "where _" + cntno + " source"
s = refstr
i = 0
repeat 4
getstr s2, s, i, ' '
i += strsize
rect.cnt = 0 + s2
loop
return
#global
dim r, 4
dialog "", 16
if stat = 0 : end
mciload refstr
mcigetrect r
screen 0, r.2, r.3 + 20
mciwinset
mciplay "", ""
pos 0, r.3 : mes "動画情報 横幅:" + r.2 + " 高さ:" +r.3
stop
|