TESTERS wanted with broken/weird OpenGL

Hi!

As I’m sure many of you have found out, KiCad often crashes if you try to switch to the OpenGL canvas and your graphics system doesn’t support it. I’m working on a clean fallback to software rendering and I need your help.

The latest nightly builds have a test tool in them for gathering some information I need to do this properly, and I’d love to get this info from as many users as possible.

Usual nightly disclaimer *Bear in mind this does require installing a nightly build; by now I'm sure most of you have heard all the warnings - if you're not sure if you should be using a nightly build, please don't, or uninstall it when you're done. A project saved by a nightly build may not work anymore in 4.0!*

Nightly builds can be found at the following locations:

Once you’ve installed the latest nightly, the test tool can be found at the following locations, and must be run from a command prompt:

  • Windows: special procedure, see below
  • macOS: /Applications/Kicad/kicad.app/Contents/MacOS/kicad-ogltest
  • Most LInux: /usr/bin/kicad-ogltest
Windows users' procedure 1. Open a command prompt 2. Paste in the following command: `"C:\Program Files\KiCad\bin\kicad-ogltest.exe" > "%HOMEPATH%\Desktop\kicad-ogltest-out.txt"` 3. Send me the kicad-ogltest.out.txt file that was created on your desktop.

Please share with me the entire output from this command as well as any operating system crash reports, and tell me whether pcbnew actually works in OpenGL mode :slight_smile:

2 Likes

Apologies if this isn’t the most straightforward thing in the world - your patience is appreciated :slight_smile:

I have tested today nightly with kubuntu 14.04 in my laptop.

Pcbnew crashes. A message with something like “opengl 2.1 required” appears, but I couldn’t read it all.

Now, when open pcbnew, the application crashes instantly, no time to hit F9. Same behaviour in standalone mode.

Okay. Any chance you could run the special test tool?

Having an “OpenGL 2.1 required” message appear is a good sign, at least.

By the way, if it’s stuck in OpenGL mode and crashing, until I get this fixed (probably a couple weeks) you can reset it to legacy with the following command:

sed -i.bak -e '/^canvas_type=/ s/[[:digit:]]$/0/' ~/.config/kicad/pcbnew
1 Like

Thanks Chris!
I’ll try to come back to legacy tonight.

1 Like

Win 7
NVIDIA GT 640

I’ve had zero crashes in OGL.

However, my one annoyance is that the “high-contrast” mode is not anywhere near as bright as the Legacy and Cairo canvass.

Well, yep, something is definately broken in the 31MAR17 nightly.

NOT AN APRIL FOOL.

INFO: Instantiated GL window
INFO: Found OpenGL version 4.5
INFO: Successfully called OPENGL_GAL::BeginDrawing
PASS

An unhandled exception occurred. Press “Abort” to terminate the
program,
“Retry” to exit the program normally and “Ignore” to try to continue.

Clicked “Ignore”, clicked on the “Render” rear-footprint layer.

Unhandled exception class St12 out_of_range what: bitset:set:
_position (which is 120)>=_Nb (which is 50)

It seems I get the error every time I attempt to “Render” the rear-footprint.
This time however, I did not click to add the F.fab layer.

Unhandled exception class St12 out_of_range what: bitset:set:
_position (which is 119)>=_Nb (which is 50)

Discovered that I get the “an unhandled exeption occurred” every time I click
any one of the “Render” boxes. Not every time does it completely crash, most
of the time I can click ignore.

I can NOT view the rear-footprints at all.

This is probably unrelated to OpenGL.

Yeah, I got suckered into thinking it might be OGL, because it is such an odd problem. Note that I can no longer duplicate the above second error messages after swapping to the Legacy canvas and back. So, there you have that.

Now when I click “Ignore” it keeps marching along without crashing.

I had the F.Fab layer unchecked and the Render Footprints back unchecked when I saved a project with an older nightly. Launching the newest nightly, these were also unchecked on program launch. Three times in a row, I clicked the above in sequence and on the second click the program crashed (yea, I forgot to copy the text the first time it crashed.

Knowing that swapping between Legacy and OGL does “reset” the grid-bug, I tried the same in Legacy. I got errors that I could ignore, but never the second error or crash. Now, the OGL canvas gives me an error that I can ignore, and no longer crashes.

Sooooo, I get that it may seem unrelated, but I can not confirm that on my machine at this point in time. I’m certainly not going to withhold any issues I find. But, I do get it, sending you down the wrong rabbit hole could be a colossal waste of your time.

Hope you can nail this one down quickly.

I’d rather file a bug report so someone more familiar with that section of the code can fix it. I think it was modified recently, so I’m sure whoever did that can have a look. I’ll probably file one later when I have time.

$ /usr/bin/kicad-ogltest
Gtk-Message: Failed to load module “canberra-gtk-module”
INFO: Instantiated GL window
FAIL: Found OpenGL version 1.4, required at least 2.1

1 Like

HEADS UP!

This nightly simply is not workable for me since I can’t view the back side of the board.

I went to install the nightly that I had been using (mostly) trouble-free; Kicad Version: (2016-12-22 revision d365dc5).

After installation, the new footprint wizard in the editor only had 2 possible entries. I don’t know how to manipulate the Python scripts. I tried a few suggestions found online; I was unable to get anything to work.

What worked was using the KiCad uninstaller found in the Program Files\KiCad location. Then, re-installing the older nightly corrected the issue.

Thank you :slight_smile:

Post must be at least 20 characters mutter grumble

Ubuntu 16.04 on Intel i915 laptop

INFO: Instantiated GL window
INFO: Found OpenGL version 3.0
INFO: Successfully called OPENGL_GAL::BeginDrawing
PASS

edit
and the same result on an i5 PC with Radeon R7 on 16.04 OS

Quick addition - can the people posting “PASS” results please confirm whether OpenGL actually works for them in pcbnew? I’m not sure if you’re reporting successful runs or false positives :slight_smile:

In my case I tried opening Pcbnew in OpenGL mode and viewing the 3D in raytraced mode

Yes but did it work? :stuck_out_tongue:

Of course and the i915 laptop is as about as low end as you are going to meet these days.
The machines that really need to be tried are:
Anything using an AMD cpu
Hybrid graphics laptops with both Intel and Nvidia

Fortunately Wayland is not the default even on 17.04

Hmm…my main development machine is one of these.

Here is my test. Somehow the nighties do not work on my rather old MSI VR610 laptop in the opengl mode. No crashes, test works fine, opengl 2.1 is detected, but all the layers are rendered in black. Legacy and Cairo work fine. Also the stable 4.06 works ok in opengl mode.