From 949f4ee260419d8c8ff08464c07c04c5386981ae Mon Sep 17 00:00:00 2001 From: vapormusic Date: Thu, 21 Jul 2022 22:41:47 +0700 Subject: [PATCH] lofty --- Cargo.toml | 2 +- build/_deps/zlib-src | 1 + build/taglib/src/taglib | 1 + examples/index.js | 2 +- output.json | 2 +- 5 files changed, 5 insertions(+), 3 deletions(-) create mode 160000 build/_deps/zlib-src create mode 160000 build/taglib/src/taglib diff --git a/Cargo.toml b/Cargo.toml index d0207f4..c3b4d92 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -11,7 +11,7 @@ crate-type = ["cdylib"] # See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html [dependencies] -lofty = "0.7.1" +lofty = { git = "https://github.com/Serial-ATA/lofty-rs", branch = "main" } base64 = "0.13.0" walkdir = "2.3.2" diff --git a/build/_deps/zlib-src b/build/_deps/zlib-src new file mode 160000 index 0000000..b56a2fd --- /dev/null +++ b/build/_deps/zlib-src @@ -0,0 +1 @@ +Subproject commit b56a2fd0b126cfe5f13e68ab9090cd4f6a773286 diff --git a/build/taglib/src/taglib b/build/taglib/src/taglib new file mode 160000 index 0000000..c8b3944 --- /dev/null +++ b/build/taglib/src/taglib @@ -0,0 +1 @@ +Subproject commit c8b39449c383158b4d669ee97374543f9d0733bf diff --git a/examples/index.js b/examples/index.js index eb5e052..4553448 100644 --- a/examples/index.js +++ b/examples/index.js @@ -2,7 +2,7 @@ const { parseFile } = require("../index.node"); const fs = require('fs'); // json data -let jsonData = parseFile("e:\\VA\\Music\\Osu music pack completed\\besssst.mp3"); +let jsonData = parseFile("e:\\VA\\Music\\My Music\\Feel_The_Power_of_Now.mp3"); let u = jsonData // replace artwork with artwork size in console.log u["artwork"] = (u["artwork"] ?? '').length diff --git a/output.json b/output.json index 6b39481..088b803 100644 --- a/output.json +++ b/output.json @@ -1 +1 @@ -{"title":"いかないで","artist":"KK","album":"小音","genre":"0","bitrate":192,"sample_rate":44100,"bit_depth":0,"duration_in_ms":199,"year":0,"track_number":0,"disc_number":0,"artwork":901936} \ No newline at end of file +{"title":"0","artist":"0","album":"0","genre":"0","bitrate":128,"sample_rate":44100,"bit_depth":0,"duration_in_ms":223112,"year":0,"track_number":0,"disc_number":0,"lossless":false,"container":"MP3","artwork":0} \ No newline at end of file