Thursday, October 5, 2017
Spice for Mac
When running autoreconf -vfi as:
PKG_CONFIG_PATH=/usr/local/opt/jpeg-turbo/lib/pkgconfig:/usr/local/opt/libjpeg-turbo/lib/pkgconfig:/usr/local/Cellar/openssl/1.0.2l/lib/pkgconfig:$PKG_CONFIG_PATH CFLAGS=-ObjC ./configure
I'm still getting
autoreconf: running: aclocal --force -I m4 Use of uninitialized value $msg in concatenation (.) or string at /usr/local/Cellar/autoconf/2.69/bin/autom4te line 1026. Use of uninitialized value $stacktrace in pattern match (m//) at /usr/local/Cellar/autoconf/2.69/bin/autom4te line 1026. unknown channel m4trace: -1- AS_VAR_APPEND(ac_configure_args, " '$ac_arg'") at /usr/local/Cellar/autoconf/2.69/share/autoconf/Autom4te/Channels.pm line 638. Autom4te::Channels::msg('m4trace: -1- AS_VAR_APPEND(ac_configure_args, " '$ac_arg'")x{a}', undef, 'warning: ', 'partial', 0) called at /usr/local/Cellar/autoconf/2.69/bin/autom4te line 1026 aclocal: error: echo failed with exit status: 1 autoreconf: aclocal failed with exit status: 1
This looks a bit similar to the bug I fixed for autoconf. If that's the case, that's annoying, as it implies that rebuilding won't work without some proper patch to autom4ke
Also spent a bit of time trying to figure out why libjpeg-turbo no longer acts as a decent replacement for libjpeg. Probably something bogus with Homebrew there.
Laptop setup
Trying to improve the setup for the test latop.
Came across this article suggesting that remote desktop for Wayland will soon be there.
3D acceleration
Trying to understand how far 3D acceleration goes on various configurations. The first test was easy:
gst-launch-1.0 -v playbin uri=file:///data/video/test.mp4
That initially failed with
Missing element: H.264and
Missing element: MPEG-4 AAC decoder. I can never remember where those are, so I had to actually google it. Answer is gstreamer1-libav. Talk about an obvious way to name H264...
But then, what is interesting is that if I run the same command on macOS, I not only get sound (which is missing with spicy), I also get very low CPU utilization (around 16%; by contrast, spicy is at around 70%). So clearly H264 decoding is hardware accelerated with gstreamer on macOS. Now, that's good news. But that means I need to understand why spicy H264 decoding is so slow. We may be setting the pipeline slightly wrong.
The output of the gst-launch command is:
Setting pipeline to PAUSED ... Pipeline is PREROLLING ... Got context from element 'sink': gst.gl.GLDisplay=context, gst.gl.GLDisplay=(GstGLDisplay)"(GstGLDisplayCocoa) gldisplaycocoa0"; Redistribute latency... Got context from element 'playsink': gst.gl.GLDisplay=context, gst.gl.GLDisplay=(GstGLDisplay)"(GstGLDisplayCocoa) gldisplaycocoa0"; Redistribute latency... Pipeline is PREROLLED ... Setting pipeline to PLAYING ... New clock: GstAudioSinkClock ^Chandling interrupt. Interrupt: Stopping pipeline ... Execution ended after 0:00:04.324361000 Setting pipeline to PAUSED ... Setting pipeline to READY ... Setting pipeline to NULL ... Freeing pipeline ...
So I have to look for a gldisplaycocoa0?
Another thing that I don't really understand is that the video is very small on macOS:
whereas it is much larger on Linux:
Not sure why. The screen I am showing this on is not a Retina screen, but the laptop is a Retina MacBook, so maybe a High-DPI scaling issue? Or more likely an issue with setting the size of the window, since the initial aspect ratio is all wrong.