Downloading music files

To develop and test the application, you are going to need at least one music file containing metadata such as author, album title, and cover image.

We are going to use the Free Music Archive website to grab some files and metadata. However, feel free to use your own content once you've finished this chapter.

Follow these steps to get started:

  1. Navigate to the Free Music Archive website (http://freemusicarchive.org) as follows:

  1. Before you start downloading files, create a separate music directory. This is where we will store all of our media files for our application.
  2. Switch to your Terminal window or Command Prompt and run the following commands:
mkdir music
open .

The preceding commands create a folder called music and open the Finder or Explorer so that we can observe its contents.

  1. Next, find the Equilibrium I (Cello version) by David Hilowitz file. It should be available at http://freemusicarchive.org/music/David_Hilowitz/Equilibrium_I_Cello_version/:

  1. Download the music file; it should be named David_Hilowitz_-_Equilibrium_I_Cello_version.mp3.
  2. Also, right-click the album cover image and save it locally; we are going to use this later.
You can find all the music files for this chapter, along with the complete project code, in this book's GitHub repository: https://github.com/PacktPublishing/Electron-Projects/tree/master/Chapter06/music.

At this point, we have created a separate folder so that we can store all of our multimedia resources. You also have an experimental music file and an image to use as an album cover. In the next section, we are going to learn how to set up the player component and play the music file we just retrieved.

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset