Hi.
I’m trying to play remote video: (Solar2D Documentation — API Reference | Libraries | native | newVideo)
My solar2d is newest, (2024.3703) my system is Linux Mint 19.3
I get error:
ERROR: Runtime error
/root/parts/solar2d/src/platform/resources/init.lua:988: table index is nil
stack traceback:
/root/parts/solar2d/src/platform/resources/init.lua:988: in function 'newVideo'
/home/michal/Documents/Solar2D Projects/AppTV/main.lua:9: in main chunk
Theres code: (error means 1’st line [newVideo()])
local video = native.newVideo( display.contentCenterX, display.contentCenterY, 640, 360 )
local function videoListener( event )
print( "Event phase: " .. event.phase )
if event.errorCode then
native.showAlert( "Error!", event.errorMessage, { "OK" } )
end
end
-- Load a remote video
video:load( "https://coronalabs.com/video/bbb/BigBuckBunny_640x360.m4v", media.RemoteSource )
-- Add video event listener
video:addEventListener( "video", videoListener )
-- Play video
video:play()
What can it be? What shall I do?
Thanks
Mike.