Problmens connected with Ubuntu 9.10, mono, Tao, SDL, OpenGL, Radeon

Bug #450263 reported by Gašper Sedej
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Ubuntu
Won't Fix
Undecided
Unassigned

Bug Description

Hi!

I am working on project mono.xna, which ports microsoft .NET game framework to Mono.
We are using Tao framework for C# bindings of OpenGL, SDL and others.

Mono.Xna games are working PROPERLY on Ubuntu 9.04 AND Nvidia graphics cards. But problems are ATI Radeon cards.

I have Radeon 9600m (RV350) on my laptop.

I still don't know where is the bug. It has to do something with:
- Ubuntu 9.10
- ATI Radeon driver (opensource)
- SDL (tao framework)
- DevIl library (tao framework)

This is log what I get if have "libtaoframework-devil1.6-cil" installed (on NVidia it is not requred to work)
It looks like it has problem with native SDL:

 mono --debug FERI-bomberman.exe

 ** (FERI-bomberman.exe:3014): WARNING **: Symbol file /home/gasper/Projects/FERi Bomberman 1.3.2 (MonoXNA)/FERI-bomberman/bin/x86/Debug/Microsoft.Xna.Framework.Game.dll.mdb doesn't match image /home/gasper/Projects/FERi Bomberman 1.3.2 (MonoXNA)/FERI-bomberman/bin/x86/Debug/Microsoft.Xna.Framework.Game.dll

 ** (FERI-bomberman.exe:3014): WARNING **: Symbol file /home/gasper/Projects/FERi Bomberman 1.3.2 (MonoXNA)/FERI-bomberman/bin/x86/Debug/Microsoft.Xna.Framework.dll.mdb doesn't match image /home/gasper/Projects/FERi Bomberman 1.3.2 (MonoXNA)/FERI-bomberman/bin/x86/Debug/Microsoft.Xna.Framework.dll

 Stacktrace:

 Native stacktrace:

  mono [0x80c8824]
  mono [0x80f4693]
  [0xa5c410]
  [0x87af1]
  [0xfc37fee8]

 Debug info from gdb:

 Cannot access memory at address 0x53e58959
 [Thread debugging using libthread_db enabled]
 [New Thread 0x1a4fb70 (LWP 21537)]
 [New Thread 0x763b70 (LWP 21536)]
 [New Thread 0x798b70 (LWP 21535)]
 0x00a5c422 in __kernel_vsyscall ()
   4 Thread 0x798b70 (LWP 21535) 0x00a5c422 in __kernel_vsyscall ()
   3 Thread 0x763b70 (LWP 21536) 0x00a5c422 in __kernel_vsyscall ()
   2 Thread 0x1a4fb70 (LWP 21537) 0x00a5c422 in __kernel_vsyscall ()
 * 1 Thread 0x6466f0 (LWP 21532) 0x00a5c422 in __kernel_vsyscall ()

 Thread 4 (Thread 0x798b70 (LWP 21535)):
 #0 0x00a5c422 in __kernel_vsyscall ()
 #1 0x00b0f466 in nanosleep () from /lib/tls/i686/cmov/libpthread.so.0
 #2 0x081a3658 in ?? ()
 #3 0x00b0780e in start_thread () from /lib/tls/i686/cmov/libpthread.so.0
 #4 0x005997ee in clone () from /lib/tls/i686/cmov/libc.so.6

 Thread 3 (Thread 0x763b70 (LWP 21536)):
 #0 0x00a5c422 in __kernel_vsyscall ()
 #1 0x00b0df75 in sem_wait@@GLIBC_2.1 ()
    from /lib/tls/i686/cmov/libpthread.so.0
 #2 0x0812bb29 in ?? ()
 #3 0x0814f96c in ?? ()
 #4 0x081bf9f2 in ?? ()
 #5 0x081de055 in ?? ()
 #6 0x00b0780e in start_thread () from /lib/tls/i686/cmov/libpthread.so.0
 #7 0x005997ee in clone () from /lib/tls/i686/cmov/libc.so.6

 Thread 2 (Thread 0x1a4fb70 (LWP 21537)):
 #0 0x00a5c422 in __kernel_vsyscall ()
 #1 0x00b0f466 in nanosleep () from /lib/tls/i686/cmov/libpthread.so.0
 #2 0x009bdf47 in SDL_Delay () from /usr/lib/libSDL-1.2.so.0
 #3 0x009bdf94 in ?? () from /usr/lib/libSDL-1.2.so.0
 #4 0x00970a6e in ?? () from /usr/lib/libSDL-1.2.so.0
 #5 0x009bad2d in ?? () from /usr/lib/libSDL-1.2.so.0
 #6 0x00b0780e in start_thread () from /lib/tls/i686/cmov/libpthread.so.0
 #7 0x005997ee in clone () from /lib/tls/i686/cmov/libc.so.6

 Thread 1 (Thread 0x6466f0 (LWP 21532)):
 #0 0x00a5c422 in __kernel_vsyscall ()
 #1 0x00b0ec8b in read () from /lib/tls/i686/cmov/libpthread.so.0
 #2 0x080c89be in ?? ()
 #3 0x080f4693 in ?? ()
 #4 <signal handler called>
 #5 0x00087af1 in ?? ()
 #6 0xfc37fee8 in ?? ()

 =================================================================
 Got a SIGSEGV while executing native code. This usually indicates
 a fatal error in the mono runtime or one of the native libraries
 used by your application.
 =================================================================

 Aborted (core dumped)

I think problematic is:
#2 0x009bdf47 in SDL_Delay () from /usr/lib/libSDL-1.2.so.0

If I disenable "libtaoframework-devil1.6-cil" I get error:

 mono FERI-bomberman.exe

 ** (FERI-bomberman.exe:11746): WARNING **: The following assembly referenced from /home/gasper/Projects/FERi Bomberman 1.3.2 (MonoXNA)/FERI-bomberman/bin/x86/Debug/Microsoft.Xna.Framework.Game.dll could not be loaded:
      Assembly: Tao.DevIl (assemblyref_index=4)
      Version: 1.6.8.3
      Public Key: 7ec4053013524957
 The assembly was not found in the Global Assembly Cache, a path listed in the MONO_PATH environment variable, or in the location of the executing assembly (/home/gasper/Projects/FERi Bomberman 1.3.2 (MonoXNA)/FERI-bomberman/bin/x86/Debug/).

 ** (FERI-bomberman.exe:11746): WARNING **: Could not load file or assembly 'Tao.DevIl, Version=1.6.8.3, Culture=neutral, PublicKeyToken=7ec4053013524957' or one of its dependencies.

 ** (FERI-bomberman.exe:11746): WARNING **: Missing method ilInit in assembly /home/gasper/Projects/FERi Bomberman 1.3.2 (MonoXNA)/FERI-bomberman/bin/x86/Debug/Microsoft.Xna.Framework.Game.dll, type Tao.DevIl.Il

 Unhandled Exception: System.IO.FileNotFoundException: Could not load file or assembly 'Tao.DevIl, Version=1.6.8.3, Culture=neutral, PublicKeyToken=7ec4053013524957' or one of its dependencies.
 File name: 'Tao.DevIl, Version=1.6.8.3, Culture=neutral, PublicKeyToken=7ec4053013524957'
   at Microsoft.Xna.Framework.Game..ctor () [0x00000]
   at FERI_bomberman.Igra1..ctor () [0x00000]
   at FERI_bomberman.Program.Main (System.String[] args) [0x00000]

 I think the problem is this one:
 System.IO.FileNotFoundException: Could not load file or assembly 'Tao.DevIl, Version=1.6.8.3, Culture=neutral, PublicKeyToken=7ec4053013524957' or one of its dependencies.

I made some tests with computers. I used VirtualBox too. I if the sistem is run on VB I will call it "VB"
I will call my laptop with ATI radeon "ATI", my workstation with Ge-Force 8600GT "GF".

machine OS Virtualbox Option Status:
GF: Ubuntu 9.04: woks fine (se the link)
GF: Ubuntu 9.04: VB ubuntu 9.10, 3D supported: Got the error above
GF: Ubuntu 9.04: VB ubuntu 9.10, 3D NOT supported: Got the error above
GF: Ubuntu 9.10: Haven't tested.
ATI: Ubuntu 9.04: Graphics is very broken. See the link below.
ATI: Ubuntu 9.10: Got the error above.
ATI: Ubuntu 9.10: VB Ubuntu 9.04. 3D supported: Graphics is very broken. (like in the link below)
ATI: Ubuntu 9.10: VB Ubuntu 9.04. 3D NOT supported: Game IS working BUT SLOW!

So if I conclude: on 9.04 it has problems with ati driver showing incorrect, but in 9.10 isnt working at all.

Btw: on ATI and Ubuntu 9.10 other SDL games are working OK!!!
I would like to tell that 3D games are rally working better on 9.10 with radeon (thanks to Mesa 7.6)

   TESTING GAME

I am includeing my game and nedded .dll-s

How to test game. You need to have installed:
- libdevil1c2
- libdevil-dev
- libtaoframework-devil1.6-cil
- libtaoframework-opengl2.1-cil
- libtaoframework-sdl1.2-cil

included files that are needed:
-Tao.DevIL
-Tao.openGL
-Tao.SDL

you just run
mono FERI-bomberman.exe
on 9.04 should be working ok (tested on few computers)

ProblemType: Bug
Architecture: i386
Date: Tue Oct 13 12:49:59 2009
DistroRelease: Ubuntu 9.10
Lsusb:
 Bus 003 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
 Bus 002 Device 002: ID 0458:003a KYE Systems Corp. (Mouse Systems)
 Bus 002 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
 Bus 004 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
 Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
MachineType: Hewlett-Packard hp Compaq nc6000 (DE646AV)
Package: xorg 1:7.4+3ubuntu5
ProcCmdLine: BOOT_IMAGE=/boot/vmlinuz-2.6.31-11-generic root=UUID=08e897f4-a699-400b-b854-2085f9bd9a8c ro quiet splash
ProcEnviron:
 LANG=sl_SI.UTF-8
 SHELL=/bin/bash
ProcVersionSignature: Ubuntu 2.6.31-11.38-generic
RelatedPackageVersions:
 xserver-xorg 1:7.4+3ubuntu5
 libgl1-mesa-glx 7.6.0-1ubuntu2
 libdrm2 2.4.14-1ubuntu1
 xserver-xorg-video-intel 2:2.9.0-1ubuntu1
 xserver-xorg-video-ati 1:6.12.99+git20090825.fc74e119-0ubuntu3
SourcePackage: xorg
Uname: Linux 2.6.31-11-generic i686
XorgConf: Error: [Errno 2] No such file or directory: '/etc/X11/xorg.conf'
dmi.bios.date: 08/30/2006
dmi.bios.vendor: Hewlett-Packard
dmi.bios.version: 68BDD Ver. F.15
dmi.board.name: 0890
dmi.board.vendor: Hewlett-Packard
dmi.board.version: 8051 Version 1A.19
dmi.chassis.asset.tag: gSedej
dmi.chassis.type: 10
dmi.chassis.vendor: Hewlett-Packard
dmi.modalias: dmi:bvnHewlett-Packard:bvr68BDDVer.F.15:bd08/30/2006:svnHewlett-Packard:pnhpCompaqnc6000(DE646AV):pvrF.15:rvnHewlett-Packard:rn0890:rvr8051Version1A.19:cvnHewlett-Packard:ct10:cvr:
dmi.product.name: hp Compaq nc6000 (DE646AV)
dmi.product.version: F.15
dmi.sys.vendor: Hewlett-Packard
fglrx: Not loaded
system:
 distro: Ubuntu
 architecture: i686kernel: 2.6.31-11-generic

Revision history for this message
Gašper Sedej (gsedej) wrote :
Revision history for this message
Gašper Sedej (gsedej) wrote :

I have forgotten to paste likns of working game (NVIDIA):
http://www.youtube.com/watch?v=KoP1hzcEATA

And the "broken" graphics on 9.04 (ATI)
http://www.youtube.com/watch?v=T4sfrA1lVDg

Revision history for this message
David Tombs (dgtombs) wrote :

Thanks for the report. Unfortunately, the report is very complex and involves code that you are developing. Since you are a developer, please try to pinpoint the problem with a very simple test case that clearly shows that an Ubuntu library is doing something wrong. (Otherwise, the mistake might very well be in your code.) Thanks in advance!

Changed in ubuntu:
status: New → Incomplete
Revision history for this message
Gašper Sedej (gsedej) wrote :

Hello, David,

thanks for your reply! A am not main developer of MonoXNA project and I wasn't programming graphics (i know only very basics of OpenGL).
I done some more testing and all ATI GPU with opensource drivers failed to draw textures correctly, all NVIDIA GPU with proprietary driver works OK.
I can't say much more because I only noticed problem with MonoXNA. Other games/apps/compiz works OK on ATI GPU with opensource drivers.

And, yes, problem is still present in Ubuntu 10.04. I will try to find time to do testing with r300g (Gallium 3D architecture) drivers, and see if it's still present.

Revision history for this message
David Tombs (dgtombs) wrote :

Hi Gasper,

I think you have two options:

1) Try to demonstrate the problem in a test application without Mono.XNA (but that might be a lot of work, I don't know).
2) Talk to the Mono.XNA developers to help diagnose your problem.

Either way, I don't think Ubuntu developers will want to spend a lot of time trying to diagnose this, unfortunately. Thanks for your help!

Revision history for this message
Gašper Sedej (gsedej) wrote :

I already talked...I think it's ATI Radeon (opensource) driver issue, but it's present only here. But either cant ATI opensource developers help.

Yes, bug is not concerned with Ubuntu itself. Thanks for help anyway! :)
Bug can be closed as invalid.

Cheers!

Revision history for this message
David Tombs (dgtombs) wrote :

Well, I can assign this to the -ati driver in Ubuntu, that's still an Ubuntu bug. What I meant when talking to the Mono.XNA developers was that you should try to pin-point the problem with them.

You have the following layers going on:
1) Your code (non-Ubuntu)
2) Mono.XNA (non-Ubuntu)
3) libtao (Ubuntu)
4) Mono (Ubuntu)
5) OpenGL (Ubuntu)
6) ATI drivers (Ubuntu)

Basically #6 is not going to want to spend a lot of time diagnosing your problem unless you can give them a test case that eliminates some of the layers. Still, if it's an Ubuntu bug, then this report should stay open.

Have you tried testing your game on a different PC with an ATI card?

Changed in ubuntu:
status: Incomplete → New
Revision history for this message
Gašper Sedej (gsedej) wrote :

Hi, David,

thanks for reply.

I tried on at least 3 (different) computers with ATI cards, and all had bug with rendering textures. Right today I was able to test on intel GPU driver (opensource) and it also had same issue.
I tried on at least 4 computers with nVidia (GeForce) cards, and all rendered OK. So I can assume it's driver problem. But I still didn't find any other application that has same bug.
This means it's not driver error, right? But why works fine on all nvidias?

1. My code: irrelevant, it only calls api.
2. MonoXNA: Uses libtao for OpenGL calls. No active developer uses ATI or intel graphics. It may be some bug during reading textures from file, but I am not sure.
http://code.google.com/p/monoxna/issues/detail?id=40
3. Libtao: I will try to find other OpenGL apps.
4. Mono works ok.
5. OpenGL. Radeon driver is OpenGL 1.5 (or less) and does not suppert GLSL. But that's not case. I done some basic OpenGL examples in Tao.OpenGL only basic box with textures...) but worked ok on ati an nvidia.
6. I already send bug report on Radeon, but I could not give other example of issue. (I can't find bug)

I will try some other Tao.OpenGL (mono opengl) applications and report back.

Revision history for this message
David Tombs (dgtombs) wrote :

OK, thanks. Post here if you find out anything.

Changed in ubuntu:
status: New → Incomplete
Revision history for this message
Gašper Sedej (gsedej) wrote :

Hi!
I finally managed to find out problem. (Mono)XNA uses S3 texture compression (DXT), which is patented. Open-source drivers (Mesa) can't legally implement it. Status can be set to "won't fix".

Revision history for this message
David Tombs (dgtombs) wrote :

OK, thanks for the update.

Changed in ubuntu:
status: Incomplete → Won't Fix
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.