1
0
mirror of https://github.com/cookiengineer/audacity synced 2025-07-17 09:07:41 +02:00

More spectral images.

This commit is contained in:
James Crook 2018-02-18 18:38:02 +00:00 committed by Paul Licameli
parent fe03e3cf51
commit 34bf4c8176
2 changed files with 51 additions and 13 deletions

View File

@ -5,12 +5,42 @@
# Make sure Audacity is running first and that mod-script-pipe is enabled
# before running this script.
import time
# records time, name of file and returns contents.
def inner( name ) :
global old_name
global start_time
global results
result = old_name + ' took ' + str( time.time() - start_time )
results.append( result )
print( result )
start_time = time.time()
if not name :
return ""
old_name = name
return open("docimages_" + name + ".py" ).read()
#initialise timing
start_time = time.time()
old_name = 'startup'
results = []
#do the different files...
exec( inner( 'tracks' ) )
exec( inner( 'labels' ) )
exec( inner( 'spectro' ) )
exec( inner( 'after' ) )
exec( inner( 'envelopes' ) )
exec( inner( 'cut_n_paste' ) )
exec( inner( 'clip_boundaries' ) )
exec( inner( 'oddments' ) )
#report on timing.
inner( "" )
print( "\n\nSummary:" )
print( "\n".join( results ) )
exec( open("docimages_tracks.py" ).read() )
exec( open("docimages_labels.py" ).read() )
exec( open("docimages_spectro.py" ).read() )
exec( open("docimages_after.py" ).read() )
exec( open("docimages_envelopes.py" ).read() )
exec( open("docimages_cut_n_paste.py" ).read() )
exec( open("docimages_clip_boundaries.py" ).read() )
exec( open("docimages_oddments.py" ).read() )

View File

@ -55,12 +55,20 @@ def spectro_imagesB():
capture( 'Spectral004.png', 'All_Tracks' )
def spectro_imagesC():
# A chirp and the word 'Audacity'
loadExample( 'AudacitySpectral.wav' )
capture( 'Spectral005.png', 'All_Tracks' )
do( 'SetTrack: Scale=dB')
capture( 'Spectral006.png', 'All_Tracks' )
do( 'SetTrack: Display=Spectrogram')
capture( 'Spectral007.png', 'All_Tracks' )
do( 'Select: Start=1.5 End=2.1 Low=3000 High=6000')
capture( 'Spectral008.png', 'All_Tracks' )
do( 'Select: Start=1.1 End=2.5' )
do( 'ZoomSel' )
do( 'Select: Start=1.5 End=2.1 Low=3000 High=6000')
do( 'SetTrack: Height=400' )
multiWindow( "SpectralVocal" )
def setWindow( name, value ):
do( 'SetTrack: SpecPrefs=1 Name="Window Size '+value+'"' )
@ -138,9 +146,9 @@ def spectro_imagesF():
#quickTest()
#spectro_imagesA()
#spectro_imagesB()
#spectro_imagesC()
#spectro_imagesD()
#spectro_imagesE()
spectro_imagesA()
spectro_imagesB()
spectro_imagesC()
spectro_imagesD()
spectro_imagesE()
spectro_imagesF()