Page 1 of 1

ebuilding 64bit games

Posted: Tue Jun 19, 2018 5:45 am
by Gavinmc42
Now that I have both my Pi3B+'s working and compiling stuff like Mesa3D, I want to try some OpenGL games.
Gaming pushes computers, I want to see how far the Pi3B+ can be pushed :D

Warzone2100, 0AD, Supertuxkart are OpenGL games but there is no Aarch64 ebuilds for lots of things like these.

In Raspbian with OpenGL turned on -
Warzone will run , some issues but playable.
0AD will start up and then stop.
Supertuxkart ? Is it too big to run on a Pi?

The other thing is the kid may then find Pi's fun and I can get my PC back from him :lol:
Supertuxkart can be networked so a multiplayer, better than arcade, racing game with Pi's become possible.

Learning how to compile games can led to modifying of games which requires some software learning ;)
Supertuxkart is good for doing that, but It may need serious pruning to get it working.

Re: ebuilding 64bit games

Posted: Tue Jul 03, 2018 2:33 am
by Gavinmc42
Been doing a crash course in OpenGL/ES 3D coding.
Hand coding OpenGLES is not fun, which is why people use 3D modeling tools.

One of the best free ones is Blender, it uses OpenGL in it's UI.
Is Blender available on Gentoo64?
A google showed an Android OpenGLES version back in 2012.

I noticed the screenshot has Gimp.
So most of the pieces are on Gentoo64 for making/designing 3D models and games.

Re: ebuilding 64bit games

Posted: Wed Jul 04, 2018 4:14 pm
by sakaki
Gavinmc42 wrote:Is Blender available on Gentoo64?
media-gfx/blender is available in the Gentoo tree, however it is not currently keyworded for arm64, as you can see by using eix:

Code: Select all

pi64 ~ # eix --exact --verbose blender
* media-gfx/blender
     Available versions:  *2.72b-r4 ~*2.79 *2.79-r1
     IUSE (all versions): +boost +bullet collada colorio cuda cycles +dds debug doc +elbeem ffmpeg fftw +game-engine headless jack jemalloc jpeg2k libav llvm man ndof nls openal opencl +openexr openimageio openmp +opennl opensubdiv openvdb osl player redcode sdl sndfile test tiff valgrind CPU_FLAGS_X86="sse sse2" PYTHON_SINGLE_TARGET="python3_5 python3_6" PYTHON_TARGETS="python3_4 python3_5 python3_6"
     Find open bugs:
     Description:         3D Creation/Animation/Publishing System
     License:             || ( GPL-2 BL )
No reason why you couldn't try building it yourself though. To do so just create the file /etc/portage/package.accept_keywords/blender and put in it:

Code: Select all

media-gfx/blender * ~*
This will allow any version of the blender ebuild keyworded as stable (the *) or testing (the ~*) on any architecture to become a build candidate for your arm64 system (see the "Available versions:" line in the eix output above - in effect, this means the system will try to emerge v2.79-r1 if asked, as it is the most recent match under these criteria).

You'll also need to enable the theora USE flag for ffmpeg, so create the file /etc/portage/package.use/blender and put in there

Code: Select all

# local USE flags for media-gfx/blender, e.g. (uncomment following line to set):
# media-gfx/blender opencl

# dependency USE flags for media-gfx/blender
media-video/ffmpeg theora
You should then be able to:

Code: Select all

pi64 ~ # emerge --ask --verbose media-gfx/blender
It may take a while to build ^-^

best, sakaki

PS firefox-61.0 is now available on the binhost!

Re: ebuilding 64bit games

Posted: Thu Jul 05, 2018 1:32 am
by Gavinmc42
Thanks Sakaki, I did find that media-gfx/blender, not sure what it was.

I don't really want Blender, it has a demented UI :twisted:
But we know .Blender 2.78 does work in Raspbian.

I am trying to compile b4a, Blender with an easy to use UI ;)

The build dependencies did not build on latest 1.0 version but I suspect that is because it is using OpenCL.
I will try older versions tonight, all the compile tools seem to be working.
I suspect it is just lib make issues for ARMv7 and ARMv8.

Version 1.0 compiled fine on my Linux Mint box, but I noticed lots of things that I am sure might not(or ever) work on Pi.
I might be able to disable features, all I am after is the basic 3D obj and UV maker.

Re: ebuilding 64bit games

Posted: Thu Jul 05, 2018 11:40 am
by Gavinmc42
Sakaki, nearly got Bforartists usable.
No images on the icons, build deps issue I think.
It jitters a bit but I think that is an OpenGL issue.
Making mesa3d demo windows bigger makes them jitter too.

I used "make lite" instead of the default "make" :D

Re: ebuilding 64bit games

Posted: Thu Jul 05, 2018 12:40 pm
by sakaki
Looks good, can you write an ebuild for it (b4a) and then file it as a PR on the rpi3-overlay?

Best, sakaki

Re: ebuilding 64bit games

Posted: Thu Jul 05, 2018 2:37 pm
by Gavinmc42
Hi Sakaki, need to fix some dependencies. I think OpenColor?
Or maybe just some path issues, it could even be no make for aarch64 issues.

I did get just get it to compile on Raspbian with the icon images :D
I have no idea how to do ebuilds or PR?

Not sure how to fix it but it was relatively painless to get it work.
If you can figure it out if would be a nice standard feature for Gentoo64, perhaps 1.23?
There are some of Eric's OpenGL driver fixes coming down line that might help.

I needed something to stress test Gentoo64's mesa3d.
Blender does that but it is a pain to use, b4a solves that.
Apparently there is a game engine built in too, not sure what comes with the 140MB lite version.

Re: ebuilding 64bit games

Posted: Thu Jul 05, 2018 3:16 pm
by sakaki

Re: ebuilding 64bit games

Posted: Fri Jul 06, 2018 2:15 am
by Gavinmc42
Thanks for the ebuild guide links, it was on my list to find them one day.

This b4a/Blender does stuff I did not expect, it basically installs a build system where you can make new versions of Blender at anytime.
This makes it extremely hack-able and this seems to be part of it's attraction with users.

It makes the Lite version now, apart from the icons which looks to be just a path issue.
The default version has more deps and full version may never work on Pi's due to the GPU.
It also seems to be distribution independent, compiles on Debian, Raspbian and Gentoo, probably Windows too ;)

Lite also works better in Gentoo64 than Raspbian :D
I suspect this is due to it being 64bit optimized?

Not a cmake expert, but does cmake allow cross compiling?
Built target all aarch64?

Rebuild, rats still no icon images, might have do serious learning ;)

Re: ebuilding 64bit games

Posted: Fri Jul 20, 2018 12:11 pm
by Gavinmc42
Ok BforArtists version 0.95 compiled with icons, using "make lite".
Very serious OpenGL testing setup :lol:
Time to learn how to make Blender games and models.