Skip to main content

the avatar of Greek openSUSE Ambassadors

Greek openSUSE community, Translation of openSUSE Weekly news in Greek (issue 205)




Hello everyone!

I am very pleased to announce the new issue (205) of openSUSE Weekly News in Greek.
In this issue you will read about:

* Jos Poortvliet: Calligra…
* The Tumbleweed subforum
* ITworld/Brian Proffitt: SUSE: Global Linux jobs on the rise
* ITWire/Sam Varghese: A tale of two distros: openSUSE and Linux Mint
* Will Stephenson: openSUSE Board Election – My Manifesto

As well as many interesting news about openSUSE and useful advice, which can make our lives easier.

Enough said though... Read more at: http://own.opensuse.gr, http://el.opensuse.org/Weekly_news or www.os-el.gr

We are always looking forward to receiving your comments as well as suggestions regarding things you would like to read about in our next issue.

The openSUSE Weekly News is being translated in the Greek language from issue #150. You can read older translated issues here: http://el.opensuse.org/Κατηγορία:Weekly_news_issues

Enjoy it!
Efstathios Agrapidis (efagra)

the avatar of James Willcox

Using direct textures on Android

I’ve been working at Mozilla on Firefox Mobile for a few months now. One of the goals of the new native UI is to have liquid smooth scrolling and panning at all times. Unsurprisingly, we do this by drawing into an OpenGL texture and moving it around on the screen. This is pretty fast until you run out of content in the texture and need to update it. Gecko runs in a separate thread and can draw to a buffer there without blocking us, but uploading that data into the texture is where problems arise. Right now we use just one very large texture (usually 2048x2048), and glTexSubImage2D can take anywhere from 25ms to 60ms. Given that our target is 60fps, we have about 16ms to draw a frame. This means we’re guaranteed to miss at least one frame every time we upload, but likely more than that. What we need is a way of uploading texture data asynchronously (and preferably quicker). This is where direct textures can help.

If you haven’t read Dianne Hackborn’s recent posts on the Android graphics stack, you’re missing out (part 1, part 2). The window compositing system she describes (called SurfaceFlinger) is particularly interesting because it is close to the problem we have in Firefox. One of the pieces Android uses to to draw windows is the gralloc module. As you may have guessed, gralloc is short for ‘graphics alloc’. You can see the short and simple API for it here. Android has a wrapper class that encapsulates access to this called GraphicBuffer. It has an even nicer API, found here. Usage is very straightforward. Simply create the GraphicBuffer with whatever size and pixel format you need, lock it, write your bits, and unlock. One of the major wins here is that you can use the GraphicBuffer instance from any thread. So not only does this reduce a copy of your image, but it also means you can upload it without blocking the rendering loop!

To get it on the screen using OpenGL, you can create an EGLImageKHR from the GraphicBuffer and bind it to a texture:

#define EGL_NATIVE_BUFFER_ANDROID 0x3140
#define EGL_IMAGE_PRESERVED_KHR   0x30D2

GraphicBuffer* buffer = new GraphicBuffer(1024, 1024, PIXEL_FORMAT_RGB_565,
                                          GraphicBuffer::USAGE_SW_WRITE_OFTEN |
                                          GraphicBuffer::USAGE_HW_TEXTURE);

unsigned char* bits = NULL;
buffer->lock(GraphicBuffer::USAGE_SW_WRITE_OFTEN, (void**)&bits);

// Write bitmap data into 'bits' here

buffer->unlock();

// Create the EGLImageKHR from the native buffer
EGLint eglImgAttrs[] = { EGL_IMAGE_PRESERVED_KHR, EGL_TRUE, EGL_NONE, EGL_NONE };
EGLImageKHR img = eglCreateImageKHR(eglGetDisplay(EGL_DEFAULT_DISPLAY), EGL_NO_CONTEXT,
                                    EGL_NATIVE_BUFFER_ANDROID,
                                    (EGLClientBuffer)buffer->getNativeBuffer(),
                                    eglImgAttrs);

// Create GL texture, bind to GL_TEXTURE_2D, etc.

// Attach the EGLImage to whatever texture is bound to GL_TEXTURE_2D
glEGLImageTargetTexture2DOES(GL_TEXTURE_2D, img);

The resulting texture can be used as a regular one, with one caveat. Whenever you manipulate pixel data, the changes will be reflected on the screen immediately after unlock. You probably want to double buffer in order to avoid problems here.

If you’ve ever used the Android NDK, it won’t be surprising that GraphicBuffer (or anything similar) doesn’t exist there. In order to use any of this in your app you’ll need to resort to dlopen hacks. It’s a pretty depressing situation. Google uses this all over the OS, but doesn’t seem to think that apps need a high performance API. But wait, it gets worse. Even after jumping through these hoops, some gralloc drivers don’t allow regular apps to play ball. So far, testing indicates that this is the case on Adreno and Mali GPUs. Thankfully, PowerVR and Tegra allow it, which covers a fair number of devices.

With any luck, I’ll land the patches that use this in Firefox Mobile today. The result should be a much smoother panning and zooming experience on devices where gralloc is allowed to work.

the avatar of Mauro Parra-Miranda
the avatar of Mauro Parra-Miranda

Mobile SDK 1.8.0.1RC1 (re post)


Hi Titans,

As most of you are aware, the release candidates for both products were initially dropped last week:

Mobile 1.8:

Studio 1.0.7:

We're hoping to go out with GA releases next week, and are currently looking to address any show-stopping issues before that release is final.  To that end, we appreciate your help in installing these latest release candidates, and reporting any issues you may find with them.  To report a bug, please use our community JIRA project, as usual, making sure to provide a small, but complete test case (an app.js and/or the smallest possible set of files necessary to recreate the issue) and conform as much as possible to the JIRA checklist below:


In the Comments section, please make a note that you used the 1.8.0.1 Release Candidate when reporting the bug.  Again, test cases are critical, as they will allow us to quickly home in on the problem.

Thanks for your help, and for letting us help you get your app up and running on 1.8!

the avatar of Mauro Parra-Miranda

Twine

Cuando pense que no me podría sorprender más, el MIT lo logra de nuevo. Tienen que conocer Twine. Básicamente, podrán twittear en el momento que alguno de los sensores detecte movimiento, humedad, presencia de objetos metalicos a la redonda, etc. 

Simplemente increible. Podría twittear cuando el piso debajo de tu platon falso tenga humedad. Muy útil para un Datacenter, por ejemplo. O cuando comience a ser muy caliente. 

Las posiblidades son infinitas. 
the avatar of Mauro Parra-Miranda

the avatar of Han Wen Kam

My openSUSE 12 Journal - 5: Desktop Bits & Bytes

This is week 3 of using 12.1 and still lovin' it.  This journal entry covers a few disparate topics, from wifi to graphics cards, as I go about my daily routine in the office (stuff I actually get paid doing) with openSUSE 12.1 on my Lenovo Thinkpad.


Can't locate your hidden Wifi access point?
Here is a neat command (as root) that you can execute to help NetworkManager connect to a hidden wireless access point OR when NetworkManager is unable to detect your desired wireless point fast enough in a wifi-saturated environment.

iwlist wlan0 scanning essid MyWifi

where wlan0 is usually your default wifi device, if you are unsure, execute ip add to verify.
MyWifi is the name of your desired/hidden wireless access point.  For ease of use, you could wrap this into a nice little script.
Read more »
the avatar of Will Stephenson

a silhouette of a person's head and shoulders, used as a default avatar

XDC 2012: Nuremberg!

Yes! The board has decided! XDC comes to Nuremberg!

For 2012 we (Egbert Eich, Professor Hopf, and I) will be hosting the annual X conference in Nuremberg!

Egbert will try to get the main SuSE conference room, or, failing that, Matthias will try to get us a university aula, so the venue itself will work itself out beautifully in one way or another. Then... Nuremberg is one of those places which is perfect for large crowds who need food and some liquids in the evening (frankonian/bavarian beergarten culture), so it is the perfect (and highly affordable) conference area from that point of view. And, the best part, even though Nuremberg is not the international hub that Frankfurt is, or the european hub that Munich is, it is halfway between the two, and travel is relatively easy from either of those points, either you take the plane, or you take a much more comfortable train from either airport, and get to Nuremberg in pretty much the same time. You can really make a big save comparing those two airports when flying inside european aerospace, and this for no time difference. One insider tip though: you get to ride the ICE at full speed (300+km/h!) when traveling from Munich (you do have to endure the rather pedestrian S-bahn for 45 minutes though).

Anyway, the main action item now is that Egbert can start to poke SuSE to see when their main conference room is available for 3 days in september 2012 (working network and enough power sockets are a given then!). I doubt that we will get an answer still in the three remaining weeks of this year.

The actual proposal e-mail sent to the board is sadly only available to X.org foundation members, but a wiki page will soon be created which recreates most of that information. But rest assured, we will get close to the wonderful experiences of XDC Toulouse (thank you Matthieu!) and XDC chicago (thank you Michael!) indeed!

(oh, and btw, we have a FOSDEM DevRoom this year, which is rapidly getting its schedule filled! If you are coming, get your talk in right now: first come, first serve!)