[PD-cvs] pd/src d_soundfile.c,1.1.1.2.2.24,1.1.1.2.2.25

Tim Blechmann timblech at users.sourceforge.net
Sat Oct 9 02:11:58 CEST 2004


Update of /cvsroot/pure-data/pd/src
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv17545

Modified Files:
      Tag: devel_0_37
	d_soundfile.c 
Log Message:
fixed soundfiler for aligned t_garrays

Index: d_soundfile.c
===================================================================
RCS file: /cvsroot/pure-data/pd/src/d_soundfile.c,v
retrieving revision 1.1.1.2.2.24
retrieving revision 1.1.1.2.2.25
diff -C2 -d -r1.1.1.2.2.24 -r1.1.1.2.2.25
*** d_soundfile.c	13 Sep 2004 12:37:48 -0000	1.1.1.2.2.24
--- d_soundfile.c	9 Oct 2004 00:11:56 -0000	1.1.1.2.2.25
***************
*** 1403,1407 ****
  	    munlockall();
  #endif
! 	    nvecs[i]=getbytes (finalsize * sizeof(t_float));
  #ifdef _POSIX_MEMLOCK
  	    mlockall(MCL_FUTURE);
--- 1403,1407 ----
  	    munlockall();
  #endif
! 	    nvecs[i]=getalignedbytes (finalsize * sizeof(t_float));
  #ifdef _POSIX_MEMLOCK
  	    mlockall(MCL_FUTURE);
***************
*** 1413,1417 ****
  		for (j=0; j!=i;++j)
  		    /* if the resizing fails, we'll have to free all arrays again */
! 		    freebytes (nvecs[i],finalsize * sizeof(t_float)); 
  		goto done;
  	    }
--- 1413,1417 ----
  		for (j=0; j!=i;++j)
  		    /* if the resizing fails, we'll have to free all arrays again */
! 		    freealignedbytes (nvecs[i],finalsize * sizeof(t_float)); 
  		goto done;
  	    }
***************
*** 1428,1432 ****
  	    munlockall();
  #endif
! 	    nvecs[i] = getbytes (vecsize[i] * sizeof(t_float));
  #ifdef _POSIX_MEMLOCK
  	    mlockall(MCL_FUTURE);
--- 1428,1432 ----
  	    munlockall();
  #endif
! 	    nvecs[i] = getalignedbytes (vecsize[i] * sizeof(t_float));
  #ifdef _POSIX_MEMLOCK
  	    mlockall(MCL_FUTURE);
***************
*** 1438,1442 ****
  		for (j=0; j!=i;++j)
  		    /* if the resizing fails, we'll have to free all arrays again */
! 		    freebytes (nvecs[i],vecsize[i] * sizeof(t_float)); 
  		goto done;
  	    }
--- 1438,1442 ----
  		for (j=0; j!=i;++j)
  		    /* if the resizing fails, we'll have to free all arrays again */
! 		    freealignedbytes (nvecs[i],vecsize[i] * sizeof(t_float)); 
  		goto done;
  	    }
***************
*** 1501,1505 ****
      /* free the old arrays */
      for (i = 0; i < argc; i++)
! 	freebytes(vecs[i], vecsize[i] * sizeof(t_float));
  
      fclose(fp);
--- 1501,1505 ----
      /* free the old arrays */
      for (i = 0; i < argc; i++)
! 	freealignedbytes(vecs[i], vecsize[i] * sizeof(t_float));
  
      fclose(fp);
***************
*** 1712,1716 ****
  	munlockall();
  #endif
! 	nvec = getbytes(n * elemsize);
  #ifdef _POSIX_MEMLOCK
  	mlockall(MCL_FUTURE);
--- 1712,1716 ----
  	munlockall();
  #endif
! 	nvec = getalignedbytes(n * elemsize);
  #ifdef _POSIX_MEMLOCK
  	mlockall(MCL_FUTURE);
***************
*** 1755,1759 ****
      else garray_redraw(x);
  
!     freebytes (vec, was * elemsize);
      sys_lock();
      outlet_float(y->x_obj.ob_outlet, (float)atom_getintarg(1,argc,argv)); 
--- 1755,1759 ----
      else garray_redraw(x);
  
!     freealignedbytes (vec, was * elemsize);
      sys_lock();
      outlet_float(y->x_obj.ob_outlet, (float)atom_getintarg(1,argc,argv)); 
***************
*** 1819,1823 ****
      munlockall();
  #endif
!     nvec = getbytes(size * elemsize);
  #ifdef _POSIX_MEMLOCK
      mlockall(MCL_FUTURE);
--- 1819,1823 ----
      munlockall();
  #endif
!     nvec = getalignedbytes(size * elemsize);
  #ifdef _POSIX_MEMLOCK
      mlockall(MCL_FUTURE);
***************
*** 1862,1866 ****
      else garray_redraw(x);
  
!     freebytes (vec, size * elemsize);
      sys_lock(),
      outlet_float(y->x_obj.ob_outlet, size); 
--- 1862,1866 ----
      else garray_redraw(x);
  
!     freealignedbytes (vec, size * elemsize);
      sys_lock(),
      outlet_float(y->x_obj.ob_outlet, size); 





More information about the Pd-cvs mailing list