[PATCH] Android: glretracer for Android.

Nigel Stewart nigels.com at gmail.com
Wed Jul 17 05:45:05 PDT 2013


Concerning Android tree versus NDK.  I see apitrace as very user-space
oriented, what I was considering for Regal was to build a
non-functional waffle .so for linking, and assume that the real waffle
is already installed on the device.  Does that same assumption make
sense for apitrace also?

- Nigel

On Wed, Jul 17, 2013 at 6:08 AM, Juha-Pekka Heikkilä
<juha-pekka.heikkila at linux.intel.com> wrote:
> Hei,
>
> I'm back from vacation being lot more tan :) Thanks for all the feedback
> while I was away!
>
> Nigel, did you get things working? In Waffle directory there is /example
> folder where if you do "mm" and then "adb remount" and "adb sync" you will
> get small program called "gl_basic" into your device. This is very simple
> test software for Waffle which should show in top left corner of the
> screen red, green and blue boxes one after each other. If this work then
> Waffle work ok. Good command line for running gl_basic would for example
> be "gl_basic android gles2". I have previously successfully run Waffle on
> ICS and JB&JBMR2 with PVR and Mesa drivers -- the driver underneath
> Surfaceflinger should not matter so much I think. Retracer I have now run
> only on top of JBMR2 with Mesa. In any case you should have seen some
> window with Waffle, the window size with retracer coming from the trace
> file.
>
> I am currently fixing things Alexander pointed out for me. I am also
> pondering what should I do with the issue where now thanks to Waffle I am
> adding requirement for full Android tree instead of just the ndk. It would
> of course be possible to change from cmakefiles those 'if (ANDROID)' which
> I added to check for if Waffle was found but don't know if it is worth the
> effort?
>
> /Juha-Pekka
>
>
> On Tue, July 9, 2013 8:27 pm, Chad Versace wrote:
>> (Apologies for the delayed reply. Vacation + a cold recently).
>>
>> When using GLX and X11/EGL, I always see the window. But, I can't
>> vouch for Android. To my knowledge, Juha-Pekka is the only one
>> who has been working on Waffle for Android. I've never ran it on Android,
>> and no longer have my dev environment set up to do that.
>>
>> There is a call to setLayer() in droid_surfaceflingerlink.cpp. Maybe the
>> secret magic should be there, but I'm just guessing.
>>
>>
>> On 07/03/2013 11:29 AM, Nigel Stewart wrote:
>>> Hi all,
>>>
>>> I got as far as a working binary for Android 4.2 using waffle.
>>> For some reason I don't see the OpenGL window on the screen,
>>> I guess it might need some help to be top-most, or something
>>> like that.
>>>
>>> Chad,
>>>
>>> Heard of that happening for other waffle deployments?
>>>
>>> - Nigel
>>>
>>>
>>> On Mon, Jul 1, 2013 at 5:21 PM, Nigel Stewart <nigels.com at gmail.com>
>>> wrote:
>>>> Ah, thanks for the clarifications.
>>>>
>>>> I filed a github pull request for building apitrace with cmake for
>>>> Android.
>>>> https://github.com/apitrace/apitrace/pull/155
>>>>
>>>> It's a small subet of Juha-Pekka's patch set.
>>>> It was puzzling that I couldn't seem to build master branch of
>>>> apitrace for Android on Ubuntu 12.04, cmake 2.8.7.
>>>> But it's possible I'm still missing something important... :-)
>>>>
>>>> - Nigel
>>>>
>>>> On Mon, Jul 1, 2013 at 3:33 PM, Chad Versace
>>>> <chad.versace at linux.intel.com> wrote:
>>>>> Waffle is intended to built in the Android source tree along with the
>>>>> rest of the system. It's not possible to do otherwise since it
>>>>> depends on APIs, internal to the Android system and not shipped by the
>>>>> NDK,
>>>>> for communicating with the compositor.
>>>>>
>>>>> To build Waffle, clone the source to $ANDROID_TOP/external/waffle and
>>>>> call `mmm external/waffle`.
>>>>>
>>>>> Unlike Waffle, APITrace is intended to be built outside the Android
>>>>> source
>>>>> tree because it relies only on NDK APIs. APITrace has some good docs
>>>>> on how
>>>>> to do that; just to search INSTALL.markdown for Android. Using
>>>>> APITrace on
>>>>> Android is tricky, but not too tricky; read Dalvik.markdown for
>>>>> instructions.
>>>>>
>>>>> I don't recommend trying to use APITrace on Android < 4.0.
>>>>>
>>>>> As for the most important part, how to use Juha's glretracer on
>>>>> Android, I
>>>>> don't how to do that. You're on your own when solving that until Juha
>>>>> returns
>>>>> from vacation.
>>>>>
>>>>>
>>>>> On 07/01/2013 12:27 PM, Nigel Stewart wrote:
>>>>>>
>>>>>> Hi,
>>>>>>
>>>>>> Any tips for building Waffle and/or apitrace for Android via the
>>>>>> Android.mk or cmake?
>>>>>>
>>>>>> I don't think I'm savvy enough with either of these build systems to
>>>>>> troubleshoot my way to a working binary.
>>>>>>
>>>>>> - Nigel
>>>>>>
>>>>>> On Mon, Jul 1, 2013 at 11:46 AM, Chad Versace
>>>>>> <chad.versace at linux.intel.com> wrote:
>>>>>>>
>>>>>>> On 06/27/2013 04:17 AM, Juha-Pekka Heikkila wrote:
>>>>>>>
>>>>>>>
>>>>>>>> I limited glws_waffle.cpp strictly to Android only but it probably
>>>>>>>> would
>>>>>>>> start to work quite easily also on desktop. Before Waffle port of
>>>>>>>> glretrace
>>>>>>>> for desktop could work Waffle need waffle_window_resize API call to
>>>>>>>> be
>>>>>>>> implemented for other plarforms than Android.
>>>>>>>>
>>>>>>>> To build for Android Waffle need to be build first.
>>>>>>>> Waffle can be obtained from:
>>>>>>>> http://cgit.freedesktop.org/~chadversary/waffle/
>>>>>>>>
>>>>>>>> Make sure these patches are in place for Waffle before compiling
>>>>>>>> (at time of writing they are still stuck on the list)
>>>>>>>> http://lists.freedesktop.org/archives/waffle/2013-June/000167.html
>>>>>>>> http://lists.freedesktop.org/archives/waffle/2013-June/000168.html
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> These two patches are now committed to Waffle master branch. There's
>>>>>>> no longer a need to apply them by hand.
>>>>>>>
>>>>>>>
>>>>>>> _______________________________________________
>>>>>>> apitrace mailing list
>>>>>>> apitrace at lists.freedesktop.org
>>>>>>> http://lists.freedesktop.org/mailman/listinfo/apitrace
>>>>>>
>>>>>>
>>>>>>
>>>>>
>>>
>>
>> _______________________________________________
>> apitrace mailing list
>> apitrace at lists.freedesktop.org
>> http://lists.freedesktop.org/mailman/listinfo/apitrace
>>
>


More information about the apitrace mailing list