NEW: Darkplaces Quake engine up and running on Raspberry PI


99 posts   Page 1 of 4   1, 2, 3, 4
by autonomous » Mon Mar 17, 2014 5:26 am
The Darkplaces engine is a significantly modified Quake engine used by several standalone games and Quake mods. It has greatly improved graphics and image quality, rendering capabilities and gameplay physics. It is considered one of the fastest engines available. It features real-time lighting, bumpmapping, an OpenGL shader system which also supports GLES2 compiled shaders, bloom lighting, model interpolation, and rewritten network code which supports connecting to NetQuake and QuakeWorld servers within the same binary. It is functional as a standalone engine and is used for many projects such as Xonotic, Darsana, and Transfusion. Known for its increase in limits, allowing more intricate mapping in various BSP formats including Half Life, as well as more flexibility in qc, DarkPlaces is preferred by most modders.

The Raspberry PI port of Darkplaces runs surprisingly well at 1080p with full audio support. Typical framerates during gameplay range between 20-30 fps at 1080p without overclocking. 1080p overclocked at 950mhz yields framerates of 35+. 720p without overclocking, up to 55 fps.

YouTube videos of Darkplaces engine running Half-Life maps, Quake mods and Quake on Raspberry PI, model B:
Image

Raspberry PI running Darkplaces engine:
Image

Darkplaces PI Version Installation and Configuration Guide

The following installation procedure has been tested with a new install of Raspbian (2014-01-07-wheezy-raspbian) with 256mb allocated to GPU:

Allocate at least 128mb memory for GPU
See http://elinux.org/RPiconfig#Memory for details.

Make sure system is up-to-date
Code: Select all
sudo rpi-update
sudo reboot


Create a folder somewhere for darkplaces
Code: Select all
mkdir ~/darkplaces
cd ~/darkplaces


Download install package into folder
Code: Select all
wget https://github.com/autonomous1/darkplacesrpi/archive/dprpi_v1.1.zip


Unpack and run installer
Code: Select all
unzip dprpi_v1.1.zip
mv darkplacesrpi-dprpi_v1.1/* .
sudo dpkg -i darkplaces-rpi.deb


Download shareware version of Quake game data
Code: Select all
wget ftp://ftp.idsoftware.com/idstuff/quake/quake106.zip

or select a faster mirror site to download quake106.zip:
http://linuxdocs.org/HOWTOs/Quake-HOWTO-2.html#quake-files


Unpack game data
Code: Select all
unzip quake106.zip
sudo apt-get install lhasa
lhasa e resource.1


Setup user permissions
Note: replace pi with your username:
Code: Select all
sudo usermod -a -G video pi


Run Darkplaces
Code: Select all
darkplaces-sdl

(type esc for menu to start game or exit. Note: Darkplaces RPi does not run under X-Windows)


Additional documentation

List of mods that run on RPi:
A list of mods known to work on the RPi. A section is included for mods suitable for children such as Nerf-Quake:
https://github.com/autonomous1/darkplacesrpi/wiki/List-of-Quake-mods-that-have-been-tested-on-Darkplaces-RPi

Mod installation guide:
https://github.com/autonomous1/darkplacesrpi/wiki/Installing-and-running-Quake-mods

Video mode configuration:
https://github.com/autonomous1/darkplacesrpi/wiki/Video-mode-configuration

Darkplaces engine configuration parameters:
https://github.com/autonomous1/darkplacesrpi/wiki
Last edited by autonomous on Mon Apr 14, 2014 10:21 pm, edited 21 times in total.
User avatar
Posts: 24
Joined: Tue Apr 23, 2013 5:24 pm
by Vanfanel » Mon Mar 17, 2014 10:35 am
This is going to be great *if* the sources are made available! :)
Will the sources for this be available, too?
Posts: 372
Joined: Sat Aug 18, 2012 5:58 pm
by GTR2Fan » Mon Mar 17, 2014 10:40 am
Well done! That looks great! :)
Pi2B Mini-PC/Media Centre: ARM=1GHz (+3), Core=500MHz, v3d=500MHz, h264=333MHz, RAM=DDR2-1200 (+6/+4/+4+schmoo). Sandisk Ultra HC-I 32GB microSD card on '50=100' OCed slot (42MB/s read) running Raspbian/KODI16, Seagate 3.5" 1.5TB HDD mass storage.
User avatar
Posts: 1601
Joined: Sun Feb 23, 2014 9:20 pm
Location: South East UK
by autonomous » Mon Mar 17, 2014 10:56 pm
Yes, the PI version of the Darkplaces engine is open-source. I am in the process of merging the modifications made to the engine to support the PI (or tile-based gpu rendering) into the main source repository. In addition development tools for real-time monitoring of the running state of the PI including the gpu will be made available.

Here is an example of real-time system monitoring while running the engine. This tool runs as a service under NodeJS and is displayed in a browser on a desktop system:
Image
Last edited by autonomous on Thu Mar 20, 2014 8:47 pm, edited 1 time in total.
User avatar
Posts: 24
Joined: Tue Apr 23, 2013 5:24 pm
by antiriad » Tue Mar 18, 2014 7:45 am
WOW. Can't wait! :D
User avatar
Posts: 87
Joined: Sun Nov 17, 2013 7:38 pm
Location: Italy
by Vanfanel » Tue Mar 18, 2014 9:38 am
I can't wait, either!!! :D :D

Does it support MP3/OGG/FLAC/WAV music tracks? Trent Reznor makes the Quake experience complete!
Posts: 372
Joined: Sat Aug 18, 2012 5:58 pm
by antiriad » Tue Mar 18, 2014 2:10 pm
...and will it support also Hexen 2? (or Hammer of Thyrion: http://uhexen2.sourceforge.net/) :D
User avatar
Posts: 87
Joined: Sun Nov 17, 2013 7:38 pm
Location: Italy
by KitchUK » Wed Mar 19, 2014 8:25 am
Looking forward to this. I've actually never played the original quake! From the video on YouTube the gameplay looks smooth and good fps.
Posts: 256
Joined: Fri Jul 19, 2013 5:40 pm
by Oldbitcollector » Thu Mar 20, 2014 1:36 am
Would a Quake/Raspberry Pi based CTF be too much to ask for in the future? :)

Great job! Thanks
Jeff
My Ongoing Raspberry Pi Reference: http://www.ledgerlabs.us/raspberrypi
User avatar
Posts: 93
Joined: Sun Sep 22, 2013 9:02 pm
Location: Orrville, OH
by autonomous » Thu Mar 20, 2014 4:19 am
Here is a status update: The distribution repository and installation guide is complete and undergoing testing at the moment. Since everything looks good to go at this point, the Darkplaces engine will be made available for distribution tomorrow, March 20.

I have been intending to answer a few questions about the engine:

Does it support MP3/OGG/FLAC/WAV music tracks? Trent Reznor makes the Quake experience complete!


Yes, Darkplaces supports OGG music tracks. The engine streams large OGG soundtracks during gameplay. 7.1 audio via HDMI is also supported.

...and will it support also Hexen 2? (or Hammer of Thyrion: http://uhexen2.sourceforge.net/)

Sorry, Hexen 2 is not supported by this engine. But the game data files are based on a very similar file structure. In addition to supporting Quake 1, 2, and 3 mods, the Darkplaces engine also supports Half-life mods. It may be possible in the future to run additional game file formats such as Hexen 2 in this engine.

Would a Quake/Raspberry Pi based CTF be too much to ask for in the future?

Yes Darkplaces supports CTF. Take a look at http://www.quaketerminus.com/ctf.shtml . I have not tested this mod yet but I don't see why it shouldn't work.
User avatar
Posts: 24
Joined: Tue Apr 23, 2013 5:24 pm
by Forgotten01 » Thu Mar 20, 2014 2:46 pm
Soooo, could we play Half Life on here?
Engineers like to solve problems. If there are no problems handily available, they will create their own problems.
Scott Adams
User avatar
Posts: 162
Joined: Sun Dec 01, 2013 6:06 pm
by KitchUK » Thu Mar 20, 2014 2:55 pm
Forgotten01 wrote:Soooo, could we play Half Life on here?


I was thinking the same thing! ;)
Posts: 256
Joined: Fri Jul 19, 2013 5:40 pm
by Vanfanel » Thu Mar 20, 2014 4:10 pm
KitchUK wrote:
Forgotten01 wrote:Soooo, could we play Half Life on here?


I was thinking the same thing! ;)


The same question here! :D
Posts: 372
Joined: Sat Aug 18, 2012 5:58 pm
by autonomous » Thu Mar 20, 2014 11:04 pm
Forgotten01 wrote:Soooo, could we play Half Life on here?


You can load Half Life maps into Darkplaces but not the models. Here are a few Half Life 1 screenshots captured off my PI with an unmodified Half Life 1 valve folder:

Image
Image
Image
Image
Image
Image
Image
Image
Image
Image

Installation process:
Make a sub folder under the ~/darkplaces game folder called halflife1 and copy contents of Half-Life I valve folder there. (500mb)

Run Half Life 1 maps in Darkplaces:
Code: Select all
darkplaces-sdl -game halflife1 +map c1a0
User avatar
Posts: 24
Joined: Tue Apr 23, 2013 5:24 pm
by tobias_huebner » Fri Mar 21, 2014 3:53 pm
Wow - that`s awesome! I just followed your instructions and the game runs great! Could you please post a short tutorial how to install the complete game, not just the shareware version (with music)? I`ll go and buy a copy on eBay to replay this great game!
Posts: 2
Joined: Fri Mar 21, 2014 3:49 pm
by autonomous » Fri Mar 21, 2014 5:59 pm
tobias_huebner wrote:Wow - that`s awesome! I just followed your instructions and the game runs great! Could you please post a short tutorial how to install the complete game, not just the shareware version (with music)? I`ll go and buy a copy on eBay to replay this great game!


You can follow these instructions on "Installing From a Quake CD"
http://linuxdocs.org/HOWTOs/Quake-HOWTO-2.html

Essentially, the retail version contains a file called id1/pak1.pak that should be copied into the ~/darkplaces/id1 folder. Many Quake mods won't run without pak1.pak so it is a good idea to have the full version on hand.

Glad to hear the installation guide works, thanks for the post!
User avatar
Posts: 24
Joined: Tue Apr 23, 2013 5:24 pm
by KitchUK » Fri Mar 21, 2014 6:15 pm
Could you point me in the direction of how to install this on the pi?
Posts: 256
Joined: Fri Jul 19, 2013 5:40 pm
by autonomous » Fri Mar 21, 2014 6:22 pm
KitchUK wrote:Could you point me in the direction of how to install this on the pi?


The install guide is included in the first post in this topic and on github:
https://github.com/autonomous1/darkplacesrpi/tree/master
User avatar
Posts: 24
Joined: Tue Apr 23, 2013 5:24 pm
by KitchUK » Fri Mar 21, 2014 8:24 pm
Hey autononomous, should this:

Code: Select all
unzip dprpi_v1.0.zip
mv  darkplacesrpi-dprpi_v1.0/* .
sudo dpkg -i darkplaces-rpi_1.0-0_all.deb


be this:

Code: Select all
unzip dprpi_v1.0.zip
mv  darkplacesrpi-dprpi_v1.0/* .
sudo dpkg -i darkplaces-rpi_1.0_all.deb
Posts: 256
Joined: Fri Jul 19, 2013 5:40 pm
by autonomous » Fri Mar 21, 2014 8:33 pm
The install procedure has been updated - thanks for catching this.
Last edited by autonomous on Sat Mar 22, 2014 10:47 pm, edited 1 time in total.
User avatar
Posts: 24
Joined: Tue Apr 23, 2013 5:24 pm
by Oldbitcollector » Sat Mar 22, 2014 4:50 am
Trying to install the halflife1 files...

Copied the valve folder with all contents (500+mb). Renamed to halflife1.

I'm getting "gfx.wad doesn't have a WAD2 id"

Bad copy?

Thanks!
Jeff
My Ongoing Raspberry Pi Reference: http://www.ledgerlabs.us/raspberrypi
User avatar
Posts: 93
Joined: Sun Sep 22, 2013 9:02 pm
Location: Orrville, OH
by autonomous » Sat Mar 22, 2014 6:15 am
Oldbitcollector wrote:I'm getting "gfx.wad doesn't have a WAD2 id"

Bad copy?

Thanks!
Jeff


Your copy of Half Life is fine. These messages are normal in DP when loading maps from an unmodified Half Life 1 valve folder. Are you able to move about the maps, such as c1a0? When running DP I use +sv_cheats 1 and enter noclip in the game console after loading a map. This enables free movement throughout the map.

There is no game play in Half Life due to DP not being able to load Half-Life models for a variety of reasons. However, "Quake Life" is an open source project that replaces Half Life models with Quake's models. It is playable to some extent and surreal with Quake characters embedded in Half Life.
User avatar
Posts: 24
Joined: Tue Apr 23, 2013 5:24 pm
by Bluelightcrew » Sat Mar 22, 2014 9:40 am
The game runs very good an looks nice! I`am using Retropie, without Keyboard. When the game is startet i can play with Gamepad,but i can not controll the Menu with Gamepad.
Do you have a solution for this?
Posts: 8
Joined: Fri Feb 28, 2014 2:01 pm
by autonomous » Sat Mar 22, 2014 6:32 pm
Bluelightcrew wrote:The game runs very good an looks nice! I`am using Retropie, without Keyboard. When the game is startet i can play with Gamepad,but i can not controll the Menu with Gamepad.
Do you have a solution for this?


Not at present. I have the same issue with my game controller not being able to control the menus. I will look into running the game without a keyboard in the next release. Meanwhile, code for the Raspberry PI port needs to be merged into the main repository for Darkplaces.

Here's the first cut of a Raspberry PI running "Quake Life":
Image

A portal to another world has opened up at the Black Mesa Research Facility! Hostile aliens from a dimension known as "Planet Quake" have entered the facility and have overwhelmed the marines. You must travel through the portal to Planet Quake and stop the invasion!
Last edited by autonomous on Sat Mar 22, 2014 8:17 pm, edited 1 time in total.
User avatar
Posts: 24
Joined: Tue Apr 23, 2013 5:24 pm
by Oldbitcollector » Sat Mar 22, 2014 6:51 pm
I downloaded and extracted the three files from this site into a folder "ctf".

using darkplaces-sdl -game ctf appears to start the game...

Locked up the first time, the second attempt has me wandering around with an axe.
My Ongoing Raspberry Pi Reference: http://www.ledgerlabs.us/raspberrypi
User avatar
Posts: 93
Joined: Sun Sep 22, 2013 9:02 pm
Location: Orrville, OH