We do not have hw to test any of this.  The only radeon devices
we have do not have 30depth compatible interfaces.

The XVisual determines the display depth, and colorspace method
truecolor, direct, ... Cinelerra uses a 24 rgb colorspace for
its pixel storage format, since byte per channel colors are widely
used and expected.  This may be the first case where the
default_visual depth is not 24 bit compatible.  Sounds problematic.

It would be really nice to see the output of
# xdpyinfo
on your system.  The default visual may be the source of the issue.


Here is what I recommend:
build cinelerra debuggable

# cd /<path>/cinelerra-5.1
# CFLAGS=-ggdb make -j rebuild_all

start gdb

# cd cinelerra
# gdb ./ci
Reading symbols from ./ci...
(gdb) b bcwindowbase.C:465
Breakpoint 1 at 0xd389ba: file bcwindowbase.C, line 465.
(gdb) r
Starting program: /mnt1/build5/cinelerra-5.1/cinelerra/ci 
...
Thread 1 "ci" hit Breakpoint 1, BC_WindowBase::create_window...
465                     default_depth = DefaultDepth(display, screen);
(gdb) p /x *vis
$2 = {ext_data = 0x0, visualid = 0x367, c_class = 0x4, red_mask = 0xff0000, green_mask = 0xff00, blue_mask = 0xff, bits_per_rgb = 0x8, 
  map_entries = 0x100}
(gdb) l
460                     vis = get_glx_visual(display);
461                     if( !vis )
462     #endif
463                             vis = DefaultVisual(display, screen);
464
465                     default_depth = DefaultDepth(display, screen);
466
467                     client_byte_order = (*(const u_int32_t*)"a   ") & 0x00000001;
468                     server_byte_order = (XImageByteOrder(display) == MSBFirst) ? 0 : 1;

This is where the color layout set via XVisual *vis.
In this case, it is determined via guicast/bcwindow3d.C:94
Visual *BC_WindowBase::get_glx_visual(Display *display)
using glx_window_fb_configs, which returns a config
matching constraints at at guicast/bcwindow3d.C:73
(gdb) l glx_window_fb_configs
65              printf(_("%s: opengl initialization failed failed\n"), msg);
66              return 0;
67      }
68
69      GLXFBConfig *BC_WindowBase::glx_window_fb_configs()
70      {
71              static int msgs = 0;
72              if( !glx_fbcfgs_window ) {
73                      int fb_attrs[] = {
74                              GLX_CONFIG_CAVEAT,      GLX_SLOW_CONFIG,

These constraints contains rgba=8888.
If get_glx_visual fails, or returns a 30bpp visual,
that probably is a bug in glx_fb_configs.
rgba=8888 is very common.
or draw with weird overlapping/truncated colors.

It may be that the card can't support an alpha channel with 30 bits
if that is rgb 10bit per channel and not rgba.  Cinelerra uses rgba...

It seems unlikely, but if get_glx_visual returns 0,
the visual in use by X can be setup via:
=== bcwindowbase.C.patch 
diff --git a/cinelerra-5.1/guicast/bcwindowbase.C b/cinelerra-5.1/guicast/bcwindowbase.C
index 1ff1492..1f1d0d3 100644
--- a/cinelerra-5.1/guicast/bcwindowbase.C
+++ b/cinelerra-5.1/guicast/bcwindowbase.C
@@ -460,8 +460,16 @@ int BC_WindowBase::create_window(BC_WindowBase *parent_window, const char *title
 		vis = get_glx_visual(display);
 		if( !vis )
 #endif
+		{
+			int mask = VisualDepthMask | VisualClassMask;
+			static XVisualInfo vinfo = { .depth = 24, .c_class = TrueColor, };
+			int nitems = 0;
+			XVisualInfo *vis_info = XGetVisualInfo(display, mask, &vinfo, &nitems);
+			vis = vis_info && nitems>0 ? vis_info[0].visual : 0;
+			if( vis_info ) XFree(vis_info);
+		}
+		if( !vis )
 			vis = DefaultVisual(display, screen);
-
 		default_depth = DefaultDepth(display, screen);
 
 		client_byte_order = (*(const u_int32_t*)"a   ") & 0x00000001;
=== end of patch
This searches for a rgba8888 visual if not already set by glx.

