Regarding OSD position

asked Mar 21, 2016 in GUI Development by StewardLin


I have a question related with OSD position. Please refer my project as follows link.

My question as follows.

* OSD::OSD::OSD_OSD_Position_Pattern 

I press F5 for 'Prototyper' and press 'RIGHT' or ' DOWN' key, and I can saw OSD menu moved. This is normal.

* Barton::Application

  1. I press F5 for 'Prototyper'
  2. Press F1 key
  3. Press RIGHT key for move icon to 'OSD'
  4. Press DOWN key for move item to 'OSD POSITION'
  5. Press RIGHT or DOWN key, then will display trace message on 'Log window'
  6. But OSD position can not move,

I think the cause is not updated for "Views::WarpGroup Main_Warp", have you any idea for move OSD position when Prototype on "Barton::Application"?


Thank you.

commented Mar 28, 2016 by Manfred Schweyer
I removed the link to the project - so there is no relation to your customers spec.

1 Answer

+1 vote
answered Mar 22, 2016 by Manfred Schweyer
Best answer

Hi Steward,

after debugging your project some while, I noticed that the panel (Position Pattern) is not shown directly within the application. The panel is buffered and the content of the panel is shown within a Views::WarpGroup class. 

If you want to change the position of the visible panel on the screen you need to change the position of the WarpGroup object that is shown on the screen.

But maybe there is a very very simple solution!!! It seems to me, that you want to make some rotation of the screen: 0° - 90° - 180° - 270°. Since you are using a Platform Package that is based on OpenGL ES 2.0, the solution can be very simple: Just create the UI as it will appear to the user - and let make OpenGL the final rotation on the screen. For doing this, you can rotate the viewport of your application.

Please have a look into your main.c file. There you will find the following initialization of the viewport:

  viewport = EwInitViewport( EwScreenSize, EwNewRect( 0, 0, w, h ), 0, 255,
    &framebuffer, eglDisplay, eglSurface, ViewportProc );

The third parameter is the orientation hint of the viewport - by default this is set to 0. The meaning of this parameter depends on the target system. For example, OpenGL targets are using this parameter to determine the screen rotation in degrees.


Ask Embedded Wizard

Welcome to the question and answer site for Embedded Wizard users and UI developers.

Ask your question and receive answers from the Embedded Wizard support team or from other members of the community!

Embedded Wizard Website | Privacy Policy | Imprint