Blender and gallium on haiku

I know GL is not complete in haiku, but i want compile it on haiku and learn from now how and what i need on this anyway, I can be a mantainer if is need it i am not a developer but am a high user from linux… then i believe can be useful in this process, anyway i wanna test gallium 3d too, only for help ;).
I really apreciate respectful colaboration.

Blender is impossible by now

I already review the latest version …

Gallium, with libdrm and opengl stuff needs come first.

Maybe there is a work-around? Like with some of the OpenGL demos?

aljen on IRC is the guy to talk to… he is currently working on porting gallium as his time permits. He had an older version of gallium and llvmpipe working but many improvements have been made since. If the current LLVMpipe driver were ported it would mean some games would be playable at decent frame rates at low resolution at least on multicore computers… celerons of course will be left out of the fun openarena would probably work OK on an i7 thats just my guess after having ram LLVMpipe on my AthlonII laptop which is not exactly speedy but did get aroud 15fps in openarena whereas regular mesa is a slideshow

I would expect LLVMpipe to work better on a turion class laptop and even better on i7 which I believe has a 256bit fpu though I could be wrong mine only has a 64bit fpu wheras turion has a 128bit fpu at least oh the late models…

That llvmpipe with gallium sounds very interesting. Mesa is usually 1 to 5 fps for games. If llvmpipe supported multicore then it would be very cool to have and use for now. Until someday when Haiku can get real hardware 3D drivers.

And where I can download it?

can you send me a copy?


@michaeloliviera you could ask aljen (Artur) on IRC…

The code has been in a svn branch of haiku for quite some time now… it probably isn’t very stable though currently.

search for aljen in trac and you should see his latest commits

Information below relates to using llvmpipe (for OpenGL):

The Gallium3D LLVMpipe driver does not touch the GPU, so it can be run with any graphics card. However, for efficient performance, you will want to be running a 64-bit operating system and a CPU that supports SSE2.0 or better. LLVM can take advantage of SSE3 and SSE4 extensions too, which will result in even greater performance. To no surprise, the better the CPU you have, the better LLVMpipe will perform. The more cores that the CPU has, the better the performance will be too, as the rasterizer supports threading and tiling. If you are running a high-end Intel Core 2 Duo/Quad, an Intel Core i3/i5/i7, Intel Xeon, AMD Athlon II X4, AMD Phenom II, or AMD Opteron your CPU should be adequate.

llvmpipe with Core i7 test:

Mesa R300 (hardware OpenGL driver - uses GPU)
Gallium 3D R300 (hardware OpenGL driver - uses GPU)
llvmpipe (software OpenGL - uses lots of CPU for better performance)

*Mesa Software OpenGL not included in benchmark:
We did not compare the performance to the traditional software Mesa rasterizer in this benchmarking since it is incapable of running any of our OpenGL benchmarks beyond a couple frames per second.

My conclusion:
llvmpipe places the OpenGL burden on the CPU (higher usage). It is way better than Mesa software OpenGL but not the same as hardware OpenGL. Still, good way to start until 3D drivers are created for Haiku.

Gallium 3D rules! For 10% of CPU it really pushed up the fps in OpenArena test. In almost all test resolutions, double or more fps than Mesa R300.

Huum… I thought that you had one copy of that lib

Yes… I saw that commits…

But to build, you have to do download of the entire branch…

Huum… I thought that you had one copy of that lib

Yes… I saw that commits…

But to build, you have to do download of the entire branch…

no matter how experimeental it is in this moment i want test it.

…and what about OpenCL ?

Check out this interesting article (and comments too) about it.


here we go

I get the libdrm from aljen branch

and SoftPipe

but I have no idea how it works…

TinyGL (like MorphOS) could be a good choice, but lacks of sys/shm.h implementation on Haiku


To install: Replace (library) found in library folder. Find and move out “Mesa Software Renderer” and move in Softpipe in that folder.

Softpipe is Gallium (reference) software driver. Similar to Mesa’s software driver but seems less optimized. More for learning how 3D drivers work.

I built and tested Softpipe about 3 weeks back. Using Teapot demo: Mesa software driver: 300 FPS, Gallium Softpipe (driver): 160 FPS. Aljen posted on irc that Softpipe was slower also. Softpipe was step 1 for him and step 2 was looking into i915 driver for Haiku.

MorphOS took TinyGL and used OpenGL acceleration to improve it. TinyGL is outdated and does not handle all of OpenGL.

The MorphOS version of TinyGL is only loosely based on the original implementation. It was rewritten to take full advantage of 3D hardware acceleration. Furthermore, it contains several carefully chosen MESA features. TinyGL on MorphOS provides a much richer feature set and surpasses the original’s speed at the same time.

Better solutions, because they would give almost everyone OpenGL 3D, would be:

  1. llvmpipe with basic hardware (GPU) acceleration
  2. Softpipe with basic hardware (GPU) acceleration
  3. llvmpipe

Rudolf with his BeOS 3D driver for TNT & Geforce 1&2 provided basic 3D hardware acceleration. I used his driver on BeOS and had Stellarium running at 50-60 FPS. #2 above would be similar to what Rudolf and MorphOS have done for their 3D drivers -ie: take software driver and use 3D (GPU) acceleration to make it usable (faster).

Yeah, thanks! I got the same results here.

Including the black screen of death (SDL+OpenGL)

~/Desktop/lesson05> lesson05
CALLED: SoftPipeRenderer::SoftPipeRenderer(BGLView*, ulong, BGLDispatcher*)
hsp_init time: 0.000000.
ColorSpace:     B_RGB32
context:        1
hsp_create_layer_context time: 0.000000.
BRect(l:0.0, t:0.0, r:1023.0, b:767.0)
Kill Thread

What leads me to think that is a bad BWindow implementation on SDL video driver

However, TinyGL is not a worst thing (there’s a BGLView implementation already done)

perhaps that could bring more faster results

SDL+OpenGL black screen. File a bug for it on using Mesa Renderer. It could be a Haiku bug. Not sure what happened to cause the Kill Thread.

If you had BeOS installed you could test SDL+OpenGL on it to see what happens. You would have to compile latest SDL for BeOS too. I don’t think this was an issue on BeOS but cannot say for sure.

Unless TinyGL had 3D hardware acceleration I would say pass. It was meant for embedded systems and provides only software 3D which is good only for simple demos.
TinyGL is intended to be a very small implementation of a subset of OpenGL * for embedded systems or games. It is a software only implementation. Only the main OpenGL calls are implemented.

To use TinyGL you would have to: 1) update code from 2002 to 2010 and 2) add 3D hardware support to it. If TinyGL is available for Haiku then test it out and let us know how it works!!!

If someone takes a software 3D driver (ie: Mesa Renderer, Softpipe) and adds hardware 3D acceleration then that should work pretty good (ie: hybrid (software with basic hardware calls) 3D driver) or llvmpipe. Only need 30 FPS for games at either 1024x768 or 800x600 to be playable.

Still, you will have to wait for one or more developers to pick this up. Could take 3 to 5 years to get hardware 3D on Haiku. This will not happen soon and I’m OK with that because I haven’t 3D gamed for long time. But would be really cool thing to have working on Haiku.

Yeah… I already did it (please see the screenshots)

axeld said that could be a SDL port problem… but I can’t remmember if in BeOS was the same thing… (my hardware is not suitable)

the Kill Thread is me :smiley:

About TinyGL, the morphOS website displays Neverball and more games that are impossible bring for Haiku now… (Neverball builds, but the black screen appears)

let sit and wait :frowning:

Another thing: In early versions, Quake III arena was playable, but not now

Could you test?

Thanks for working on this, guys. I am really looking forward to when Haiku has decent 3D.