Solved

Playing Real Audio Sound Files in Delphi

Posted on 1998-08-17
12
525 Views
Last Modified: 2013-11-17
Basically, my question is, can you play Real Audio (*.ra) sound files from a Delphi program.

I have a program where I want to play stored sound files. These sound files a full length songs, and by using the WAV format it just takes up too much space to store these files. By converting them to Real Audio format it reduces the size of a sound file to about 20% of it's original WAV format size.

So, is it possible to play a non-Windows sound file from a Delphi program? Or is there another sound format out there that will save me space? Is it possible to get the file format of a Real Audio file and program it at the lowest level to play it?

Thanks.
0
Comment
Question by:rocknroll
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 5
  • 4
  • 2
  • +1
12 Comments
 
LVL 8

Expert Comment

by:ZifNab
ID: 1336404
do you mean just audio cd tracks?
0
 
LVL 4

Expert Comment

by:d003303
ID: 1336405
Another good format is MPEG-Layer-3 Audio that has a very effective compression (nearly CD-Quality) and is most common on the net. There are several MP3 sources on the net, but all in C. I'll take a look if there are some free libraries to use.

Slash/d003303
0
 
LVL 1

Expert Comment

by:Greedy
ID: 1336406
You can embed the Real Audio control by doing this.
These instructions are for D3.

From the main menu in Delphi go to Component | Import ActiveX Control...
Select RealAudio ActiveX Control Library from the list and click on the Install button

Install it into a new package (second tab)
it then builds the new package and installs it into you component pallet...usualy under the ActiveX Tab.  Then just drop this on the form and your all done...for some reason it doesn't size itself very well so you'll have to resize it...you may also need to right click on it and go to scale to get it to look right.

MP3 might be a better choice because it's not as propriatary as this thing is...but I have never seen anything comparing MP3 to real audio format so I don't know what is better/smaller...there are several MP3 libs for Delphi and some even have MOD file players build into them too...Oh well, hope this gives you some help or ideas on what you want to do.

0
Salesforce Has Never Been Easier

Improve and reinforce salesforce training & adoption using WalkMe's digital adoption platform. Start saving on costly employee training by creating fast intuitive Walk-Thrus for Salesforce. Claim your Free Account Now

 

Author Comment

by:rocknroll
ID: 1336407
I've checked out the *.MP3 files. The compression rate doesn't seem to be as good as *.RA files, but I get the feeling that they are more easy to work with. I couldn't find a lot of info on *.MP3 files and how to play them within a program.

Is this more difficult than I imagined? I'm using Delphi 2 by the way. Is there any code out there that will play an *.MP3 audio file?


0
 
LVL 8

Expert Comment

by:ZifNab
ID: 1336408
rocknroll,

 look at these, that what I know about them :

there are components at : http://www.delphipages.com/ 

but they are made to talk with winamp, ...

other's, but not winamp 'needers'

    http://www.ig.com.ua/wabbit/programs/mpegplay.html 

    http://www.dialog-medien.de/html/products.html 

    http://www.ege.edu.tr/delphi/ftp/d20free/mpegplay.zip 

Regards, Zif.

0
 
LVL 4

Expert Comment

by:d003303
ID: 1336409
A good library, including source and demo program is on the DSP. Take a look at

http://sunsite.icm.edu.pl/delphi/ftp/d20free/mpegplay.zip

The demo is not that portable. You will have to modify some properties of MPlayer in object inspector. Change EndPos to 0 to play the entire file and set PathToDLL to an empty string. Put the mpegdll.dll in the same directory as your project and be happy !

Slash/d003303
0
 
LVL 8

Expert Comment

by:ZifNab
ID: 1336410
d003303, euhm, no problem, but the answer you gave : mpegplay.zip... is already proposed in my comment. Zif.
0
 
LVL 4

Expert Comment

by:d003303
ID: 1336411
uh, sorry ! Did not read through it well enough I think...
I did not intend that, I downloaded the component a week ago and did not have much time for testing around until yesterday.
Sorry again.

rocknroll,
if this is what you need please reject my answer, Zif was first !

Slash/d003303
0
 
LVL 8

Expert Comment

by:ZifNab
ID: 1336412
d003303, no problem, thought already that you didn't read it thouroughly :-)). Bad, bad boy, tsss, tsss, ..., has your mother never told... ;-))))). C.u. Zif.
0
 
LVL 4

Expert Comment

by:d003303
ID: 1336413
...she tried, but seems that she only tried, no success ;-))
0
 

Author Comment

by:rocknroll
ID: 1336414
Thanks guys,

Yes, this is what I was looking for.

d003303, I rejected your answer like you said. Yes, apparently Zif was first. Now, how do I allocate the points for this question?
0
 
LVL 8

Accepted Solution

by:
ZifNab earned 200 total points
ID: 1336415
rocknroll,

        look at these, that what I know about them :

       there are components at : http://www.delphipages.com/ 

       but they are made to talk with winamp, ...

       other's, but not winamp 'needers'

           http://www.ig.com.ua/wabbit/programs/mpegplay.html

           http://www.dialog-medien.de/html/products.html

           http://www.ege.edu.tr/delphi/ftp/d20free/mpegplay.zip

       Regards, Zif.

Like this, now you can grade this Q. but, heck, it was no problem if you gave the points to   d003303 (easy, fo me to say now :-)) ...
0

Featured Post

PeopleSoft Has Never Been Easier

PeopleSoft Adoption Made Smooth & Simple!

On-The-Job Training Is made Intuitive & Easy With WalkMe's On-Screen Guidance Tool.  Claim Your Free WalkMe Account Now

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

In this article, you will read about the trends across the human resources departments for the upcoming year. Some of them include improving employee experience, adopting new technologies, using HR software to its full extent, and integrating artifi…
Developer portfolios can be a bit of an enigma—how do you present yourself to employers without burying them in lines of code?  A modern portfolio is more than just work samples, it’s also a statement of how you work.
The viewer will learn how to successfully download and install the SARDU utility on Windows 8, without downloading adware.
Monitoring a network: why having a policy is the best policy? Michael Kulchisky, MCSE, MCSA, MCP, VTSP, VSP, CCSP outlines the enormous benefits of having a policy-based approach when monitoring medium and large networks. Software utilized in this v…

729 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question