Author Topic: LAME Delphi question about error 1  (Read 141 times)

MikeatBookup

  • Posts: 1
LAME Delphi question about error 1
« on: 28 Mar '21 - 18:24 »
First, I have read a number of web pages (twice) and I still don't understand the relationship between LAME and BASS.

I have compiled and run the LAMEEncoderTutorial in Delphi 10.4.2.

The app's exe folder contains bass.dll and lame_enc.dll

When pressing the "Encode WAV" button, LAMEEncodeFile.EncodeWAVFile() returns 1.

The only documentation I can find is BASS Encoder Library ReadMe.TXT which states:

HResult error codes:
====================

S_OK: Success.
S_FALSE: Unknown error occured or catastrophic failure.
2: lame_enc.dll could not be loaded.
3: bass.dll could not be loaded.
4: bassmix.dll could not be loaded.
5: bassenc_opus.dll could not be loaded.
6: bassenc_flac.dll could not be loaded.
7: bassenc_ogg.dll could not be loaded.
8: bass_fx.dll or bassenc_mp3.dll could not be loaded.
9: Input file could not be opened.
10: Output file could not be created.
E_INVALIDARG: Parameters specified are invalid.

No mention of what error code '1' might be.
 

Chris

  • Posts: 1933
Re: LAME Delphi question about error 1
« Reply #1 on: 28 Mar '21 - 20:38 »
Hi, no you will need "Lame.exe" and not lame_enc,
another possible way is to use the BASSenc_MP3 Extension.


Michael Leahy

  • Guest
Re: LAME Delphi question about error 1
« Reply #2 on: 29 Mar '21 - 21:01 »
I have no idea how my Delphi code would access LAME.EXE.

Chris

  • Posts: 1933
Re: LAME Delphi question about error 1
« Reply #3 on: 29 Mar '21 - 21:22 »
Take a look @ the Delphi Demo Cast (inside the Package) bass_enc
by the way its more easy to encode via the BASSenc_MP3 Extension  http://www.un4seen.com/download.php?bassenc_mp324.

Encoding as a File via BASS_Encode_MP3_StartFile
Encoding for a Cast (for Shout or Icecast) via BASS_Encode_MP3_Start......


I think a Bass Only Solution is much more easy.
« Last Edit: 29 Mar '21 - 22:29 by Chris »

Michael Leahy

  • Guest
Re: LAME Delphi question about error 1
« Reply #4 on: 30 Mar '21 - 02:12 »
I downloaded the file from http://www.un4seen.com/download.php?bassenc_mp324

In the Delphi folder there is just a unit Bassend_MP3.pas with this Uses statement:

uses BASSenc, Windows;

Where is "BASSenc?"

Ian @ un4seen

  • Administrator
  • Posts: 23553
Re: LAME Delphi question about error 1
« Reply #5 on: 30 Mar '21 - 16:28 »
You can download the BASSenc add-on from the BASS webpage (click the "BASS" link in the top-left of this page).