I'm recently starting with codenameone and I'm working on a music player app. I want to get the musics from a folder. I found out in the documentation a code about "Audio Capture & Recording".
But what I'm looking for is to just play audios from a specific folder.How can I adjust this code? I'm also not finding where these audios are being saved to.
Here's the code+ a footage of the Recording code.
Button button = new Button("musiques!");
Form hi = new Form("musiques", new BorderLayout(BorderLayout.CENTER_BEHAVIOR_CENTER_ABSOLUTE));
hi.addComponent(BorderLayout.CENTER, LayeredLayout.encloseIn(BoxLayout.encloseY(button)));
button.addActionListener((e) -> {
InputStream streamFromResource = CN.getResourceAsStream("/filename.mp3");
try {
MediaManager.createMedia(streamFromResource, "audio/mp3");
} catch (IOException ex) {
System.out.print("non");
}
});