From 70ce734ecebaca83ef9c42447666837d3fbc028e Mon Sep 17 00:00:00 2001 From: Wolfram Sang Date: Thu, 19 Jan 2023 22:53:26 +0100 Subject: codec: sid: use cRSID as a library for playing SID files Change-Id: Iee70933e47ff8df8f26c9a63112de4da4a8e6c17 --- lib/rbcodec/codecs/cRSID/README.rockbox | 19 +++++++++++++++++++ lib/rbcodec/codecs/cRSID/SOURCES | 1 + lib/rbcodec/codecs/cRSID/cRSID.make | 16 ++++++++++++++++ 3 files changed, 36 insertions(+) create mode 100644 lib/rbcodec/codecs/cRSID/README.rockbox create mode 100644 lib/rbcodec/codecs/cRSID/SOURCES create mode 100644 lib/rbcodec/codecs/cRSID/cRSID.make (limited to 'lib/rbcodec/codecs/cRSID') diff --git a/lib/rbcodec/codecs/cRSID/README.rockbox b/lib/rbcodec/codecs/cRSID/README.rockbox new file mode 100644 index 0000000000..b95151aa09 --- /dev/null +++ b/lib/rbcodec/codecs/cRSID/README.rockbox @@ -0,0 +1,19 @@ +Some notes about cRSID usage in Rockbox +by Ninja (Wolfram Sang) in 2023 + +The cRSID codebase is from v1.0. The only change made was a separation of the +cRSID header into a public and private one, so it could be compiled as a +library. You can find it as a separate commit in the git repository. This +likely needs to be updated whenever a newer version of cRSID shall be used. + +Currently, newer versions of cRSID are available but they have been discarded. +v1.1 mainly adds a high quality playback mode using 7x oversampling. This is +too much for a Sansa Clip. Because the old playback mode still exists, it might +be possible to add a runtime option to let the user choose. As a first step +however, it was decided to give the user a working codec without having to deal +with options. v1.2 mainly adds a SDL-based GUI player, no bigger changes in SID +emulation. Staying with v1.0 also keeps the codec size significantly lower +(~50KB for v1.0 vs ~90KB for v1.2 on the Sansa Clip). + +cRSID Releases can be found here: +https://csdb.dk/search/?seinsel=releases&search=crsid diff --git a/lib/rbcodec/codecs/cRSID/SOURCES b/lib/rbcodec/codecs/cRSID/SOURCES new file mode 100644 index 0000000000..203c9dfbd1 --- /dev/null +++ b/lib/rbcodec/codecs/cRSID/SOURCES @@ -0,0 +1 @@ +libcRSID.c diff --git a/lib/rbcodec/codecs/cRSID/cRSID.make b/lib/rbcodec/codecs/cRSID/cRSID.make new file mode 100644 index 0000000000..2d5acb8b20 --- /dev/null +++ b/lib/rbcodec/codecs/cRSID/cRSID.make @@ -0,0 +1,16 @@ +# __________ __ ___. +# Open \______ \ ____ ____ | | _\_ |__ _______ ___ +# Source | _// _ \_/ ___\| |/ /| __ \ / _ \ \/ / +# Jukebox | | ( <_> ) \___| < | \_\ ( <_> > < < +# Firmware |____|_ /\____/ \___ >__|_ \|___ /\____/__/\_ \ +# \/ \/ \/ \/ \/ + +# cRSID +CRSID := $(CODECDIR)/cRSID.a +CRSID_SRC := $(call preprocess, $(RBCODECLIB_DIR)/codecs/cRSID/SOURCES) +CRSID_OBJ := $(call c2obj, $(CRSID_SRC)) +OTHER_SRC += $(CRSID_SRC) + +$(CRSID): $(CRSID_OBJ) + $(SILENT)$(shell rm -f $@) + $(call PRINTS,AR $(@F))$(AR) rcs $@ $^ >/dev/null -- cgit v1.2.3