Re: [LAD] simulating analog audio devices

From: Pieter Palmers <pieterp@email-addr-hidden>
Date: Fri Jun 01 2007 - 16:46:20 EEST

Robin Gareus wrote:
> Erik de Castro Lopo wrote:
>> Robin Gareus wrote:
>>
>> When Spice loads the libsndfile component, can the component find out
>> the inter-sample period used by Spice?
>
> no. Spice does not use a constant interval; else it would be straight
> forward to use libsamplerate.
>
>> If the above is not possible, I suggest that you up sample the audio
>> by say 128 times and then linearly interpolate to get whatever inter
>> sample values you need.
>
> sounds like a great idea.
>
> I should do that with the output too, but it's a little more complex
> there: In the beginning I've tried to take the average for all the
> "spice"-samples matching the corresponding audio-sample. I've only tried
> that up to 1/(4*Fsample) and it gave much worse results than just taking
> the closest sample... - combining interpolation and resampling could be
> the solution.
>
> now that I've got the framework, I'll dig into the details..

Since you're patching ngspice anyway, maybe introducing a fixed-timestep
behavior into ngspice is easier? IMHO it's the 'correct' solution (cfr
other mails).

Pieter

_______________________________________________
Linux-audio-dev mailing list
Linux-audio-dev@email-addr-hidden
http://lists.linuxaudio.org/mailman/listinfo.cgi/linux-audio-dev
Received on Fri Jun 1 20:15:02 2007

This archive was generated by hypermail 2.1.8 : Fri Jun 01 2007 - 20:15:02 EEST