m4a & ogg

Sorry if it has been asked before (I haven't found something while searching for either m4a or ogg) or if it is the wrong forum.

1. I have a project where I have one file only in the ogg format and it works.
Why do I need both?

2. If I have a .wav/.mp3/.midi file, how can I get a .ogg and a .m4a file having the same content?
1. Mostly for androids. If you don't want to export on mobiles, you don't need m4a.
2. Conversion.
Which conversion software would you recommend?
Audacity should do the job.
Why do I need both?
basically someone needs to pay for the decoder licence so that the compressed audio can be played.

this usually is the manufacturer of the device, but those only pay for one codec - after all conversion programs are usually free.
So you as the developer can either provide both formats and let the engine check and select which can be played with the build-in codec of the device, or you'll have to pay for integrating a player-licence into the game project.

guess what Kadokawa selected? Because this way no user needs to pay additional licences, they just have to provide both formats to cover all devices.
Or they could've just used mp3 which is license-free.

Edit: Granted, it's possible that MV was developed before licensing for the format was removed, in which case I kind of hope the next RM embraces this.
@Poryg: Thank you so much.
@Andar: Thanks for the detailed explanation.
BTW, to batch convert files in audacity, the proper menu command is

Tools -> Macros -> OGG Conversion

They recently changed how you do that, so the old guides will tell you to click on things that don't exist.

Original thread: https://forums.rpgmakerweb.com/threads/m4a-ogg.114307/