English Language flag
// Log In
// CVSweb
Project: FreeWRT
// Summary // Activity // Search // Tracker // Lists // News // SCM // Wiki

SCM Repository

ViewVC logotype

Contents of /branches/freewrt_1_0/package/esound/patches/patch-esd_c

Parent Directory Parent Directory | Revision Log Revision Log


Revision 2552 - (show annotations) (download)
Sat May 19 18:53:25 2007 UTC (6 years, 9 months ago) by wbx
File size: 761 byte(s)
add esd sound daemon, nice for network sound card, idea and esd patch from Sven Geggus
1 $FreeWRT$
2
3 cast to double, to avoid sinf, patch from Sven Gugges
4
5 --- esound-0.2.38.orig/esd.c 2007-05-03 22:28:35.000000000 +0200
6 +++ esound-0.2.38/esd.c 2007-05-19 17:21:23.000000000 +0200
7 @@ -131,14 +131,14 @@ void set_audio_buffer( void *buf, esd_fo
8 {
9 case ESD_BITS8:
10 for ( i = 0 ; i < length ; i+=2 ) {
11 - sample = sin( (float)(i+offset) * kf );
12 + sample = sin( (double)(i+offset) * kf );
13 uc_buf[i] = 127 + magl * sample;
14 uc_buf[i+1] = 127 + magr * sample;
15 }
16 break;
17 case ESD_BITS16: /* assume same endianness */
18 for ( i = 0 ; i < length ; i+=2 ) {
19 - sample = sin( (float)(i+offset) * kf );
20 + sample = sin( (double)(i+offset) * kf );
21 ss_buf[i] = magl * sample;
22 ss_buf[i+1] = magr * sample;
23 }

root@freewrt.org:443
ViewVC Help
Powered by ViewVC 1.1.20