How would I extract coverart from a PlayBin?
codedcosmos opened this issue · 1 comments
codedcosmos commented
I want to create a BufferedImage from a music files cover/song art.
I can get tag details with this
PlayBin playBin = new PlayBin("AudioPlayer");
playBin.setInputFile(new File("InsertMusicFileHere"));
playBin.getBus().connect((Bus.TAG) (source, tagList) -> {
for (String tagName : tagList.getTagNames()) {
// Each tag can have multiple values, so print them all.
for (Object tagData : tagList.getValues(tagName)) {
System.out.printf("[%s]=%s\n", tagName, tagData);
}
}
});
There is an image tag:
[image]=
However I don't think its quite what I want.
Sorry if this is in the wrong place
Thanks
neilcsmith-net commented
Yes, please use the mailing list for support queries - https://groups.google.com/forum/#!forum/gstreamer-java If nothing else, you'll reach a lot more people that way! 😄
Also, can you add this code in a post to the list, along with whether tagData
is actually null
there or a particular Java type? And what upstream GStreamer / native type it should be if you already know?
Thanks.