Which OpenGL ES Version is most compatible with OpenGL 3.3? - opengl

I would like to build a cross platform OpenGL program using 3.3 on windows and linux.
I would also like to port it to android, although I'm not sure which ES version is most compatible with 3.

With my experience it's OpenGL ES 2.0.
Only one thing, I wrote small shader parser which is doing transformation shaders from GLSL 1.1 to 1.5.
I have heavy app which is runs on Mac, iOS and Android.
But maybe better for you to use some small engine.

Related

xming 7.7.0.23 OpenGl version reported incorrectly

I'm trying to use xming to render software using OpenGl running on the same machine in WSL / windows bash.
This works fine for some really small demos, however once I try something like glmark2, it fails because it seems the OpenGl version is reported incorrectly.
glxinfo | grep OpenGL reports this:
OpenGL vendor string: NVIDIA Corporation
OpenGL renderer string: GeForce GTX 970M/PCIe/SSE2
OpenGL version string: 1.4 (4.5.0 NVIDIA 382.05)
If I let xming run on my internal graphics card (using a laptop), it reports
OpenGL vendor string: Intel
OpenGL renderer string: Intel(R) HD Graphics 4600
OpenGL version string: 1.4 (4.3.0 - Build 20.19.15.4568)
The weird part is the 1.4 in front of 4.5.0 NVIDIA 382.05.
The OpenGl support is definitely at least 3, because a demo using GLSL shaders which require newer OpenGl runs, but the version string is kinda garbage.
The problem you're running into is, that the GLX portion of XMing does support only up to OpenGL-1.4. The part inside the parentheses is the version string as reported by the system native OpenGL implementation. However since XMing lacks (so far) the capability to reliably pass on anything beyond OpenGL-1.4 it will simply tell you "all I guarantee you to support is OpenGL 1.4, but the system I'm running on could actually do …".
Maybe some day someone goes through the effort to implement a fully featured dynamic GLX←→WGL wrapper.

Is it possible to use OpenGL 4.5 features with latest mesa libraries?

I want to use latest OpenGL features on Ubuntu. And I have installed mesa-common-dev but as far as I understand mesa does not support OpenGL 4.5 features. Also how can I use OpenGL via hardware without any API ?
Note :
glxinfo | grep "OpenGL version"
OpenGL version string: 4.5.13397 Compatibility Profile Context 15.20.1046
I want to use latest OpenGL features on Ubuntu. And I have installed mesa-common-dev but as far as I understand mesa does not support OpenGL 4.5 features.
All that matters is, that your actual OpenGL implementation supports the profile you want. The Linux ABI on OpenGL is pinned to OpenGL-1.2 (LSB5 has been released recently, so expect upcoming distribution releases to follow it, which bumped it to OpenGL-2.1).
Anything that goes beyond the ABI requirements is done through the extension mechanism. I.e. use load function pointers through …GetProcAddress and introduce new tokens with a glext.h. This processes has been repacked into OpenGL extension wrapper-loader libraries like GLEW.
The stuff mesa-common-dev provides is what's written down in the Linux LSB ABI specs… in a vendor neutral way, so you can compile your program using mesa-common-dev stuff, but it will work with the NVidia or AMD/ATI drivers as well.
Also how can I use OpenGL via hardware without any API ?
By definition you can't. OpenGL is an API. If you remove the API you remove OpenGL. If your intention is working the naked GPU on the bare metal, well, that would boil down to writing a full driver. In a few weeks/months Vulkan will be released and this gets you much closer to the GPU than OpenGL.

OpenGL ES 2.x compatible with OpenGL

I am planning to use Ubuntu with QT Creator to study and develop OpenGL ES 2.x applications. it is obvious that OpenGL ES 2.x is not easy to be configured in desktop environment, and OpenGL ES is sub-specification of OpenGL.
So I want to know if it is possible to develop the core part of OpenGL ES 2.x application in OpenGL environment and move my code to android or iOS to develop GUI later?
Not easy to configure? I beg to differ. Just get an emulator like the one Mali has, and let your program use their libraries instead of system ones directly.
Then you can be pretty sure that the GL code should be fine, as long, of course, as you will manage to run it on iOS(Obj-C++?) or Android(NDK?).
Qt5 is built with OpenGL ES 2.0 by default, so if you use current Qt you will have it out of the box, also Qt developers tell that they will support both android and iPhone in 5.2 version.
Mesa implements both regular OpenGL and OpenGL ES: http://www.mesa3d.org/opengles.html.
OpenGL ES 3.0 is supported on select GPUs too, AFAIK.
There's also cross-API compatibility built into most OpenGL libraries, so you can compile and run OpenGL ES code with no or minimal changes. You do need to work out platform specifics like setting up a render context, framebuffers and doing the actual drawing. But this is not GL/GLES specific.
ES API compatibility has been around since OpenGL 3.2 with most calls supported. The remaining ones were added by the ARB_ES2_compatibility extension, which is part of OpenGL 4.1. OpenGL 4.2 adds full OpenGL ES 3.0 support.
And yes, it works well. I've been running the same ES code on both Android, Linux, Mac OS X and iOS myself. It just needs a little bit more work than single platform support.
I've a own engine which implements ES 2.0 on iOS and Windows, so its working on both systems. You just have to care about unsupported formats and methods ( like pvrtc which is not supported on windows, so i wrote a converter ).
To make it easy i first implement everything on iOS so i know its working, after that i porting it to windows. Currently i've just around 1000 Lines of code which differ on each platform ( But i'm using Xamarin ).

Can I programming OpenGL4+ in a card that support 2.1 only?

This is the OpenGL version I have:
Video Card Vendor: Intel
Renderer: Intel(R) HD Graphics
OpenGL Version: 2.1.0 - Build 8.15.10.2622
GLU Version: 1.2.2.0 Microsoft Corporation
I'd like to learn the latest OpenGL API. But my card supports only 2.1 (and I cant update). Is it possible to program in latest API even with no card support?
AshleysBrain's answer is not quite correct. You can use a software implementation of OpenGL such as Mesa3D which can execute newer code using your CPU instead of your GPU. It will be slower but will allow you to compile and run your 4+ code against it OpenGL 3.1 code against it.
Edit: just checked, it seems Mesa only supports up to OpenGL 3.1. Still; that's pretty good for free.
It's more to do with what version the driver supports. Try updating your driver and see if it supports a newer version. Otherwise I'm afraid you're stuck with that version, there's nothing else you can do!
Send money/time Mesa's way in the hope they'll support GL4 in their software rasterizer sometime soon.
Or pester Khronos for a reference implementation.
As of Mesa 20.2 llvmpipe supports OpenGL 4.5.
Intel(R) HD Graphics are usually onboard.So NO you can't use GPU accelerated OpenGL 4.2 with this.You need dedicated card like those of Nvidia.The highest version of OpenGL I have seen on the dedicated cards is 3.1 which still delivers fixed pipeline API with Shaders support.But OpenGL 4.2 has completely removed all this and uses programmable way of doing things which requires programmable hardware too.

Getting started with OpenGL ES 2.0 on Windows

This is a very specific questions about the steps necessary to Build a simple OpenGL ES 2.0 program on the Windows platform. The environment is Visual Studio with unmanaged C++.
I go to the Khronos.org site and, frankly, find it a bit opaque because it reads like something written by a standards body. I don't want to download a "reference" or a "specification", etc.
All I'm looking for are the links and steps to get me from A to B. In other words, "Download these files or run this setup at this URL. Create a new Visual studio project with references to these libraries. Include this header file."
Again, I'm interested in ES 2.0.
I have been using googles Angle Project. It converts opengles 2.0 to DirectX 9 calls for win32. It works fairly well and even has quite a few examples. Its also the BSD licence so anything you make you can use the source for your own projects.
After alot of digging around for the same thing. I found an emulator for openGL es 2 from PowerVR: http://www.imgtec.com/powervr/insider/sdkdownloads/index.asp
The AMD one linked above is no longer available or supported.
AMD bundle OpenGL ES with their normal Catalyst drivers (for Win & Lin).
You just need to use EGL to get OpenGL ES context! (And have to use headers/includes from AMD OpenGL ES SDK).
AMD users already have everything they need to run your app.
Every doc about EGL and OGL ES is valid.
It work on AMD only.
PS Yes it is different from OLD/DEPRECATED OpenGL ES emulator. Because it is native!!!
AMD now ship a desktop OpenGL ES 2.0 version with EGL library
http://developer.amd.com/tools/graphics-development/amd-opengl-es-sdk/
You can have a look at Angle Project which brings OpenGL ES to desktops. It works pretty good and not that hard to setup: http://code.google.com/p/angleproject/
OpenGL ES is not generally available for Desktop machines. It is intended for embedded systems, hence the name - ES: Embedded Systems.
There isn't a native implementation available (the ES stands for Embedded Systems after all), but you could try ATI's OpenGL ES Emulator.
edit: 3/3/12 It looks like AMD has discontinued their support of the simulator.