InternalError: XXX0 profile[2]: GL2 -> profileImpl GL3bc !!! not mapped

classic Classic list List threaded Threaded
35 messages Options
12
Reply | Threaded
Open this post in threaded view
|

Re: InternalError: XXX0 profile[2]: GL2 -> profileImpl GL3bc !!! not mapped

serkan_tas
So much time passed over my latest comment but let me share my glxinfo output

https://drive.google.com/file/d/1OAdj1HjPpq3t3NVAcOBrDSjmLdugaszZ/view?usp=sharing

Let me know it helps

Reply | Threaded
Open this post in threaded view
|

Re: InternalError: XXX0 profile[2]: GL2 -> profileImpl GL3bc !!! not mapped

gouessej
Administrator
Serkan_tas, you're using a Mac, aren't you? I see "Apple M1 Max".
Julien Gouesse | Personal blog | Website
Reply | Threaded
Open this post in threaded view
|

Re: InternalError: XXX0 profile[2]: GL2 -> profileImpl GL3bc !!! not mapped

serkan_tas
Yes it is written in mostly all of my replies including the first mail of this thread.
Reply | Threaded
Open this post in threaded view
|

Re: InternalError: XXX0 profile[2]: GL2 -> profileImpl GL3bc !!! not mapped

gouessej
Administrator
Ok but I have no Mac and I don't use Parallels. I'll focus on reproducing this problem without using a virtual machine. Rather install rEFInd and Ubuntu directly on your computer without Parallels.
Julien Gouesse | Personal blog | Website
Reply | Threaded
Open this post in threaded view
|

Re: InternalError: XXX0 profile[2]: GL2 -> profileImpl GL3bc !!! not mapped

gouessej
Administrator
In reply to this post by serkan_tas
serkan_tas, your driver is correctly detected as coming from Mesa according to glxinfo, please use -Dnewt.debug=all -Dnativewindow.debug=all -Djogl.debug=all in order to give me some information I need to implement a workaround. I'm going to use newell's debug logs in the meantime but I don't want to miss some similar cases. If I could fix the 3 known cases at once, it would be far better for all of us.
Julien Gouesse | Personal blog | Website
Reply | Threaded
Open this post in threaded view
|

Re: InternalError: XXX0 profile[2]: GL2 -> profileImpl GL3bc !!! not mapped

gouessej
Administrator
In reply to this post by serkan_tas
Actually, several years ago (maybe 3), I decided not to commit a small part of my fix because I found it dirty but it has become necessary.

You have to replace in GLProfile.java:
} else if(GL2 == profile && hasAnyGL234Impl && ( desktopCtxUndef || GLContext.isGL2Available(device, isHardwareRasterizer))) {
            return desktopCtxUndef ? GL2 : GLContext.getAvailableGLProfileName(device, 2, GLContext.CTX_PROFILE_COMPAT);

by:
} else if(GL2 == profile && hasAnyGL234Impl && ( desktopCtxUndef || GLContext.isGL2Available(device, isHardwareRasterizer))) {
            return desktopCtxUndef || (GL3bc == GLContext.getAvailableGLProfileName(device, 2, GLContext.CTX_PROFILE_COMPAT) && !GLContext.isGL3bcAvailable(device, isHardwareRasterizer)) ? GL2 : GLContext.getAvailableGLProfileName(device, 2, GLContext.CTX_PROFILE_COMPAT);

Martin, please can you provide a build with this fix?
Julien Gouesse | Personal blog | Website
Reply | Threaded
Open this post in threaded view
|

Re: InternalError: XXX0 profile[2]: GL2 -> profileImpl GL3bc !!! not mapped

serkan_tas
This post was updated on .
In reply to this post by gouessej
Reply | Threaded
Open this post in threaded view
|

Re: InternalError: XXX0 profile[2]: GL2 -> profileImpl GL3bc !!! not mapped

gouessej
Administrator
Thank you serkan_tas. I confirm that my fix should work in your case too, the root cause is exactly the same than in newell's case.
Julien Gouesse | Personal blog | Website
Reply | Threaded
Open this post in threaded view
|

Re: InternalError: XXX0 profile[2]: GL2 -> profileImpl GL3bc !!! not mapped

gouessej
Administrator
In reply to this post by serkan_tas
Replace GLProfile.class in your JogAmp fat JAR and it should work:
GLProfile.class
Julien Gouesse | Personal blog | Website
Reply | Threaded
Open this post in threaded view
|

Re: InternalError: XXX0 profile[2]: GL2 -> profileImpl GL3bc !!! not mapped

serkan_tas
I guess passed the error

https://docs.google.com/document/d/16kOL-iUePAi34KQguv4AcVFe1O14oVvWqKYT-HIcqSs/edit?usp=sharing

or just my test code has done it :)


package jMAVSimTester;

import java.awt.GraphicsConfiguration;

import com.sun.j3d.utils.universe.SimpleUniverse;

public class TestMe {

        public static void main(String[] args) {

                GraphicsConfiguration gc = SimpleUniverse.getPreferredConfiguration();
               
                System.out.println(gc.toString());
        }

}


Thank you so much. I need to try it in PX4 project
Reply | Threaded
Open this post in threaded view
|

Re: InternalError: XXX0 profile[2]: GL2 -> profileImpl GL3bc !!! not mapped

serkan_tas
I confirm that I can open simulator with command

java -Djava.ext.dirs= -cp lib/*:out/production/jmavsim.jar me.drton.jmavsim.Simulator

with new GLProfile.class.

Thank you so much Julien
Reply | Threaded
Open this post in threaded view
|

Re: InternalError: XXX0 profile[2]: GL2 -> profileImpl GL3bc !!! not mapped

Martin
Congratulation to Julien!

And thank you Serkan for the feedback.

I noted Julien's fix here and will add it as soon as I can for a new build.
Reply | Threaded
Open this post in threaded view
|

Re: InternalError: XXX0 profile[2]: GL2 -> profileImpl GL3bc !!! not mapped

gouessej
Administrator
In reply to this post by serkan_tas
You're welcome. By the way, "java.ext.dirs=" has no effect with Java >= 9. Thank you for your feedback.
Julien Gouesse | Personal blog | Website
Reply | Threaded
Open this post in threaded view
|

Re: InternalError: XXX0 profile[2]: GL2 -> profileImpl GL3bc !!! not mapped

gouessej
Administrator
In reply to this post by Martin
Thanks Martin, it's better that way, I had forgotten this fix during almost 2 years, shame on me.
Julien Gouesse | Personal blog | Website
Reply | Threaded
Open this post in threaded view
|

Re: InternalError: XXX0 profile[2]: GL2 -> profileImpl GL3bc !!! not mapped

Sven Gothel
Administrator
In reply to this post by gouessej
commit edf0d33ba913fd37f9e6ce0a771d8dfb6fa962e6

    Fix GLProfile GL2 Mapping: Only use GL3bc is available, add additional GLContext.isGL3bcAvailable() check
   
    Julien Gouesse resolved this odd issue, where a requested GL2 profile was mapped to GL3bc but is not implemented,
    see <https://forum.jogamp.org/InternalError-XXX0-profile-2-GL2-gt-profileImpl-GL3bc-not-mapped-td4041754i20.html#a4042018>.
   
    I exploded his patch a little to reuse the GLContext.getAvailableGLProfileName() result
    and simplify the conditional statement.
   
    This might need more testing perhaps, plus analyis why GLContext.getAvailableGLProfileName()
    offers GL3bc but is not available via GLContext.isGL3bcAvailable() check.


Thank you.
12