computing - www.mjo.co.uk

Programming Projects

The CD-Player/Converter

Introduction - Foreword-Preamble

An Application/Utility to Play and Convert CD Audio Tracks, with the ability to generate a CD Fingerprint and ID, to enable a Track Name List to be downloaded from the FreeCD Database. There are no third party inclusions within the Software itself, however, currently MP3 conversion does require the Lame Executable to be available alongside the main program. I opted for the Lame Executable, rather than the dll as I felt that the inclusion and interfacing requirement appears to be much simpler, and more robust than other methods, and also felt that if Lame is updated, the command interfacing would remain static, hopefully making any Lame update replacement a simple affair. Lame is not included with the program, and where MP3 conversion is required it must be downloaded separately from the Official Lame Site. All the other processing - including .wav conversion is taken care of within the confines of the program itself, and only the MP3 conversion requires any additional files to be present! The Lame size overhead is quite large, considering that the current Lame executable is 938KB, and my program provides all the other functionality at a mere 50KB, Something to look at in the future I think - If I live long enough!

The Opening Dialog

The Opening Application Dialog


Fig.1 - Opening Dialog

On starting the Application, the related PC will be checked for ALL available Drives, each one being checked for readiness, and whether or not the Drive contains a Audio CD. At this stage a Dialog report will be made of the Drive status. Each available drive can then be Ejected/Loaded or Selected if an Audio CD is Loaded.

Audio CD Loaded

If an Audio CD is Available or loaded by the Application, the Dialog will display the CD Audio Tracks by Number and Duration, and which will also allow the CD ID button to become active!


Fig.2 - Audio CD Loaded

At this stage the CD tracks can be Selected and Played or Converted as required, however, by clicking the CD ID Button, a CD Fingerprint and Fingerprint ID will be generated for the Audio CD/Album, to allow for a Download of the Actual Album Track names from the FreeCD Database.


Fig.3 - Fingerprint/ID

Optional Processing

If the CD ID Button is Active and Selected, the application will check to ascertain whether or not a local track list has been previously downloaded/available, and will provide a dialog depending on the outcome of the check, as shown below:


Fig.4a - Local Track List Available
 
Fig.4b - Check for a Track Listing

Option: No Album Track List Available

If no local track list is available, the application can optionally check the FreeDB to see if a track listing is available. To add a little clarity to the process of checking the FreeDB a series of advice dialogs are presented which provide feedback on the various stages of the process, these are by no means exhaustive, as there are many other monitors within the program that can, and will indeed provide advice dialogs to cater for any unforseen Events or Exceptions etc that may occur! The first check made, is to ensure there is a valid internet connection available, and from that being established, some of the main interfacing dialogs that will presented are as follows:


Fig.5 - FreeDB Connection Dialogs

A FreeDB Connection is established, and a feedback response is returned providing a Code, and the Mirror/Server Details, and 'a ready' status at the current Date/Time. Log-In credentials are then sent to the Server and a 'Hello and welcome response is sent back, confirming the Log-In details and the running Application/ID. The CD Fingerprint is submitted, and the DB checked for availablity, under normal circumstances a single exact match will be advised, as shown below.


Fig.6 - FreeDB Check Status

However, there are occasions - as shown below - when mutiple inexact matches are found, the user will then need to make a selection based on the results! - this was discovered whilst entering a particular CD from my Collection, when I was first testing the application, so obviously this facility had to be added to the basic development, and an additional selection process added to allow for this, the example below is the actual CD that first prompted this action.


Fig.7 - Inexact Matches Found
 
Fig.8 - Listing Provision

In the case of this application, and a match being found, Two files are created and Saved, the first is the Full Server Response Stream provided by the Server, the Second is purely a simple track list file parsed from the original response stream. This was done this way, so as to keep a record of the full server response detail - for reference - which contains far more information than is required by the track list update, and the provision of a simple track title list file to update the CD content display as required - Connection to the FreeDB is then released.


Fig.9 - FreeDB Connection Release

Note: If no previous records exist, an Album Folder will be created in the location of where the application is running from, where all records are directed and stored, a Cover Sub-Folder will also be created within it.

Option: Local Track List Available

If a Track List is already available, it will provide the option to update the Track List, as per the dialog advisor shown at Fig.10a. If the track list has just been downloaded from the Database the update option with be as Fig.10b, both providing the same end result, which will follow, and will also allow the Cover Selector to become active if an Album Cover Image is also available.


Fig.10a - Local Track List Option
 
Fig.11 - Track List Update

Fig.10b - FreeDB Track List Option

If the Cover Selector has become active and selected, the Dialog will be resized to present the Cover Image, along with the Album Title/Details. Album details are truncated on a word break if the detail is too large to fit within the confines of Cover Image width area!


Fig.12 - Application Dialog with Cover

Once a Track[s] has been Selected both the Convert and Play Options become active allowing a choice to be made. Selecting the Convert Option will re-adjust the Application Dialog again, this time deselecting the Cover Image and Bringing up the Conversion Options as shown at Fig.13


Fig.13 - Application Dialog with Convert Option

As can be seen from the Image at Fig.13, the track[s] can be converted to Wave and/or MP3 Files with a Selectable Bitrate and Sampling Rate to a Folder of choice, set by the Select Button. A Status Bar provides an indication of the conversion progress!


Fig.14 - Conversion Process

All Images Captured (With Cursor) using: SCREENCAPTURE by JRS

On completion of the Conversion the Read/Conversion speed will be advised in the Status Bar.

As an example to the conversion process, using the Track as illustrated in the above dialogs ie. Story of the Blues. The Wave Format translation size is 68,801KB, in MP3 this reduces dramatically in Size to only 6,243KB a massive reduction in size, and as a consequence storage space, with virtually no perceptable reduction in Audio Quality, certainly nothing I could hear using Beyerdynamic DT770 PRO Headphones for the listening/comparison tests!

Epilogue

Full CD Album Translation - Gary Moore - Ballads & Blues 1982-1994

WAV Format: 717MB
MP3 Format: 65.1MB [@128/22.05]



General Disclaimer/Liability Limitation - Legal Issues

All Software, Manuals and Opinions Irrespective or Regardless of Complexity or Simplicity are Governed and Constrained by the MjO computing Terms and Conditions, and also as Set-Out Herein.

• This Application and Manual are Copyright © MjO-JRS - But are Completely Free to Use! [1]

This Software is provided "As Is" and in no event shall I, the author, be liable for any consequential, special, incidental or indirect damages of any kind arising out of the delivery, performance, use or inability to use this Software. As with any Software or Projects undertaken or written by me, it has been done with great care, but I do not warrant that the Software is Error Free. You may 'Not' Attempt to Reverse Compile, Modify or otherwise translate or Disassemble the Software in whole or in Part, or make any adjustments to the Useage Manual.

You the User must agree to the said terms and conditions prior to using this Software and assume all responsibility in its use and utilisation. Use of this Software shall be Deemed to be your absolute and unequivical acceptance and agreement with these terms and conditions as set out herein and in all cases. If your Country is not party to the constraints of the Limitation of Liability, this exclusion will not apply to you, and in all such situations you are 'Not Allowed' under any circumstances whatsoever or wheresoever to download or use this Software.

The Software will always be supplied with an MD5 and/or SHA1 Checksum Please Ensure that you use this to ascertain - as far as possible - that the Data has not been tampered with, or has not been infected with any Destructive Code or Virus, since being initially archived by me the author, but, the end user is Always advised to Virus Check any executable file including this one, by means and/or methods not related to the provision of this Software, or indeed to the provision of any Software to ensure Complete Data and System Integrity.

Reference [1]
[a] Free Useage is defined and applicable to the Limited Public Release as outlined in the Download Area, There is 'NO' Software whatsover hosted on this Server, and should you have access to my Applications and/or Utilities, you are advised to use the Encrypted ID as instructed which will in turn direct you to the Download Menu of the Anonymous Host Server! You agree that any software or material downloaded will be for your own personal, private and non-commercial use only, and in addition agree not to distribute, host, or otherwise translate the said material by any manner or means whatsoever!

[b] Where certain specific applications have been designed and developed to interact with, and/or Download information from WebSites other than mjo.co.uk - such as this particular one, which gets its information from the FreeCDdB, it will be the total responsibility of the End User to establish and ascertain that they do indeed have permission to do so, either by this being a well known public fact, or providing proof of this, otherwise any Download of these type of Applications will 'NOT' be Allowed or Possible!

[c] Obviously this Application can be used to make a WAV or MP3 Copy of any audio album/track and so it is the duty of this reference to remind the user to be mindful of any Copyright Issue there may be, and not to use such products to promote piracy issues! and not to make copies of any product that the user doesn't already personally own! ... Thank You ...

Legal Terms and Conditions © MjO-JRS 1996-2016