@@ -307,8 +307,8 @@ static int FindHostApi( PaDeviceIndex device, int *hostSpecificDeviceIndex )
307307
308308static void AddOpenStream ( PaStream * stream )
309309{
310- (( PaUtilStreamRepresentation * ) stream )-> nextOpenStream = firstOpenStream_ ;
311- firstOpenStream_ = ( PaUtilStreamRepresentation * ) stream ;
310+ (stream )-> nextOpenStream = firstOpenStream_ ;
311+ firstOpenStream_ = stream ;
312312}
313313
314314
@@ -1372,7 +1372,7 @@ PaError PaUtil_ValidateStreamPointer( PaStream* stream )
13721372
13731373 if ( stream == NULL ) return paBadStreamPtr ;
13741374
1375- if ( (( PaUtilStreamRepresentation * ) stream )-> magic != PA_STREAM_MAGIC )
1375+ if ( (stream )-> magic != PA_STREAM_MAGIC )
13761376 return paBadStreamPtr ;
13771377
13781378 return paNoError ;
@@ -1394,7 +1394,7 @@ PaError Pa_CloseStream( PaStream* stream )
13941394
13951395 if ( result == paNoError )
13961396 {
1397- interface = PA_STREAM_INTERFACE ( stream ) ;
1397+ interface = stream -> streamInterface ;
13981398
13991399 /* abort the stream if it isn't stopped */
14001400 result = interface -> IsStopped ( stream );
@@ -1423,14 +1423,14 @@ PaError Pa_SetStreamFinishedCallback( PaStream *stream, PaStreamFinishedCallback
14231423
14241424 if ( result == paNoError )
14251425 {
1426- result = PA_STREAM_INTERFACE ( stream ) -> IsStopped ( stream );
1426+ result = stream -> streamInterface -> IsStopped ( stream );
14271427 if ( result == 0 )
14281428 {
14291429 result = paStreamIsNotStopped ;
14301430 }
14311431 if ( result == 1 )
14321432 {
1433- PA_STREAM_REP ( stream ) -> streamFinishedCallback = streamFinishedCallback ;
1433+ stream -> streamFinishedCallback = streamFinishedCallback ;
14341434 result = paNoError ;
14351435 }
14361436 }
@@ -1451,14 +1451,14 @@ PaError Pa_StartStream( PaStream *stream )
14511451
14521452 if ( result == paNoError )
14531453 {
1454- result = PA_STREAM_INTERFACE ( stream ) -> IsStopped ( stream );
1454+ result = stream -> streamInterface -> IsStopped ( stream );
14551455 if ( result == 0 )
14561456 {
14571457 result = paStreamIsNotStopped ;
14581458 }
14591459 else if ( result == 1 )
14601460 {
1461- result = PA_STREAM_INTERFACE ( stream ) -> Start ( stream );
1461+ result = stream -> streamInterface -> Start ( stream );
14621462 }
14631463 }
14641464
@@ -1477,10 +1477,10 @@ PaError Pa_StopStream( PaStream *stream )
14771477
14781478 if ( result == paNoError )
14791479 {
1480- result = PA_STREAM_INTERFACE ( stream ) -> IsStopped ( stream );
1480+ result = stream -> streamInterface -> IsStopped ( stream );
14811481 if ( result == 0 )
14821482 {
1483- result = PA_STREAM_INTERFACE ( stream ) -> Stop ( stream );
1483+ result = stream -> streamInterface -> Stop ( stream );
14841484 }
14851485 else if ( result == 1 )
14861486 {
@@ -1503,10 +1503,10 @@ PaError Pa_AbortStream( PaStream *stream )
15031503
15041504 if ( result == paNoError )
15051505 {
1506- result = PA_STREAM_INTERFACE ( stream ) -> IsStopped ( stream );
1506+ result = stream -> streamInterface -> IsStopped ( stream );
15071507 if ( result == 0 )
15081508 {
1509- result = PA_STREAM_INTERFACE ( stream ) -> Abort ( stream );
1509+ result = stream -> streamInterface -> Abort ( stream );
15101510 }
15111511 else if ( result == 1 )
15121512 {
@@ -1528,7 +1528,7 @@ PaError Pa_IsStreamStopped( PaStream *stream )
15281528 PA_LOGAPI (("\tPaStream* stream: 0x%p\n" , stream ));
15291529
15301530 if ( result == paNoError )
1531- result = PA_STREAM_INTERFACE ( stream ) -> IsStopped ( stream );
1531+ result = stream -> streamInterface -> IsStopped ( stream );
15321532
15331533 PA_LOGAPI_EXIT_PAERROR ( "Pa_IsStreamStopped" , result );
15341534
@@ -1544,7 +1544,7 @@ PaError Pa_IsStreamActive( PaStream *stream )
15441544 PA_LOGAPI (("\tPaStream* stream: 0x%p\n" , stream ));
15451545
15461546 if ( result == paNoError )
1547- result = PA_STREAM_INTERFACE ( stream ) -> IsActive ( stream );
1547+ result = stream -> streamInterface -> IsActive ( stream );
15481548
15491549
15501550 PA_LOGAPI_EXIT_PAERROR ( "Pa_IsStreamActive" , result );
@@ -1571,7 +1571,7 @@ const PaStreamInfo* Pa_GetStreamInfo( PaStream *stream )
15711571 }
15721572 else
15731573 {
1574- result = & PA_STREAM_REP ( stream ) -> streamInfo ;
1574+ result = & stream -> streamInfo ;
15751575
15761576 PA_LOGAPI (("Pa_GetStreamInfo returned:\n" ));
15771577 PA_LOGAPI (("\tconst PaStreamInfo*: 0x%p:\n" , result ));
@@ -1607,7 +1607,7 @@ PaTime Pa_GetStreamTime( PaStream *stream )
16071607 }
16081608 else
16091609 {
1610- result = PA_STREAM_INTERFACE ( stream ) -> GetTime ( stream );
1610+ result = stream -> streamInterface -> GetTime ( stream );
16111611
16121612 PA_LOGAPI (("Pa_GetStreamTime returned:\n" ));
16131613 PA_LOGAPI (("\tPaTime: %g\n" , result ));
@@ -1637,7 +1637,7 @@ double Pa_GetStreamCpuLoad( PaStream* stream )
16371637 }
16381638 else
16391639 {
1640- result = PA_STREAM_INTERFACE ( stream ) -> GetCpuLoad ( stream );
1640+ result = stream -> streamInterface -> GetCpuLoad ( stream );
16411641
16421642 PA_LOGAPI (("Pa_GetStreamCpuLoad returned:\n" ));
16431643 PA_LOGAPI (("\tdouble: %g\n" , result ));
@@ -1670,10 +1670,10 @@ PaError Pa_ReadStream( PaStream* stream,
16701670 }
16711671 else
16721672 {
1673- result = PA_STREAM_INTERFACE ( stream ) -> IsStopped ( stream );
1673+ result = stream -> streamInterface -> IsStopped ( stream );
16741674 if ( result == 0 )
16751675 {
1676- result = PA_STREAM_INTERFACE ( stream ) -> Read ( stream , buffer , frames );
1676+ result = stream -> streamInterface -> Read ( stream , buffer , frames );
16771677 }
16781678 else if ( result == 1 )
16791679 {
@@ -1710,10 +1710,10 @@ PaError Pa_WriteStream( PaStream* stream,
17101710 }
17111711 else
17121712 {
1713- result = PA_STREAM_INTERFACE ( stream ) -> IsStopped ( stream );
1713+ result = stream -> streamInterface -> IsStopped ( stream );
17141714 if ( result == 0 )
17151715 {
1716- result = PA_STREAM_INTERFACE ( stream ) -> Write ( stream , buffer , frames );
1716+ result = stream -> streamInterface -> Write ( stream , buffer , frames );
17171717 }
17181718 else if ( result == 1 )
17191719 {
@@ -1745,7 +1745,7 @@ signed long Pa_GetStreamReadAvailable( PaStream* stream )
17451745 }
17461746 else
17471747 {
1748- result = PA_STREAM_INTERFACE ( stream ) -> GetReadAvailable ( stream );
1748+ result = stream -> streamInterface -> GetReadAvailable ( stream );
17491749
17501750 PA_LOGAPI (("Pa_GetStreamReadAvailable returned:\n" ));
17511751 PA_LOGAPI (("\tPaError: %d ( %s )\n" , result , Pa_GetErrorText ( result ) ));
@@ -1774,7 +1774,7 @@ signed long Pa_GetStreamWriteAvailable( PaStream* stream )
17741774 }
17751775 else
17761776 {
1777- result = PA_STREAM_INTERFACE ( stream ) -> GetWriteAvailable ( stream );
1777+ result = stream -> streamInterface -> GetWriteAvailable ( stream );
17781778
17791779 PA_LOGAPI (("Pa_GetStreamWriteAvailable returned:\n" ));
17801780 PA_LOGAPI (("\tPaError: %d ( %s )\n" , result , Pa_GetErrorText ( result ) ));
0 commit comments