I think it is possible if the DLL is using the Windows multimedia file I/O services. There is a component floating around called TMediaPlayerMemoryExtension, or TMediaPlayerMemoryFile which does the job. But you have to use a pretend extension which you register to a callback with  mmioInstallIOProc and append a "+" to the end of the file. When the DLL calls the mciSendCommand function with mci_open on the file (eg, "SomeFile.MMM+") the callback you register with mmioInstallIOProc will be called and allow you to pass the memory data.

If you have trouble tracking the component down then let me know and I will have a hunt on my hard drive. This was discussed not so long ago on the list so a search of the list archive should provide all you need.

Cheers,
Phil.

Ross Levis wrote:
I doubt this is possible but I thought I would ask anyway.
 
I have a 3rd party DLL which opens a file that I specify.  Specially it is an audio decoder plugin which decodes MP3 to PCM.
 
What I would like to do is use this plugin to access a memory location which contains MP3 data instead of a file.
 
Is it possible to set up something in Windows where you specify a filename but actually accesses memory instead.
 
This will be used with encrypted mp3 files so they are not accessible to anyone to steal for their own use.  I am currently opening the file, decrypting, and then saving a temporary file to disk.  But this has 2 disadvantages.  It is very slow, so lots of latency between asking a track to play and hearing it.  And also, while the file is decrypted on disk, someone can steal it.
 
The DLL cannot be modified.  Is there any solution?
 
Thanks,
Ross.

_______________________________________________ Delphi mailing list [email protected] http://ns3.123.co.nz/mailman/listinfo/delphi


begin:vcard
fn:Phil Middlemiss
n:Middlemiss;Phil
org:Vision Software, MTS Ltd
email;internet:[EMAIL PROTECTED]
title:Project Leader
tel;work:+64 7 3480001
tel;cell:+64 27 4592648
x-mozilla-html:TRUE
url:http://www.tumonz.co.nz
version:2.1
end:vcard

_______________________________________________
Delphi mailing list
[email protected]
http://ns3.123.co.nz/mailman/listinfo/delphi

Reply via email to