cannot open vlc from matlab using system command
3 vues (au cours des 30 derniers jours)
Afficher commentaires plus anciens
cannot open vlc from matlab using system command i used this version of matlab: MATLAB Version: 9.0.0.341360 (R2016a) MATLAB License Number: rutracker.org Operating System: Linux 4.13.16-100.fc25.x86_64 #1 SMP Mon Nov 27 19:52:46 UTC 2017 x86_64 Java Version: Java 1.7.0_60-b19 with Oracle Corporation Java HotSpot™ 64-Bit Server VM mixed mode
the code is as follows: >>[status, msg] = system('"/usr/bin/vlc" test.y4m &') Result given is as follows:
status =
0
msg =
''
My expectation:
Invoking a VLC that will automatically play the file. But the Vlc is not displaying.
What is the problem pls. thanks
4 commentaires
Rik
le 6 Mai 2018
Please don't use the 'answer' field for comments.
You can use the exact code Chad posted here. You used double quotes (") inside the command. That is not usually needed under Unix systems. The system function should send the entire string (so all text between the single quote marks) to the terminal. If the code works there, it should work in this function as well.
Walter Roberson
le 8 Mai 2018
The "" are not a problem in Unix. Using "" around a path is still the general form on Unix, as paths on Unix can contain spaces and other special characters, Using '' inside would be more robust but is a bit of a nuisance
[status, msg] = system('''/usr/bin/vlc'' test.y4m &')
Réponses (4)
Wick
le 6 Mai 2018
[status, msg] = system('/usr/bin/vlc test.y4m &')
Note the single quotes on either end of the command to be sent to the prompt. In your statement of the problem you have single & double quotes. In your above answer you have no quotes at all.
Highlight, copy, and paste what I wrote above into MATLAB and see if that works. If it doesn't, highlight and copy everything inside of the single quotes (not including those quotes) and paste that to a terminal. If that doesn't work, the problem is not in MATLAB but in the UNIX command.
Nagarjuna Manchineni
le 8 Mai 2018
Hi Ezekiel,
I was able to launch the VLC player and play the video successfully by using the 'system' command on MATLAB R2018a. Can you try once using that release?
0 commentaires
Voir également
Catégories
En savoir plus sur Startup and Shutdown dans Help Center et File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!