Feat: opus metadata encoding (#12974)
Feat: Downloading: Add opus audio metadata tags for title, author, date, and a comment tag with the originating URL This removes the DownloadManagerService.EXTRA_SOURCE field, which is always inferred from the StreamInfo.
This commit is contained in:
parent
7f57493da1
commit
49aaaebd86
5 changed files with 107 additions and 18 deletions
|
|
@ -4,6 +4,7 @@ import android.util.Log;
|
|||
|
||||
import androidx.annotation.NonNull;
|
||||
|
||||
import org.schabi.newpipe.extractor.stream.StreamInfo;
|
||||
import org.schabi.newpipe.streams.io.SharpStream;
|
||||
|
||||
import java.io.File;
|
||||
|
|
@ -30,7 +31,8 @@ public abstract class Postprocessing implements Serializable {
|
|||
public transient static final String ALGORITHM_M4A_NO_DASH = "mp4D-m4a";
|
||||
public transient static final String ALGORITHM_OGG_FROM_WEBM_DEMUXER = "webm-ogg-d";
|
||||
|
||||
public static Postprocessing getAlgorithm(@NonNull String algorithmName, String[] args) {
|
||||
public static Postprocessing getAlgorithm(@NonNull String algorithmName, String[] args,
|
||||
StreamInfo streamInfo) {
|
||||
Postprocessing instance;
|
||||
|
||||
switch (algorithmName) {
|
||||
|
|
@ -56,6 +58,7 @@ public abstract class Postprocessing implements Serializable {
|
|||
}
|
||||
|
||||
instance.args = args;
|
||||
instance.streamInfo = streamInfo;
|
||||
return instance;
|
||||
}
|
||||
|
||||
|
|
@ -75,8 +78,8 @@ public abstract class Postprocessing implements Serializable {
|
|||
*/
|
||||
private final String name;
|
||||
|
||||
|
||||
private String[] args;
|
||||
protected StreamInfo streamInfo;
|
||||
|
||||
private transient DownloadMission mission;
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue