I made a project that plays a video file inside a panel boundary (w/o any video player apps), using Cheat Engine Lua script + mciSendString winmm.dll, it's work fine. The problem is I want to fit video size to panel size. I have this part of VB script:
Public Function getDefaultSize() As Size
'Returns the default width, height the movie
Dim c_Data As String = Space(128)
mciSendString("where movie source", c_Data, 128, 0)
Dim parts() As String = Split(c_Data, " ")
Return New Size(CInt(parts(2)), CInt(parts(3)))
End Function
and I want ported that script to CE Lua, so far:
function getDefaultSize(Size)
local c_Data = string.rep(" ",128) -- Space(128)
mciSendString("where movie source", c_Data, 128, 0)
--- this part need adapting to Lua
-- Dim parts() = Split(c_Data, " ") --string
-- return New Size(CInt(parts(2)), CInt(parts(3)))
end
Any solutions?