Bridgecommand Compile for the Raspberry Pi 3

Compile Bridgecommand for the Raspberry Pi 3, Raspbian OS (and Linux Mint)

Ensure Raspbian is up to date:
sudo apt-get update
sudo apt-get dist-upgrade

Install required libraries:
sudo apt-get install mesa-common-dev libxxf86vm-dev freeglut3-dev libxext-dev libxcursor-dev
sudo apt install libportaudio2
sudo apt install libsndfile1

Enable opengl in Raspbian:
Run raspi-config
choose '7 - advanced' then 'A7 GL Driver' then 'G2 - GL Fake KMS'

Download source code from:
Extract to your desktop.

In a console / terminal, at the root directory of the source code type:
make -f MakefileWithSound

Run bridgecommand-ini
1. In bridgecommand-ini set 'water_segments'. Set it to 8 or lower. The processing power required for the wave motion is just too much for the Raspberry Pi. To fix this I change a setting in MovingWater.cpp. I change 'segments = 32' to 'segments=8'. This is on line 86. Mr. Packer wrote this setting into his code. I haven't had a crash or a freeze on the Pi since this setting was available and set appropriately.
2. In bridgecommand-ini Turn off Shading
3. In bridgecommand-ini set width and height to: 800x600 or less 640x480 and start in windowed mode. It will not work well at higher resolutions.
3. In bridgecommand-ini set 'use_directx' to 0

On the PI, some of the land will be invisible. It is likely due to the video hardware limitations.
To fix this simply reduce the size of all images in the bc-master/World folder to 257x257 and make sure you update the terrain.ini variable TerrainHeightMapSize(1)=257 to match.


Compile Bridgecommand for the Raspberry Pi 3 (using Gentoo Linux 64)

Gentoo Linux can be downloaded here:
edit bc-master/libs/Irrlicht/irrlicht-svn/source/Irrlicht/libpng/pngpriv.h and change:
then run 'make'


Notes for PI:
Run bridgecommand-bc alone. It crashes a lot when the browser is open.
Boot off a SD card, not a USB. It crashes often. You can boot off a USB, but it must be a fast, high quality one. I use an 60 GB SSD and it is fast.
Use IP addresses not network name on the Pi for repeater and network settings.


Ideas / Plans: