Page 2 of 2
Re: PlayMovie() LinkerError
Posted: Sat Jan 03, 2015 6:16 pm
by heartbone
Shardik wrote:So you installed three new libraries. Did you also install the library "mesa-vdpau-drivers"? Without the drivers from this library your observed behaviour is typical...
You should also check whether the library "libvdpau1" is installed. VDPAU (
Video
Decode and
Presentation
API for
Unix) and its drivers from "mesa-vdpau-drivers" are essential together with the different libxine2 libraries to display videos using PB commands.
In order to help you further you should follow these steps:
- Start my example program from the PB IDE (to download one of the two videos into your /tmp folder) and terminate it.
- Start my example program from the console using the PB compiler (please change the path to your PB installation folder and the path where you saved my example program together with its name):
> export PUREBASIC_HOME=/home/shardik/PureBasic/5.31
> export PATH=$PUREBASIC_HOME/compilers:$PATH
> pbcompiler /home/shardik/Download+PlayMovie.pb
Now you should see error messages in your console which you should post in this thread and then I can try to help you further...

That was an embarrASSing public brain fart.
After I installed the "mesa-vdpau-drivers" library, the movie playback started working!
Thanks for your expert diagnosis
Shardik, it is much appreciated.
Re: PlayMovie() LinkerError
Posted: Sat Jan 03, 2015 6:26 pm
by Shardik
heartbone wrote:After I installed the "mesa-vdpau-drivers" library, the movie playback started working!
I am glad it's now working for you...

Re: PlayMovie() LinkerError
Posted: Sun Jan 04, 2015 3:17 pm
by Vera
Shardik wrote:I am very sorry but I think that it will be very difficult if you are still running PB 4.51 on OpenSuSE 11.1 x86
I'm about to return to my now repaired PC and than doing that big step to PB 5.31, but trying to stick with Suse 11.2 if possible.
But to give some feedback.
Your updated test-code now also downloads the files for me.
Doing some researches it looked to me as if the libvdpau_r600 came with Suse 12 and dared not to install it. Checking xine again, I found the devel-packages were missing and installed those.
And that was successful in the way that the linker errors don't apear anymore and your code now fully runs for me. With mpg LoadMovie fails, but avi is loaded ... only it wouldn't play and just display an artefact picture.
But playing sound via Movie does work now

... and with that a further punching-contribution.
Hoping to be likewise successfull with PlaySound I installed all missing SDL-dev packages, but that didn't work out.
And while looking for further hints I crossed another thread where you already helped
uwekel to figure out
which libraries would be needed on Fedora 19 to PlayMovie which is worth redarding:
-
Movie example does not work on Linux
Thanks for your proposal - I merged it with mine.
and congrats to Mr heartbone
cheers ~ Vera
Re: Necessary libraries to PlayMovie()
Posted: Sat Feb 28, 2015 3:00 pm
by John Duchek
This stream addresses long standing problems I have seen with pure under linux. I am running Fedora 21 64 bit. As I read through here I am trying to install various codecs and programs to get linux to play video properly. As I do, I am noting a few things. On installing the gstreamer codecs in fedora, they are separated into 'free' and non-free versions. The free versions are usually in the normal repository, but the non-free versions are in the rpmfusion-nonfree repository. If one hasn't installed the rpmfusion repositories, they are unavailable, and of course not installed. I am working on getting them all installed now.
Thanks,
John
Re: Necessary libraries to PlayMovie()
Posted: Sun May 21, 2023 1:46 am
by emm
Hi
It's an old thread but as the issue experienced maybe related I post here.
GOAL: I try to play a mp4 video stored online
Environment:
I use ubuntu 22.04 on a 64 bit intel CPU on a PC. All videos play well on VLC and online.
I don't know how to install codecs on linux.
I searched online but found many 'solutions' which don't provide a way to test if they work as using VLC use its own codecs if I understand well.
I use PB 6.02 LTS free edition using this code:
Code: Select all
InitMovie()
file$ = "/home/manu/Downloads/1.mp4"
-> *** If LoadMovie(0, file$)
OpenWindow(0, #PB_Ignore, #PB_Ignore, MovieWidth(0), MovieHeight(0), "movietest")
PlayMovie(0, WindowID(0))
While MovieStatus(0) <= 0
Delay(10)
Wend
Repeat
Select WaitWindowEvent(100)
Case #PB_Event_CloseWindow
Break
Case 0
If Not MovieStatus(0)
Break
EndIf
EndSelect
ForEver
EndIf
I traced the code and see it exits at the -> *** part.
I can play the file with VLC and the permission enable reading for the user running PB so I assume the loadMovie function exits due to not supporting the format.
The format is:
I tried with avi file and mpeg file too and same issue.
The documentation of PB don't tell anything about Linux:
https://www.purebasic.com/documentation ... index.html
Questions:
1- How could I list all the codecs installed on this linux version?
2- How to list all codecs supported by PB 6.02 LTS via code?
3- How to get more info from LoadMovie about the failure?
Thanks
Re: Necessary libraries to PlayMovie()
Posted: Sun May 21, 2023 9:13 am
by mk-soft
Possibly a package or app is still missing
Simple Install of Purebasic ...
* Movie / Ubuntu
sudo apt install xine*
* Movie / Raspberry PI Desktop
sudo apt-get install libvlc-dev