Movies on Lubuntu 22.10

Linux specific forum
dmontaine
User
User
Posts: 45
Joined: Tue Jun 04, 2019 1:03 pm

Movies on Lubuntu 22.10

Post by dmontaine »

I am running lubuntu 22.10 beta. Movies do not play unless you run 'sudo apt install xine*'. Tested with sample avi and mp4 movies and both worked.

Installing xine is not listed in the INSTALL document.

I used the movie example program. I had to modify the program to include mp4 movies in the selection dialog.
User avatar
mk-soft
Always Here
Always Here
Posts: 5335
Joined: Fri May 12, 2006 6:51 pm
Location: Germany

Re: Movies on Lubuntu 22.10

Post by mk-soft »

My Projects ThreadToGUI / OOP-BaseClass / EventDesigner V3
PB v3.30 / v5.75 - OS Mac Mini OSX 10.xx - VM Window Pro / Linux Ubuntu
Downloads on my Webspace / OneDrive
dmontaine
User
User
Posts: 45
Joined: Tue Jun 04, 2019 1:03 pm

Re: Movies on Lubuntu 22.10

Post by dmontaine »

Here is the example movie program with a different coding style. Tested on Lubuntu 22.10 beta with xine installed. Tested with the sample video files at https://file-examples.com/index.php/sample-video-files/.

Code: Select all

; --------------------------------------------------------
;
;   PureBasic - Movie example file
;
;   Original Code: (c) Fantaisie Software
;   Modifications: (c) Donald S Montaine
;---------------------------------------------------------

EnableExplicit

; --------------------------------------------------------
; INITIALIZE VARIABLES
;---------------------------------------------------------

ExamineDesktops()
Define DskWth.i       = DesktopWidth(0)
Define DskHgt.i       = DesktopHeight(0)
Define MovWth.i       = 960
Define MovHgt.i       = 540

Define FileListStr.s  = "Movie files|*.avi;*.mpg;*.mp4|All Files|*.*"
Define FileListCapn.s = "Choose the movie to play"
Define WinTitle.s     = "PureBasic - Movie"

Define ErrTitle.s     = "Error!"
Define ErrNoInit.s    = "Can't initialize movie playback !"
Define ErrNoLoad.s    = "Can't load the movie..."

Define MovieName.s    = ""

;---------------------------------------------------------
;MAIN PROGRAM
;---------------------------------------------------------

If InitMovie() = 0
    MessageRequester(ErrTitle, ErrNoInit, 0)
Else
    MovieName = OpenFileRequester(FileListCapn, "", FileListStr, 0)
    If MovieName
        If LoadMovie(0, MovieName)
            OpenWindow(0, (DskWth/2)-(MovWth/2),(DskHgt/2)-(MovHgt/2), MovWth, MovHgt, WinTitle)
            PlayMovie(0, WindowID(0))
            ResizeMovie(0,0,0,MovWth,MovHgt)
            Repeat
                ;wait until close window event
            Until WaitWindowEvent() = #PB_Event_CloseWindow
        Else
            MessageRequester(ErrTitle, ErrNoLoad, 0)
        EndIf
    EndIf
EndIf
Post Reply