An open API service indexing awesome lists of open source software.

https://github.com/thrive4/app.fb.audioplayer-sdlmixer

audioplayer with freebasic and lib sdl2 mixer
https://github.com/thrive4/app.fb.audioplayer-sdlmixer

audio basic educational mp3-player

Last synced: 2 months ago
JSON representation

audioplayer with freebasic and lib sdl2 mixer

Awesome Lists containing this project

README

          

## audioplayer (sdl2 mixer) [![Github All Releases](https://img.shields.io/github/downloads/thrive4/app.fb.audioplayer-sdlmixer/total.svg)]()
basic audioplayer written in freebasic and sdl_mixer
* supported audio types are .flac, .mp3, .m4a, .mp4, .ogg, .wav
* supported playlists .m3u, .pls
* supported streams icecast and shoutcast http, https * currently not working with sdl
* ascii interface

if present coverart will be extracted and written to file as thumb.jpg\
When a file or path is specified the current dir and sub dir(s)\
will be scanned for audio file(s) which will generate an internal playlist

## usage
audioplayer.exe "path to file or folder"\
if a file or path is specified the folder will be scanned for an audio file\
if the folder has subfolder(s) these will be scanned for audio files as well.\

generate .m3u: audioplayer "path to file or folder" "tag" "tagquery"\
example: audioplayer.exe g:datamp3classic artist beethoven\
generates the m3u file beethoven.m3u\
which then can be played by audioplayer.exe beethoven.m3u\
* simple search so 195 is equivelant of ?195? or *195*
* runtime in seconds is not calculated default is #EXTINF:134
* no explicit wildcard support, only searchs on one tag
* supported tags artist, title, album, genre and year

## install
open zip file and copy contents to preferd folder\
this application is **portable**.

## configuration
basic config options in conf.ini\
locale = \
defaultvolume = <1 .. 128>\
playtype = \
' dynamic range compression *currently not working with sdl\
drc = \
' location media\
mediafolder = g:datamp3classic\
' location thumbnail media for station *currently not working with sdl\
' example: uk3 internet-radio.jpg put in ...\
radiofolder = g:internetradio

## requirements
sdl2.dll (32bit)\
https://www.libsdl.org/ \
and\
sdl2_mixer.dll (32bit)\
https://github.com/libsdl-org/SDL_mixer

Note a number of bindings have been added to\
SDL2_mixer.bi\
located in incSDL2\

Either copy the SDL2_mixer.bi included in the source\
from\
incSDL2\
to\
incSDL2\

or add this to incSDL2SDL2_mixer.bi\

>' added for version sdl2 mixer 2.6.2
declare function Mix_GetMusicArtistTag(byval music as Mix_Music ptr) as const zstring ptr
declare function Mix_GetMusicTitleTag(byval music as Mix_Music ptr) as const zstring ptr
declare function Mix_GetMusicAlbumTag(byval music as Mix_Music ptr) as const zstring ptr
declare function Mix_GetMusicCopyrightTag(byval music as Mix_Music ptr) as const zstring ptr
declare function Mix_MusicDuration(byval music as Mix_Music ptr) as double
declare function Mix_GetMusicPosition(byval music as Mix_Music ptr) as double
declare function Mix_GetMusicVolume(byval volume as long) as long
declare function Mix_MasterVolume(byval volume as long) as long

## performance
windows 7 / windows 10(1903)\
ram usage ~2MB / 2MB\
handles ~120 / ~200 \
threads 4 / 7 \
cpu ~1 (low) / ~2 \
tested on intel i5-6600T

## navigation
press . to play next\
press , to play previous\
press ] to skip forward 10 secs\
press [ to skip backwards 10 secs\
press space to pause / play or mute / unmute\
press r to restart\
press l for linear / shuffle list play\
press d for dynamic range compression *note currently not working for sdl\
press - to increase volume\
press + to decrease volume\
press esc to quit\

# special thanks to
squall4226 for getmp3tag
see https://www.freebasic.net/forum/viewtopic.php?p=149207&hilit=user+need+TALB+for+album#p149207 \
rosetta code for compoundtime\
https://rosettacode.org/wiki/Convert_seconds_to_compound_duration#FreeBASIC