My C++ application calls VLC as a subprocess. Is there a way to avoid having the GUI pop-up? I am looking for a Mac and a Windows solution. Hackish workarounds are welcome too.
PS: I know there is such a thing as cvlc (command-line version of VLC), but I haven't found any builds for it online. You do get it when you make the build yourself, but that hasn't worked out yet on my Snow Leopard machine. I also need a Windows version, but I don't feel courageous enough to attempt making a VLC build myself on this platform.
Solved
All I had to do was add the "-I dummy" parameters.
I found the answer. VLC allows you to start without GUI by using:
VLC -I dummy
Starts the "dummy" interface.
VLC -I rc
Starts the "remote control" interface, which allows you to send commands using the stdin channel.
There are a few options in this thread
When you create the VLC instance using the libvlc_new function you have a VLC arguments to not display VLC interface. See this small example.
Related
I've used YouTube-dl successfully on my mac for quite some time.
I downloaded YouTube-dl.exe (after downloading Microsoft Visual C++ I was told a newer version already exists on my computer - it also says Python is not required), but when I launch the executable, it briefly opens a command line window but then closes immediately and nothing else happens. I've tried Googling and even went to the IRC support chat (who turned out to be more rude than helpful) to no avail. Any ideas what to do?
youtube-dl is a command-line application. To use it directly, start a terminal windows by pressing Win+R, and entering cmd. To get to know the command-line interface, you probably want to consult a tutorial.
If you were looking for a graphical application, use one of the graphical frontends instead; for instance, youtube-dlg.
I'm using Debian Jessie and dmesg | grep video returns:
[ 22.280407] Linux video capture interface: v2.00
[ 22.790704] uvcvideo: Found UVC 1.00 device Lenovo EasyCamera (13d3:5170)
[ 22.796546] usbcore: registered new interface driver uvcvideo
The example compiles fine but upon launch i get a dialog telling me that the camera service is missing. I'm using Qt 5.5.0. This question points to a similar issue but it's for windows. Also I've installed Qt using the installer provided at it's web site. I've tested my webcam with Cheese application and it works but QCameraInfo::availableCameras() returns nothing.
I don't know if this is a definitive answer, but in my experience the dreaded "camera service is missing" comes down to exactly what the message says; for some reason the media back-end that Qt uses to get video input from a camera is broken or miss-configured in some way. In my case I had this problem in the following situations:
1. Building Qt from source
Qt build system SILENTLY DISABLES FEATURES if you don't have all the dependencies that it requires to include them in the build. Make sure to read this official article very carefully for your platform. I lost count of the times this has ruined my <insert favourite period of time such as day/week/year here >, and not only for the multimedia module...
2. Missing some gstreamer packages on my Ubuntu
I develop for Linux & Debian mostly, and on those platforms Qt depends on gstreamer backend. gstreamer is basically a plugin architecture in the core with every single feature added as plugins, and with endless possibilities of manual intervention through configuration files. See where is this is going? Clue: make sure you have all the plugins you want installed and configured properly. Here is a link to some gstreamer tools you can use. Same probably goes for other back-ends on other platforms.
And a pro tip in the end: Since both Qt5.5 gstreamer0.1 (old) and gstreamer1.0 (new) are supported as back-ends, and since Qt5.6 the new one is default. This will give you some room for experimenting, for example if the old does not work, you can try the new etc.
Hope this was useful!
Is there some alternative IDE for developing for Adruino
I tried to use Eclipe and Arduino IDE, but i am fan of Sublime Text.
So, can i use it for programming for Arduino or Seeeduino in Linux?
I mean i must download some libraries and plugged in to my source code?
I use a make file, to compile and upload programs to Arduino. You can use any IDE you like (sublime Text in your case and vim in my case)
make upload
make screen # to view the serial monitor
You could use AVR Studio http://www.atmel.com/microsite/atmel_studio6/
Here is a tutorial on to use it with Arduino:
http://www.engblaze.com/tutorial-using-avr-studio-5-with-arduino-projects/
Use whatever editor you feel like and build/upload from the command line. Personally, I use arscons to pull this off. You'll need SCons, of course. Building is as simple as running
$ scons
$ scons upload
at the command line. There are a lot of other options in the SConstruct file provided by the arscons project, such as specifying the location for extra libraries; the type of Arduino you're building for; and which USB port you're plugged into. I wasn't able to get wireless programming for an Arduino Fio working with it, but it works great with the Arduino Mega and Uno.
As others have pointed out, you can use Arduino with any IDE if you set up the toolchain properly. If you're looking for a list of possibilities, as well as documentation on how to start on specific platforms, check out the Development Tools section of the Arduino Playground.
To use with Sublime Text, you could adapt one of the existing command-line build scripts to work with Sublime's build system.
It's my first device driver for Windows and I followed the step-by-step instructions at http://www.adp-gmbh.ch/win/misc/writing_devicedriver.html but my device driver doesn't start at windows boot and also the event viewer shows an error and when I click on the error in the event viewer the thing crashes. When I start the driver manually after windows boot it works. Is this tutorial incomplete? I already found the sources in the internet but not at this site and I think I found an error in his sources, too, he just forgot to add a header file to the "Writing Events from a Device Driver. I can compile it without any errors in DDK.
Yes, this tutorial is incomplete and very old. Install WDK and follow one of WDK samples, written using plain WDM, or better, KMDF. Driver installation should be done using .inf file, and not by manual Registry editing.
If you still want to know why this driver doesn't start, debug it. Possibly its DriverEntry or CreateCamel function fail from some reason.
Another thing you can do without debugging, is to add a lot of KdPrint statements to the driver, and watch them using WinDbg, or DebugView.
I'm trying to develop a GUI application for an embedded platform, without any windowing whatsoever and I'm doing that with DirectFB, and it suits my needs very fine.
Since the embedded I develop for is not that powerful, I would really like to try to develop on my own Ubuntu desktop. The problem is Framebuffer is conflicting with X.org causing me to leave the whole desktop, and shutdown X.org just to see the result of my changes.
Is there a good framebuffer simulator that suits my needs? Qt has one, called QVFb, but it only works for developing Qt apps, and the VNC back-end of DirectFB always crash.
So, any ideas?
DirectFB has a X11 backend.
$ sudo apt-get install libdirectfb-extra # for Debian and Ubuntu, anyhow
$ cat ~/.directfbrc
system=x11
force-windowed
Also, DirectFB has a SDL backend, and SDL has a X11 backend. Also, SDL has a GGI backend, and GGI has an X backend. That's a bit circuitous, but it should work :)
I tested it with
$ SDL_VIDEODRIVER=directfb ffplay some_movie.avi
and got a nice 640x480 window with media playing and DirectFB handling layering and input, so I'm sure this works.
The three previous answers are all good suggestions. I'd suggest trying ephemient's answer because it's the simplest. For more details on setting up your .directfbrc file, check out "man directfbrc".
One other possibility would be to switch from X to another virtual terminal (using CTRL+ALT+F1), run your directfb program, and then switch back X (using CTRL+ALT+F7).
I came to use ephemient's solution to run DirectFB applications inside a chroot environment (target filesystem as a courtesy of buildroot) in addition to Xnest, a separate X environment which runs in a window of the current X.
$ Xnest -ac :1 &
$ cd $TARGET_DIR # into the target file system root
$ DISPLAY=:1 sudo chroot . usr/bin/df_neo
This way you can assure not only your directfb installation is correct, but also all the required dependencies are installed inside the chroot'ed file system.
You could use Moblin Image Creator to create a disk image of Moblin, which you can then run inside a VM like QEMU. You can then test your DirectFB application inside the virtual machine.
You could develop (i.e. edit and compile) your application on your Ubuntu desktop, and test your application on the embedded platform that it is intended to run on.
If the embedded platform supports networking, you might be able to reduce the length of your edit-compile-test loop by running the application directly from an NFS share.
Here is a nice example with qemu and directFB:
https://bootlin.com/blog/qemu-arm-directfb-demo/