User avatar
peepo
Posts: 305
Joined: Sun Oct 21, 2012 9:36 am

Re: EGL - How to use fb1?

Tue Apr 07, 2015 10:44 am

found this post helpful, tx

I am able to use hdmi and usb display at the same time, both show rotating cube.
however there are significant colour differences,
background glClearColor(1.0f, 0.0f, 0.0f, 1.0f) is red on hdmi, blue on usb display
Lucca_128_128.raw has blue background on hdmi, on usb display.
anyone able to hint on solution?

a few comments on 'full source':
http://www.raspberrypi.org/forums/viewt ... 78#p557978

the extra files (.raw,.h) needed are on RPi here:
/opt/vc/src/hello_pi/hello_triangle

I edited a little further for RoboPeak usb display,
and believe output runs smoother/faster:

Code: Select all

    static int screen_width      = 320;
    static int screen_height   = 210;

          EGL_RED_SIZE, 5,
          EGL_GREEN_SIZE, 6,
          EGL_BLUE_SIZE, 5,
          EGL_ALPHA_SIZE, 0,

// replace eglChooseConfig(
          result = eglSaneChooseConfigBRCM(

       state->screen_width = 320;
       state->screen_height = 210;

// strong blue, so we know we have colour
       glClearColor(1.0f, 0.0f, 0.0f, 1.0f);

tvjon
Posts: 710
Joined: Mon Jan 07, 2013 9:11 am

Re: EGL - How to use fb1?

Tue Apr 07, 2015 5:11 pm

It is an interesting thread, agreed.

What is the attraction of the RoboPeak usb display?

I have several devices on the (effectively single) USB input, so not sure I'd want a relatively high bandwidth device such as a display, as well!

It looks like for best performance (least hassle?) a kernel recompile is best?

I too have 2 displays now, hdmi & a vga (also 1920 * 1080), but they are completely independent.
I prefer to use RPi for compiling app's, & controlling them, rather than additional computers & or ssh.

I made a couple of posts about it in the beginners' sticky "Gert's vga..."

It means I can have a big & cheap (second-hand, 1/3 the cost of RPi), vga monitor to show the output of my steep learning curve with the GPU API's.

I can edit shaders etc., via the hdmi monitor using Raspbian, watching the result on the vga screen (gles, dispmanx, openvg).

C_D
Posts: 18
Joined: Tue Mar 10, 2015 9:51 pm
Location: New Zealand

Re: EGL - How to use fb1?

Tue Apr 21, 2015 2:04 am

Good to see a few more RoboPeak USB display users turning up :)

I have been working with one for a while now, there are certainly plenty of little traps depending on what you are trying to achieve.

AndyD, has created a more powerful version of the rpi-fbcp utility which for my application works much better. Using rpi-fbcp with the RoboPeak display was vveeerrrry slow, but Andy's tool can work a lot faster in certain applications:
https://github.com/AndrewFromMelbourne/raspi2f
discussion here:
viewtopic.php?f=67&t=104296

I also have a problem with colour inversion, my thread on that topic never received much interest:
viewtopic.php?f=67&t=103600
I haven't really looked into it yet, I have had more pressing issues to work on and filed it away for another day.

tvjon:
For me the Robopeak USB display is my only input and output device for an RPi in an embedded application and 3-4" LCD is the size I need. I chose it over parallel or spi bus displays because its platform independent. While an RPi suits my application at the moment, if I later change to different ARM board the same display should work.

Return to “Graphics programming”