The Zizula Forum
October 22, 2017, 04:43:11 PM *
Welcome, Guest. Please login or register.

Login with username, password and session length
News: Looking for best Canvas Printing and Picture Framing studio in Dubai, then visit: www.pickframes.com
 
   Home   Help Arcade Search Calendar Login Register  
Del.icio.us Digg FURL FaceBook Stumble Upon Reddit SlashDot Ask BlinkBits BlinkList Co.mments Delirious Google Bookmarks Linkagogo Ma.gnolia MSN Live Netscape Netvouz Newsvine RawSugar Rojo Smarking Socializer Sphinn Spurl Squidoo Tailrank Technorati Yahoo My Web

Pages: [1]   Go Down
  Print  
Author Topic: python file to output vst paremters  (Read 1666 times)
edexter
Moderator
Full Member
*****

Karma: 22
Offline Offline

Posts: 177



View Profile WWW
« on: June 05, 2011, 05:05:52 PM »

import sys

#The "no legal opcode" mesage suggests that the dll containing the
#opcode is not found.
#Do you have the file "vst4cs.dll" in your plugins directory ? (e.g.
#C:/Program Files/Csound/plugins64).

#This is a batch line program for csound to print out the paremeters
#in windows use the redirection code to output to a file.
#You could also use pyvst.


outfile = open('vsttemp.orc','w')
outfile.write("""/* orc */
sr = 44100
kr = 4410
ksmps = 10
nchnls = 2
instr 1
gihandle1 vstinit """)
outfile.write('"')

outfile.write(sys.argv[1])
outfile.write('"')
outfile.write(',1')
outfile.write('\n')

outfile.write("""
endin""")
Logged

http://dextracker.blogspot.com/ The number one spot for dex tracker audio software on the internet.
edexter
Moderator
Full Member
*****

Karma: 22
Offline Offline

Posts: 177



View Profile WWW
« Reply #1 on: June 05, 2011, 06:12:25 PM »

import sys

#use after vstcsoundparemsreendump.py to parse them for use with a spreadsheet
#or whatever
#This will write a text file ending in .spr to whatever directory the plugin is in.
#Seems like you would only need to run this once per plugin in normal circumstances
#The next logical program would take a spreadsheet format and write it back
#to something csound could read.


infile = open('dump.txt','r')
outfile = open(sys.argv[1][:-3] + 'spr','w')
#outfile
for line in infile:
    if line.startswith('  Parameter'):
        par = line.split(': ')
        out_par = par[1][:-2]
        out_par = out_par.replace(' ','_')
        outfile.write(out_par)
        outfile.write(' ')
Logged

http://dextracker.blogspot.com/ The number one spot for dex tracker audio software on the internet.
Pages: [1]   Go Up
  Print  

 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.21 | SMF © 2015, Simple Machines | Sitemap Valid XHTML 1.0! Valid CSS!