Results 1 to 6 of 6

Thread: Target the desktop and mobile devices?

  1. #1

    Target the desktop and mobile devices?

    Hi All,

    I am just learning about OpenGL ES. I was wondering if it's possible to write an application that would work both on the desktop and on mobile devices just by switching out headers and recompiling. I realize there are some differences in OpenGL vs. ES APIs, but if you just used the ES subset and switched out the headers, is it possible? It seems it wouldn't be possible ( or at least not easy ) to do this with JOGL-ES, since they use different package names and even different class names, but it looks like the C implementation used all the same names and namespaces. Any thoughts on this?

    many thanks,

    B

  2. #2

    Re: Target the desktop and mobile devices?

    You can compile your OpenGL ES on Desktop but, you need use an implementation of the OpenGL ES for Desktop, you cant use OpenGL.

    OpenGL ES is based on OpenGL. OpenGL ES functionalities can be considered a subset of the OpenGL functionalities but that doesnt mean that you will compile the OpenGL ES using OpenGL.

    If you wanna use the OpenGL on desktop, you can change the function calls. Since the functionalities is a subset, you may change one OpenGL ES method for one with equal functionality in OpenGL.

    My current implementation using OpenGL ES is compiled to Nokia S60 and PocketPC... but both used OpenGL ES implemenations.



    *sorry for my english.

  3. #3

    Re: Target the desktop and mobile devices?

    I compiled my OpenGL ES project to OpenGL/Win32... and the only method i had to change was

    glClearDepthf to glClearDepth



    *ps: i believe was easy since im not using any fixed-point math.

  4. #4

    Re: Target the desktop and mobile devices?

    Hmmmm... maybe I'm not being clear. I understand you cannot use OpenGL to build for OpenGL ES. That's not what I'm asking.

    Let's say I build an app for a mobile device using OpenGL ES. Now I want to run this same app on the desktop. Can I simply switch out the headers ( to OpenGL ) and rebuild it? It seems the function calls are the same ( a subset I know ). Does it make sense?

    thanks,

    B

  5. #5

    Re: Target the desktop and mobile devices?

    Funny... we were replying at the same time.

    Yeah... that's what I was wondering. You have answered my question!

    That's pretty cool. As I said, that's something you really can't do with JOGL/JOGL - ES if you're going the Java route. This is a pretty nice advantage I think.

  6. #6

    Re: Target the desktop and mobile devices?

    glClearDepthf to glClearDepth
    P.S. But even this you could get around with a compiler directive.

Similar Threads

  1. Save image code from Desktop
    By djgolu123 in forum OpenVG and VGU
    Replies: 3
    Last Post: 02-15-2012, 06:22 AM
  2. Opengl ES for mobile devices???
    By qasim1981 in forum OpenGL ES general technical discussions
    Replies: 2
    Last Post: 01-17-2005, 11:32 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •