Merge branch 'master' into clangen/sndiotest

This commit is contained in:
casey langen 2019-01-01 19:58:56 +00:00
commit 80185085ec
17 changed files with 49 additions and 32 deletions

View File

@ -1,3 +1,14 @@
0.60.1
musikcube:
* fixed m4a playback
* added support for aac and alac playback
musikdroid:
* fixed crash on startup on some versions of Android. oops.
--------------------------------------------------------------------------------
0.60.0 0.60.0
musikcube: musikcube:

View File

@ -8,7 +8,7 @@ cmake_minimum_required(VERSION 3.0)
project(musikcube) project(musikcube)
set (musikcube_VERSION_MAJOR 0) set (musikcube_VERSION_MAJOR 0)
set (musikcube_VERSION_MINOR 60) set (musikcube_VERSION_MINOR 60)
set (musikcube_VERSION_PATCH 0) set (musikcube_VERSION_PATCH 1)
set (musikcube_VERSION "${musikcube_VERSION_MAJOR}.${musikcube_VERSION_MINOR}.${musikcube_VERSION_PATCH}") set (musikcube_VERSION "${musikcube_VERSION_MAJOR}.${musikcube_VERSION_MINOR}.${musikcube_VERSION_PATCH}")
include(CMakeToolsHelpers OPTIONAL) include(CMakeToolsHelpers OPTIONAL)

View File

@ -1,6 +1,6 @@
%define name musikcube %define name musikcube
%define build_timestamp %{lua: print(os.date("%Y%m%d"))} %define build_timestamp %{lua: print(os.date("%Y%m%d"))}
%define version 0.60.0 %define version 0.60.1
Name: %{name} Name: %{name}
Version: %{version} Version: %{version}
Release: %{dist} Release: %{dist}

2
src/3rdparty/bin vendored

@ -1 +1 @@
Subproject commit 549f033102ef7550b80db1e54ca03070f1dc20c5 Subproject commit f77857c24dec5e4d6d900995ed3d140088657eb6

View File

@ -61,7 +61,6 @@ TrackList::TrackList(ILibraryPtr library) {
TrackList::TrackList(TrackList* other) TrackList::TrackList(TrackList* other)
: ids(other->ids) : ids(other->ids)
, library(other->library) { , library(other->library) {
this->library = library;
} }
TrackList::TrackList(ILibraryPtr library, const int64_t* trackIds, size_t trackIdCount) TrackList::TrackList(ILibraryPtr library, const int64_t* trackIds, size_t trackIdCount)

View File

@ -55,6 +55,7 @@
#include <ostream> #include <ostream>
#include <iomanip> #include <iomanip>
#include <limits> #include <limits>
#include <sstream>
using namespace musik::core; using namespace musik::core;
using namespace musik::core::sdk; using namespace musik::core::sdk;

View File

@ -46,6 +46,8 @@
#include <cursespp/DialogOverlay.h> #include <cursespp/DialogOverlay.h>
#include <cursespp/Screen.h> #include <cursespp/Screen.h>
#include <sstream>
using namespace musik; using namespace musik;
using namespace musik::core; using namespace musik::core;
using namespace musik::core::sdk; using namespace musik::core::sdk;

View File

@ -38,6 +38,7 @@
#include <app/util/Playback.h> #include <app/util/Playback.h>
#include <unordered_map> #include <unordered_map>
#include <unordered_set> #include <unordered_set>
#include <iostream>
using namespace musik::cube; using namespace musik::cube;
using namespace musik::core; using namespace musik::core;

View File

@ -4,8 +4,8 @@
#define VERSION_MAJOR 0 #define VERSION_MAJOR 0
#define VERSION_MINOR 60 #define VERSION_MINOR 60
#define VERSION_PATCH 0 #define VERSION_PATCH 1
#define VERSION "0.60.0" #define VERSION "0.60.1"
namespace musik { namespace musik {
namespace cube { namespace cube {

View File

@ -44,6 +44,7 @@
#include <cursespp/Screen.h> #include <cursespp/Screen.h>
#include <algorithm> #include <algorithm>
#include <thread> #include <thread>
#include <iostream>
#ifdef WIN32 #ifdef WIN32
#include <cursespp/Win32Util.h> #include <cursespp/Win32Util.h>

View File

@ -103,7 +103,6 @@ InputOverlay& InputOverlay::SetTitle(const std::string& title) {
} }
InputOverlay& InputOverlay::SetText(const std::string& text) { InputOverlay& InputOverlay::SetText(const std::string& text) {
this->title = title;
this->textInput->SetText(text); this->textInput->SetText(text);
return *this; return *this;
} }

Binary file not shown.

View File

@ -22,8 +22,8 @@ android {
applicationId "io.casey.musikcube.remote" applicationId "io.casey.musikcube.remote"
minSdkVersion 21 minSdkVersion 21
targetSdkVersion 28 targetSdkVersion 28
versionCode 60 versionCode 61
versionName "0.60.0" versionName "0.60.1"
testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner" testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
} }

View File

@ -6,6 +6,7 @@
<uses-permission android:name="android.permission.INTERNET" /> <uses-permission android:name="android.permission.INTERNET" />
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" /> <uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />
<uses-permission android:name="android.permission.WAKE_LOCK" /> <uses-permission android:name="android.permission.WAKE_LOCK" />
<uses-permission android:name="android.permission.FOREGROUND_SERVICE" />
<permission android:name="android.permission.MEDIA_CONTENT_CONTROL" /> <permission android:name="android.permission.MEDIA_CONTENT_CONTROL" />
<application <application

View File

@ -1,5 +1,5 @@
buildscript { buildscript {
ext.kotlin_version = '1.2.71' ext.kotlin_version = '1.3.11'
repositories { repositories {
google() google()

View File

@ -92,11 +92,13 @@ class FfmpegDecoderFactory : public musik::core::sdk::IDecoderFactory {
{ ".opus", AV_CODEC_ID_OPUS }, { ".opus", AV_CODEC_ID_OPUS },
{ ".flac", AV_CODEC_ID_FLAC }, { ".flac", AV_CODEC_ID_FLAC },
{ "audio/flac", AV_CODEC_ID_FLAC }, { "audio/flac", AV_CODEC_ID_FLAC },
{ ".alac", AV_CODEC_ID_ALAC },
{ ".aac", AV_CODEC_ID_AAC }, { ".aac", AV_CODEC_ID_AAC },
{ "audio/aac", AV_CODEC_ID_AAC }, { "audio/aac", AV_CODEC_ID_AAC },
{ ".mp4", AV_CODEC_ID_MPEG4 }, { ".mp4", AV_CODEC_ID_MPEG4 },
{ "audio/mp4", AV_CODEC_ID_MPEG4 }, { "audio/mp4", AV_CODEC_ID_MPEG4 },
{ ".m4a", AV_CODEC_ID_MPEG4 }, { ".aac", AV_CODEC_ID_AAC },
{ ".m4a", AV_CODEC_ID_AAC },
{ ".mpc", AV_CODEC_ID_MUSEPACK8 }, { ".mpc", AV_CODEC_ID_MUSEPACK8 },
{ ".mp+", AV_CODEC_ID_MUSEPACK8 }, { ".mp+", AV_CODEC_ID_MUSEPACK8 },
{ ".mpp", AV_CODEC_ID_MUSEPACK8 }, { ".mpp", AV_CODEC_ID_MUSEPACK8 },

View File

@ -159,6 +159,7 @@ bool TaglibMetadataReader::CanRead(const char *extension) {
ext.compare("ape") == 0 || ext.compare("ape") == 0 ||
ext.compare("mpc") == 0 || ext.compare("mpc") == 0 ||
ext.compare("aac") == 0 || ext.compare("aac") == 0 ||
ext.compare("alac") == 0 ||
#endif #endif
ext.compare("mp3") == 0 || ext.compare("mp3") == 0 ||
ext.compare("ogg") == 0 || ext.compare("ogg") == 0 ||
@ -178,14 +179,19 @@ bool TaglibMetadataReader::Read(const char* uri, ITagStore *track) {
extension = path.substr(lastDot + 1).c_str(); extension = path.substr(lastDot + 1).c_str();
} }
bool success = false; try {
this->ReadGeneric(uri, track);
}
catch (...) {
std::cerr << "generic tag read for " << uri << "failed!";
}
if (extension.size()) { if (extension.size()) {
boost::algorithm::to_lower(extension); boost::algorithm::to_lower(extension);
if (extension == "mp3") { if (extension == "mp3") {
try { try {
success = this->ReadID3V2(uri, track); this->ReadID3V2(uri, track);
} }
catch (...) { catch (...) {
std::cerr << "id3v2 tag read for " << uri << "failed!"; std::cerr << "id3v2 tag read for " << uri << "failed!";
@ -193,14 +199,7 @@ bool TaglibMetadataReader::Read(const char* uri, ITagStore *track) {
} }
} }
try { return true;
success |= this->ReadGeneric(uri, track);
}
catch (...) {
std::cerr << "generic tag read for " << uri << "failed!";
}
return success;
} }
bool TaglibMetadataReader::ReadGeneric(const char* uri, ITagStore *target) { bool TaglibMetadataReader::ReadGeneric(const char* uri, ITagStore *target) {
@ -210,7 +209,10 @@ bool TaglibMetadataReader::ReadGeneric(const char* uri, ITagStore *target) {
TagLib::FileRef file(uri); TagLib::FileRef file(uri);
#endif #endif
if (!file.isNull()) { if (file.isNull()) {
this->SetTagValue("title", uri, target);
}
else {
TagLib::Tag *tag = file.tag(); TagLib::Tag *tag = file.tag();
if (tag) { if (tag) {
@ -221,10 +223,10 @@ bool TaglibMetadataReader::ReadGeneric(const char* uri, ITagStore *target) {
this->SetTagValue("title", uri, target); this->SetTagValue("title", uri, target);
} }
this->SetTagValue("album",tag->album(), target); this->SetTagValue("album", tag->album(),target);
this->SetSlashSeparatedValues("artist",tag->artist() , target); this->SetSlashSeparatedValues("artist", tag->artist(), target);
this->SetTagValue("genre",tag->genre(), target); this->SetTagValue("genre", tag->genre(), target);
this->SetTagValue("comment",tag->comment(), target); this->SetTagValue("comment", tag->comment(), target);
if (tag->track()) { if (tag->track()) {
this->SetTagValue("track", tag->track(), target); this->SetTagValue("track", tag->track(), target);
@ -285,12 +287,10 @@ bool TaglibMetadataReader::ReadGeneric(const char* uri, ITagStore *target) {
TagLib::AudioProperties *audio = file.audioProperties(); TagLib::AudioProperties *audio = file.audioProperties();
this->SetAudioProperties(audio, target); this->SetAudioProperties(audio, target);
}
}
return true; return true;
}
}
return false;
} }
void TaglibMetadataReader::ExtractValueForKey( void TaglibMetadataReader::ExtractValueForKey(