[core] Eliminate platform::assetRoot()

I regenerated assets.zip so that all file paths have an `assets/` prefix, as the Android AssetFileSource implementation asserts, and removed `TEST_DATA` from the paths.
This commit is contained in:
John Firebaugh
2016-01-11 15:00:56 -08:00
parent 86c8446d3a
commit 5a7d2fd60e
29 changed files with 29 additions and 89 deletions

View File

@@ -30,6 +30,7 @@ int main(int argc, char *argv[]) {
double pixelRatio = 1.0;
static std::string output = "out.png";
std::string cache_file = "cache.sqlite";
std::string asset_root = ".";
std::vector<std::string> classes;
std::string token;
bool debug = false;
@@ -48,6 +49,7 @@ int main(int argc, char *argv[]) {
("debug", po::bool_switch(&debug)->default_value(debug), "Debug mode")
("output,o", po::value(&output)->value_name("file")->default_value(output), "Output file name")
("cache,d", po::value(&cache_file)->value_name("file")->default_value(cache_file), "Cache database file name")
("assets,d", po::value(&asset_root)->value_name("file")->default_value(asset_root), "Directory to which asset:// URLs will resolve")
;
try {
@@ -64,7 +66,7 @@ int main(int argc, char *argv[]) {
using namespace mbgl;
util::RunLoop loop;
DefaultFileSource fileSource(cache_file);
DefaultFileSource fileSource(cache_file, asset_root);
// Try to load the token from the environment.
if (!token.size()) {