12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268126912701271127212731274127512761277127812791280128112821283128412851286128712881289129012911292129312941295129612971298129913001301130213031304130513061307130813091310131113121313131413151316131713181319132013211322132313241325132613271328132913301331133213331334133513361337133813391340134113421343134413451346134713481349135013511352135313541355135613571358135913601361136213631364136513661367136813691370137113721373137413751376137713781379138013811382138313841385138613871388138913901391139213931394139513961397139813991400140114021403140414051406140714081409141014111412141314141415141614171418141914201421142214231424142514261427142814291430143114321433143414351436143714381439144014411442144314441445144614471448144914501451145214531454145514561457145814591460146114621463146414651466146714681469147014711472147314741475147614771478147914801481148214831484148514861487148814891490149114921493149414951496149714981499150015011502150315041505150615071508150915101511151215131514151515161517151815191520152115221523152415251526152715281529153015311532153315341535153615371538153915401541154215431544154515461547154815491550155115521553155415551556155715581559156015611562156315641565156615671568156915701571157215731574157515761577157815791580158115821583158415851586158715881589159015911592159315941595159615971598159916001601160216031604160516061607160816091610161116121613161416151616161716181619162016211622162316241625162616271628162916301631163216331634163516361637163816391640164116421643164416451646164716481649165016511652165316541655165616571658165916601661166216631664166516661667166816691670167116721673167416751676167716781679168016811682168316841685168616871688168916901691169216931694169516961697169816991700170117021703170417051706170717081709171017111712171317141715171617171718171917201721172217231724172517261727172817291730173117321733173417351736173717381739174017411742174317441745174617471748174917501751175217531754175517561757175817591760176117621763176417651766176717681769177017711772177317741775177617771778177917801781178217831784178517861787178817891790179117921793179417951796179717981799180018011802180318041805180618071808180918101811181218131814181518161817181818191820182118221823182418251826182718281829183018311832183318341835183618371838183918401841184218431844184518461847184818491850185118521853185418551856185718581859186018611862186318641865186618671868186918701871187218731874187518761877187818791880188118821883188418851886188718881889189018911892189318941895189618971898189919001901190219031904190519061907190819091910191119121913191419151916191719181919192019211922192319241925192619271928192919301931193219331934193519361937193819391940194119421943194419451946194719481949195019511952195319541955195619571958195919601961196219631964196519661967196819691970197119721973197419751976197719781979198019811982198319841985198619871988198919901991199219931994199519961997199819992000200120022003200420052006200720082009201020112012201320142015201620172018201920202021202220232024202520262027202820292030203120322033203420352036203720382039204020412042204320442045204620472048204920502051205220532054205520562057205820592060206120622063206420652066206720682069207020712072207320742075207620772078207920802081208220832084208520862087208820892090209120922093209420952096209720982099210021012102210321042105210621072108210921102111211221132114211521162117211821192120212121222123212421252126212721282129213021312132213321342135213621372138213921402141214221432144214521462147214821492150215121522153215421552156215721582159216021612162216321642165216621672168216921702171217221732174217521762177217821792180218121822183218421852186218721882189219021912192219321942195219621972198219922002201220222032204220522062207220822092210221122122213221422152216221722182219222022212222222322242225222622272228222922302231223222332234223522362237223822392240224122422243224422452246224722482249225022512252225322542255225622572258225922602261226222632264226522662267226822692270227122722273227422752276227722782279228022812282228322842285228622872288228922902291229222932294229522962297229822992300230123022303230423052306230723082309231023112312231323142315231623172318231923202321232223232324232523262327232823292330233123322333233423352336233723382339234023412342234323442345234623472348234923502351235223532354235523562357235823592360236123622363236423652366236723682369237023712372237323742375237623772378237923802381238223832384238523862387238823892390239123922393239423952396239723982399240024012402240324042405240624072408240924102411241224132414241524162417241824192420242124222423242424252426242724282429243024312432243324342435243624372438243924402441244224432444244524462447244824492450245124522453245424552456245724582459246024612462246324642465246624672468246924702471247224732474247524762477247824792480248124822483248424852486248724882489249024912492249324942495249624972498249925002501250225032504250525062507250825092510251125122513251425152516251725182519252025212522252325242525252625272528252925302531253225332534253525362537253825392540254125422543254425452546254725482549255025512552255325542555255625572558255925602561256225632564256525662567256825692570257125722573257425752576257725782579258025812582258325842585258625872588258925902591259225932594259525962597259825992600260126022603260426052606260726082609261026112612261326142615261626172618261926202621262226232624262526262627262826292630263126322633263426352636263726382639264026412642264326442645264626472648264926502651265226532654265526562657265826592660266126622663266426652666266726682669267026712672267326742675267626772678267926802681268226832684268526862687268826892690269126922693269426952696269726982699270027012702270327042705270627072708270927102711271227132714271527162717271827192720272127222723272427252726272727282729273027312732273327342735273627372738273927402741274227432744274527462747274827492750275127522753275427552756275727582759276027612762276327642765276627672768276927702771277227732774277527762777277827792780278127822783278427852786278727882789279027912792279327942795279627972798279928002801280228032804280528062807280828092810281128122813281428152816281728182819282028212822282328242825282628272828282928302831283228332834283528362837283828392840284128422843284428452846284728482849285028512852285328542855285628572858285928602861286228632864286528662867286828692870287128722873287428752876287728782879288028812882288328842885288628872888288928902891289228932894289528962897289828992900290129022903290429052906290729082909291029112912291329142915291629172918291929202921292229232924292529262927292829292930293129322933293429352936293729382939294029412942294329442945294629472948294929502951295229532954295529562957295829592960296129622963296429652966296729682969297029712972297329742975297629772978297929802981298229832984298529862987298829892990299129922993299429952996299729982999300030013002300330043005300630073008300930103011301230133014301530163017301830193020302130223023302430253026302730283029303030313032303330343035303630373038303930403041304230433044304530463047304830493050305130523053305430553056305730583059306030613062306330643065306630673068306930703071307230733074307530763077307830793080308130823083308430853086308730883089309030913092309330943095309630973098309931003101310231033104310531063107310831093110311131123113311431153116311731183119312031213122312331243125312631273128312931303131313231333134313531363137313831393140314131423143314431453146314731483149315031513152315331543155315631573158315931603161316231633164316531663167316831693170317131723173317431753176317731783179318031813182318331843185318631873188318931903191319231933194319531963197319831993200320132023203320432053206320732083209321032113212321332143215321632173218321932203221322232233224322532263227322832293230323132323233323432353236323732383239324032413242324332443245324632473248324932503251325232533254325532563257325832593260326132623263326432653266326732683269327032713272327332743275327632773278327932803281328232833284328532863287328832893290329132923293329432953296329732983299330033013302330333043305330633073308330933103311331233133314331533163317331833193320332133223323332433253326332733283329333033313332333333343335333633373338333933403341334233433344334533463347334833493350335133523353335433553356335733583359336033613362336333643365336633673368336933703371337233733374337533763377337833793380338133823383338433853386338733883389339033913392339333943395339633973398339934003401340234033404340534063407340834093410341134123413341434153416341734183419342034213422342334243425342634273428342934303431343234333434343534363437343834393440344134423443344434453446344734483449345034513452345334543455345634573458345934603461346234633464346534663467346834693470347134723473347434753476347734783479348034813482348334843485348634873488348934903491349234933494349534963497349834993500350135023503350435053506350735083509351035113512351335143515351635173518351935203521352235233524352535263527352835293530353135323533353435353536353735383539354035413542354335443545354635473548354935503551355235533554355535563557355835593560356135623563356435653566356735683569357035713572357335743575357635773578357935803581358235833584358535863587358835893590359135923593359435953596359735983599360036013602360336043605360636073608360936103611361236133614361536163617361836193620362136223623362436253626362736283629363036313632363336343635363636373638363936403641364236433644364536463647364836493650365136523653365436553656365736583659366036613662366336643665366636673668366936703671367236733674367536763677367836793680368136823683368436853686368736883689369036913692369336943695369636973698369937003701370237033704370537063707370837093710371137123713371437153716371737183719372037213722372337243725372637273728372937303731373237333734373537363737373837393740374137423743374437453746374737483749375037513752375337543755375637573758375937603761376237633764376537663767376837693770377137723773377437753776377737783779378037813782378337843785378637873788378937903791379237933794379537963797379837993800380138023803380438053806380738083809381038113812381338143815381638173818381938203821382238233824382538263827382838293830383138323833383438353836383738383839384038413842384338443845384638473848384938503851385238533854385538563857385838593860386138623863386438653866386738683869387038713872387338743875387638773878387938803881388238833884388538863887388838893890389138923893389438953896389738983899390039013902390339043905390639073908390939103911391239133914391539163917391839193920392139223923392439253926392739283929393039313932393339343935393639373938393939403941394239433944394539463947394839493950395139523953395439553956395739583959396039613962396339643965396639673968396939703971397239733974397539763977397839793980398139823983398439853986398739883989399039913992399339943995399639973998399940004001400240034004400540064007400840094010401140124013401440154016401740184019402040214022402340244025402640274028402940304031403240334034403540364037403840394040404140424043404440454046404740484049405040514052405340544055405640574058405940604061406240634064406540664067406840694070407140724073407440754076407740784079408040814082408340844085408640874088408940904091409240934094409540964097409840994100410141024103410441054106410741084109411041114112411341144115411641174118411941204121412241234124412541264127412841294130413141324133413441354136413741384139414041414142414341444145414641474148414941504151415241534154415541564157415841594160416141624163416441654166416741684169417041714172417341744175417641774178417941804181418241834184418541864187418841894190419141924193419441954196419741984199420042014202420342044205420642074208420942104211421242134214421542164217421842194220422142224223422442254226422742284229423042314232423342344235423642374238423942404241424242434244424542464247424842494250425142524253425442554256425742584259426042614262426342644265426642674268426942704271427242734274427542764277427842794280428142824283428442854286428742884289429042914292429342944295429642974298429943004301430243034304430543064307430843094310431143124313431443154316431743184319432043214322432343244325432643274328432943304331433243334334433543364337433843394340434143424343434443454346434743484349435043514352435343544355435643574358435943604361436243634364436543664367436843694370437143724373437443754376437743784379438043814382438343844385438643874388438943904391439243934394439543964397439843994400440144024403440444054406440744084409441044114412441344144415441644174418441944204421442244234424442544264427442844294430443144324433443444354436443744384439444044414442444344444445444644474448444944504451445244534454445544564457445844594460446144624463446444654466446744684469447044714472447344744475447644774478447944804481448244834484448544864487448844894490449144924493449444954496449744984499450045014502450345044505450645074508450945104511451245134514451545164517451845194520452145224523452445254526452745284529453045314532453345344535453645374538453945404541454245434544454545464547454845494550455145524553455445554556455745584559456045614562456345644565456645674568456945704571457245734574457545764577457845794580458145824583458445854586458745884589459045914592459345944595459645974598459946004601460246034604460546064607460846094610461146124613461446154616461746184619462046214622462346244625462646274628462946304631463246334634463546364637463846394640464146424643464446454646464746484649465046514652465346544655465646574658465946604661466246634664466546664667466846694670467146724673467446754676467746784679468046814682468346844685468646874688468946904691469246934694469546964697469846994700470147024703470447054706470747084709471047114712471347144715471647174718471947204721472247234724472547264727472847294730473147324733473447354736473747384739474047414742474347444745474647474748474947504751475247534754475547564757475847594760476147624763476447654766476747684769477047714772477347744775477647774778477947804781478247834784478547864787478847894790479147924793479447954796479747984799480048014802480348044805480648074808480948104811481248134814481548164817481848194820482148224823482448254826482748284829483048314832483348344835483648374838483948404841484248434844484548464847484848494850485148524853485448554856485748584859486048614862486348644865486648674868486948704871487248734874487548764877487848794880488148824883488448854886488748884889489048914892489348944895489648974898489949004901490249034904490549064907490849094910491149124913491449154916491749184919492049214922492349244925492649274928492949304931493249334934493549364937493849394940494149424943494449454946494749484949495049514952495349544955495649574958495949604961496249634964496549664967496849694970497149724973497449754976497749784979498049814982498349844985498649874988498949904991499249934994499549964997499849995000500150025003500450055006500750085009501050115012501350145015501650175018501950205021502250235024502550265027502850295030503150325033503450355036503750385039504050415042504350445045504650475048504950505051505250535054505550565057505850595060506150625063506450655066506750685069507050715072507350745075507650775078507950805081508250835084508550865087508850895090509150925093509450955096509750985099510051015102510351045105510651075108510951105111511251135114511551165117511851195120512151225123512451255126512751285129513051315132513351345135513651375138513951405141514251435144514551465147514851495150515151525153515451555156515751585159516051615162516351645165516651675168516951705171517251735174517551765177517851795180518151825183518451855186518751885189519051915192519351945195519651975198519952005201520252035204520552065207520852095210521152125213521452155216521752185219522052215222522352245225522652275228522952305231523252335234523552365237523852395240524152425243524452455246524752485249525052515252525352545255525652575258525952605261526252635264526552665267526852695270527152725273527452755276527752785279528052815282528352845285528652875288528952905291529252935294529552965297529852995300530153025303530453055306530753085309531053115312531353145315531653175318531953205321532253235324532553265327532853295330533153325333533453355336533753385339534053415342534353445345534653475348534953505351535253535354535553565357535853595360536153625363536453655366536753685369537053715372537353745375537653775378537953805381538253835384538553865387538853895390539153925393539453955396539753985399540054015402540354045405540654075408540954105411541254135414541554165417541854195420542154225423542454255426542754285429543054315432543354345435543654375438543954405441544254435444544554465447544854495450545154525453545454555456545754585459546054615462546354645465546654675468546954705471547254735474547554765477547854795480548154825483548454855486548754885489549054915492549354945495549654975498549955005501550255035504550555065507550855095510551155125513551455155516551755185519552055215522552355245525552655275528552955305531553255335534553555365537553855395540554155425543554455455546554755485549555055515552555355545555555655575558555955605561556255635564556555665567556855695570557155725573557455755576557755785579558055815582558355845585558655875588558955905591559255935594559555965597559855995600560156025603560456055606560756085609561056115612561356145615561656175618561956205621562256235624562556265627562856295630563156325633563456355636563756385639564056415642564356445645564656475648564956505651565256535654565556565657565856595660566156625663566456655666566756685669567056715672567356745675567656775678567956805681568256835684568556865687568856895690569156925693569456955696569756985699570057015702570357045705570657075708570957105711571257135714571557165717571857195720572157225723572457255726572757285729573057315732573357345735573657375738573957405741574257435744574557465747574857495750575157525753575457555756575757585759576057615762576357645765576657675768576957705771577257735774577557765777577857795780578157825783578457855786578757885789579057915792579357945795579657975798579958005801580258035804580558065807580858095810581158125813581458155816581758185819582058215822582358245825582658275828582958305831583258335834583558365837583858395840584158425843584458455846584758485849585058515852585358545855585658575858585958605861586258635864586558665867586858695870587158725873587458755876587758785879588058815882588358845885588658875888588958905891589258935894589558965897589858995900590159025903590459055906590759085909591059115912591359145915591659175918591959205921592259235924592559265927592859295930593159325933593459355936593759385939594059415942594359445945594659475948594959505951595259535954595559565957595859595960596159625963596459655966596759685969597059715972597359745975597659775978597959805981598259835984598559865987598859895990599159925993599459955996599759985999600060016002600360046005600660076008600960106011601260136014601560166017601860196020602160226023602460256026602760286029603060316032603360346035603660376038603960406041604260436044604560466047604860496050605160526053605460556056605760586059606060616062606360646065606660676068606960706071607260736074607560766077607860796080608160826083608460856086608760886089609060916092609360946095609660976098609961006101610261036104610561066107610861096110611161126113611461156116611761186119612061216122612361246125612661276128612961306131613261336134613561366137613861396140614161426143614461456146614761486149615061516152615361546155615661576158615961606161616261636164616561666167616861696170617161726173617461756176617761786179618061816182618361846185618661876188618961906191619261936194619561966197619861996200620162026203620462056206620762086209621062116212621362146215621662176218621962206221622262236224622562266227622862296230623162326233623462356236623762386239624062416242624362446245624662476248624962506251625262536254625562566257625862596260626162626263626462656266626762686269627062716272627362746275627662776278627962806281628262836284628562866287628862896290629162926293629462956296629762986299630063016302630363046305630663076308630963106311631263136314631563166317631863196320632163226323632463256326632763286329633063316332633363346335633663376338633963406341634263436344634563466347634863496350635163526353635463556356635763586359636063616362636363646365636663676368636963706371637263736374637563766377637863796380638163826383638463856386638763886389639063916392639363946395639663976398639964006401640264036404640564066407640864096410641164126413641464156416641764186419642064216422642364246425642664276428642964306431643264336434643564366437643864396440644164426443644464456446644764486449645064516452645364546455645664576458645964606461646264636464646564666467646864696470647164726473647464756476647764786479648064816482648364846485648664876488648964906491649264936494649564966497649864996500650165026503650465056506650765086509651065116512651365146515651665176518651965206521652265236524652565266527652865296530653165326533653465356536653765386539654065416542654365446545654665476548654965506551655265536554655565566557655865596560656165626563656465656566656765686569657065716572657365746575657665776578657965806581658265836584658565866587658865896590659165926593659465956596659765986599660066016602660366046605660666076608660966106611661266136614661566166617661866196620662166226623662466256626662766286629663066316632663366346635663666376638663966406641664266436644664566466647664866496650665166526653665466556656665766586659666066616662666366646665666666676668666966706671667266736674667566766677667866796680668166826683668466856686668766886689669066916692669366946695669666976698669967006701670267036704670567066707670867096710671167126713671467156716671767186719672067216722672367246725672667276728672967306731673267336734673567366737673867396740674167426743674467456746674767486749675067516752675367546755675667576758675967606761676267636764676567666767676867696770677167726773677467756776677767786779678067816782678367846785678667876788678967906791679267936794679567966797679867996800680168026803680468056806680768086809681068116812681368146815681668176818681968206821682268236824682568266827682868296830683168326833683468356836683768386839684068416842684368446845684668476848684968506851685268536854685568566857685868596860686168626863686468656866686768686869687068716872687368746875687668776878687968806881688268836884688568866887688868896890689168926893689468956896689768986899690069016902690369046905690669076908690969106911691269136914691569166917691869196920692169226923692469256926692769286929693069316932693369346935693669376938693969406941694269436944694569466947694869496950695169526953695469556956695769586959696069616962696369646965696669676968696969706971697269736974697569766977697869796980698169826983698469856986698769886989699069916992699369946995699669976998699970007001700270037004700570067007700870097010701170127013701470157016701770187019702070217022702370247025702670277028702970307031703270337034703570367037703870397040704170427043704470457046704770487049705070517052705370547055705670577058705970607061706270637064706570667067706870697070707170727073707470757076707770787079708070817082708370847085708670877088708970907091709270937094709570967097709870997100710171027103710471057106710771087109711071117112711371147115711671177118711971207121712271237124712571267127712871297130713171327133713471357136713771387139714071417142714371447145714671477148714971507151715271537154715571567157715871597160716171627163716471657166716771687169717071717172717371747175717671777178717971807181718271837184718571867187718871897190719171927193719471957196719771987199720072017202720372047205720672077208720972107211721272137214721572167217721872197220722172227223722472257226722772287229723072317232723372347235723672377238723972407241724272437244724572467247724872497250725172527253725472557256725772587259726072617262726372647265726672677268726972707271727272737274727572767277727872797280728172827283728472857286728772887289729072917292729372947295729672977298729973007301730273037304730573067307730873097310731173127313731473157316731773187319732073217322732373247325732673277328732973307331733273337334733573367337733873397340734173427343734473457346734773487349735073517352735373547355735673577358735973607361736273637364736573667367736873697370737173727373737473757376737773787379738073817382738373847385738673877388738973907391739273937394739573967397739873997400740174027403740474057406740774087409741074117412741374147415741674177418741974207421742274237424742574267427742874297430743174327433743474357436743774387439744074417442744374447445744674477448744974507451745274537454745574567457745874597460746174627463746474657466746774687469747074717472747374747475747674777478747974807481748274837484748574867487748874897490749174927493749474957496749774987499750075017502750375047505750675077508750975107511751275137514751575167517751875197520752175227523752475257526752775287529753075317532753375347535753675377538753975407541754275437544754575467547754875497550755175527553755475557556755775587559756075617562756375647565756675677568756975707571757275737574757575767577757875797580758175827583758475857586758775887589759075917592759375947595759675977598759976007601760276037604760576067607760876097610761176127613761476157616761776187619762076217622762376247625762676277628762976307631763276337634763576367637763876397640764176427643764476457646764776487649765076517652765376547655765676577658765976607661766276637664766576667667766876697670767176727673767476757676767776787679768076817682768376847685768676877688768976907691769276937694769576967697769876997700770177027703770477057706770777087709771077117712771377147715771677177718771977207721772277237724772577267727772877297730773177327733773477357736773777387739774077417742774377447745774677477748774977507751775277537754775577567757775877597760776177627763776477657766776777687769777077717772777377747775777677777778777977807781778277837784778577867787778877897790779177927793779477957796779777987799780078017802780378047805780678077808780978107811781278137814781578167817781878197820782178227823782478257826782778287829783078317832783378347835783678377838783978407841784278437844784578467847784878497850785178527853785478557856785778587859786078617862786378647865786678677868786978707871787278737874787578767877787878797880788178827883788478857886788778887889789078917892789378947895789678977898789979007901790279037904790579067907790879097910791179127913791479157916791779187919792079217922792379247925792679277928792979307931793279337934793579367937793879397940794179427943794479457946794779487949795079517952795379547955795679577958795979607961796279637964796579667967796879697970797179727973797479757976797779787979798079817982798379847985798679877988798979907991799279937994799579967997799879998000800180028003800480058006800780088009801080118012801380148015801680178018801980208021802280238024802580268027802880298030803180328033803480358036803780388039804080418042804380448045804680478048804980508051805280538054805580568057805880598060806180628063806480658066806780688069807080718072807380748075807680778078807980808081808280838084808580868087808880898090809180928093809480958096809780988099810081018102810381048105810681078108810981108111811281138114811581168117811881198120812181228123812481258126812781288129813081318132813381348135813681378138813981408141814281438144814581468147814881498150815181528153815481558156815781588159816081618162816381648165816681678168816981708171817281738174817581768177817881798180818181828183818481858186818781888189819081918192819381948195819681978198819982008201820282038204820582068207820882098210821182128213821482158216821782188219822082218222822382248225822682278228822982308231823282338234823582368237823882398240824182428243824482458246824782488249825082518252825382548255825682578258825982608261826282638264826582668267826882698270827182728273827482758276827782788279828082818282828382848285828682878288828982908291829282938294829582968297829882998300830183028303830483058306830783088309831083118312831383148315831683178318831983208321832283238324832583268327832883298330833183328333833483358336833783388339834083418342834383448345834683478348834983508351835283538354835583568357835883598360836183628363836483658366836783688369837083718372837383748375837683778378837983808381838283838384838583868387838883898390839183928393839483958396839783988399840084018402840384048405840684078408840984108411841284138414841584168417841884198420842184228423842484258426842784288429843084318432843384348435843684378438843984408441844284438444844584468447844884498450845184528453845484558456845784588459846084618462846384648465846684678468846984708471847284738474847584768477847884798480848184828483848484858486848784888489849084918492849384948495849684978498849985008501850285038504850585068507850885098510851185128513851485158516851785188519852085218522852385248525852685278528852985308531853285338534853585368537853885398540854185428543854485458546854785488549855085518552855385548555855685578558855985608561856285638564856585668567856885698570857185728573857485758576857785788579858085818582858385848585858685878588858985908591859285938594859585968597859885998600860186028603860486058606860786088609861086118612861386148615861686178618861986208621862286238624862586268627862886298630863186328633863486358636863786388639864086418642864386448645864686478648864986508651865286538654865586568657865886598660866186628663866486658666866786688669867086718672867386748675867686778678867986808681868286838684868586868687868886898690869186928693869486958696869786988699870087018702870387048705870687078708870987108711871287138714871587168717871887198720872187228723872487258726872787288729873087318732873387348735873687378738873987408741874287438744874587468747874887498750875187528753875487558756875787588759876087618762876387648765876687678768876987708771877287738774877587768777877887798780878187828783878487858786878787888789879087918792879387948795879687978798879988008801880288038804880588068807880888098810881188128813881488158816881788188819882088218822882388248825882688278828882988308831883288338834883588368837883888398840884188428843884488458846884788488849885088518852885388548855885688578858885988608861886288638864886588668867886888698870887188728873887488758876887788788879888088818882888388848885888688878888888988908891889288938894889588968897889888998900890189028903890489058906890789088909891089118912891389148915891689178918891989208921892289238924892589268927892889298930893189328933893489358936893789388939894089418942894389448945894689478948894989508951895289538954895589568957895889598960896189628963896489658966896789688969897089718972897389748975897689778978897989808981898289838984898589868987898889898990899189928993899489958996899789988999900090019002900390049005900690079008900990109011901290139014901590169017901890199020902190229023902490259026902790289029903090319032903390349035903690379038903990409041904290439044904590469047904890499050905190529053905490559056905790589059906090619062906390649065906690679068906990709071907290739074907590769077907890799080908190829083908490859086908790889089909090919092909390949095909690979098909991009101910291039104910591069107910891099110911191129113911491159116911791189119912091219122912391249125912691279128912991309131913291339134913591369137913891399140914191429143914491459146914791489149915091519152915391549155915691579158915991609161916291639164916591669167916891699170917191729173917491759176917791789179918091819182918391849185918691879188918991909191919291939194919591969197919891999200920192029203920492059206920792089209921092119212921392149215921692179218921992209221922292239224922592269227922892299230923192329233923492359236923792389239924092419242924392449245924692479248924992509251925292539254925592569257925892599260926192629263926492659266926792689269927092719272927392749275927692779278927992809281928292839284928592869287928892899290929192929293929492959296929792989299930093019302930393049305930693079308930993109311931293139314931593169317931893199320932193229323932493259326932793289329933093319332933393349335933693379338933993409341934293439344934593469347934893499350935193529353935493559356935793589359936093619362936393649365936693679368936993709371937293739374937593769377937893799380938193829383938493859386938793889389939093919392939393949395939693979398939994009401940294039404940594069407940894099410941194129413941494159416941794189419942094219422942394249425942694279428942994309431943294339434943594369437943894399440944194429443944494459446944794489449945094519452945394549455945694579458945994609461946294639464946594669467946894699470947194729473947494759476947794789479948094819482948394849485948694879488948994909491949294939494949594969497949894999500950195029503950495059506950795089509951095119512951395149515951695179518951995209521952295239524952595269527952895299530953195329533953495359536953795389539954095419542954395449545954695479548954995509551955295539554955595569557955895599560956195629563956495659566956795689569957095719572957395749575957695779578957995809581958295839584958595869587958895899590959195929593959495959596959795989599960096019602960396049605960696079608960996109611961296139614961596169617961896199620962196229623962496259626962796289629963096319632963396349635963696379638963996409641964296439644964596469647964896499650965196529653965496559656965796589659966096619662966396649665966696679668966996709671967296739674967596769677967896799680968196829683968496859686968796889689969096919692969396949695969696979698969997009701970297039704970597069707970897099710971197129713971497159716971797189719972097219722972397249725972697279728972997309731973297339734973597369737973897399740974197429743974497459746974797489749975097519752975397549755975697579758975997609761976297639764976597669767976897699770977197729773977497759776977797789779978097819782978397849785978697879788978997909791979297939794979597969797979897999800980198029803980498059806980798089809981098119812981398149815981698179818981998209821982298239824982598269827982898299830983198329833983498359836983798389839984098419842984398449845984698479848984998509851985298539854985598569857985898599860986198629863986498659866986798689869987098719872987398749875987698779878987998809881988298839884988598869887988898899890989198929893989498959896989798989899990099019902990399049905990699079908990999109911991299139914991599169917991899199920992199229923992499259926992799289929993099319932993399349935993699379938993999409941994299439944994599469947994899499950995199529953995499559956995799589959996099619962996399649965996699679968996999709971997299739974997599769977997899799980998199829983998499859986998799889989999099919992999399949995999699979998999910000100011000210003100041000510006100071000810009100101001110012100131001410015100161001710018100191002010021100221002310024100251002610027100281002910030100311003210033100341003510036100371003810039100401004110042100431004410045100461004710048100491005010051100521005310054100551005610057100581005910060100611006210063100641006510066100671006810069100701007110072100731007410075100761007710078100791008010081100821008310084100851008610087100881008910090100911009210093100941009510096100971009810099101001010110102101031010410105101061010710108101091011010111101121011310114101151011610117101181011910120101211012210123101241012510126101271012810129101301013110132101331013410135101361013710138101391014010141101421014310144101451014610147101481014910150101511015210153101541015510156101571015810159101601016110162101631016410165101661016710168101691017010171101721017310174101751017610177101781017910180101811018210183101841018510186101871018810189101901019110192101931019410195101961019710198101991020010201102021020310204102051020610207102081020910210102111021210213102141021510216102171021810219102201022110222102231022410225102261022710228102291023010231102321023310234102351023610237102381023910240102411024210243102441024510246102471024810249102501025110252102531025410255102561025710258102591026010261102621026310264102651026610267102681026910270102711027210273102741027510276102771027810279102801028110282102831028410285102861028710288102891029010291102921029310294102951029610297102981029910300103011030210303103041030510306103071030810309103101031110312103131031410315103161031710318103191032010321103221032310324103251032610327103281032910330103311033210333103341033510336103371033810339103401034110342103431034410345103461034710348103491035010351103521035310354103551035610357103581035910360103611036210363103641036510366103671036810369103701037110372103731037410375103761037710378103791038010381103821038310384103851038610387103881038910390103911039210393103941039510396103971039810399104001040110402104031040410405104061040710408104091041010411104121041310414104151041610417104181041910420104211042210423104241042510426104271042810429104301043110432104331043410435104361043710438104391044010441104421044310444104451044610447104481044910450104511045210453104541045510456104571045810459104601046110462104631046410465104661046710468104691047010471104721047310474104751047610477104781047910480104811048210483104841048510486104871048810489104901049110492104931049410495104961049710498104991050010501105021050310504105051050610507105081050910510105111051210513105141051510516105171051810519105201052110522105231052410525105261052710528105291053010531105321053310534105351053610537105381053910540105411054210543105441054510546105471054810549105501055110552105531055410555105561055710558105591056010561105621056310564105651056610567105681056910570105711057210573105741057510576105771057810579105801058110582105831058410585105861058710588105891059010591105921059310594105951059610597105981059910600106011060210603106041060510606106071060810609106101061110612106131061410615106161061710618106191062010621106221062310624106251062610627106281062910630106311063210633106341063510636106371063810639106401064110642106431064410645106461064710648106491065010651106521065310654106551065610657106581065910660106611066210663106641066510666106671066810669106701067110672106731067410675106761067710678106791068010681106821068310684106851068610687106881068910690106911069210693106941069510696106971069810699107001070110702107031070410705107061070710708107091071010711107121071310714107151071610717107181071910720107211072210723107241072510726107271072810729107301073110732107331073410735107361073710738107391074010741107421074310744107451074610747107481074910750107511075210753107541075510756107571075810759107601076110762107631076410765107661076710768107691077010771107721077310774107751077610777107781077910780107811078210783107841078510786107871078810789107901079110792107931079410795107961079710798107991080010801108021080310804108051080610807108081080910810108111081210813108141081510816108171081810819108201082110822108231082410825108261082710828108291083010831108321083310834108351083610837108381083910840108411084210843108441084510846108471084810849108501085110852108531085410855108561085710858108591086010861108621086310864108651086610867108681086910870108711087210873108741087510876108771087810879108801088110882108831088410885108861088710888108891089010891108921089310894108951089610897108981089910900109011090210903109041090510906109071090810909109101091110912109131091410915109161091710918109191092010921109221092310924109251092610927109281092910930109311093210933109341093510936109371093810939109401094110942109431094410945109461094710948109491095010951109521095310954109551095610957109581095910960109611096210963109641096510966109671096810969109701097110972109731097410975109761097710978109791098010981109821098310984109851098610987109881098910990109911099210993109941099510996109971099810999110001100111002110031100411005110061100711008110091101011011110121101311014110151101611017110181101911020110211102211023110241102511026110271102811029110301103111032110331103411035110361103711038110391104011041110421104311044110451104611047110481104911050110511105211053110541105511056110571105811059110601106111062110631106411065110661106711068110691107011071110721107311074110751107611077110781107911080110811108211083110841108511086110871108811089110901109111092110931109411095110961109711098110991110011101111021110311104111051110611107111081110911110111111111211113111141111511116111171111811119111201112111122111231112411125111261112711128111291113011131111321113311134111351113611137111381113911140111411114211143111441114511146111471114811149111501115111152111531115411155111561115711158111591116011161111621116311164111651116611167111681116911170111711117211173111741117511176111771117811179111801118111182111831118411185111861118711188111891119011191111921119311194111951119611197111981119911200112011120211203112041120511206112071120811209112101121111212112131121411215112161121711218112191122011221112221122311224112251122611227112281122911230112311123211233112341123511236112371123811239112401124111242112431124411245112461124711248112491125011251112521125311254112551125611257112581125911260112611126211263112641126511266112671126811269112701127111272112731127411275112761127711278112791128011281112821128311284112851128611287112881128911290112911129211293112941129511296112971129811299113001130111302113031130411305113061130711308113091131011311113121131311314113151131611317113181131911320113211132211323113241132511326113271132811329113301133111332113331133411335113361133711338113391134011341113421134311344113451134611347113481134911350113511135211353113541135511356113571135811359113601136111362113631136411365113661136711368113691137011371113721137311374113751137611377113781137911380113811138211383113841138511386113871138811389113901139111392113931139411395113961139711398113991140011401114021140311404114051140611407114081140911410114111141211413114141141511416114171141811419114201142111422114231142411425114261142711428114291143011431114321143311434114351143611437114381143911440114411144211443114441144511446114471144811449114501145111452114531145411455114561145711458114591146011461114621146311464114651146611467114681146911470114711147211473114741147511476114771147811479114801148111482114831148411485114861148711488114891149011491114921149311494114951149611497114981149911500115011150211503115041150511506115071150811509115101151111512115131151411515115161151711518115191152011521115221152311524115251152611527115281152911530115311153211533115341153511536115371153811539115401154111542115431154411545115461154711548115491155011551115521155311554115551155611557115581155911560115611156211563115641156511566115671156811569115701157111572115731157411575115761157711578115791158011581115821158311584115851158611587115881158911590115911159211593115941159511596115971159811599116001160111602116031160411605116061160711608116091161011611116121161311614116151161611617116181161911620116211162211623116241162511626116271162811629116301163111632116331163411635116361163711638116391164011641116421164311644116451164611647116481164911650116511165211653116541165511656116571165811659116601166111662116631166411665116661166711668116691167011671116721167311674116751167611677116781167911680116811168211683116841168511686116871168811689116901169111692116931169411695116961169711698116991170011701117021170311704117051170611707117081170911710117111171211713117141171511716117171171811719117201172111722117231172411725117261172711728117291173011731117321173311734117351173611737117381173911740117411174211743117441174511746117471174811749117501175111752117531175411755117561175711758117591176011761117621176311764117651176611767117681176911770117711177211773117741177511776117771177811779117801178111782117831178411785117861178711788117891179011791117921179311794117951179611797117981179911800118011180211803118041180511806118071180811809118101181111812118131181411815118161181711818118191182011821118221182311824118251182611827118281182911830118311183211833118341183511836118371183811839118401184111842118431184411845118461184711848118491185011851118521185311854118551185611857118581185911860118611186211863118641186511866118671186811869118701187111872118731187411875118761187711878118791188011881118821188311884118851188611887118881188911890118911189211893118941189511896118971189811899119001190111902119031190411905119061190711908119091191011911119121191311914119151191611917119181191911920119211192211923119241192511926119271192811929119301193111932119331193411935119361193711938119391194011941119421194311944119451194611947119481194911950119511195211953119541195511956119571195811959119601196111962119631196411965119661196711968119691197011971119721197311974119751197611977119781197911980119811198211983119841198511986119871198811989119901199111992119931199411995119961199711998119991200012001120021200312004120051200612007120081200912010120111201212013120141201512016120171201812019120201202112022120231202412025120261202712028120291203012031120321203312034120351203612037120381203912040120411204212043120441204512046120471204812049120501205112052120531205412055120561205712058120591206012061120621206312064120651206612067120681206912070120711207212073120741207512076120771207812079120801208112082120831208412085120861208712088120891209012091120921209312094120951209612097120981209912100121011210212103121041210512106121071210812109121101211112112121131211412115121161211712118121191212012121121221212312124121251212612127121281212912130121311213212133121341213512136121371213812139121401214112142121431214412145121461214712148121491215012151121521215312154121551215612157121581215912160121611216212163121641216512166121671216812169121701217112172121731217412175121761217712178121791218012181121821218312184121851218612187121881218912190121911219212193121941219512196121971219812199122001220112202122031220412205122061220712208122091221012211122121221312214122151221612217122181221912220122211222212223122241222512226122271222812229122301223112232122331223412235122361223712238122391224012241122421224312244122451224612247122481224912250122511225212253122541225512256122571225812259122601226112262122631226412265122661226712268122691227012271122721227312274122751227612277122781227912280122811228212283122841228512286122871228812289122901229112292122931229412295122961229712298122991230012301123021230312304123051230612307123081230912310123111231212313123141231512316123171231812319123201232112322123231232412325123261232712328123291233012331123321233312334123351233612337123381233912340123411234212343123441234512346123471234812349123501235112352123531235412355123561235712358123591236012361123621236312364123651236612367123681236912370123711237212373123741237512376123771237812379123801238112382123831238412385123861238712388123891239012391123921239312394123951239612397123981239912400124011240212403124041240512406124071240812409124101241112412124131241412415124161241712418124191242012421124221242312424124251242612427124281242912430124311243212433124341243512436124371243812439124401244112442124431244412445124461244712448124491245012451124521245312454124551245612457124581245912460124611246212463124641246512466124671246812469124701247112472124731247412475124761247712478124791248012481124821248312484124851248612487124881248912490124911249212493124941249512496124971249812499125001250112502125031250412505125061250712508125091251012511125121251312514125151251612517125181251912520125211252212523125241252512526125271252812529125301253112532125331253412535125361253712538125391254012541125421254312544125451254612547125481254912550125511255212553125541255512556125571255812559125601256112562125631256412565125661256712568125691257012571125721257312574125751257612577125781257912580125811258212583125841258512586125871258812589125901259112592125931259412595125961259712598125991260012601126021260312604126051260612607126081260912610126111261212613126141261512616126171261812619126201262112622126231262412625126261262712628126291263012631126321263312634126351263612637126381263912640126411264212643126441264512646126471264812649126501265112652126531265412655126561265712658126591266012661126621266312664126651266612667126681266912670126711267212673126741267512676126771267812679126801268112682126831268412685126861268712688126891269012691126921269312694126951269612697126981269912700127011270212703127041270512706127071270812709127101271112712127131271412715127161271712718127191272012721127221272312724127251272612727127281272912730127311273212733127341273512736127371273812739127401274112742127431274412745127461274712748127491275012751127521275312754127551275612757127581275912760127611276212763127641276512766127671276812769127701277112772127731277412775127761277712778127791278012781127821278312784127851278612787127881278912790127911279212793127941279512796127971279812799128001280112802128031280412805128061280712808128091281012811128121281312814128151281612817128181281912820128211282212823128241282512826128271282812829128301283112832128331283412835128361283712838128391284012841128421284312844128451284612847128481284912850128511285212853128541285512856128571285812859128601286112862128631286412865128661286712868128691287012871128721287312874128751287612877128781287912880128811288212883128841288512886128871288812889128901289112892128931289412895128961289712898128991290012901129021290312904129051290612907129081290912910129111291212913129141291512916129171291812919129201292112922129231292412925129261292712928129291293012931129321293312934129351293612937129381293912940129411294212943129441294512946129471294812949129501295112952129531295412955129561295712958129591296012961129621296312964129651296612967129681296912970129711297212973129741297512976129771297812979129801298112982129831298412985129861298712988129891299012991129921299312994129951299612997129981299913000130011300213003130041300513006130071300813009130101301113012130131301413015130161301713018130191302013021130221302313024130251302613027130281302913030130311303213033130341303513036130371303813039130401304113042130431304413045130461304713048130491305013051130521305313054130551305613057130581305913060130611306213063130641306513066130671306813069130701307113072130731307413075130761307713078130791308013081130821308313084130851308613087130881308913090130911309213093130941309513096130971309813099131001310113102131031310413105131061310713108131091311013111131121311313114131151311613117131181311913120131211312213123131241312513126131271312813129131301313113132131331313413135131361313713138131391314013141131421314313144131451314613147131481314913150131511315213153131541315513156131571315813159131601316113162131631316413165131661316713168131691317013171131721317313174131751317613177131781317913180131811318213183131841318513186131871318813189131901319113192131931319413195131961319713198131991320013201132021320313204132051320613207132081320913210132111321213213132141321513216132171321813219132201322113222132231322413225132261322713228132291323013231132321323313234132351323613237132381323913240132411324213243132441324513246132471324813249132501325113252132531325413255132561325713258132591326013261132621326313264132651326613267132681326913270132711327213273132741327513276132771327813279132801328113282132831328413285132861328713288132891329013291132921329313294132951329613297132981329913300133011330213303133041330513306133071330813309133101331113312133131331413315133161331713318133191332013321133221332313324133251332613327133281332913330133311333213333133341333513336133371333813339133401334113342133431334413345133461334713348133491335013351133521335313354133551335613357133581335913360133611336213363133641336513366133671336813369133701337113372133731337413375133761337713378133791338013381133821338313384133851338613387133881338913390133911339213393133941339513396133971339813399134001340113402134031340413405134061340713408134091341013411134121341313414134151341613417134181341913420134211342213423134241342513426134271342813429134301343113432134331343413435134361343713438134391344013441134421344313444134451344613447134481344913450134511345213453134541345513456134571345813459134601346113462134631346413465134661346713468134691347013471134721347313474134751347613477134781347913480134811348213483134841348513486134871348813489134901349113492134931349413495134961349713498134991350013501135021350313504135051350613507135081350913510135111351213513135141351513516135171351813519135201352113522135231352413525135261352713528135291353013531135321353313534135351353613537135381353913540135411354213543135441354513546135471354813549135501355113552135531355413555135561355713558135591356013561135621356313564135651356613567135681356913570135711357213573135741357513576135771357813579135801358113582135831358413585135861358713588135891359013591135921359313594135951359613597135981359913600136011360213603136041360513606136071360813609136101361113612136131361413615136161361713618136191362013621136221362313624136251362613627136281362913630136311363213633136341363513636136371363813639136401364113642136431364413645136461364713648136491365013651136521365313654136551365613657136581365913660136611366213663136641366513666136671366813669136701367113672136731367413675136761367713678136791368013681136821368313684136851368613687136881368913690136911369213693136941369513696136971369813699137001370113702137031370413705137061370713708137091371013711137121371313714137151371613717137181371913720137211372213723137241372513726137271372813729137301373113732137331373413735137361373713738137391374013741137421374313744137451374613747137481374913750137511375213753137541375513756137571375813759137601376113762137631376413765137661376713768137691377013771137721377313774137751377613777137781377913780137811378213783137841378513786137871378813789137901379113792137931379413795137961379713798137991380013801138021380313804138051380613807138081380913810138111381213813138141381513816138171381813819138201382113822138231382413825138261382713828138291383013831138321383313834138351383613837138381383913840138411384213843138441384513846138471384813849138501385113852138531385413855138561385713858138591386013861138621386313864138651386613867138681386913870138711387213873138741387513876138771387813879138801388113882138831388413885138861388713888138891389013891138921389313894138951389613897138981389913900139011390213903139041390513906139071390813909139101391113912139131391413915139161391713918139191392013921139221392313924139251392613927139281392913930139311393213933139341393513936139371393813939139401394113942139431394413945139461394713948139491395013951139521395313954139551395613957139581395913960139611396213963139641396513966139671396813969139701397113972139731397413975139761397713978139791398013981139821398313984139851398613987139881398913990139911399213993139941399513996139971399813999140001400114002140031400414005140061400714008140091401014011140121401314014140151401614017140181401914020140211402214023140241402514026140271402814029140301403114032140331403414035140361403714038140391404014041140421404314044140451404614047140481404914050140511405214053140541405514056140571405814059140601406114062140631406414065140661406714068140691407014071140721407314074140751407614077140781407914080140811408214083140841408514086140871408814089140901409114092140931409414095140961409714098140991410014101141021410314104141051410614107141081410914110141111411214113141141411514116141171411814119141201412114122141231412414125141261412714128141291413014131141321413314134141351413614137141381413914140141411414214143141441414514146141471414814149141501415114152141531415414155141561415714158141591416014161141621416314164141651416614167141681416914170141711417214173141741417514176141771417814179141801418114182141831418414185141861418714188141891419014191141921419314194141951419614197141981419914200142011420214203142041420514206142071420814209142101421114212142131421414215142161421714218142191422014221142221422314224142251422614227142281422914230142311423214233142341423514236142371423814239142401424114242142431424414245142461424714248142491425014251142521425314254142551425614257142581425914260142611426214263142641426514266142671426814269142701427114272142731427414275142761427714278142791428014281142821428314284142851428614287142881428914290142911429214293142941429514296142971429814299143001430114302143031430414305143061430714308143091431014311143121431314314143151431614317143181431914320143211432214323143241432514326143271432814329143301433114332143331433414335143361433714338143391434014341143421434314344143451434614347143481434914350143511435214353143541435514356143571435814359143601436114362143631436414365143661436714368143691437014371143721437314374143751437614377143781437914380143811438214383143841438514386143871438814389143901439114392143931439414395143961439714398143991440014401144021440314404144051440614407144081440914410144111441214413144141441514416144171441814419144201442114422144231442414425144261442714428144291443014431144321443314434144351443614437144381443914440144411444214443144441444514446144471444814449144501445114452144531445414455144561445714458144591446014461144621446314464144651446614467144681446914470144711447214473144741447514476144771447814479144801448114482144831448414485144861448714488144891449014491144921449314494144951449614497144981449914500145011450214503145041450514506145071450814509145101451114512145131451414515145161451714518145191452014521145221452314524145251452614527145281452914530145311453214533145341453514536145371453814539145401454114542145431454414545145461454714548145491455014551145521455314554145551455614557145581455914560145611456214563145641456514566145671456814569145701457114572145731457414575145761457714578145791458014581145821458314584145851458614587145881458914590145911459214593145941459514596145971459814599146001460114602146031460414605146061460714608146091461014611146121461314614146151461614617146181461914620146211462214623146241462514626146271462814629146301463114632146331463414635146361463714638146391464014641146421464314644146451464614647146481464914650146511465214653146541465514656146571465814659146601466114662146631466414665146661466714668146691467014671146721467314674146751467614677146781467914680146811468214683146841468514686146871468814689146901469114692146931469414695146961469714698146991470014701147021470314704147051470614707147081470914710147111471214713147141471514716147171471814719147201472114722147231472414725147261472714728147291473014731147321473314734147351473614737147381473914740147411474214743147441474514746147471474814749147501475114752147531475414755147561475714758147591476014761147621476314764147651476614767147681476914770147711477214773147741477514776147771477814779147801478114782147831478414785147861478714788147891479014791147921479314794147951479614797147981479914800148011480214803148041480514806148071480814809148101481114812148131481414815148161481714818148191482014821148221482314824148251482614827148281482914830148311483214833148341483514836148371483814839148401484114842148431484414845148461484714848148491485014851148521485314854148551485614857148581485914860148611486214863148641486514866148671486814869148701487114872148731487414875148761487714878148791488014881148821488314884148851488614887148881488914890148911489214893148941489514896148971489814899149001490114902149031490414905149061490714908149091491014911149121491314914149151491614917149181491914920149211492214923149241492514926149271492814929149301493114932149331493414935149361493714938149391494014941149421494314944149451494614947149481494914950149511495214953149541495514956149571495814959149601496114962149631496414965149661496714968149691497014971149721497314974149751497614977149781497914980149811498214983149841498514986149871498814989149901499114992149931499414995149961499714998149991500015001150021500315004150051500615007150081500915010150111501215013150141501515016150171501815019150201502115022150231502415025150261502715028150291503015031150321503315034150351503615037150381503915040150411504215043150441504515046150471504815049150501505115052150531505415055150561505715058150591506015061150621506315064150651506615067150681506915070150711507215073150741507515076150771507815079150801508115082150831508415085150861508715088150891509015091150921509315094150951509615097150981509915100151011510215103151041510515106151071510815109151101511115112151131511415115151161511715118151191512015121151221512315124151251512615127151281512915130151311513215133151341513515136151371513815139151401514115142151431514415145151461514715148151491515015151151521515315154151551515615157151581515915160151611516215163151641516515166151671516815169151701517115172151731517415175151761517715178151791518015181151821518315184151851518615187151881518915190151911519215193151941519515196151971519815199152001520115202152031520415205152061520715208152091521015211152121521315214152151521615217152181521915220152211522215223152241522515226152271522815229152301523115232152331523415235152361523715238152391524015241152421524315244152451524615247152481524915250152511525215253152541525515256152571525815259152601526115262152631526415265152661526715268152691527015271152721527315274152751527615277152781527915280152811528215283152841528515286152871528815289152901529115292152931529415295152961529715298152991530015301153021530315304153051530615307153081530915310153111531215313153141531515316153171531815319153201532115322153231532415325153261532715328153291533015331153321533315334153351533615337153381533915340153411534215343153441534515346153471534815349153501535115352153531535415355153561535715358153591536015361153621536315364153651536615367153681536915370153711537215373153741537515376153771537815379153801538115382153831538415385153861538715388153891539015391153921539315394153951539615397153981539915400154011540215403154041540515406154071540815409154101541115412154131541415415154161541715418154191542015421154221542315424154251542615427154281542915430154311543215433154341543515436154371543815439154401544115442154431544415445154461544715448154491545015451154521545315454154551545615457154581545915460154611546215463154641546515466154671546815469154701547115472154731547415475154761547715478154791548015481154821548315484154851548615487154881548915490154911549215493154941549515496154971549815499155001550115502155031550415505155061550715508155091551015511155121551315514155151551615517155181551915520155211552215523155241552515526155271552815529155301553115532155331553415535155361553715538155391554015541155421554315544155451554615547155481554915550155511555215553155541555515556155571555815559155601556115562155631556415565155661556715568155691557015571155721557315574155751557615577155781557915580155811558215583155841558515586155871558815589155901559115592155931559415595155961559715598155991560015601156021560315604156051560615607156081560915610156111561215613156141561515616156171561815619156201562115622156231562415625156261562715628156291563015631156321563315634156351563615637156381563915640156411564215643156441564515646156471564815649156501565115652156531565415655156561565715658156591566015661156621566315664156651566615667156681566915670156711567215673156741567515676156771567815679156801568115682156831568415685156861568715688156891569015691156921569315694156951569615697156981569915700157011570215703157041570515706157071570815709157101571115712157131571415715157161571715718157191572015721157221572315724157251572615727157281572915730157311573215733157341573515736157371573815739157401574115742157431574415745157461574715748157491575015751157521575315754157551575615757157581575915760157611576215763157641576515766157671576815769157701577115772157731577415775157761577715778157791578015781157821578315784157851578615787157881578915790157911579215793157941579515796157971579815799158001580115802158031580415805158061580715808158091581015811158121581315814158151581615817158181581915820158211582215823158241582515826158271582815829158301583115832158331583415835158361583715838158391584015841158421584315844158451584615847158481584915850158511585215853158541585515856158571585815859158601586115862158631586415865158661586715868158691587015871158721587315874158751587615877158781587915880158811588215883158841588515886158871588815889158901589115892158931589415895158961589715898158991590015901159021590315904159051590615907159081590915910159111591215913159141591515916159171591815919159201592115922159231592415925159261592715928159291593015931159321593315934159351593615937159381593915940159411594215943159441594515946159471594815949159501595115952159531595415955159561595715958159591596015961159621596315964159651596615967159681596915970159711597215973159741597515976159771597815979159801598115982159831598415985159861598715988159891599015991159921599315994159951599615997159981599916000160011600216003160041600516006160071600816009160101601116012160131601416015160161601716018160191602016021160221602316024160251602616027160281602916030160311603216033160341603516036160371603816039160401604116042160431604416045160461604716048160491605016051160521605316054160551605616057160581605916060160611606216063160641606516066160671606816069160701607116072160731607416075160761607716078160791608016081160821608316084160851608616087160881608916090160911609216093160941609516096160971609816099161001610116102161031610416105161061610716108161091611016111161121611316114161151611616117161181611916120161211612216123161241612516126161271612816129161301613116132161331613416135161361613716138161391614016141161421614316144161451614616147161481614916150161511615216153161541615516156161571615816159161601616116162161631616416165161661616716168161691617016171161721617316174161751617616177161781617916180161811618216183161841618516186161871618816189161901619116192161931619416195161961619716198161991620016201162021620316204162051620616207162081620916210162111621216213162141621516216162171621816219162201622116222162231622416225162261622716228162291623016231162321623316234162351623616237162381623916240162411624216243162441624516246162471624816249162501625116252162531625416255162561625716258162591626016261162621626316264162651626616267162681626916270162711627216273162741627516276162771627816279162801628116282162831628416285162861628716288162891629016291162921629316294162951629616297162981629916300163011630216303163041630516306163071630816309163101631116312163131631416315163161631716318163191632016321163221632316324163251632616327163281632916330163311633216333163341633516336163371633816339163401634116342163431634416345163461634716348163491635016351163521635316354163551635616357163581635916360163611636216363163641636516366163671636816369163701637116372163731637416375163761637716378163791638016381163821638316384163851638616387163881638916390163911639216393163941639516396163971639816399164001640116402164031640416405164061640716408164091641016411164121641316414164151641616417164181641916420164211642216423164241642516426164271642816429164301643116432164331643416435164361643716438164391644016441164421644316444164451644616447164481644916450164511645216453164541645516456164571645816459164601646116462164631646416465164661646716468164691647016471164721647316474164751647616477164781647916480164811648216483164841648516486164871648816489164901649116492164931649416495164961649716498164991650016501165021650316504165051650616507165081650916510165111651216513165141651516516165171651816519165201652116522165231652416525165261652716528165291653016531165321653316534165351653616537165381653916540165411654216543165441654516546165471654816549165501655116552165531655416555165561655716558165591656016561165621656316564165651656616567165681656916570165711657216573165741657516576165771657816579165801658116582165831658416585165861658716588165891659016591165921659316594165951659616597165981659916600166011660216603166041660516606166071660816609166101661116612166131661416615166161661716618166191662016621166221662316624166251662616627166281662916630166311663216633166341663516636166371663816639166401664116642166431664416645166461664716648166491665016651166521665316654166551665616657166581665916660166611666216663166641666516666166671666816669166701667116672166731667416675166761667716678166791668016681166821668316684166851668616687166881668916690166911669216693166941669516696166971669816699167001670116702167031670416705167061670716708167091671016711167121671316714167151671616717167181671916720167211672216723167241672516726167271672816729167301673116732167331673416735167361673716738167391674016741167421674316744167451674616747167481674916750167511675216753167541675516756167571675816759167601676116762167631676416765167661676716768167691677016771167721677316774167751677616777167781677916780167811678216783167841678516786167871678816789167901679116792167931679416795167961679716798167991680016801168021680316804168051680616807168081680916810168111681216813168141681516816168171681816819168201682116822168231682416825168261682716828168291683016831168321683316834168351683616837168381683916840168411684216843168441684516846168471684816849168501685116852168531685416855168561685716858168591686016861168621686316864168651686616867168681686916870168711687216873168741687516876168771687816879168801688116882168831688416885168861688716888168891689016891168921689316894168951689616897168981689916900169011690216903169041690516906169071690816909169101691116912169131691416915169161691716918169191692016921169221692316924169251692616927169281692916930169311693216933169341693516936169371693816939169401694116942169431694416945169461694716948169491695016951169521695316954169551695616957169581695916960169611696216963169641696516966169671696816969169701697116972169731697416975169761697716978169791698016981169821698316984169851698616987169881698916990169911699216993169941699516996169971699816999170001700117002170031700417005170061700717008170091701017011170121701317014170151701617017170181701917020170211702217023170241702517026170271702817029170301703117032170331703417035170361703717038170391704017041170421704317044170451704617047170481704917050170511705217053170541705517056170571705817059170601706117062170631706417065170661706717068170691707017071170721707317074170751707617077170781707917080170811708217083170841708517086170871708817089170901709117092170931709417095170961709717098170991710017101171021710317104171051710617107171081710917110171111711217113171141711517116171171711817119171201712117122171231712417125171261712717128171291713017131171321713317134171351713617137171381713917140171411714217143171441714517146171471714817149171501715117152171531715417155171561715717158171591716017161171621716317164171651716617167171681716917170171711717217173171741717517176171771717817179171801718117182171831718417185171861718717188171891719017191171921719317194171951719617197171981719917200172011720217203172041720517206172071720817209172101721117212172131721417215172161721717218172191722017221172221722317224172251722617227172281722917230172311723217233172341723517236172371723817239172401724117242172431724417245172461724717248172491725017251172521725317254172551725617257172581725917260172611726217263172641726517266172671726817269172701727117272172731727417275172761727717278172791728017281172821728317284172851728617287172881728917290172911729217293172941729517296172971729817299173001730117302173031730417305173061730717308173091731017311173121731317314173151731617317173181731917320173211732217323173241732517326173271732817329173301733117332173331733417335173361733717338173391734017341173421734317344173451734617347173481734917350173511735217353173541735517356173571735817359173601736117362173631736417365173661736717368173691737017371173721737317374173751737617377173781737917380173811738217383173841738517386173871738817389173901739117392173931739417395173961739717398173991740017401174021740317404174051740617407174081740917410174111741217413174141741517416174171741817419174201742117422174231742417425174261742717428174291743017431174321743317434174351743617437174381743917440174411744217443174441744517446174471744817449174501745117452174531745417455174561745717458174591746017461174621746317464174651746617467174681746917470174711747217473174741747517476174771747817479174801748117482174831748417485174861748717488174891749017491174921749317494174951749617497174981749917500175011750217503175041750517506175071750817509175101751117512175131751417515175161751717518175191752017521175221752317524175251752617527175281752917530175311753217533175341753517536175371753817539175401754117542175431754417545175461754717548175491755017551175521755317554175551755617557175581755917560175611756217563175641756517566175671756817569175701757117572175731757417575175761757717578175791758017581175821758317584175851758617587175881758917590175911759217593175941759517596175971759817599176001760117602176031760417605176061760717608176091761017611176121761317614176151761617617176181761917620176211762217623176241762517626176271762817629176301763117632176331763417635176361763717638176391764017641176421764317644176451764617647176481764917650176511765217653176541765517656176571765817659176601766117662176631766417665176661766717668176691767017671176721767317674176751767617677176781767917680176811768217683176841768517686176871768817689176901769117692176931769417695176961769717698176991770017701177021770317704177051770617707177081770917710177111771217713177141771517716177171771817719177201772117722177231772417725177261772717728177291773017731177321773317734177351773617737177381773917740177411774217743177441774517746177471774817749177501775117752177531775417755177561775717758177591776017761177621776317764177651776617767177681776917770177711777217773177741777517776177771777817779177801778117782177831778417785177861778717788177891779017791177921779317794177951779617797177981779917800178011780217803178041780517806178071780817809178101781117812178131781417815178161781717818178191782017821178221782317824178251782617827178281782917830178311783217833178341783517836178371783817839178401784117842178431784417845178461784717848178491785017851178521785317854178551785617857178581785917860178611786217863178641786517866178671786817869178701787117872178731787417875178761787717878178791788017881178821788317884178851788617887178881788917890178911789217893178941789517896178971789817899179001790117902179031790417905179061790717908179091791017911179121791317914179151791617917179181791917920179211792217923179241792517926179271792817929179301793117932179331793417935179361793717938179391794017941179421794317944179451794617947179481794917950179511795217953179541795517956179571795817959179601796117962179631796417965179661796717968 |
- REM CAC is free software: you can redistribute it and/or modify
- REM it under the terms of the GNU General Public License as published by
- REM the Free Software Foundation, either version 2 of the License, or
- REM (at your option) any later version.
- REM
- REM CAC is distributed in the hope that it will be useful,
- REM but WITHOUT ANY WARRANTY; without even the implied warranty of
- REM MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- REM GNU General Public License for more details.
- REM
- REM You should have received a copy of the GNU General Public License
- REM along with CAC. If not, see <https://www.gnu.org/licenses/>.
- REM
- REM CAC
- REM Copyright (C) 1990 Richard Emsley
- MODE 12 : COLOUR 0 : COLOUR 191 : CLS
- *CONFIGURE spritesize 300K
- errorbeforedisplay$ = "y"
- ON ERROR PROCerror
- biga% = 10^5 : bigb% = 0 : bigc% = 0 : bigd% = 10^5 : box$ = "n"
- :
- PROCtobegin
- END
- :
- REM*******************************
- :
- DEF PROCawait
- :
- IF easiermenus$ = "n" THEN
- PROCwindow(20,69,60,55)
- PRINT'" Functions F"
- PRINT " Add one note (fully defined) O"
- PRINT " Delete notes X"
- PRINT " Copy/move notes C"
- PRINT " Define a group of values G"
- PRINT " Add the group of values A"
- PRINT " Rhythmicize R"
- PRINT " Display D"
- PRINT " Play P"
- PRINT " Various V"
- PRINT " Undo last operation Z"
- PRINT " Save S"
- PRINT " Quit Q"
- ELSE
- PROCwindow(20,69,60,42)
- PRINT' " Functions F"
- PRINT' " Add one note (fully defined) O"
- PRINT' " Delete notes X"
- PRINT' " Copy/move notes C"
- PRINT' " Define a group of values G"
- PRINT' " Add the group of values A"
- PRINT' " Rhythmicize R"
- PRINT' " Display D"
- PRINT' " Play P"
- PRINT' " Various V"
- PRINT' " Undo last operation Z"
- PRINT' " Save S"
- PRINT' " Quit Q"
- ENDIF
- :
- CASE GET$ OF
- WHEN "f" : ON : PROCfunctionreception
- WHEN "o" : ON : PROCaddonenote
- WHEN "x" : ON : PROCdelete
- WHEN "c","1","`" : ON : PROCcopy
- WHEN "g", "3" : ON : PROCsubawaitG
- WHEN "a" : ON : PROCsubawaitA
- WHEN "r" :
- VDU 7
- IF easiermenus$ = "n" THEN PROCwindow(20,69,63,52) ELSE PROCwindow(20,69,63,42)
- CLS
- PRINT'" To rhythmicize attacks, first switch on "
- PRINT'" Rhythmicize Attacks in Display Options "
- PRINT'" (M/V/D/H) then create a group of attacks "
- PRINT'" or copy some attacks or move some attacks "
- PRINT'" to itself, during the course of which you "
- PRINT'" will be invited to rhythmicize them. "
- PRINT'" (press a key to continue) "
- CASE GET$ OF
- WHEN "m" : PROCdisplay
- OTHERWISE
- PROCdisplay
- ENDCASE
- WHEN "d" : ON : PROCpredisplay
- WHEN "p" : ON : play$ = "play" : PROCplay
- WHEN "m" : ON :
- PROCdisplay : REM toggle
- WHEN "v" : ON : PROCplaysubmenu
- WHEN "s" : ON : PROCsave
- WHEN "Z","z" : PROCundo
- WHEN "q" : ON : PROCquit
- OTHERWISE ON : VDU 7 : PROCawait : REM bleep and loop back to start of proc
- ENDCASE
- :
- ENDPROC
- :
- REM*********************************
- :
- DEF PROCsubawaitG
- :
- IF easiermenus$ = "n" THEN
- CLS
- PRINT' " attacks A"
- PRINT " envelope points R"
- PRINT " pitches P"
- PRINT " amplitudes L"
- PRINT " amplitude gradations G"
- PRINT " envelopes/glissandos E"
- PRINT " durations D"
- PRINT " microtonal inflections M"
- ELSE
- CLS
- PRINT'" attacks A"
- PRINT'" envelope points R"
- PRINT'" pitches P"
- PRINT'" amplitudes L"
- PRINT'" amplitude gradations G"
- PRINT'" envelopes/glissandos E"
- PRINT'" durations D"
- PRINT'" microtonal inflections M"
- ENDIF
- :
- CASE GET$ OF
- WHEN "A","a" : PROCseriesattacks
- WHEN "R","r" : PROCreleases
- WHEN "P","p", "3" : PROCseriespitches
- WHEN "L","l" : PROCseriesamplitudes
- WHEN "E","e" : PROCseriesenvelopes
- WHEN "G","g" : gradations$ = "y" : PROCseriesenvelopes
- WHEN "D","d" : PROCseriesdurations
- WHEN "M","m" : PROCseriesinflections
- OTHERWISE VDU 7 : PROCsubawaitG
- ENDCASE
- :
- ENDPROC
- :
- REM***********************************
- :
- DEF PROCprearraysetup
- :
- MODE 12 : COLOUR 0 : COLOUR 191
- CLS
- numwaves% = 19
- INPUT'''''" Estimate the maximum number of bars "nobars%
- INPUT''" Estimate the average number of notes per bar in the busiest part "nonotes
- INPUT''" How many voices "numparts%
- :
- DIM insts$(numparts%,2) : instsdimmed$ = "y"
- PRINT''" Do you want to define the voices or use default ones (Y/D)"
- CASE GET$ OF
- WHEN "Y","y" :
- FOR count% = 1 TO numparts%
- PRINT '" voice ";count%;" is called"
- INPUT name$
- PRINT " and is in clef (P/T/B/D...TT/TB/BB etc)"
- INPUT clef$
- PRINT " and has how many staves"
- INPUT staves$
- insts$(count%,0) = name$ : insts$(count%,1) = clef$ : insts$(count%,2) = staves$
- NEXT
- WHEN "D","d" :
- FOR count% = 1 TO numparts%
- insts$(count%,0) = "" : insts$(count%,1) = "T" : insts$(count%,2)="1"
- NEXT
- OTHERWISE
- ENDCASE
- :
- REPEAT
- INPUT''" The time signature has how many beats to the bar "factor%
- :
- CASE factor% OF
- WHEN 1,2,3,4,5,6,8,10,12 : success$ = "YES"
- OTHERWISE
- success$ = "NO"
- VDU 7
- PRINT'" Only 1,2,3,4,5,6,8,10 or 12 are allowed "
- PRINT'" press a key to try again"
- CASE GET$ OF
- WHEN "m" : success$ = "NO"
- OTHERWISE
- success$ = "NO"
- ENDCASE
- :
- ENDCASE
- UNTIL success$ = "YES"
- :
- factor% = factor% * 8
- beatfactor% = 960/factor%
- :
- REPEAT
- success$ = "YES"
- PRINT''" of what note value "
- PRINT' " (minim/half-note = 2 "
- PRINT' " crotchet/quarter-note = 4 "
- PRINT' " quaver/eighth-note = 8 "
- PRINT' " semiquaver/sixteenth-note = 16 "
- INPUT' " demisemiquaver/thirtysecond-note = 32) "beams%
- :
- CASE beams% OF
- WHEN 2 : beams% = 2
- WHEN 4 : beams% = 3
- WHEN 8 : beams% = 4
- WHEN 16 : beams% = 5
- WHEN 32 : beams% = 6
- OTHERWISE
- PRINT'" sorry, try again "
- success$ = "NO"
- ENDCASE
- UNTIL success$ = "YES"
- :
- manynotes% = nobars%*nonotes
- filename$ = ""
- ENDPROC
- :
- REM***********************************************
- :
- DEF PROCarraysetup
- :
- DIM array%(manynotes%,2,(numparts%-1)) : DIM arrayX%(manynotes%,2,(numparts%-1))
- IF instsdimmed$ = "n" THEN DIM insts$(numparts%,2)
- DIM instsX$(numparts%,2)
- DIM numusedcells%(numparts%-1) : DIM numusedcellsX%(numparts%-1)
- DIM cell%(1999), bar%(1999)
- DIM attacks1%(10000), attacks2%(10000), attacks3%(10000), attacks4%(10000), attacks5%(10000)
- DIM pitches%(10000), pitches1%(10000), pitches2%(10000), amplitudes%(10000), envelopes%(10000)
- DIM durations%(10000), glissandos%(10000), inflections%(10000)
- DIM pitchset%(numparts%+47), ampset%(numparts%+47), envset%(numparts%+47), durset%(numparts%+47), glissset%(numparts%+47), infset%(numparts%+47)
- DIM pitchsetX%(numparts%+47), ampsetX%(numparts%+47), envsetX%(numparts%+47), dursetX%(numparts%+47), glisssetX%(numparts%+47)
- DIM functionattacks(10000)
- DIM nodes%(47), nodes1%(47)
- DIM dur%(999), proportion%(999), rhythmicattacks%(999), groupattacks%(999)
- DIM error%(999), notategroup%(999,1), errororder%(999), errororder1%(999)
- DIM disarray%(nobars%,3,(numparts%-1)) : DIM disarrayX%(nobars%,3,(numparts%-1))
- DIM displayvoices%(numparts%), holddisplay%(numparts%), rgroup%(6), longinsts$(2,2), staves%(6)
- DIM displayvoices1%(numparts%) : DIM displayvoicesX%(numparts%)
- DIM value%(2), pos%(2), longbeamposn%(numparts%), shortbeamposn%(numparts%), actbeamposn%(numparts%), shortamppos%(numparts%), longamppos%(numparts%), actamppos%(numparts%)
- DIM longbeamposnX%(numparts%), shortbeamposnX%(numparts%), shortampposX%(numparts%), longampposX%(numparts%)
- DIM longstemdir$(numparts%-1), shortstemdir$(numparts%-1)
- DIM longstemdirX$(numparts%-1), shortstemdirX$(numparts%-1)
- DIM waveforms$(numparts%), playvoices%(8), lvdata%(8,9), tic%(4), tun%(8)
- DIM waveformsX$(numparts%), lvdataX%(8,9)
- DIM wforms$(19) : waveload$ = "notdone"
- DIM wformsX$(19)
- DIM startoflayersection%(50), shareoflayers%(50,50), chanceoflayer%(50)
- DIM layershare%(50), numattackssections%(50), startofattackssection%(50,50)
- DIM numattax%(50,50,1), attackscontrol$(50)
- DIM numattackssections1%(50), startofattackssection1%(50,200)
- DIM numattax1%(50,200,1), appearances%(50)
- DIM durationscontrol$(50), numdurationssections%(50)
- DIM numdurationssections1%(50), startofdurationssection%(50,200)
- DIM startofdurationssection1%(50,200), doorations%(50,200), doorations1%(50,200)
- DIM numvalues%(50), values(50,50), valuescounter%(50), multiplier$(50)
- DIM multipliermode$(50)
- DIM contoursequences%(50,15), transpositionsequences%(199,1)
- DIM sample%(299), group%(7), contours%(69,7), octavesequences%(50,48,11)
- DIM pitchnames$(47), octaveloop%(48), distortparas%(50,3)
- DIM numlayerOKsects%(50), OKtouselayers%(50,1), layersOK%(50,50,2)
- DIM layerends%(50), amplitudes1%(10000), dynlayers%(12,5), dynnumbers%(99)
- DIM ampsample%(49)
- DIM tempi%(nobars%), bannedpitches%(80), bannedints%(24,2), triednotes%(88)
- DIM tempiX%(nobars%)
- DIM extractinfo%(20), redpitches%(9,30), numredpitches%(9), holdstartcell%(numparts%)
- DIM remarks$(nobars%,1), quickdisplay%(numparts%), prequickdisplay%(numparts%), thebeats%(15)
- DIM remarksX$(nobars%,1)
- DIM envattacks%(3000), envpitches%(3000), taken%(19)
- FOR count% = 0 TO nobars% : tempi%(count%) = 30 : NEXT
- FOR count% = 0 TO 47 : READ name$ : pitchnames$(count%) = name$ : NEXT
- DATA "C 1/4 flat","C 1/8 flat","C nat","C 1/8 shrp","C 1/4 shrp"
- DATA "C 3/8 shrp","D flat","D 3/8 flat","D 1/4 flat","D 1/8 flat"
- DATA "D nat","D 1/8 shrp","D 1/4 shrp","D 3/8 shrp","E flat","E 3/8 flat"
- DATA "E 1/4 flat","E 1/8 flat","E nat","E 1/8 shrp","E 1/4 shrp"
- DATA "F 1/8 flat","F nat","F 1/8 shrp","F 1/4 shrp","F 3/8 shrp"
- DATA "F shrp","G 3/8 flat","G 1/4 flat","G 1/8 flat","G nat","G 1/8 shrp"
- DATA "G 1/4 shrp","G 3/8 shrp","A flat","A 3/8 flat","A 1/4 flat"
- DATA "A 1/8 flat","A nat","A 1/8 shrp","A 1/4 shrp","A 3/8 shrp"
- DATA "B flat","B 3/8 flat","B 1/4 flat","B 1/8 flat","B nat","B 1/8 shrp"
- DATA 10,1,1,20,2,1,2,21,2,2,1,22,3,1,3,2,23,3,3,1,2,24,3,2,3,1
- DATA 25,3,2,1,3,30,3,1,2,3,31,3,3,2,1,32,4,1,3,4,2,33,4,4,2,1,3
- DATA 34,4,2,3,4,1,35,4,3,2,1,4,36,4,3,1,2,4,37,4,2,4,3,1,38,4,4,1,2,3
- DATA 39,4,1,4,3,2,40,4,1,2,3,4,41,4,4,3,2,1,42,5,1,2,4,5,3
- DATA 43,5,5,4,2,1,3,44,5,2,3,4,5,1,45,5,4,3,2,1,5,46,5,3,1,2,4,5
- DATA 47,5,3,5,4,2,1,48,5,5,1,2,3,4,49,5,1,5,4,3,2,50,5,1,2,3,4,5
- DATA 51,5,5,4,3,2,1,52,6,1,2,4,5,6,3,53,6,6,5,3,2,1,4
- DATA 54,6,2,3,4,5,6,1,55,6,5,4,3,2,1,6,56,6,4,1,2,3,5,6
- DATA 57,6,3,6,5,4,2,1,58,6,6,1,2,3,4,5,59,6,1,6,5,4,3,2
- DATA 60,6,1,2,3,4,5,6,61,6,6,5,4,3,2,1,62,7,1,2,3,5,6,7,4
- DATA 63,7,7,6,5,3,2,1,4,64,7,2,3,4,5,6,7,1,65,7,6,5,4,3,2,1,7
- DATA 66,7,4,1,2,3,5,6,7,67,7,4,7,6,5,3,2,1,68,7,7,1,2,3,4,5,6
- DATA 69,7,1,7,6,5,4,3,2
- FOR count% = 1 TO 47
- READ a%,b%
- contours%(a%,0) = b%
- FOR counter% = 1 TO b%
- READ c%
- contours%(a%,counter%) = c%
- NEXT
- NEXT
- FOR count% = 0 TO numparts%-1 : pitchset%(count%) = 55 : NEXT
- FOR count% = 0 TO numparts%-1 : ampset%(count%) = 3 : NEXT
- FOR count% = 0 TO numparts%-1 : envset%(count%) = 9 : NEXT
- FOR count% = 0 TO numparts%-1 : durset%(count%) = 60 : NEXT
- FOR count% = 0 TO numparts%-1 : glissset%(count%) = 105050 : NEXT
- FOR count% = 0 TO numparts%-1 : infset%(count%) = 50 : NEXT
- *TUNING 0
- VOICES 8
- *CHANNELVOICE 1 WaveSynth-Beep
- *CHANNELVOICE 2 WaveSynth-Beep
- *CHANNELVOICE 3 WaveSynth-Beep
- *CHANNELVOICE 4 WaveSynth-Beep
- *CHANNELVOICE 5 WaveSynth-Beep
- *CHANNELVOICE 6 WaveSynth-Beep
- *CHANNELVOICE 7 WaveSynth-Beep
- *CHANNELVOICE 8 WaveSynth-Beep
- direction$ = "" : shortstemdir$() = "U" : longstemdir$() = "U" : shortbeamposn%() = 106 : longbeamposn%() = 106
- manyattacks% = 0 : longbeatsupper% = 739 : longbeatslower% = 405
- tempo% = 19660 : REM default tempo = MM30 per bar
- defaultvoices$ = "y" : PROCassignvoices
- CLS
- VDU 28,20,27,60,15
- COLOUR 0 : COLOUR 191 : CLS
- numbars% = 4 : startbar% = 1
- :
- numvoices% = numparts%
- FOR count% = 1 TO numvoices%
- displayvoices%(count%) = 1 + count% - 1
- holddisplay%(count%) = 1 + count% - 1
- NEXT
- holdnum% = numvoices%
- :
- quickdisplay%(1) = 1 : prequickdisplay%(1) = 1
- holdnum% = 1 : holdstart% = 1 : quicknum% = 1 : quickstart% = 1
- prequicknum% = 1 : prequickstart% = 1
- notehead$ = "vsmall" : longscore$ = "y" : startv% = 1 : startv1% = 1
- printing$ = "n"
- barlines$ = "y" : staves$ = "y" : beats$ = "n" : amplitudes$ = "y"
- staves$ = "y" : barlines$ = "y" : names$ = "y" : lowerstave$ = "y"
- accidentals$ = "y" : stems$ = "y" : xoption$ = "y" : durations$ = "n"
- envelopes$ = "y" : glissandos$ = "y" : MM% = 30 : beatstep% = 8
- copyit$ = "OFF" : distort$ = "OFF" : beatnumbers$ = "n"
- wavefilingsystem$ = "notloaded" : manywaves% = 0 : barnosoften% = 5
- reordered$ = "n" : equalized$ = "n" : notenumbers$ = "n" : beatnum_diff$ = "num"
- beatunits$ = "big" : parasdefined$ = "no" : preplaydisplay$ = "n"
- paraset$ = "off" : savevoice$ = "N"
- method$ = "raw" : reordered$ = "n" : quiz$ = "yes" : typeintervals$ = "s"
- displayintervals$ = "n" : numintervals% = 1 : alterbeatsat% = 0
- compoundpitch% = 12 : compoundquarter% = 24 : compoundeighth% = 48 : compoundcent% = 1200
- defaultsieve = 2 : funcinput$ = "durat" : redpitches$ = "n" : printno% = 0
- seegraph$ = "n" : seeinfo$ = "n" : seereorder$ = "n" : seereorderx$ = "n" : seereordery$ = "n"
- seeequalize$ = "n" : seeequalizex$ = "n" : seeequalizey$ = "n"
- seerhythmicize$ = "n" : seequery$ = "n" : startfinishdurats$ = "Y" : displayedfunc$ = "n"
- along% = 0 : playnewscreen$ = "y" : seeduration$ = "n" : lower% = 0 : justone$ = "n"
- biga% = 10^5 : bigb% = 0 : bigc% = 0 : bigd% = 10^5 : printinfo$ = "n"
- lowerstart% = 1 : upperstart% = 99 : lowerend% = 1 : upperend% = 99 : toggle$ = "orig"
- quickcopy$ = "y" : quickplay% = 1 : seedurinbts$ = "n" : seedurincrots$ = "n"
- screenvoices$ = "n" : ampoptions$ = "n" : screenmovesby% = 3 : copydownwards$ = "n"
- setalong$ = "y" : numvoicesgiven$ = "n" : envelopedata$ = "none" : deleteone$ = "none"
- quickextract$ = "n" : askaboutpitches$ = "y" : usebottomstave$ = "n" : copysuccessively$ = "n"
- succfirsttime$ = "y" : sequalssection$ = "n"
- addpitches$ = "y" : downwardsspeed% = 50
- horizscroll% = 25 : addten$ = "n" : squarebracket$ = "addten" : queryalong$ = "n"
- waitafterfirst% = 50 : waitaftersecond% = 50 : notenames$ = "n" : holdbackby% = 0
- updisplay% = 1 : vertscroll% = 25 : singlepitch$ = "m" : nosevery% = 1 : startnos% = 1
- reorderpitches$ = "n" : namestaves$ = "nameone" : usebeep$ = "n" : firsttimequick$ = "y"
- onlycontent$ = "n" : compress$ = "n" : quickdisplaywindow$ = "y" : ampmethod$ = "sample"
- holdbackby% = 960 : copytoend$ = "n" : gradations$ = "n" : firstasking$ = "y"
- resetdefaults$ = "n" : firstpitch$ = "y" : usedprev$ = "n" : nodelay$ = "n"
- askprevious$ = "y" : errorbeforedisplay$ = "n" : quitnow$ = "n"
- crossing$ = "n" : easiermenus$ = "y" : copymove$ = "C"
- PROCrhythmdefaults
- :
- ENDPROC
- :
- REM*************************************
- :
- DEF PROCsubawaitA
- :
- IF easiermenus$ = "n" THEN
- PROCwindow(20,69,70,55)
- CLS
- PRINT' " attacks A"
- PRINT " pitches P"
- PRINT " amplitudes L"
- PRINT " envelopes E"
- PRINT " durations D"
- PRINT " glissandos G"
- PRINT " microtonal inflections M"
- ELSE
- PROCwindow(20,69,70,42)
- CLS
- PRINT' " attacks A"
- PRINT '" pitches P"
- PRINT '" amplitudes L"
- PRINT '" envelopes E"
- PRINT '" durations D"
- PRINT '" glissandos G"
- PRINT '" microtonal inflections M"
- ENDIF
- :
- CASE GET$ OF
- WHEN "A","a" : PROCinsertattacks
- WHEN "P","p" : PROCinsertpitches
- WHEN "L","l" : PROCinsertamplitudes
- WHEN "E","e" : PROCinsertenvelopes
- WHEN "D","d" : PROCinsertdurations
- WHEN "M","m" : PROCinsertinflections
- OTHERWISE VDU 7 : PROCsubawaitA
- ENDCASE
- :
- ENDPROC
- :
- REM**************************************
- :
- DEF PROCnewnotereception(voice%,barno%,beatno%,pitch%,amp%,env%,dur%,gliss%,inf%)
- :
- value% = (barno% * 10^3) + beatno%
- :
- option% = 0
- :
- ::::::REM if new note is very first to be added::::::
- IF numusedcells%(voice%) = 0 THEN option% = 1
- :
- IF option% <> 1 THEN
- :
- :::::::REM to tack new note on at end:::::
- IF numusedcells%(voice%) > 0 AND value% > (array%((numusedcells%(voice%)-1),0,voice%)) DIV 10^3 THEN option% = 2
- :
- :::::::REM to tack new note on at START::::
- IF numusedcells%(voice%) > 0 AND value% < (array%(0,0,voice%)) DIV 10^3 THEN option% = 3
- :
- ::::::REM to put new note in middle::::::::::
- IF numusedcells%(voice%) > 0 AND value% >= (array%(0,0,voice%)) DIV 10^3 AND value% <= (array%(numusedcells%(voice%)-1,0,voice%)) DIV 10^3 THEN option% = 4
- :
- ENDIF
- :
- IF addingnotes$ = "y" THEN
- CASE option% OF
- WHEN 1 : shunt$ = "Y"
- PROCcellfill(0,voice%,barno%,beatno%,pitch%,amp%,env%,dur%,gliss%,inf%)
- :
- WHEN 2 : shunt$="Y"
- PROCcellfill(numusedcells%(voice%),voice%,barno%,beatno%,pitch%,amp%,env%,dur%,gliss%,inf%)
- :
- WHEN 3 : shunt$="Y"
- PROCshuntright(0)
- PROCcellfill(0,voice%,barno%,beatno%,pitch%,amp%,env%,dur%,gliss%,inf%)
- :
- WHEN 4 : PROCsearch(value%)
- IF shunt$="Y" PROCshuntright(startcell%)
- PROCcellfill(startcell%,voice%,barno%,beatno%,pitch%,amp%,env%,dur%,gliss%,inf%)
- :
- ENDCASE
- ENDIF
- :
- ENDPROC
- :
- REM****************************************************
- :
- DEF PROCcellfill(cell%,voice%,barno%,beatno%,pitch%,amp%,env%,dur%,gliss%,inf%)
- :
- IF barno% = 999 THEN barno% = array%(cell%,0,voice%) DIV 10^6
- IF beatno% = 999 THEN beatno% = (array%(cell%,0,voice%)DIV 10^3)MOD 10^3
- IF pitch% = 999 THEN pitch% = array%(cell%,0,voice%) MOD 10^3
- IF amp% = 9 THEN amp% = array%(cell%,1,voice%) MOD10
- IF env% = 999 THEN env% = array%(cell%,2,voice%) DIV10^2
- IF dur% = 999 THEN dur% = (array%(cell%,1,voice%) DIV10) MOD 10^3 ELSE PROCconvertdur
- IF gliss% = 99 THEN gliss% = array%(cell%,1,voice%) DIV10^4
- IF inf% = 99 THEN inf% = array%(cell%,2,voice%) MOD 10^2
- :
- array%(cell%,0,voice%) = (barno%*10^6) + (beatno%*10^3) + pitch%
- array%(cell%,1,voice%) = (gliss%*10^4)+(dur%*10)+amp%
- array%(cell%,2,voice%) = (env%*10^2)+inf%
- :
- IF shunt$="Y" THEN numusedcells%(voice%) += 1
- :
- ENDPROC
- :
- REM******************************************************
- :
- DEF PROCshuntright(startcell%)
- :
- FOR tier% = 0 TO 2
- FOR count% = (numusedcells%(voice%)) TO (startcell%+1) STEP -1
- array%(count%,tier%,voice%) = array%((count%-1),tier%,voice%)
- NEXT
- NEXT
- :
- ENDPROC
- :
- REM*********************************************************
- :
- DEF PROCsearch(newvalue%)
- :
- startcell% = -1
- distance% = numusedcells%(voice%)/2
- cellnum% = distance%
- :
- REPEAT
- :
- :
- IF newvalue% = (array%(cellnum%,0,voice%)) DIV 10^3 THEN
- startcell% = cellnum% : REM this ALTERS, rather than adds, a note
- shunt$ = "N"
- ENDIF
- :
- IF cellnum% > 0 THEN
- :
- IF newvalue% = (array%(cellnum%+1,0,voice%)) DIV 10^3 THEN
- startcell% = cellnum%+1 : REM this ALTERS too
- shunt$ = "N"
- ENDIF
- :
- :
- IF newvalue% = (array%(cellnum%-1,0,voice%)) DIV 10^3 THEN
- startcell% = cellnum%-1 : REM this ALTERS too
- shunt$ = "N"
- ENDIF
- :
- IF newvalue% > (array%(cellnum%,0,voice%) DIV 10^3) AND newvalue% < (array%(cellnum%+1,0,voice%) DIV 10^3) THEN
- startcell% = (cellnum%+1) : REM newvalue immediately to right of cellnum
- shunt$ = "Y"
- ENDIF
- :
- :
- IF newvalue% < (array%(cellnum%,0,voice%) DIV 10^3) AND newvalue% > (array%(cellnum%-1,0,voice%) DIV 10^3) THEN
- startcell% = cellnum% : REM immediately to left
- shunt$ = "Y"
- ENDIF
- :
- :
- IF newvalue% > (array%(cellnum%+1,0,voice%) DIV 10^3) THEN
- IF distance% = 1 THEN distance% = 2
- distance% = distance%/2
- cellnum% = cellnum% + distance%
- ENDIF
- :
- :
- IF newvalue% < (array%(cellnum%-1,0,voice%) DIV 10^3) THEN
- IF distance% = 1 THEN distance% = 2
- distance% = distance%/2
- cellnum% = cellnum% - distance%
- ENDIF
- ENDIF
- :
- :
- UNTIL startcell% > -1
- :
- ENDPROC
- :
- REM***************************************************
- :
- DEF PROCplay
- :
- waveload$ = "notdone"
- :
- BEATS 960 : REM 2/4 bars, 480 each crotchet
- tic%() = 0
- tun%() = 0
- :
- IF play$ = "play" THEN
- IF easiermenus$ = "n" THEN PROCwindow(20,69,60,55) ELSE PROCwindow(20,69,60,42)
- CLS
- INPUT'" Starting at bar "startingbar%
- INPUT " beat "beats%
- PROCalterbeats : startbeat% = beats%
- INPUT " and ending at bar "endbar%
- INPUT'" How many voices "nvoices%
- ENDIF
- :
- :
- FOR count% = 1 TO nvoices%
- IF play$ = "play" THEN
- PRINT'" voice number ";count%;" is which voice number"
- INPUT vnumber%
- playvoices%(count%) = vnumber%
- ELSE vnumber% = playvoices%(count%)
- ENDIF
- :
- IF usebeep$ = "n" THEN
- CASE count% OF
- WHEN 1 :
- CASE waveforms$(vnumber%) OF
- WHEN "WaveSynth-Beep" : *CHANNELVOICE 1 WaveSynth-Beep
- WHEN "StringLib-Soft" : *CHANNELVOICE 1 StringLib-Soft
- WHEN "StringLib-Pluck" : *CHANNELVOICE 1 StringLib-Pluck
- WHEN "StringLib-Steel" : *CHANNELVOICE 1 StringLib-Steel
- WHEN "StringLib-Hard" : *CHANNELVOICE 1 StringLib-Hard
- WHEN "Percussion-Soft" : *CHANNELVOICE 1 Percussion-Soft
- WHEN "Percussion-Medium" : *CHANNELVOICE 1 Percussion-Medium
- WHEN "Percussion-Snare" : *CHANNELVOICE 1 Percussion-Snare
- WHEN "Percussion-Noise" : *CHANNELVOICE 1 Percussion-Noise
- WHEN "BassBowAb" : *CHANNELVOICE 1 BassBowAb
- tun%(1) = -1470
- WHEN "AcouBass" : *CHANNELVOICE 1 AcouBass
- tun%(1) = -2731
- WHEN "Vibe" : *CHANNELVOICE 1 Vibe
- tun%(1) = -6912
- WHEN "BugleC" : *CHANNELVOICE 1 BugleC
- tun%(1) = -11008
- WHEN "CornetEb" : *CHANNELVOICE 1 CornetEb
- tun%(1) = -12117
- WHEN "SaxEbBarC" : *CHANNELVOICE 1 SaxEbBarC
- tun%(1) = -2816
- WHEN "SaxBbTenrE" : *CHANNELVOICE 1 SaxBbTenrE
- tun%(1) = -4181
- WHEN "BassoonEb" : *CHANNELVOICE 1 BassoonEb
- tun%(1) = -4011
- WHEN "ClarinetBb" : *CHANNELVOICE 1 ClarinetBb
- tun%(1) = -10325
- WHEN "EngHornGb" : *CHANNELVOICE 1 EngHornGb
- tun%(1) = -8960
- WHEN "MandolinDb" : *CHANNELVOICE 1 MandolinDb
- tun%(1) = -11264
- WHEN "Piano2B" : *CHANNELVOICE 1 Piano2B
- tun%(1) = -2475
- WHEN "ClarVibEb" : *CHANNELVOICE 1 ClarVibEb
- tun%(1) = -7850
- WHEN "GtrDobroB" : *CHANNELVOICE 1 GtrDobroB
- tun%(1) = -6485
- WHEN "RecorderGb" : *CHANNELVOICE 1 RecorderGb
- tun%(1) = -13056
- WHEN "FlugelHnEb" : *CHANNELVOICE 1 FlugelHnEb
- tun%(1) = -12032
- WHEN "VceMmmGb23" : *CHANNELVOICE 1 VceMmmGb23
- tun%(1) = -853
- WHEN "VceMOooGb3" : *CHANNELVOICE 1 VceMOooGb3
- tun%(1) = -4843
- WHEN "VceFemAahC" : *CHANNELVOICE 1 VceFemAahC
- tun%(1) = -10948
- WHEN "VceFMmmGb4" : *CHANNELVOICE 1 VceFMmmGb4
- tun%(1) = -8918
- WHEN "Bass" : *CHANNELVOICE 1 Bass
- tun%(1) = 0
- WHEN "ChurchBell" : *CHANNELVOICE 1 ChurchBell
- tun%(1) = -2731
- WHEN "mysound" : *CHANNELVOICE 1 mysound
- tun%(1) = 0
- WHEN "GuiroFast" : *CHANNELVOICE 1 GuiroFast
- tun%(1) = -4000
- WHEN "Clave" : *CHANNELVOICE 1 Clave
- tun%(1) = -8096
- WHEN "CowBell" : *CHANNELVOICE 1 CowBell
- tun%(1) = -5707
- WHEN "CymbRideHd" : *CHANNELVOICE 1 CymbRideHd
- tun%(1) = -8096
- WHEN "AcGuitar1" : *CHANNELVOICE 1 AcGuitar1
- tun%(1) = -7072
- WHEN "CongaHi" : *CHANNELVOICE 1 CongaHi
- tun%(1) = -4000
- WHEN "DrumExplo" : *CHANNELVOICE 1 DrumExplo
- tun%(1) = -4000
- WHEN "ElecTom1" : *CHANNELVOICE 1 ElecTom1
- tun%(1) = -8096
- WHEN "Harp1" : *CHANNELVOICE 1 Harp1
- tun%(1) = -10997
- WHEN "Harpsi" : *CHANNELVOICE 1 Harpsi
- tun%(1) = -6901
- WHEN "HiString" : *CHANNELVOICE 1 HiString
- tun%(1) = -10997
- WHEN "HonkyPiano" : *CHANNELVOICE 1 HonkyPiano
- tun%(1) = -6901
- WHEN "JapFlute" : *CHANNELVOICE 1 JapFlute
- tun%(1) = -10997
- WHEN "JazzOrgan" : *CHANNELVOICE 1 JazzOrgan
- tun%(1) = -10997
- WHEN "MidStrings" : *CHANNELVOICE 1 MidStrings
- tun%(1) = -6901
- WHEN "NoteArp1" : *CHANNELVOICE 1 NoteArp1
- tun%(1) = -4000
- WHEN "SnareEcho" : *CHANNELVOICE 1 SnareEcho
- tun%(1) = -4341
- WHEN "TablaHi" : *CHANNELVOICE 1 TablaHi
- tun%(1) = -7669
- WHEN "Timpani" : *CHANNELVOICE 1 Timpani
- tun%(1) = -928
- WHEN "Tomtom1" : *CHANNELVOICE 1 Tomtom1
- tun%(1) = -5365
- WHEN "Trombone1" : *CHANNELVOICE 1 Trombone1
- tun%(1) = -6901
- WHEN "Trumpet" : *CHANNELVOICE 1 Trumpet
- tun%(1) = -10997
- WHEN "Xylophone" : *CHANNELVOICE 1 Xylophone
- tun%(1) = -6901
- WHEN "AcouGtr2B" : *CHANNELVOICE 1 AcouGtr2B
- tun%(1) = -6560
- WHEN "AcuBassAb1" : *CHANNELVOICE 1 AcuBassAb1
- tun%(1) = -1610
- WHEN "BagPipeG" : *CHANNELVOICE 1 BagPipeG
- tun%(1) = -9291
- WHEN "BanjoChdBb" : *CHANNELVOICE 1 BanjoChdBb
- tun%(1) = -4000
- WHEN "BazookiE" : *CHANNELVOICE 1 BazookiE
- tun%(1) = -8267
- WHEN "BellC" : *CHANNELVOICE 1 BellC
- tun%(1) = -10997
- WHEN "BrassEns1B" : *CHANNELVOICE 1 BrassEns1B
- tun%(1) = -6560
- WHEN "ClavichdBb" : *CHANNELVOICE 1 ClavichdBb
- tun%(1) = -10315
- WHEN "ClavinetBb" : *CHANNELVOICE 1 ClavinetBb
- tun%(1) = -6219
- WHEN "CornetEb" : *CHANNELVOICE 1 CornetEb
- tun%(1) = -4000
- WHEN "EnsWodAb45" : *CHANNELVOICE 1 EnsWodAb45
- tun%(1) = -9632
- WHEN "EnsWodGb12" : *CHANNELVOICE 1 EnsWodGb12
- tun%(1) = -4853
- WHEN "Glock2Ab5" : *CHANNELVOICE 1 Glock2Ab5
- tun%(1) = -9632
- WHEN "GtMelobarC" : *CHANNELVOICE 1 GtMelobarC
- tun%(1) = -6901
- WHEN "GtWashbnBb" : *CHANNELVOICE 1 GtWashbnBb
- tun%(1) = -6219
- WHEN "HarmonicaE" : *CHANNELVOICE 1 HarmonicaE
- tun%(1) = -4171
- WHEN "Jew'sHarpA" : *CHANNELVOICE 1 Jew'sHarpA
- tun%(1) = -6219
- WHEN "MusetteB" : *CHANNELVOICE 1 MusetteB
- tun%(1) = -10656
- WHEN "OboeGb" : *CHANNELVOICE 1 OboeGb
- tun%(1) = -13131
- WHEN "OrchHit2B" : *CHANNELVOICE 1 OrchHit2B
- tun%(1) = -5451
- WHEN "OrcSusBb23" : *CHANNELVOICE 1 OrcSusBb23
- tun%(1) = -6304
- WHEN "PiccoloE" : *CHANNELVOICE 1 PiccoloE
- tun%(1) = -16544
- WHEN "SaxSoprnoE" : *CHANNELVOICE 1 SaxSoprnoE
- tun%(1) = -12448
- WHEN "StrngThkBb" : *CHANNELVOICE 1 StrngThkBb
- tun%(1) = -5792
- WHEN "TubaGb" : *CHANNELVOICE 1 TubaGb
- tun%(1) = -929
- WHEN "BassDrum" : *CHANNELVOICE 1 BassDrum
- tun%(1) = -4000
- WHEN "HiHat" : *CHANNELVOICE 1 HiHat
- tun%(1) = -4000
- WHEN "OrcHit" : *CHANNELVOICE 1 OrcHit
- tun%(1) = -4085
- WHEN "Piano" : *CHANNELVOICE 1 Piano
- tun%(1) = -4171
- WHEN "Sax" : *CHANNELVOICE 1 Sax
- tun%(1) = -4085
- WHEN "Snare" : *CHANNELVOICE 1 Snare
- tun%(1) = -8096
- WHEN "Choir1" : *CHANNELVOICE 1 Choir1
- tun%(1) = -6901
- WHEN "ChurOrgan" : *CHANNELVOICE 1 ChurOrgan
- tun%(1) = -6901
- WHEN "Opera" : *CHANNELVOICE 1 Opera
- tun%(1) = -13387
- WHEN "OrchChoir" : *CHANNELVOICE 1 OrchChoir
- tun%(1) = -6133
- WHEN "OrganHit" : *CHANNELVOICE 1 OrganHit
- tun%(1) = -5024
- WHEN "AgogoAfric" : *CHANNELVOICE 1 AgogoAfric
- tun%(1) = -6219
- WHEN "AgogoBrazi" : *CHANNELVOICE 1 AgogoBrazi
- tun%(1) = -10997
- WHEN "AgogoWood" : *CHANNELVOICE 1 AgogoWood
- tun%(1) = -13728
- WHEN "BDGatedRev" : *CHANNELVOICE 1 BDGatedRev
- tun%(1) = -5877
- WHEN "BDMarching" : *CHANNELVOICE 1 BDMarching
- tun%(1) = -8608
- WHEN "BDPiloMute" : *CHANNELVOICE 1 BDPiloMute
- tun%(1) = -7072
- WHEN "Cabasa" : *CHANNELVOICE 1 Cabasa
- tun%(1) = -7072
- WHEN "Cachichi1" : *CHANNELVOICE 1 Cachichi1
- tun%(1) = -4000
- WHEN "CachichiTr" : *CHANNELVOICE 1 CachichiTr
- tun%(1) = -8096
- WHEN "Castanets" : *CHANNELVOICE 1 Castanets
- tun%(1) = -4000
- WHEN "CongaMid" : *CHANNELVOICE 1 CongaMid
- tun%(1) = -4171
- WHEN "CongaSmCl" : *CHANNELVOICE 1 CongaSmCl
- tun%(1) = -4683
- WHEN "CymbalCrsh" : *CHANNELVOICE 1 CymbalCrsh
- tun%(1) = -4000
- WHEN "CymRideBel" : *CHANNELVOICE 1 CymRideBel
- tun%(1) = -16288
- WHEN "CymRStRoll" : *CHANNELVOICE 1 CymRStRoll
- tun%(1) = -6389
- WHEN "CymSplshCa" : *CHANNELVOICE 1 CymSplshCa
- tun%(1) = -9120
- WHEN "Flexitone" : *CHANNELVOICE 1 Flexitone
- tun%(1) = -8096
- WHEN "GongSoft" : *CHANNELVOICE 1 GongSoft
- tun%(1) = -5365
- WHEN "Gonza1" : *CHANNELVOICE 1 Gonza1
- tun%(1) = -12192
- WHEN "GuiroSlow" : *CHANNELVOICE 1 GuiroSlow
- tun%(1) = -6048
- WHEN "HandClaps" : *CHANNELVOICE 1 HandClaps
- tun%(1) = -4000
- WHEN "HiHatFoot" : *CHANNELVOICE 1 HiHatFoot
- tun%(1) = -6389
- WHEN "Maracas1" : *CHANNELVOICE 1 Maracas1
- tun%(1) = -8096
- WHEN "MarimbaSB3" : *CHANNELVOICE 1 MarimbaSB3
- tun%(1) = -4000
- WHEN "Ratchet" : *CHANNELVOICE 1 Ratchet
- tun%(1) = -6731
- WHEN "RotoTomRev" : *CHANNELVOICE 1 RotoTomRev
- tun%(1) = -6133
- WHEN "SimmonsBD1" : *CHANNELVOICE 1 SimmonsBD1
- tun%(1) = -8096
- WHEN "SimmonsSn1" : *CHANNELVOICE 1 SimmonsSn1
- tun%(1) = -5707
- WHEN "SleighBell" : *CHANNELVOICE 1 SleighBell
- tun%(1) = -4000
- WHEN "SuperGong" : *CHANNELVOICE 1 SuperGong
- tun%(1) = -4341
- WHEN "SynthSnare" : *CHANNELVOICE 1 SynthSnare
- tun%(1) = -4000
- WHEN "SynTom" : *CHANNELVOICE 1 SynTom
- tun%(1) = -9120
- WHEN "TimpCresBb" : *CHANNELVOICE 1 TimpCresBb
- tun%(1) = -5962
- WHEN "TimpLowBb" : *CHANNELVOICE 1 TimpLowBb
- tun%(1) = -5707
- WHEN "TimpRollEb" : *CHANNELVOICE 1 TimpRollEb
- tun%(1) = -4000
- WHEN "TomRoll" : *CHANNELVOICE 1 TomRoll
- tun%(1) = -4000
- WHEN "ToyHooter" : *CHANNELVOICE 1 ToyHooter
- tun%(1) = -9717
- WHEN "ToyWhistle" : *CHANNELVOICE 1 ToyWhistle
- tun%(1) = -4000
- ENDCASE
- :
- WHEN 2 :
- CASE waveforms$(vnumber%) OF
- WHEN "WaveSynth-Beep" : *CHANNELVOICE 2 WaveSynth-Beep
- WHEN "StringLib-Soft" : *CHANNELVOICE 2 StringLib-Soft
- WHEN "StringLib-Pluck" : *CHANNELVOICE 2 StringLib-Pluck
- WHEN "StringLib-Steel" : *CHANNELVOICE 2 StringLib-Steel
- WHEN "StringLib-Hard" : *CHANNELVOICE 2 StringLib-Hard
- WHEN "Percussion-Soft" : *CHANNELVOICE 2 Percussion-Soft
- WHEN "Percussion-Medium" : *CHANNELVOICE 2 Percussion-Medium
- WHEN "Percussion-Snare" : *CHANNELVOICE 2 Percussion-Snare
- WHEN "Percussion-Noise" : *CHANNELVOICE 2 Percussion-Noise
- WHEN "BassBowAb" : *CHANNELVOICE 2 BassBowAb
- tun%(2) = -1470
- WHEN "AcouBass" : *CHANNELVOICE 2 AcouBass
- tun%(2) = -2731
- WHEN "Vibe" : *CHANNELVOICE 2 Vibe
- tun%(2) = -6912
- WHEN "BugleC" : *CHANNELVOICE 2 BugleC
- tun%(2) = -11008
- WHEN "CornetEb" : *CHANNELVOICE 2 CornetEb
- tun%(2) = -12117
- WHEN "SaxEbBarC" : *CHANNELVOICE 2 SaxEbBarC
- tun%(2) = -2816
- WHEN "SaxBbTenrE" : *CHANNELVOICE 2 SaxBbTenrE
- tun%(2) = -4181
- WHEN "BassoonEb" : *CHANNELVOICE 2 BassoonEb
- tun%(2) = -4011
- WHEN "ClarinetBb" : *CHANNELVOICE 2 ClarinetBb
- tun%(2) = -10325
- WHEN "EngHornGb" : *CHANNELVOICE 2 EngHornGb
- tun%(2) = -8960
- WHEN "MandolinDb" : *CHANNELVOICE 2 MandolinDb
- tun%(2) = -11264
- WHEN "Piano2B" : *CHANNELVOICE 2 Piano2B
- tun%(2) = -2475
- WHEN "ClarVibEb" : *CHANNELVOICE 2 ClarVibEb
- tun%(2) = -7850
- WHEN "GtrDobroB" : *CHANNELVOICE 2 GtrDobroB
- tun%(2) = -6485
- WHEN "RecorderGb" : *CHANNELVOICE 2 RecorderGb
- tun%(2) = -13056
- WHEN "FlugelHnEb" : *CHANNELVOICE 2 FlugelHnEb
- tun%(2) = -12032
- WHEN "VceMmmGb23" : *CHANNELVOICE 2 VceMmmGb23
- tun%(2) = -853
- WHEN "VceMOooGb3" : *CHANNELVOICE 2 VceMOooGb3
- tun%(2) = -4843
- WHEN "VceFemAahC" : *CHANNELVOICE 2 VceFemAahC
- tun%(2) = -10948
- WHEN "VceFMmmGb4" : *CHANNELVOICE 2 VceFMmmGb4
- tun%(2) = -8918
- WHEN "Bass" : *CHANNELVOICE 2 Bass
- tun%(2) = 0
- WHEN "ChurchBell" : *CHANNELVOICE 2 ChurchBell
- tun%(2) = -2731
- WHEN "mysound" : *CHANNELVOICE 2 mysound
- tun%(2) = 0
- WHEN "GuiroFast" : *CHANNELVOICE 2 GuiroFast
- tun%(2) = -4000
- WHEN "Clave" : *CHANNELVOICE 2 Clave
- tun%(2) = -8096
- WHEN "CowBell" : *CHANNELVOICE 2 CowBell
- tun%(2) = -5707
- WHEN "CymbRideHd" : *CHANNELVOICE 2 CymbRideHd
- tun%(2) = -8096
- WHEN "AcGuitar1" : *CHANNELVOICE 2 AcGuitar1
- tun%(2) = -7072
- WHEN "CongaHi" : *CHANNELVOICE 2 CongaHi
- tun%(2) = -4000
- WHEN "DrumExplo" : *CHANNELVOICE 2 DrumExplo
- tun%(2) = -4000
- WHEN "ElecTom1" : *CHANNELVOICE 2 ElecTom1
- tun%(2) = -8096
- WHEN "Harp1" : *CHANNELVOICE 2 Harp1
- tun%(2) = -10997
- WHEN "Harpsi" : *CHANNELVOICE 2 Harpsi
- tun%(2) = -6901
- WHEN "HiString" : *CHANNELVOICE 2 HiString
- tun%(2) = -10997
- WHEN "HonkyPiano" : *CHANNELVOICE 2 HonkyPiano
- tun%(2) = -6901
- WHEN "JapFlute" : *CHANNELVOICE 2 JapFlute
- tun%(2) = -10997
- WHEN "JazzOrgan" : *CHANNELVOICE 2 JazzOrgan
- tun%(2) = -10997
- WHEN "MidStrings" : *CHANNELVOICE 2 MidStrings
- tun%(2) = -6901
- WHEN "NoteArp1" : *CHANNELVOICE 2 NoteArp1
- tun%(2) = -4000
- WHEN "SnareEcho" : *CHANNELVOICE 2 SnareEcho
- tun%(2) = -4341
- WHEN "TablaHi" : *CHANNELVOICE 2 TablaHi
- tun%(2) = -7669
- WHEN "Timpani" : *CHANNELVOICE 2 Timpani
- tun%(2) = -928
- WHEN "Tomtom1" : *CHANNELVOICE 2 Tomtom1
- tun%(2) = -5365
- WHEN "Trombone1" : *CHANNELVOICE 2 Trombone1
- tun%(2) = -6901
- WHEN "Trumpet" : *CHANNELVOICE 2 Trumpet
- tun%(2) = -10997
- WHEN "Xylophone" : *CHANNELVOICE 2 Xylophone
- tun%(2) = -6901
- WHEN "AcouGtr2B" : *CHANNELVOICE 2 AcouGtr2B
- tun%(2) = -6560
- WHEN "AcuBassAb1" : *CHANNELVOICE 2 AcuBassAb1
- tun%(2) = -1610
- WHEN "BagPipeG" : *CHANNELVOICE 2 BagPipeG
- tun%(2) = -9291
- WHEN "BanjoChdBb" : *CHANNELVOICE 2 BanjoChdBb
- tun%(2) = -4000
- WHEN "BazookiE" : *CHANNELVOICE 2 BazookiE
- tun%(2) = -8267
- WHEN "BellC" : *CHANNELVOICE 2 BellC
- tun%(2) = -10997
- WHEN "BrassEns1B" : *CHANNELVOICE 2 BrassEns1B
- tun%(2) = -6560
- WHEN "ClavichdBb" : *CHANNELVOICE 2 ClavichdBb
- tun%(2) = -10315
- WHEN "ClavinetBb" : *CHANNELVOICE 2 ClavinetBb
- tun%(2) = -6219
- WHEN "CornetEb" : *CHANNELVOICE 2 CornetEb
- tun%(2) = -4000
- WHEN "EnsWodAb45" : *CHANNELVOICE 2 EnsWodAb45
- tun%(2) = -9632
- WHEN "EnsWodGb12" : *CHANNELVOICE 2 EnsWodGb12
- tun%(2) = -4853
- WHEN "Glock2Ab5" : *CHANNELVOICE 2 Glock2Ab5
- tun%(2) = -9632
- WHEN "GtMelobarC" : *CHANNELVOICE 2 GtMelobarC
- tun%(2) = -6901
- WHEN "GtWashbnBb" : *CHANNELVOICE 2 GtWashbnBb
- tun%(2) = -6219
- WHEN "HarmonicaE" : *CHANNELVOICE 2 HarmonicaE
- tun%(2) = -4171
- WHEN "Jew'sHarpA" : *CHANNELVOICE 2 Jew'sHarpA
- tun%(2) = -6219
- WHEN "MusetteB" : *CHANNELVOICE 2 MusetteB
- tun%(2) = -10656
- WHEN "OboeGb" : *CHANNELVOICE 2 OboeGb
- tun%(2) = -13131
- WHEN "OrchHit2B" : *CHANNELVOICE 2 OrchHit2B
- tun%(2) = -5451
- WHEN "OrcSusBb23" : *CHANNELVOICE 2 OrcSusBb23
- tun%(2) = -6304
- WHEN "PiccoloE" : *CHANNELVOICE 2 PiccoloE
- tun%(2) = -16544
- WHEN "SaxSoprnoE" : *CHANNELVOICE 2 SaxSoprnoE
- tun%(2) = -12448
- WHEN "StrngThkBb" : *CHANNELVOICE 2 StrngThkBb
- tun%(2) = -5792
- WHEN "TubaGb" : *CHANNELVOICE 2 TubaGb
- tun%(2) = -929
- WHEN "BassDrum" : *CHANNELVOICE 2 BassDrum
- tun%(2) = -4000
- WHEN "HiHat" : *CHANNELVOICE 2 HiHat
- tun%(2) = -4000
- WHEN "OrcHit" : *CHANNELVOICE 2 OrcHit
- tun%(2) = -4085
- WHEN "Piano" : *CHANNELVOICE 2 Piano
- tun%(2) = -4171
- WHEN "Sax" : *CHANNELVOICE 2 Sax
- tun%(2) = -4085
- WHEN "Snare" : *CHANNELVOICE 2 Snare
- tun%(2) = -8096
- WHEN "Choir1" : *CHANNELVOICE 2 Choir1
- tun%(2) = -6901
- WHEN "ChurOrgan" : *CHANNELVOICE 2 ChurOrgan
- tun%(2) = -6901
- WHEN "Opera" : *CHANNELVOICE 2 Opera
- tun%(2) = -13387
- WHEN "OrchChoir" : *CHANNELVOICE 2 OrchChoir
- tun%(2) = -6133
- WHEN "OrganHit" : *CHANNELVOICE 2 OrganHit
- tun%(2) = -5024
- WHEN "AgogoAfric" : *CHANNELVOICE 2 AgogoAfric
- tun%(2) = -6219
- WHEN "AgogoBrazi" : *CHANNELVOICE 2 AgogoBrazi
- tun%(2) = -10997
- WHEN "AgogoWood" : *CHANNELVOICE 2 AgogoWood
- tun%(2) = -13728
- WHEN "BDGatedRev" : *CHANNELVOICE 2 BDGatedRev
- tun%(2) = -5877
- WHEN "BDMarching" : *CHANNELVOICE 2 BDMarching
- tun%(2) = -8608
- WHEN "BDPiloMute" : *CHANNELVOICE 2 BDPiloMute
- tun%(2) = -7072
- WHEN "Cabasa" : *CHANNELVOICE 2 Cabasa
- tun%(2) = -7072
- WHEN "Cachichi1" : *CHANNELVOICE 2 Cachichi1
- tun%(2) = -4000
- WHEN "CachichiTr" : *CHANNELVOICE 2 CachichiTr
- tun%(2) = -8096
- WHEN "Castanets" : *CHANNELVOICE 2 Castanets
- tun%(2) = -4000
- WHEN "CongaMid" : *CHANNELVOICE 2 CongaMid
- tun%(2) = -4171
- WHEN "CongaSmCl" : *CHANNELVOICE 2 CongaSmCl
- tun%(2) = -4683
- WHEN "CymbalCrsh" : *CHANNELVOICE 2 CymbalCrsh
- tun%(2) = -4000
- WHEN "CymRideBel" : *CHANNELVOICE 2 CymRideBel
- tun%(2) = -16288
- WHEN "CymRStRoll" : *CHANNELVOICE 2 CymRStRoll
- tun%(2) = -6389
- WHEN "CymSplshCa" : *CHANNELVOICE 2 CymSplshCa
- tun%(2) = -9120
- WHEN "Flexitone" : *CHANNELVOICE 2 Flexitone
- tun%(2) = -8096
- WHEN "GongSoft" : *CHANNELVOICE 2 GongSoft
- tun%(2) = -5365
- WHEN "Gonza1" : *CHANNELVOICE 2 Gonza1
- tun%(2) = -12192
- WHEN "GuiroSlow" : *CHANNELVOICE 2 GuiroSlow
- tun%(2) = -6048
- WHEN "HandClaps" : *CHANNELVOICE 2 HandClaps
- tun%(2) = -4000
- WHEN "HiHatFoot" : *CHANNELVOICE 2 HiHatFoot
- tun%(2) = -6389
- WHEN "Maracas1" : *CHANNELVOICE 2 Maracas1
- tun%(2) = -8096
- WHEN "MarimbaSB3" : *CHANNELVOICE 2 MarimbaSB3
- tun%(2) = -4000
- WHEN "Ratchet" : *CHANNELVOICE 2 Ratchet
- tun%(2) = -6731
- WHEN "RotoTomRev" : *CHANNELVOICE 2 RotoTomRev
- tun%(2) = -6133
- WHEN "SimmonsBD1" : *CHANNELVOICE 2 SimmonsBD1
- tun%(2) = -8096
- WHEN "SimmonsSn1" : *CHANNELVOICE 2 SimmonsSn1
- tun%(2) = -5707
- WHEN "SleighBell" : *CHANNELVOICE 2 SleighBell
- tun%(2) = -4000
- WHEN "SuperGong" : *CHANNELVOICE 2 SuperGong
- tun%(2) = -4341
- WHEN "SynthSnare" : *CHANNELVOICE 2 SynthSnare
- tun%(2) = -4000
- WHEN "SynTom" : *CHANNELVOICE 2 SynTom
- tun%(2) = -9120
- WHEN "TimpCresBb" : *CHANNELVOICE 2 TimpCresBb
- tun%(2) = -5962
- WHEN "TimpLowBb" : *CHANNELVOICE 2 TimpLowBb
- tun%(2) = -5707
- WHEN "TimpRollEb" : *CHANNELVOICE 2 TimpRollEb
- tun%(2) = -4000
- WHEN "TomRoll" : *CHANNELVOICE 2 TomRoll
- tun%(2) = -4000
- WHEN "ToyHooter" : *CHANNELVOICE 2 ToyHooter
- tun%(2) = -9717
- WHEN "ToyWhistle" : *CHANNELVOICE 2 ToyWhistle
- tun%(2) = -4000
- ENDCASE
- WHEN 3 :
- CASE waveforms$(vnumber%) OF
- WHEN "WaveSynth-Beep" : *CHANNELVOICE 3 WaveSynth-Beep
- WHEN "StringLib-Soft" : *CHANNELVOICE 3 StringLib-Soft
- WHEN "StringLib-Pluck" : *CHANNELVOICE 3 StringLib-Pluck
- WHEN "StringLib-Steel" : *CHANNELVOICE 3 StringLib-Steel
- WHEN "StringLib-Hard" : *CHANNELVOICE 3 StringLib-Hard
- WHEN "Percussion-Soft" : *CHANNELVOICE 3 Percussion-Soft
- WHEN "Percussion-Medium" : *CHANNELVOICE 3 Percussion-Medium
- WHEN "Percussion-Snare" : *CHANNELVOICE 3 Percussion-Snare
- WHEN "Percussion-Noise" : *CHANNELVOICE 3 Percussion-Noise
- WHEN "BassBowAb" : *CHANNELVOICE 3 BassBowAb
- tun%(3) = -1470
- WHEN "AcouBass" : *CHANNELVOICE 3 AcouBass
- tun%(3) = -2731
- WHEN "Vibe" : *CHANNELVOICE 3 Vibe
- tun%(3) = -6912
- WHEN "BugleC" : *CHANNELVOICE 3 BugleC
- tun%(3) = -11008
- WHEN "CornetEb" : *CHANNELVOICE 3 CornetEb
- tun%(3) = -12117
- WHEN "SaxEbBarC" : *CHANNELVOICE 3 SaxEbBarC
- tun%(3) = -2816
- WHEN "SaxBbTenrE" : *CHANNELVOICE 3 SaxBbTenrE
- tun%(3) = -4181
- WHEN "BassoonEb" : *CHANNELVOICE 3 BassoonEb
- tun%(3) = -4011
- WHEN "ClarinetBb" : *CHANNELVOICE 3 ClarinetBb
- tun%(3) = -10325
- WHEN "EngHornGb" : *CHANNELVOICE 3 EngHornGb
- tun%(3) = -8960
- WHEN "MandolinDb" : *CHANNELVOICE 3 MandolinDb
- tun%(3) = -11264
- WHEN "Piano2B" : *CHANNELVOICE 3 Piano2B
- tun%(3) = -2475
- WHEN "ClarVibEb" : *CHANNELVOICE 3 ClarVibEb
- tun%(3) = -7850
- WHEN "GtrDobroB" : *CHANNELVOICE 3 GtrDobroB
- tun%(3) = -6485
- WHEN "RecorderGb" : *CHANNELVOICE 3 RecorderGb
- tun%(3) = -13056
- WHEN "FlugelHnEb" : *CHANNELVOICE 3 FlugelHnEb
- tun%(3) = -12032
- WHEN "VceMmmGb23" : *CHANNELVOICE 3 VceMmmGb23
- tun%(3) = -853
- WHEN "VceMOooGb3" : *CHANNELVOICE 3 VceMOooGb3
- tun%(3) = -4843
- WHEN "VceFemAahC" : *CHANNELVOICE 3 VceFemAahC
- tun%(3) = -10948
- WHEN "VceFMmmGb4" : *CHANNELVOICE 3 VceFMmmGb4
- tun%(3) = -8918
- WHEN "Bass" : *CHANNELVOICE 3 Bass
- tun%(3) = 0
- WHEN "ChurchBell" : *CHANNELVOICE 3 ChurchBell
- tun%(3) = -2731
- WHEN "mysound" : *CHANNELVOICE 3 mysound
- tun%(3) = 0
- WHEN "GuiroFast" : *CHANNELVOICE 3 GuiroFast
- tun%(3) = -4000
- WHEN "Clave" : *CHANNELVOICE 3 Clave
- tun%(3) = -8096
- WHEN "CowBell" : *CHANNELVOICE 3 CowBell
- tun%(3) = -5707
- WHEN "CymbRideHd" : *CHANNELVOICE 3 CymbRideHd
- tun%(3) = -8096
- WHEN "AcGuitar1" : *CHANNELVOICE 3 AcGuitar1
- tun%(3) = -7072
- WHEN "CongaHi" : *CHANNELVOICE 3 CongaHi
- tun%(3) = -4000
- WHEN "DrumExplo" : *CHANNELVOICE 3 DrumExplo
- tun%(3) = -4000
- WHEN "ElecTom1" : *CHANNELVOICE 3 ElecTom1
- tun%(3) = -8096
- WHEN "Harp1" : *CHANNELVOICE 3 Harp1
- tun%(3) = -10997
- WHEN "Harpsi" : *CHANNELVOICE 3 Harpsi
- tun%(3) = -6901
- WHEN "HiString" : *CHANNELVOICE 3 HiString
- tun%(3) = -10997
- WHEN "HonkyPiano" : *CHANNELVOICE 3 HonkyPiano
- tun%(3) = -6901
- WHEN "JapFlute" : *CHANNELVOICE 3 JapFlute
- tun%(3) = -10997
- WHEN "JazzOrgan" : *CHANNELVOICE 3 JazzOrgan
- tun%(3) = -10997
- WHEN "MidStrings" : *CHANNELVOICE 3 MidStrings
- tun%(3) = -6901
- WHEN "NoteArp1" : *CHANNELVOICE 3 NoteArp1
- tun%(3) = -4000
- WHEN "SnareEcho" : *CHANNELVOICE 3 SnareEcho
- tun%(3) = -4341
- WHEN "TablaHi" : *CHANNELVOICE 3 TablaHi
- tun%(3) = -7669
- WHEN "Timpani" : *CHANNELVOICE 3 Timpani
- tun%(3) = -928
- WHEN "Tomtom1" : *CHANNELVOICE 3 Tomtom1
- tun%(3) = -5365
- WHEN "Trombone1" : *CHANNELVOICE 3 Trombone1
- tun%(3) = -6901
- WHEN "Trumpet" : *CHANNELVOICE 3 Trumpet
- tun%(3) = -10997
- WHEN "Xylophone" : *CHANNELVOICE 3 Xylophone
- tun%(3) = -6901
- WHEN "AcouGtr2B" : *CHANNELVOICE 3 AcouGtr2B
- tun%(3) = -6560
- WHEN "AcuBassAb1" : *CHANNELVOICE 3 AcuBassAb1
- tun%(3) = -1610
- WHEN "BagPipeG" : *CHANNELVOICE 3 BagPipeG
- tun%(3) = -9291
- WHEN "BanjoChdBb" : *CHANNELVOICE 3 BanjoChdBb
- tun%(3) = -4000
- WHEN "BazookiE" : *CHANNELVOICE 3 BazookiE
- tun%(3) = -8267
- WHEN "BellC" : *CHANNELVOICE 3 BellC
- tun%(3) = -10997
- WHEN "BrassEns1B" : *CHANNELVOICE 3 BrassEns1B
- tun%(3) = -6560
- WHEN "ClavichdBb" : *CHANNELVOICE 3 ClavichdBb
- tun%(3) = -10315
- WHEN "ClavinetBb" : *CHANNELVOICE 3 ClavinetBb
- tun%(3) = -6219
- WHEN "CornetEb" : *CHANNELVOICE 3 CornetEb
- tun%(3) = -4000
- WHEN "EnsWodAb45" : *CHANNELVOICE 3 EnsWodAb45
- tun%(3) = -9632
- WHEN "EnsWodGb12" : *CHANNELVOICE 3 EnsWodGb12
- tun%(3) = -4853
- WHEN "Glock2Ab5" : *CHANNELVOICE 3 Glock2Ab5
- tun%(3) = -9632
- WHEN "GtMelobarC" : *CHANNELVOICE 3 GtMelobarC
- tun%(3) = -6901
- WHEN "GtWashbnBb" : *CHANNELVOICE 3 GtWashbnBb
- tun%(3) = -6219
- WHEN "HarmonicaE" : *CHANNELVOICE 3 HarmonicaE
- tun%(3) = -4171
- WHEN "Jew'sHarpA" : *CHANNELVOICE 3 Jew'sHarpA
- tun%(3) = -6219
- WHEN "MusetteB" : *CHANNELVOICE 3 MusetteB
- tun%(3) = -10656
- WHEN "OboeGb" : *CHANNELVOICE 3 OboeGb
- tun%(3) = -13131
- WHEN "OrchHit2B" : *CHANNELVOICE 3 OrchHit2B
- tun%(3) = -5451
- WHEN "OrcSusBb23" : *CHANNELVOICE 3 OrcSusBb23
- tun%(3) = -6304
- WHEN "PiccoloE" : *CHANNELVOICE 3 PiccoloE
- tun%(3) = -16544
- WHEN "SaxSoprnoE" : *CHANNELVOICE 3 SaxSoprnoE
- tun%(3) = -12448
- WHEN "StrngThkBb" : *CHANNELVOICE 3 StrngThkBb
- tun%(3) = -5792
- WHEN "TubaGb" : *CHANNELVOICE 3 TubaGb
- tun%(3) = -929
- WHEN "BassDrum" : *CHANNELVOICE 3 BassDrum
- tun%(3) = -4000
- WHEN "HiHat" : *CHANNELVOICE 3 HiHat
- tun%(3) = -4000
- WHEN "OrcHit" : *CHANNELVOICE 3 OrcHit
- tun%(3) = -4085
- WHEN "Piano" : *CHANNELVOICE 3 Piano
- tun%(3) = -4171
- WHEN "Sax" : *CHANNELVOICE 3 Sax
- tun%(3) = -4085
- WHEN "Snare" : *CHANNELVOICE 3 Snare
- tun%(3) = -8096
- WHEN "Choir1" : *CHANNELVOICE 3 Choir1
- tun%(3) = -6901
- WHEN "ChurOrgan" : *CHANNELVOICE 3 ChurOrgan
- tun%(3) = -6901
- WHEN "Opera" : *CHANNELVOICE 3 Opera
- tun%(3) = -13387
- WHEN "OrchChoir" : *CHANNELVOICE 3 OrchChoir
- tun%(3) = -6133
- WHEN "OrganHit" : *CHANNELVOICE 3 OrganHit
- tun%(3) = -5024
- WHEN "AgogoAfric" : *CHANNELVOICE 3 AgogoAfric
- tun%(3) = -6219
- WHEN "AgogoBrazi" : *CHANNELVOICE 3 AgogoBrazi
- tun%(3) = -10997
- WHEN "AgogoWood" : *CHANNELVOICE 3 AgogoWood
- tun%(3) = -13728
- WHEN "BDGatedRev" : *CHANNELVOICE 3 BDGatedRev
- tun%(3) = -5877
- WHEN "BDMarching" : *CHANNELVOICE 3 BDMarching
- tun%(3) = -8608
- WHEN "BDPiloMute" : *CHANNELVOICE 3 BDPiloMute
- tun%(3) = -7072
- WHEN "Cabasa" : *CHANNELVOICE 3 Cabasa
- tun%(3) = -7072
- WHEN "Cachichi1" : *CHANNELVOICE 3 Cachichi1
- tun%(3) = -4000
- WHEN "CachichiTr" : *CHANNELVOICE 3 CachichiTr
- tun%(3) = -8096
- WHEN "Castanets" : *CHANNELVOICE 3 Castanets
- tun%(3) = -4000
- WHEN "CongaMid" : *CHANNELVOICE 3 CongaMid
- tun%(3) = -4171
- WHEN "CongaSmCl" : *CHANNELVOICE 3 CongaSmCl
- tun%(3) = -4683
- WHEN "CymbalCrsh" : *CHANNELVOICE 3 CymbalCrsh
- tun%(3) = -4000
- WHEN "CymRideBel" : *CHANNELVOICE 3 CymRideBel
- tun%(3) = -16288
- WHEN "CymRStRoll" : *CHANNELVOICE 3 CymRStRoll
- tun%(3) = -6389
- WHEN "CymSplshCa" : *CHANNELVOICE 3 CymSplshCa
- tun%(3) = -9120
- WHEN "Flexitone" : *CHANNELVOICE 3 Flexitone
- tun%(3) = -8096
- WHEN "GongSoft" : *CHANNELVOICE 3 GongSoft
- tun%(3) = -5365
- WHEN "Gonza1" : *CHANNELVOICE 3 Gonza1
- tun%(3) = -12192
- WHEN "GuiroSlow" : *CHANNELVOICE 3 GuiroSlow
- tun%(3) = -6048
- WHEN "HandClaps" : *CHANNELVOICE 3 HandClaps
- tun%(3) = -4000
- WHEN "HiHatFoot" : *CHANNELVOICE 3 HiHatFoot
- tun%(3) = -6389
- WHEN "Maracas1" : *CHANNELVOICE 3 Maracas1
- tun%(3) = -8096
- WHEN "MarimbaSB3" : *CHANNELVOICE 3 MarimbaSB3
- tun%(3) = -4000
- WHEN "Ratchet" : *CHANNELVOICE 3 Ratchet
- tun%(3) = -6731
- WHEN "RotoTomRev" : *CHANNELVOICE 3 RotoTomRev
- tun%(3) = -6133
- WHEN "SimmonsBD1" : *CHANNELVOICE 3 SimmonsBD1
- tun%(3) = -8096
- WHEN "SimmonsSn1" : *CHANNELVOICE 3 SimmonsSn1
- tun%(3) = -5707
- WHEN "SleighBell" : *CHANNELVOICE 3 SleighBell
- tun%(3) = -4000
- WHEN "SuperGong" : *CHANNELVOICE 3 SuperGong
- tun%(3) = -4341
- WHEN "SynthSnare" : *CHANNELVOICE 3 SynthSnare
- tun%(3) = -4000
- WHEN "SynTom" : *CHANNELVOICE 3 SynTom
- tun%(3) = -9120
- WHEN "TimpCresBb" : *CHANNELVOICE 3 TimpCresBb
- tun%(3) = -5962
- WHEN "TimpLowBb" : *CHANNELVOICE 3 TimpLowBb
- tun%(3) = -5707
- WHEN "TimpRollEb" : *CHANNELVOICE 3 TimpRollEb
- tun%(3) = -4000
- WHEN "TomRoll" : *CHANNELVOICE 3 TomRoll
- tun%(3) = -4000
- WHEN "ToyHooter" : *CHANNELVOICE 3 ToyHooter
- tun%(3) = -9717
- WHEN "ToyWhistle" : *CHANNELVOICE 3 ToyWhistle
- tun%(3) = -4000
- ENDCASE
- WHEN 4 :
- CASE waveforms$(vnumber%) OF
- WHEN "WaveSynth-Beep" : *CHANNELVOICE 4 WaveSynth-Beep
- WHEN "StringLib-Soft" : *CHANNELVOICE 4 StringLib-Soft
- WHEN "StringLib-Pluck" : *CHANNELVOICE 4 StringLib-Pluck
- WHEN "StringLib-Steel" : *CHANNELVOICE 4 StringLib-Steel
- WHEN "StringLib-Hard" : *CHANNELVOICE 4 StringLib-Hard
- WHEN "Percussion-Soft" : *CHANNELVOICE 4 Percussion-Soft
- WHEN "Percussion-Medium" : *CHANNELVOICE 4 Percussion-Medium
- WHEN "Percussion-Snare" : *CHANNELVOICE 4 Percussion-Snare
- WHEN "Percussion-Noise" : *CHANNELVOICE 4 Percussion-Noise
- WHEN "BassBowAb" : *CHANNELVOICE 4 BassBowAb
- tun%(4) = -1470
- WHEN "AcouBass" : *CHANNELVOICE 4 AcouBass
- tun%(4) = -2731
- WHEN "Vibe" : *CHANNELVOICE 4 Vibe
- tun%(4) = -6912
- WHEN "BugleC" : *CHANNELVOICE 4 BugleC
- tun%(4) = -11008
- WHEN "CornetEb" : *CHANNELVOICE 4 CornetEb
- tun%(4) = -12117
- WHEN "SaxEbBarC" : *CHANNELVOICE 4 SaxEbBarC
- tun%(4) = -2816
- WHEN "SaxBbTenrE" : *CHANNELVOICE 4 SaxBbTenrE
- tun%(4) = -4181
- WHEN "BassoonEb" : *CHANNELVOICE 4 BassoonEb
- tun%(4) = -4011
- WHEN "ClarinetBb" : *CHANNELVOICE 4 ClarinetBb
- tun%(4) = -10325
- WHEN "EngHornGb" : *CHANNELVOICE 4 EngHornGb
- tun%(4) = -8960
- WHEN "MandolinDb" : *CHANNELVOICE 4 MandolinDb
- tun%(4) = -11264
- WHEN "Piano2B" : *CHANNELVOICE 4 Piano2B
- tun%(4) = -2475
- WHEN "ClarVibEb" : *CHANNELVOICE 4 ClarVibEb
- tun%(4) = -7850
- WHEN "GtrDobroB" : *CHANNELVOICE 4 GtrDobroB
- tun%(4) = -6485
- WHEN "RecorderGb" : *CHANNELVOICE 4 RecorderGb
- tun%(4) = -13056
- WHEN "FlugelHnEb" : *CHANNELVOICE 4 FlugelHnEb
- tun%(4) = -12032
- WHEN "VceMmmGb23" : *CHANNELVOICE 4 VceMmmGb23
- tun%(4) = -853
- WHEN "VceMOooGb3" : *CHANNELVOICE 4 VceMOooGb3
- tun%(4) = -4843
- WHEN "VceFemAahC" : *CHANNELVOICE 4 VceFemAahC
- tun%(4) = -10948
- WHEN "VceFMmmGb4" : *CHANNELVOICE 4 VceFMmmGb4
- tun%(4) = -8918
- WHEN "Bass" : *CHANNELVOICE 4 Bass
- tun%(4) = 0
- WHEN "ChurchBell" : *CHANNELVOICE 4 ChurchBell
- tun%(4) = -2731
- WHEN "mysound" : *CHANNELVOICE 4 mysound
- tun%(4) = 0
- WHEN "GuiroFast" : *CHANNELVOICE 4 GuiroFast
- tun%(4) = -4000
- WHEN "Clave" : *CHANNELVOICE 4 Clave
- tun%(4) = -8096
- WHEN "CowBell" : *CHANNELVOICE 4 CowBell
- tun%(4) = -5707
- WHEN "CymbRideHd" : *CHANNELVOICE 4 CymbRideHd
- tun%(4) = -8096
- WHEN "AcGuitar1" : *CHANNELVOICE 4 AcGuitar1
- tun%(4) = -7072
- WHEN "CongaHi" : *CHANNELVOICE 4 CongaHi
- tun%(4) = -4000
- WHEN "DrumExplo" : *CHANNELVOICE 4 DrumExplo
- tun%(4) = -4000
- WHEN "ElecTom1" : *CHANNELVOICE 4 ElecTom1
- tun%(4) = -8096
- WHEN "Harp1" : *CHANNELVOICE 4 Harp1
- tun%(4) = -10997
- WHEN "Harpsi" : *CHANNELVOICE 4 Harpsi
- tun%(4) = -6901
- WHEN "HiString" : *CHANNELVOICE 4 HiString
- tun%(4) = -10997
- WHEN "HonkyPiano" : *CHANNELVOICE 4 HonkyPiano
- tun%(4) = -6901
- WHEN "JapFlute" : *CHANNELVOICE 4 JapFlute
- tun%(4) = -10997
- WHEN "JazzOrgan" : *CHANNELVOICE 4 JazzOrgan
- tun%(4) = -10997
- WHEN "MidStrings" : *CHANNELVOICE 4 MidStrings
- tun%(4) = -6901
- WHEN "NoteArp1" : *CHANNELVOICE 4 NoteArp1
- tun%(4) = -4000
- WHEN "SnareEcho" : *CHANNELVOICE 4 SnareEcho
- tun%(4) = -4341
- WHEN "TablaHi" : *CHANNELVOICE 4 TablaHi
- tun%(4) = -7669
- WHEN "Timpani" : *CHANNELVOICE 4 Timpani
- tun%(4) = -928
- WHEN "Tomtom1" : *CHANNELVOICE 4 Tomtom1
- tun%(4) = -5365
- WHEN "Trombone1" : *CHANNELVOICE 4 Trombone1
- tun%(4) = -6901
- WHEN "Trumpet" : *CHANNELVOICE 4 Trumpet
- tun%(4) = -10997
- WHEN "Xylophone" : *CHANNELVOICE 4 Xylophone
- tun%(4) = -6901
- WHEN "AcouGtr2B" : *CHANNELVOICE 4 AcouGtr2B
- tun%(4) = -6560
- WHEN "AcuBassAb1" : *CHANNELVOICE 4 AcuBassAb1
- tun%(4) = -1610
- WHEN "BagPipeG" : *CHANNELVOICE 4 BagPipeG
- tun%(4) = -9291
- WHEN "BanjoChdBb" : *CHANNELVOICE 4 BanjoChdBb
- tun%(4) = -4000
- WHEN "BazookiE" : *CHANNELVOICE 4 BazookiE
- tun%(4) = -8267
- WHEN "BellC" : *CHANNELVOICE 4 BellC
- tun%(4) = -10997
- WHEN "BrassEns1B" : *CHANNELVOICE 4 BrassEns1B
- tun%(4) = -6560
- WHEN "ClavichdBb" : *CHANNELVOICE 4 ClavichdBb
- tun%(4) = -10315
- WHEN "ClavinetBb" : *CHANNELVOICE 4 ClavinetBb
- tun%(4) = -6219
- WHEN "CornetEb" : *CHANNELVOICE 4 CornetEb
- tun%(4) = -4000
- WHEN "EnsWodAb45" : *CHANNELVOICE 4 EnsWodAb45
- tun%(4) = -9632
- WHEN "EnsWodGb12" : *CHANNELVOICE 4 EnsWodGb12
- tun%(4) = -4853
- WHEN "Glock2Ab5" : *CHANNELVOICE 4 Glock2Ab5
- tun%(4) = -9632
- WHEN "GtMelobarC" : *CHANNELVOICE 4 GtMelobarC
- tun%(4) = -6901
- WHEN "GtWashbnBb" : *CHANNELVOICE 4 GtWashbnBb
- tun%(4) = -6219
- WHEN "HarmonicaE" : *CHANNELVOICE 4 HarmonicaE
- tun%(4) = -4171
- WHEN "Jew'sHarpA" : *CHANNELVOICE 4 Jew'sHarpA
- tun%(4) = -6219
- WHEN "MusetteB" : *CHANNELVOICE 4 MusetteB
- tun%(4) = -10656
- WHEN "OboeGb" : *CHANNELVOICE 4 OboeGb
- tun%(4) = -13131
- WHEN "OrchHit2B" : *CHANNELVOICE 4 OrchHit2B
- tun%(4) = -5451
- WHEN "OrcSusBb23" : *CHANNELVOICE 4 OrcSusBb23
- tun%(4) = -6304
- WHEN "PiccoloE" : *CHANNELVOICE 4 PiccoloE
- tun%(4) = -16544
- WHEN "SaxSoprnoE" : *CHANNELVOICE 4 SaxSoprnoE
- tun%(4) = -12448
- WHEN "StrngThkBb" : *CHANNELVOICE 4 StrngThkBb
- tun%(4) = -5792
- WHEN "TubaGb" : *CHANNELVOICE 4 TubaGb
- tun%(4) = -929
- WHEN "BassDrum" : *CHANNELVOICE 4 BassDrum
- tun%(4) = -4000
- WHEN "HiHat" : *CHANNELVOICE 4 HiHat
- tun%(4) = -4000
- WHEN "OrcHit" : *CHANNELVOICE 4 OrcHit
- tun%(4) = -4085
- WHEN "Piano" : *CHANNELVOICE 4 Piano
- tun%(4) = -4171
- WHEN "Sax" : *CHANNELVOICE 4 Sax
- tun%(4) = -4085
- WHEN "Snare" : *CHANNELVOICE 4 Snare
- tun%(4) = -8096
- WHEN "Choir1" : *CHANNELVOICE 4 Choir1
- tun%(4) = -6901
- WHEN "ChurOrgan" : *CHANNELVOICE 4 ChurOrgan
- tun%(4) = -6901
- WHEN "Opera" : *CHANNELVOICE 4 Opera
- tun%(4) = -13387
- WHEN "OrchChoir" : *CHANNELVOICE 4 OrchChoir
- tun%(4) = -6133
- WHEN "OrganHit" : *CHANNELVOICE 4 OrganHit
- tun%(4) = -5024
- WHEN "AgogoAfric" : *CHANNELVOICE 4 AgogoAfric
- tun%(4) = -6219
- WHEN "AgogoBrazi" : *CHANNELVOICE 4 AgogoBrazi
- tun%(4) = -10997
- WHEN "AgogoWood" : *CHANNELVOICE 4 AgogoWood
- tun%(4) = -13728
- WHEN "BDGatedRev" : *CHANNELVOICE 4 BDGatedRev
- tun%(4) = -5877
- WHEN "BDMarching" : *CHANNELVOICE 4 BDMarching
- tun%(4) = -8608
- WHEN "BDPiloMute" : *CHANNELVOICE 4 BDPiloMute
- tun%(4) = -7072
- WHEN "Cabasa" : *CHANNELVOICE 4 Cabasa
- tun%(4) = -7072
- WHEN "Cachichi1" : *CHANNELVOICE 4 Cachichi1
- tun%(4) = -4000
- WHEN "CachichiTr" : *CHANNELVOICE 4 CachichiTr
- tun%(4) = -8096
- WHEN "Castanets" : *CHANNELVOICE 4 Castanets
- tun%(4) = -4000
- WHEN "CongaMid" : *CHANNELVOICE 4 CongaMid
- tun%(4) = -4171
- WHEN "CongaSmCl" : *CHANNELVOICE 4 CongaSmCl
- tun%(4) = -4683
- WHEN "CymbalCrsh" : *CHANNELVOICE 4 CymbalCrsh
- tun%(4) = -4000
- WHEN "CymRideBel" : *CHANNELVOICE 4 CymRideBel
- tun%(4) = -16288
- WHEN "CymRStRoll" : *CHANNELVOICE 4 CymRStRoll
- tun%(4) = -6389
- WHEN "CymSplshCa" : *CHANNELVOICE 4 CymSplshCa
- tun%(4) = -9120
- WHEN "Flexitone" : *CHANNELVOICE 4 Flexitone
- tun%(4) = -8096
- WHEN "GongSoft" : *CHANNELVOICE 4 GongSoft
- tun%(4) = -5365
- WHEN "Gonza1" : *CHANNELVOICE 4 Gonza1
- tun%(4) = -12192
- WHEN "GuiroSlow" : *CHANNELVOICE 4 GuiroSlow
- tun%(4) = -6048
- WHEN "HandClaps" : *CHANNELVOICE 4 HandClaps
- tun%(4) = -4000
- WHEN "HiHatFoot" : *CHANNELVOICE 4 HiHatFoot
- tun%(4) = -6389
- WHEN "Maracas1" : *CHANNELVOICE 4 Maracas1
- tun%(4) = -8096
- WHEN "MarimbaSB3" : *CHANNELVOICE 4 MarimbaSB3
- tun%(4) = -4000
- WHEN "Ratchet" : *CHANNELVOICE 4 Ratchet
- tun%(4) = -6731
- WHEN "RotoTomRev" : *CHANNELVOICE 4 RotoTomRev
- tun%(4) = -6133
- WHEN "SimmonsBD1" : *CHANNELVOICE 4 SimmonsBD1
- tun%(4) = -8096
- WHEN "SimmonsSn1" : *CHANNELVOICE 4 SimmonsSn1
- tun%(4) = -5707
- WHEN "SleighBell" : *CHANNELVOICE 4 SleighBell
- tun%(4) = -4000
- WHEN "SuperGong" : *CHANNELVOICE 4 SuperGong
- tun%(4) = -4341
- WHEN "SynthSnare" : *CHANNELVOICE 4 SynthSnare
- tun%(4) = -4000
- WHEN "SynTom" : *CHANNELVOICE 4 SynTom
- tun%(4) = -9120
- WHEN "TimpCresBb" : *CHANNELVOICE 4 TimpCresBb
- tun%(4) = -5962
- WHEN "TimpLowBb" : *CHANNELVOICE 4 TimpLowBb
- tun%(4) = -5707
- WHEN "TimpRollEb" : *CHANNELVOICE 4 TimpRollEb
- tun%(4) = -4000
- WHEN "TomRoll" : *CHANNELVOICE 4 TomRoll
- tun%(4) = -4000
- WHEN "ToyHooter" : *CHANNELVOICE 4 ToyHooter
- tun%(4) = -9717
- WHEN "ToyWhistle" : *CHANNELVOICE 4 ToyWhistle
- tun%(4) = -4000
- ENDCASE
- WHEN 5 :
- CASE waveforms$(vnumber%) OF
- WHEN "WaveSynth-Beep" : *CHANNELVOICE 5 WaveSynth-Beep
- WHEN "StringLib-Soft" : *CHANNELVOICE 5 StringLib-Soft
- WHEN "StringLib-Pluck" : *CHANNELVOICE 5 StringLib-Pluck
- WHEN "StringLib-Steel" : *CHANNELVOICE 5 StringLib-Steel
- WHEN "StringLib-Hard" : *CHANNELVOICE 5 StringLib-Hard
- WHEN "Percussion-Soft" : *CHANNELVOICE 5 Percussion-Soft
- WHEN "Percussion-Medium" : *CHANNELVOICE 5 Percussion-Medium
- WHEN "Percussion-Snare" : *CHANNELVOICE 5 Percussion-Snare
- WHEN "Percussion-Noise" : *CHANNELVOICE 5 Percussion-Noise
- WHEN "BassBowAb" : *CHANNELVOICE 5 BassBowAb
- tun%(5) = -1470
- WHEN "AcouBass" : *CHANNELVOICE 5 AcouBass
- tun%(5) = -2731
- WHEN "Vibe" : *CHANNELVOICE 5 Vibe
- tun%(5) = -6912
- WHEN "BugleC" : *CHANNELVOICE 5 BugleC
- tun%(5) = -11008
- WHEN "CornetEb" : *CHANNELVOICE 5 CornetEb
- tun%(5) = -12117
- WHEN "SaxEbBarC" : *CHANNELVOICE 5 SaxEbBarC
- tun%(5) = -2816
- WHEN "SaxBbTenrE" : *CHANNELVOICE 5 SaxBbTenrE
- tun%(5) = -4181
- WHEN "BassoonEb" : *CHANNELVOICE 5 BassoonEb
- tun%(5) = -4011
- WHEN "ClarinetBb" : *CHANNELVOICE 5 ClarinetBb
- tun%(5) = -10325
- WHEN "EngHornGb" : *CHANNELVOICE 5 EngHornGb
- tun%(5) = -8960
- WHEN "MandolinDb" : *CHANNELVOICE 5 MandolinDb
- tun%(5) = -11264
- WHEN "Piano2B" : *CHANNELVOICE 5 Piano2B
- tun%(5) = -2475
- WHEN "ClarVibEb" : *CHANNELVOICE 5 ClarVibEb
- tun%(5) = -7850
- WHEN "GtrDobroB" : *CHANNELVOICE 5 GtrDobroB
- tun%(5) = -6485
- WHEN "RecorderGb" : *CHANNELVOICE 5 RecorderGb
- tun%(5) = -13056
- WHEN "FlugelHnEb" : *CHANNELVOICE 5 FlugelHnEb
- tun%(5) = -12032
- WHEN "VceMmmGb23" : *CHANNELVOICE 5 VceMmmGb23
- tun%(5) = -853
- WHEN "VceMOooGb3" : *CHANNELVOICE 5 VceMOooGb3
- tun%(5) = -4843
- WHEN "VceFemAahC" : *CHANNELVOICE 5 VceFemAahC
- tun%(5) = -10948
- WHEN "VceFMmmGb4" : *CHANNELVOICE 5 VceFMmmGb4
- tun%(5) = -8918
- WHEN "Bass" : *CHANNELVOICE 5 Bass
- tun%(5) = 0
- WHEN "ChurchBell" : *CHANNELVOICE 5 ChurchBell
- tun%(5) = -2731
- WHEN "mysound" : *CHANNELVOICE 5 mysound
- tun%(5) = 0
- WHEN "GuiroFast" : *CHANNELVOICE 5 GuiroFast
- tun%(5) = -4000
- WHEN "Clave" : *CHANNELVOICE 5 Clave
- tun%(5) = -8096
- WHEN "CowBell" : *CHANNELVOICE 5 CowBell
- tun%(5) = -5707
- WHEN "CymbRideHd" : *CHANNELVOICE 5 CymbRideHd
- tun%(5) = -8096
- WHEN "AcGuitar1" : *CHANNELVOICE 5 AcGuitar1
- tun%(5) = -7072
- WHEN "CongaHi" : *CHANNELVOICE 5 CongaHi
- tun%(5) = -4000
- WHEN "DrumExplo" : *CHANNELVOICE 5 DrumExplo
- tun%(5) = -4000
- WHEN "ElecTom1" : *CHANNELVOICE 5 ElecTom1
- tun%(5) = -8096
- WHEN "Harp1" : *CHANNELVOICE 5 Harp1
- tun%(5) = -10997
- WHEN "Harpsi" : *CHANNELVOICE 5 Harpsi
- tun%(5) = -6901
- WHEN "HiString" : *CHANNELVOICE 5 HiString
- tun%(5) = -10997
- WHEN "HonkyPiano" : *CHANNELVOICE 5 HonkyPiano
- tun%(5) = -6901
- WHEN "JapFlute" : *CHANNELVOICE 5 JapFlute
- tun%(5) = -10997
- WHEN "JazzOrgan" : *CHANNELVOICE 5 JazzOrgan
- tun%(5) = -10997
- WHEN "MidStrings" : *CHANNELVOICE 5 MidStrings
- tun%(5) = -6901
- WHEN "NoteArp1" : *CHANNELVOICE 5 NoteArp1
- tun%(5) = -4000
- WHEN "SnareEcho" : *CHANNELVOICE 5 SnareEcho
- tun%(5) = -4341
- WHEN "TablaHi" : *CHANNELVOICE 5 TablaHi
- tun%(5) = -7669
- WHEN "Timpani" : *CHANNELVOICE 5 Timpani
- tun%(5) = -928
- WHEN "Tomtom1" : *CHANNELVOICE 5 Tomtom1
- tun%(5) = -5365
- WHEN "Trombone1" : *CHANNELVOICE 5 Trombone1
- tun%(5) = -6901
- WHEN "Trumpet" : *CHANNELVOICE 5 Trumpet
- tun%(5) = -10997
- WHEN "Xylophone" : *CHANNELVOICE 5 Xylophone
- tun%(5) = -6901
- WHEN "AcouGtr2B" : *CHANNELVOICE 5 AcouGtr2B
- tun%(5) = -6560
- WHEN "AcuBassAb1" : *CHANNELVOICE 5 AcuBassAb1
- tun%(5) = -1610
- WHEN "BagPipeG" : *CHANNELVOICE 5 BagPipeG
- tun%(5) = -9291
- WHEN "BanjoChdBb" : *CHANNELVOICE 5 BanjoChdBb
- tun%(5) = -4000
- WHEN "BazookiE" : *CHANNELVOICE 5 BazookiE
- tun%(5) = -8267
- WHEN "BellC" : *CHANNELVOICE 5 BellC
- tun%(5) = -10997
- WHEN "BrassEns1B" : *CHANNELVOICE 5 BrassEns1B
- tun%(5) = -6560
- WHEN "ClavichdBb" : *CHANNELVOICE 5 ClavichdBb
- tun%(5) = -10315
- WHEN "ClavinetBb" : *CHANNELVOICE 5 ClavinetBb
- tun%(5) = -6219
- WHEN "CornetEb" : *CHANNELVOICE 5 CornetEb
- tun%(5) = -4000
- WHEN "EnsWodAb45" : *CHANNELVOICE 5 EnsWodAb45
- tun%(5) = -9632
- WHEN "EnsWodGb12" : *CHANNELVOICE 5 EnsWodGb12
- tun%(5) = -4853
- WHEN "Glock2Ab5" : *CHANNELVOICE 5 Glock2Ab5
- tun%(5) = -9632
- WHEN "GtMelobarC" : *CHANNELVOICE 5 GtMelobarC
- tun%(5) = -6901
- WHEN "GtWashbnBb" : *CHANNELVOICE 5 GtWashbnBb
- tun%(5) = -6219
- WHEN "HarmonicaE" : *CHANNELVOICE 5 HarmonicaE
- tun%(5) = -4171
- WHEN "Jew'sHarpA" : *CHANNELVOICE 5 Jew'sHarpA
- tun%(5) = -6219
- WHEN "MusetteB" : *CHANNELVOICE 5 MusetteB
- tun%(5) = -10656
- WHEN "OboeGb" : *CHANNELVOICE 5 OboeGb
- tun%(5) = -13131
- WHEN "OrchHit2B" : *CHANNELVOICE 5 OrchHit2B
- tun%(5) = -5451
- WHEN "OrcSusBb23" : *CHANNELVOICE 5 OrcSusBb23
- tun%(5) = -6304
- WHEN "PiccoloE" : *CHANNELVOICE 5 PiccoloE
- tun%(5) = -16544
- WHEN "SaxSoprnoE" : *CHANNELVOICE 5 SaxSoprnoE
- tun%(5) = -12448
- WHEN "StrngThkBb" : *CHANNELVOICE 5 StrngThkBb
- tun%(5) = -5792
- WHEN "TubaGb" : *CHANNELVOICE 5 TubaGb
- tun%(5) = -929
- WHEN "BassDrum" : *CHANNELVOICE 5 BassDrum
- tun%(5) = -4000
- WHEN "HiHat" : *CHANNELVOICE 5 HiHat
- tun%(5) = -4000
- WHEN "OrcHit" : *CHANNELVOICE 5 OrcHit
- tun%(5) = -4085
- WHEN "Piano" : *CHANNELVOICE 5 Piano
- tun%(5) = -4171
- WHEN "Sax" : *CHANNELVOICE 5 Sax
- tun%(5) = -4085
- WHEN "Snare" : *CHANNELVOICE 5 Snare
- tun%(5) = -8096
- WHEN "Choir1" : *CHANNELVOICE 5 Choir1
- tun%(5) = -6901
- WHEN "ChurOrgan" : *CHANNELVOICE 5 ChurOrgan
- tun%(5) = -6901
- WHEN "Opera" : *CHANNELVOICE 5 Opera
- tun%(5) = -13387
- WHEN "OrchChoir" : *CHANNELVOICE 5 OrchChoir
- tun%(5) = -6133
- WHEN "OrganHit" : *CHANNELVOICE 5 OrganHit
- tun%(5) = -5024
- WHEN "AgogoAfric" : *CHANNELVOICE 5 AgogoAfric
- tun%(5) = -6219
- WHEN "AgogoBrazi" : *CHANNELVOICE 5 AgogoBrazi
- tun%(5) = -10997
- WHEN "AgogoWood" : *CHANNELVOICE 5 AgogoWood
- tun%(5) = -13728
- WHEN "BDGatedRev" : *CHANNELVOICE 5 BDGatedRev
- tun%(5) = -5877
- WHEN "BDMarching" : *CHANNELVOICE 5 BDMarching
- tun%(5) = -8608
- WHEN "BDPiloMute" : *CHANNELVOICE 5 BDPiloMute
- tun%(5) = -7072
- WHEN "Cabasa" : *CHANNELVOICE 5 Cabasa
- tun%(5) = -7072
- WHEN "Cachichi1" : *CHANNELVOICE 5 Cachichi1
- tun%(5) = -4000
- WHEN "CachichiTr" : *CHANNELVOICE 5 CachichiTr
- tun%(5) = -8096
- WHEN "Castanets" : *CHANNELVOICE 5 Castanets
- tun%(5) = -4000
- WHEN "CongaMid" : *CHANNELVOICE 5 CongaMid
- tun%(5) = -4171
- WHEN "CongaSmCl" : *CHANNELVOICE 5 CongaSmCl
- tun%(5) = -4683
- WHEN "CymbalCrsh" : *CHANNELVOICE 5 CymbalCrsh
- tun%(5) = -4000
- WHEN "CymRideBel" : *CHANNELVOICE 5 CymRideBel
- tun%(5) = -16288
- WHEN "CymRStRoll" : *CHANNELVOICE 5 CymRStRoll
- tun%(5) = -6389
- WHEN "CymSplshCa" : *CHANNELVOICE 5 CymSplshCa
- tun%(5) = -9120
- WHEN "Flexitone" : *CHANNELVOICE 5 Flexitone
- tun%(5) = -8096
- WHEN "GongSoft" : *CHANNELVOICE 5 GongSoft
- tun%(5) = -5365
- WHEN "Gonza1" : *CHANNELVOICE 5 Gonza1
- tun%(5) = -12192
- WHEN "GuiroSlow" : *CHANNELVOICE 5 GuiroSlow
- tun%(5) = -6048
- WHEN "HandClaps" : *CHANNELVOICE 5 HandClaps
- tun%(5) = -4000
- WHEN "HiHatFoot" : *CHANNELVOICE 5 HiHatFoot
- tun%(5) = -6389
- WHEN "Maracas1" : *CHANNELVOICE 5 Maracas1
- tun%(5) = -8096
- WHEN "MarimbaSB3" : *CHANNELVOICE 5 MarimbaSB3
- tun%(5) = -4000
- WHEN "Ratchet" : *CHANNELVOICE 5 Ratchet
- tun%(5) = -6731
- WHEN "RotoTomRev" : *CHANNELVOICE 5 RotoTomRev
- tun%(5) = -6133
- WHEN "SimmonsBD1" : *CHANNELVOICE 5 SimmonsBD1
- tun%(5) = -8096
- WHEN "SimmonsSn1" : *CHANNELVOICE 5 SimmonsSn1
- tun%(5) = -5707
- WHEN "SleighBell" : *CHANNELVOICE 5 SleighBell
- tun%(5) = -4000
- WHEN "SuperGong" : *CHANNELVOICE 5 SuperGong
- tun%(5) = -4341
- WHEN "SynthSnare" : *CHANNELVOICE 5 SynthSnare
- tun%(5) = -4000
- WHEN "SynTom" : *CHANNELVOICE 5 SynTom
- tun%(5) = -9120
- WHEN "TimpCresBb" : *CHANNELVOICE 5 TimpCresBb
- tun%(5) = -5962
- WHEN "TimpLowBb" : *CHANNELVOICE 5 TimpLowBb
- tun%(5) = -5707
- WHEN "TimpRollEb" : *CHANNELVOICE 5 TimpRollEb
- tun%(5) = -4000
- WHEN "TomRoll" : *CHANNELVOICE 5 TomRoll
- tun%(5) = -4000
- WHEN "ToyHooter" : *CHANNELVOICE 5 ToyHooter
- tun%(5) = -9717
- WHEN "ToyWhistle" : *CHANNELVOICE 5 ToyWhistle
- tun%(5) = -4000
- ENDCASE
- WHEN 6 :
- CASE waveforms$(vnumber%) OF
- WHEN "WaveSynth-Beep" : *CHANNELVOICE 6 WaveSynth-Beep
- WHEN "StringLib-Soft" : *CHANNELVOICE 6 StringLib-Soft
- WHEN "StringLib-Pluck" : *CHANNELVOICE 6 StringLib-Pluck
- WHEN "StringLib-Steel" : *CHANNELVOICE 6 StringLib-Steel
- WHEN "StringLib-Hard" : *CHANNELVOICE 6 StringLib-Hard
- WHEN "Percussion-Soft" : *CHANNELVOICE 6 Percussion-Soft
- WHEN "Percussion-Medium" : *CHANNELVOICE 6 Percussion-Medium
- WHEN "Percussion-Snare" : *CHANNELVOICE 6 Percussion-Snare
- WHEN "Percussion-Noise" : *CHANNELVOICE 6 Percussion-Noise
- WHEN "BassBowAb" : *CHANNELVOICE 6 BassBowAb
- tun%(6) = -1470
- WHEN "AcouBass" : *CHANNELVOICE 6 AcouBass
- tun%(6) = -2731
- WHEN "Vibe" : *CHANNELVOICE 6 Vibe
- tun%(6) = -6912
- WHEN "BugleC" : *CHANNELVOICE 6 BugleC
- tun%(6) = -11008
- WHEN "CornetEb" : *CHANNELVOICE 6 CornetEb
- tun%(6) = -12117
- WHEN "SaxEbBarC" : *CHANNELVOICE 6 SaxEbBarC
- tun%(6) = -2816
- WHEN "SaxBbTenrE" : *CHANNELVOICE 6 SaxBbTenrE
- tun%(6) = -4181
- WHEN "BassoonEb" : *CHANNELVOICE 6 BassoonEb
- tun%(6) = -4011
- WHEN "ClarinetBb" : *CHANNELVOICE 6 ClarinetBb
- tun%(6) = -10325
- WHEN "EngHornGb" : *CHANNELVOICE 6 EngHornGb
- tun%(6) = -8960
- WHEN "MandolinDb" : *CHANNELVOICE 6 MandolinDb
- tun%(6) = -11264
- WHEN "Piano2B" : *CHANNELVOICE 6 Piano2B
- tun%(6) = -2475
- WHEN "ClarVibEb" : *CHANNELVOICE 6 ClarVibEb
- tun%(6) = -7850
- WHEN "GtrDobroB" : *CHANNELVOICE 6 GtrDobroB
- tun%(6) = -6485
- WHEN "RecorderGb" : *CHANNELVOICE 6 RecorderGb
- tun%(6) = -13056
- WHEN "FlugelHnEb" : *CHANNELVOICE 6 FlugelHnEb
- tun%(6) = -12032
- WHEN "VceMmmGb23" : *CHANNELVOICE 6 VceMmmGb23
- tun%(6) = -853
- WHEN "VceMOooGb3" : *CHANNELVOICE 6 VceMOooGb3
- tun%(6) = -4843
- WHEN "VceFemAahC" : *CHANNELVOICE 6 VceFemAahC
- tun%(6) = -10948
- WHEN "VceFMmmGb4" : *CHANNELVOICE 6 VceFMmmGb4
- tun%(6) = -8918
- WHEN "Bass" : *CHANNELVOICE 6 Bass
- tun%(6) = 0
- WHEN "ChurchBell" : *CHANNELVOICE 6 ChurchBell
- tun%(6) = -2731
- WHEN "mysound" : *CHANNELVOICE 6 mysound
- tun%(6) = 0
- WHEN "GuiroFast" : *CHANNELVOICE 6 GuiroFast
- tun%(6) = -4000
- WHEN "Clave" : *CHANNELVOICE 6 Clave
- tun%(6) = -8096
- WHEN "CowBell" : *CHANNELVOICE 6 CowBell
- tun%(6) = -5707
- WHEN "CymbRideHd" : *CHANNELVOICE 6 CymbRideHd
- tun%(6) = -8096
- WHEN "AcGuitar1" : *CHANNELVOICE 6 AcGuitar1
- tun%(6) = -7072
- WHEN "CongaHi" : *CHANNELVOICE 6 CongaHi
- tun%(6) = -4000
- WHEN "DrumExplo" : *CHANNELVOICE 6 DrumExplo
- tun%(6) = -4000
- WHEN "ElecTom1" : *CHANNELVOICE 6 ElecTom1
- tun%(6) = -8096
- WHEN "Harp1" : *CHANNELVOICE 6 Harp1
- tun%(6) = -10997
- WHEN "Harpsi" : *CHANNELVOICE 6 Harpsi
- tun%(6) = -6901
- WHEN "HiString" : *CHANNELVOICE 6 HiString
- tun%(6) = -10997
- WHEN "HonkyPiano" : *CHANNELVOICE 6 HonkyPiano
- tun%(6) = -6901
- WHEN "JapFlute" : *CHANNELVOICE 6 JapFlute
- tun%(6) = -10997
- WHEN "JazzOrgan" : *CHANNELVOICE 6 JazzOrgan
- tun%(6) = -10997
- WHEN "MidStrings" : *CHANNELVOICE 6 MidStrings
- tun%(6) = -6901
- WHEN "NoteArp1" : *CHANNELVOICE 6 NoteArp1
- tun%(6) = -4000
- WHEN "SnareEcho" : *CHANNELVOICE 6 SnareEcho
- tun%(6) = -4341
- WHEN "TablaHi" : *CHANNELVOICE 6 TablaHi
- tun%(6) = -7669
- WHEN "Timpani" : *CHANNELVOICE 6 Timpani
- tun%(6) = -928
- WHEN "Tomtom1" : *CHANNELVOICE 6 Tomtom1
- tun%(6) = -5365
- WHEN "Trombone1" : *CHANNELVOICE 6 Trombone1
- tun%(6) = -6901
- WHEN "Trumpet" : *CHANNELVOICE 6 Trumpet
- tun%(6) = -10997
- WHEN "Xylophone" : *CHANNELVOICE 6 Xylophone
- tun%(6) = -6901
- WHEN "AcouGtr2B" : *CHANNELVOICE 6 AcouGtr2B
- tun%(6) = -6560
- WHEN "AcuBassAb1" : *CHANNELVOICE 6 AcuBassAb1
- tun%(6) = -1610
- WHEN "BagPipeG" : *CHANNELVOICE 6 BagPipeG
- tun%(6) = -9291
- WHEN "BanjoChdBb" : *CHANNELVOICE 6 BanjoChdBb
- tun%(6) = -4000
- WHEN "BazookiE" : *CHANNELVOICE 6 BazookiE
- tun%(6) = -8267
- WHEN "BellC" : *CHANNELVOICE 6 BellC
- tun%(6) = -10997
- WHEN "BrassEns1B" : *CHANNELVOICE 6 BrassEns1B
- tun%(6) = -6560
- WHEN "ClavichdBb" : *CHANNELVOICE 6 ClavichdBb
- tun%(6) = -10315
- WHEN "ClavinetBb" : *CHANNELVOICE 6 ClavinetBb
- tun%(6) = -6219
- WHEN "CornetEb" : *CHANNELVOICE 6 CornetEb
- tun%(6) = -4000
- WHEN "EnsWodAb45" : *CHANNELVOICE 6 EnsWodAb45
- tun%(6) = -9632
- WHEN "EnsWodGb12" : *CHANNELVOICE 6 EnsWodGb12
- tun%(6) = -4853
- WHEN "Glock2Ab5" : *CHANNELVOICE 6 Glock2Ab5
- tun%(6) = -9632
- WHEN "GtMelobarC" : *CHANNELVOICE 6 GtMelobarC
- tun%(6) = -6901
- WHEN "GtWashbnBb" : *CHANNELVOICE 6 GtWashbnBb
- tun%(6) = -6219
- WHEN "HarmonicaE" : *CHANNELVOICE 6 HarmonicaE
- tun%(6) = -4171
- WHEN "Jew'sHarpA" : *CHANNELVOICE 6 Jew'sHarpA
- tun%(6) = -6219
- WHEN "MusetteB" : *CHANNELVOICE 6 MusetteB
- tun%(6) = -10656
- WHEN "OboeGb" : *CHANNELVOICE 6 OboeGb
- tun%(6) = -13131
- WHEN "OrchHit2B" : *CHANNELVOICE 6 OrchHit2B
- tun%(6) = -5451
- WHEN "OrcSusBb23" : *CHANNELVOICE 6 OrcSusBb23
- tun%(6) = -6304
- WHEN "PiccoloE" : *CHANNELVOICE 6 PiccoloE
- tun%(6) = -16544
- WHEN "SaxSoprnoE" : *CHANNELVOICE 6 SaxSoprnoE
- tun%(6) = -12448
- WHEN "StrngThkBb" : *CHANNELVOICE 6 StrngThkBb
- tun%(6) = -5792
- WHEN "TubaGb" : *CHANNELVOICE 6 TubaGb
- tun%(6) = -929
- WHEN "BassDrum" : *CHANNELVOICE 6 BassDrum
- tun%(6) = -4000
- WHEN "HiHat" : *CHANNELVOICE 6 HiHat
- tun%(6) = -4000
- WHEN "OrcHit" : *CHANNELVOICE 6 OrcHit
- tun%(6) = -4085
- WHEN "Piano" : *CHANNELVOICE 6 Piano
- tun%(6) = -4171
- WHEN "Sax" : *CHANNELVOICE 6 Sax
- tun%(6) = -4085
- WHEN "Snare" : *CHANNELVOICE 6 Snare
- tun%(6) = -8096
- WHEN "Choir1" : *CHANNELVOICE 6 Choir1
- tun%(6) = -6901
- WHEN "ChurOrgan" : *CHANNELVOICE 6 ChurOrgan
- tun%(6) = -6901
- WHEN "Opera" : *CHANNELVOICE 6 Opera
- tun%(6) = -13387
- WHEN "OrchChoir" : *CHANNELVOICE 6 OrchChoir
- tun%(6) = -6133
- WHEN "OrganHit" : *CHANNELVOICE 6 OrganHit
- tun%(6) = -5024
- WHEN "AgogoAfric" : *CHANNELVOICE 6 AgogoAfric
- tun%(6) = -6219
- WHEN "AgogoBrazi" : *CHANNELVOICE 6 AgogoBrazi
- tun%(6) = -10997
- WHEN "AgogoWood" : *CHANNELVOICE 6 AgogoWood
- tun%(6) = -13728
- WHEN "BDGatedRev" : *CHANNELVOICE 6 BDGatedRev
- tun%(6) = -5877
- WHEN "BDMarching" : *CHANNELVOICE 6 BDMarching
- tun%(6) = -8608
- WHEN "BDPiloMute" : *CHANNELVOICE 6 BDPiloMute
- tun%(6) = -7072
- WHEN "Cabasa" : *CHANNELVOICE 6 Cabasa
- tun%(6) = -7072
- WHEN "Cachichi1" : *CHANNELVOICE 6 Cachichi1
- tun%(6) = -4000
- WHEN "CachichiTr" : *CHANNELVOICE 6 CachichiTr
- tun%(6) = -8096
- WHEN "Castanets" : *CHANNELVOICE 6 Castanets
- tun%(6) = -4000
- WHEN "CongaMid" : *CHANNELVOICE 6 CongaMid
- tun%(6) = -4171
- WHEN "CongaSmCl" : *CHANNELVOICE 6 CongaSmCl
- tun%(6) = -4683
- WHEN "CymbalCrsh" : *CHANNELVOICE 6 CymbalCrsh
- tun%(6) = -4000
- WHEN "CymRideBel" : *CHANNELVOICE 6 CymRideBel
- tun%(6) = -16288
- WHEN "CymRStRoll" : *CHANNELVOICE 6 CymRStRoll
- tun%(6) = -6389
- WHEN "CymSplshCa" : *CHANNELVOICE 6 CymSplshCa
- tun%(6) = -9120
- WHEN "Flexitone" : *CHANNELVOICE 6 Flexitone
- tun%(6) = -8096
- WHEN "GongSoft" : *CHANNELVOICE 6 GongSoft
- tun%(6) = -5365
- WHEN "Gonza1" : *CHANNELVOICE 6 Gonza1
- tun%(6) = -12192
- WHEN "GuiroSlow" : *CHANNELVOICE 6 GuiroSlow
- tun%(6) = -6048
- WHEN "HandClaps" : *CHANNELVOICE 6 HandClaps
- tun%(6) = -4000
- WHEN "HiHatFoot" : *CHANNELVOICE 6 HiHatFoot
- tun%(6) = -6389
- WHEN "Maracas1" : *CHANNELVOICE 6 Maracas1
- tun%(6) = -8096
- WHEN "MarimbaSB3" : *CHANNELVOICE 6 MarimbaSB3
- tun%(6) = -4000
- WHEN "Ratchet" : *CHANNELVOICE 6 Ratchet
- tun%(6) = -6731
- WHEN "RotoTomRev" : *CHANNELVOICE 6 RotoTomRev
- tun%(6) = -6133
- WHEN "SimmonsBD1" : *CHANNELVOICE 6 SimmonsBD1
- tun%(6) = -8096
- WHEN "SimmonsSn1" : *CHANNELVOICE 6 SimmonsSn1
- tun%(6) = -5707
- WHEN "SleighBell" : *CHANNELVOICE 6 SleighBell
- tun%(6) = -4000
- WHEN "SuperGong" : *CHANNELVOICE 6 SuperGong
- tun%(6) = -4341
- WHEN "SynthSnare" : *CHANNELVOICE 6 SynthSnare
- tun%(6) = -4000
- WHEN "SynTom" : *CHANNELVOICE 6 SynTom
- tun%(6) = -9120
- WHEN "TimpCresBb" : *CHANNELVOICE 6 TimpCresBb
- tun%(6) = -5962
- WHEN "TimpLowBb" : *CHANNELVOICE 6 TimpLowBb
- tun%(6) = -5707
- WHEN "TimpRollEb" : *CHANNELVOICE 6 TimpRollEb
- tun%(6) = -4000
- WHEN "TomRoll" : *CHANNELVOICE 6 TomRoll
- tun%(6) = -4000
- WHEN "ToyHooter" : *CHANNELVOICE 6 ToyHooter
- tun%(6) = -9717
- WHEN "ToyWhistle" : *CHANNELVOICE 6 ToyWhistle
- tun%(6) = -4000
- ENDCASE
- WHEN 7 :
- CASE waveforms$(vnumber%) OF
- WHEN "WaveSynth-Beep" : *CHANNELVOICE 7 WaveSynth-Beep
- WHEN "StringLib-Soft" : *CHANNELVOICE 7 StringLib-Soft
- WHEN "StringLib-Pluck" : *CHANNELVOICE 7 StringLib-Pluck
- WHEN "StringLib-Steel" : *CHANNELVOICE 7 StringLib-Steel
- WHEN "StringLib-Hard" : *CHANNELVOICE 7 StringLib-Hard
- WHEN "Percussion-Soft" : *CHANNELVOICE 7 Percussion-Soft
- WHEN "Percussion-Medium" : *CHANNELVOICE 7 Percussion-Medium
- WHEN "Percussion-Snare" : *CHANNELVOICE 7 Percussion-Snare
- WHEN "Percussion-Noise" : *CHANNELVOICE 7 Percussion-Noise
- WHEN "BassBowAb" : *CHANNELVOICE 7 BassBowAb
- tun%(7) = -1470
- WHEN "AcouBass" : *CHANNELVOICE 7 AcouBass
- tun%(7) = -2731
- WHEN "Vibe" : *CHANNELVOICE 7 Vibe
- tun%(7) = -6912
- WHEN "BugleC" : *CHANNELVOICE 7 BugleC
- tun%(7) = -11008
- WHEN "CornetEb" : *CHANNELVOICE 7 CornetEb
- tun%(7) = -12117
- WHEN "SaxEbBarC" : *CHANNELVOICE 7 SaxEbBarC
- tun%(7) = -2816
- WHEN "SaxBbTenrE" : *CHANNELVOICE 7 SaxBbTenrE
- tun%(7) = -4181
- WHEN "BassoonEb" : *CHANNELVOICE 7 BassoonEb
- tun%(7) = -4011
- WHEN "ClarinetBb" : *CHANNELVOICE 7 ClarinetBb
- tun%(7) = -10325
- WHEN "EngHornGb" : *CHANNELVOICE 7 EngHornGb
- tun%(7) = -8960
- WHEN "MandolinDb" : *CHANNELVOICE 7 MandolinDb
- tun%(7) = -11264
- WHEN "Piano2B" : *CHANNELVOICE 7 Piano2B
- tun%(7) = -2475
- WHEN "ClarVibEb" : *CHANNELVOICE 7 ClarVibEb
- tun%(7) = -7850
- WHEN "GtrDobroB" : *CHANNELVOICE 7 GtrDobroB
- tun%(7) = -6485
- WHEN "RecorderGb" : *CHANNELVOICE 7 RecorderGb
- tun%(7) = -13056
- WHEN "FlugelHnEb" : *CHANNELVOICE 7 FlugelHnEb
- tun%(7) = -12032
- WHEN "VceMmmGb23" : *CHANNELVOICE 7 VceMmmGb23
- tun%(7) = -853
- WHEN "VceMOooGb3" : *CHANNELVOICE 7 VceMOooGb3
- tun%(7) = -4843
- WHEN "VceFemAahC" : *CHANNELVOICE 7 VceFemAahC
- tun%(7) = -10948
- WHEN "VceFMmmGb4" : *CHANNELVOICE 7 VceFMmmGb4
- tun%(7) = -8918
- WHEN "Bass" : *CHANNELVOICE 7 Bass
- tun%(7) = 0
- WHEN "ChurchBell" : *CHANNELVOICE 7 ChurchBell
- tun%(7) = -2731
- WHEN "mysound" : *CHANNELVOICE 7 mysound
- tun%(7) = 0
- WHEN "GuiroFast" : *CHANNELVOICE 7 GuiroFast
- tun%(7) = -4000
- WHEN "Clave" : *CHANNELVOICE 7 Clave
- tun%(7) = -8096
- WHEN "CowBell" : *CHANNELVOICE 7 CowBell
- tun%(7) = -5707
- WHEN "CymbRideHd" : *CHANNELVOICE 7 CymbRideHd
- tun%(7) = -8096
- WHEN "AcGuitar1" : *CHANNELVOICE 7 AcGuitar1
- tun%(7) = -7072
- WHEN "CongaHi" : *CHANNELVOICE 7 CongaHi
- tun%(7) = -4000
- WHEN "DrumExplo" : *CHANNELVOICE 7 DrumExplo
- tun%(7) = -4000
- WHEN "ElecTom1" : *CHANNELVOICE 7 ElecTom1
- tun%(7) = -8096
- WHEN "Harp1" : *CHANNELVOICE 7 Harp1
- tun%(7) = -10997
- WHEN "Harpsi" : *CHANNELVOICE 7 Harpsi
- tun%(7) = -6901
- WHEN "HiString" : *CHANNELVOICE 7 HiString
- tun%(7) = -10997
- WHEN "HonkyPiano" : *CHANNELVOICE 7 HonkyPiano
- tun%(7) = -6901
- WHEN "JapFlute" : *CHANNELVOICE 7 JapFlute
- tun%(7) = -10997
- WHEN "JazzOrgan" : *CHANNELVOICE 7 JazzOrgan
- tun%(7) = -10997
- WHEN "MidStrings" : *CHANNELVOICE 7 MidStrings
- tun%(7) = -6901
- WHEN "NoteArp1" : *CHANNELVOICE 7 NoteArp1
- tun%(7) = -4000
- WHEN "SnareEcho" : *CHANNELVOICE 7 SnareEcho
- tun%(7) = -4341
- WHEN "TablaHi" : *CHANNELVOICE 7 TablaHi
- tun%(7) = -7669
- WHEN "Timpani" : *CHANNELVOICE 7 Timpani
- tun%(7) = -928
- WHEN "Tomtom1" : *CHANNELVOICE 7 Tomtom1
- tun%(7) = -5365
- WHEN "Trombone1" : *CHANNELVOICE 7 Trombone1
- tun%(7) = -6901
- WHEN "Trumpet" : *CHANNELVOICE 7 Trumpet
- tun%(7) = -10997
- WHEN "Xylophone" : *CHANNELVOICE 7 Xylophone
- tun%(7) = -6901
- WHEN "AcouGtr2B" : *CHANNELVOICE 7 AcouGtr2B
- tun%(7) = -6560
- WHEN "AcuBassAb1" : *CHANNELVOICE 7 AcuBassAb1
- tun%(7) = -1610
- WHEN "BagPipeG" : *CHANNELVOICE 7 BagPipeG
- tun%(7) = -9291
- WHEN "BanjoChdBb" : *CHANNELVOICE 7 BanjoChdBb
- tun%(7) = -4000
- WHEN "BazookiE" : *CHANNELVOICE 7 BazookiE
- tun%(7) = -8267
- WHEN "BellC" : *CHANNELVOICE 7 BellC
- tun%(7) = -10997
- WHEN "BrassEns1B" : *CHANNELVOICE 7 BrassEns1B
- tun%(7) = -6560
- WHEN "ClavichdBb" : *CHANNELVOICE 7 ClavichdBb
- tun%(7) = -10315
- WHEN "ClavinetBb" : *CHANNELVOICE 7 ClavinetBb
- tun%(7) = -6219
- WHEN "CornetEb" : *CHANNELVOICE 7 CornetEb
- tun%(7) = -4000
- WHEN "EnsWodAb45" : *CHANNELVOICE 7 EnsWodAb45
- tun%(7) = -9632
- WHEN "EnsWodGb12" : *CHANNELVOICE 7 EnsWodGb12
- tun%(7) = -4853
- WHEN "Glock2Ab5" : *CHANNELVOICE 7 Glock2Ab5
- tun%(7) = -9632
- WHEN "GtMelobarC" : *CHANNELVOICE 7 GtMelobarC
- tun%(7) = -6901
- WHEN "GtWashbnBb" : *CHANNELVOICE 7 GtWashbnBb
- tun%(7) = -6219
- WHEN "HarmonicaE" : *CHANNELVOICE 7 HarmonicaE
- tun%(7) = -4171
- WHEN "Jew'sHarpA" : *CHANNELVOICE 7 Jew'sHarpA
- tun%(7) = -6219
- WHEN "MusetteB" : *CHANNELVOICE 7 MusetteB
- tun%(7) = -10656
- WHEN "OboeGb" : *CHANNELVOICE 7 OboeGb
- tun%(7) = -13131
- WHEN "OrchHit2B" : *CHANNELVOICE 7 OrchHit2B
- tun%(7) = -5451
- WHEN "OrcSusBb23" : *CHANNELVOICE 7 OrcSusBb23
- tun%(7) = -6304
- WHEN "PiccoloE" : *CHANNELVOICE 7 PiccoloE
- tun%(7) = -16544
- WHEN "SaxSoprnoE" : *CHANNELVOICE 7 SaxSoprnoE
- tun%(7) = -12448
- WHEN "StrngThkBb" : *CHANNELVOICE 7 StrngThkBb
- tun%(7) = -5792
- WHEN "TubaGb" : *CHANNELVOICE 7 TubaGb
- tun%(7) = -929
- WHEN "BassDrum" : *CHANNELVOICE 7 BassDrum
- tun%(7) = -4000
- WHEN "HiHat" : *CHANNELVOICE 7 HiHat
- tun%(7) = -4000
- WHEN "OrcHit" : *CHANNELVOICE 7 OrcHit
- tun%(7) = -4085
- WHEN "Piano" : *CHANNELVOICE 7 Piano
- tun%(7) = -4171
- WHEN "Sax" : *CHANNELVOICE 7 Sax
- tun%(7) = -4085
- WHEN "Snare" : *CHANNELVOICE 7 Snare
- tun%(7) = -8096
- WHEN "Choir1" : *CHANNELVOICE 7 Choir1
- tun%(7) = -6901
- WHEN "ChurOrgan" : *CHANNELVOICE 7 ChurOrgan
- tun%(7) = -6901
- WHEN "Opera" : *CHANNELVOICE 7 Opera
- tun%(7) = -13387
- WHEN "OrchChoir" : *CHANNELVOICE 7 OrchChoir
- tun%(7) = -6133
- WHEN "OrganHit" : *CHANNELVOICE 7 OrganHit
- tun%(7) = -5024
- WHEN "AgogoAfric" : *CHANNELVOICE 7 AgogoAfric
- tun%(7) = -6219
- WHEN "AgogoBrazi" : *CHANNELVOICE 7 AgogoBrazi
- tun%(7) = -10997
- WHEN "AgogoWood" : *CHANNELVOICE 7 AgogoWood
- tun%(7) = -13728
- WHEN "BDGatedRev" : *CHANNELVOICE 7 BDGatedRev
- tun%(7) = -5877
- WHEN "BDMarching" : *CHANNELVOICE 7 BDMarching
- tun%(7) = -8608
- WHEN "BDPiloMute" : *CHANNELVOICE 7 BDPiloMute
- tun%(7) = -7072
- WHEN "Cabasa" : *CHANNELVOICE 7 Cabasa
- tun%(7) = -7072
- WHEN "Cachichi1" : *CHANNELVOICE 7 Cachichi1
- tun%(7) = -4000
- WHEN "CachichiTr" : *CHANNELVOICE 7 CachichiTr
- tun%(7) = -8096
- WHEN "Castanets" : *CHANNELVOICE 7 Castanets
- tun%(7) = -4000
- WHEN "CongaMid" : *CHANNELVOICE 7 CongaMid
- tun%(7) = -4171
- WHEN "CongaSmCl" : *CHANNELVOICE 7 CongaSmCl
- tun%(7) = -4683
- WHEN "CymbalCrsh" : *CHANNELVOICE 7 CymbalCrsh
- tun%(7) = -4000
- WHEN "CymRideBel" : *CHANNELVOICE 7 CymRideBel
- tun%(7) = -16288
- WHEN "CymRStRoll" : *CHANNELVOICE 7 CymRStRoll
- tun%(7) = -6389
- WHEN "CymSplshCa" : *CHANNELVOICE 7 CymSplshCa
- tun%(7) = -9120
- WHEN "Flexitone" : *CHANNELVOICE 7 Flexitone
- tun%(7) = -8096
- WHEN "GongSoft" : *CHANNELVOICE 7 GongSoft
- tun%(7) = -5365
- WHEN "Gonza1" : *CHANNELVOICE 7 Gonza1
- tun%(7) = -12192
- WHEN "GuiroSlow" : *CHANNELVOICE 7 GuiroSlow
- tun%(7) = -6048
- WHEN "HandClaps" : *CHANNELVOICE 7 HandClaps
- tun%(7) = -4000
- WHEN "HiHatFoot" : *CHANNELVOICE 7 HiHatFoot
- tun%(7) = -6389
- WHEN "Maracas1" : *CHANNELVOICE 7 Maracas1
- tun%(7) = -8096
- WHEN "MarimbaSB3" : *CHANNELVOICE 7 MarimbaSB3
- tun%(7) = -4000
- WHEN "Ratchet" : *CHANNELVOICE 7 Ratchet
- tun%(7) = -6731
- WHEN "RotoTomRev" : *CHANNELVOICE 7 RotoTomRev
- tun%(7) = -6133
- WHEN "SimmonsBD1" : *CHANNELVOICE 7 SimmonsBD1
- tun%(7) = -8096
- WHEN "SimmonsSn1" : *CHANNELVOICE 7 SimmonsSn1
- tun%(7) = -5707
- WHEN "SleighBell" : *CHANNELVOICE 7 SleighBell
- tun%(7) = -4000
- WHEN "SuperGong" : *CHANNELVOICE 7 SuperGong
- tun%(7) = -4341
- WHEN "SynthSnare" : *CHANNELVOICE 7 SynthSnare
- tun%(7) = -4000
- WHEN "SynTom" : *CHANNELVOICE 7 SynTom
- tun%(7) = -9120
- WHEN "TimpCresBb" : *CHANNELVOICE 7 TimpCresBb
- tun%(7) = -5962
- WHEN "TimpLowBb" : *CHANNELVOICE 7 TimpLowBb
- tun%(7) = -5707
- WHEN "TimpRollEb" : *CHANNELVOICE 7 TimpRollEb
- tun%(7) = -4000
- WHEN "TomRoll" : *CHANNELVOICE 7 TomRoll
- tun%(7) = -4000
- WHEN "ToyHooter" : *CHANNELVOICE 7 ToyHooter
- tun%(7) = -9717
- WHEN "ToyWhistle" : *CHANNELVOICE 7 ToyWhistle
- tun%(7) = -4000
- ENDCASE
- WHEN 8 :
- CASE waveforms$(vnumber%) OF
- WHEN "WaveSynth-Beep" : *CHANNELVOICE 8 WaveSynth-Beep
- WHEN "StringLib-Soft" : *CHANNELVOICE 8 StringLib-Soft
- WHEN "StringLib-Pluck" : *CHANNELVOICE 8 StringLib-Pluck
- WHEN "StringLib-Steel" : *CHANNELVOICE 8 StringLib-Steel
- WHEN "StringLib-Hard" : *CHANNELVOICE 8 StringLib-Hard
- WHEN "Percussion-Soft" : *CHANNELVOICE 8 Percussion-Soft
- WHEN "Percussion-Medium" : *CHANNELVOICE 8 Percussion-Medium
- WHEN "Percussion-Snare" : *CHANNELVOICE 8 Percussion-Snare
- WHEN "Percussion-Noise" : *CHANNELVOICE 8 Percussion-Noise
- WHEN "BassBowAb" : *CHANNELVOICE 8 BassBowAb
- tun%(8) = -1470
- WHEN "AcouBass" : *CHANNELVOICE 8 AcouBass
- tun%(8) = -2731
- WHEN "Vibe" : *CHANNELVOICE 8 Vibe
- tun%(8) = -6912
- WHEN "BugleC" : *CHANNELVOICE 8 BugleC
- tun%(8) = -11008
- WHEN "CornetEb" : *CHANNELVOICE 8 CornetEb
- tun%(8) = -12117
- WHEN "SaxEbBarC" : *CHANNELVOICE 8 SaxEbBarC
- tun%(8) = -2816
- WHEN "SaxBbTenrE" : *CHANNELVOICE 8 SaxBbTenrE
- tun%(8) = -4181
- WHEN "BassoonEb" : *CHANNELVOICE 8 BassoonEb
- tun%(8) = -4011
- WHEN "ClarinetBb" : *CHANNELVOICE 8 ClarinetBb
- tun%(8) = -10325
- WHEN "EngHornGb" : *CHANNELVOICE 8 EngHornGb
- tun%(8) = -8960
- WHEN "MandolinDb" : *CHANNELVOICE 8 MandolinDb
- tun%(8) = -11264
- WHEN "Piano2B" : *CHANNELVOICE 8 Piano2B
- tun%(8) = -2475
- WHEN "ClarVibEb" : *CHANNELVOICE 8 ClarVibEb
- tun%(8) = -7850
- WHEN "GtrDobroB" : *CHANNELVOICE 8 GtrDobroB
- tun%(8) = -6485
- WHEN "RecorderGb" : *CHANNELVOICE 8 RecorderGb
- tun%(8) = -13056
- WHEN "FlugelHnEb" : *CHANNELVOICE 8 FlugelHnEb
- tun%(8) = -12032
- WHEN "VceMmmGb23" : *CHANNELVOICE 8 VceMmmGb23
- tun%(8) = -853
- WHEN "VceMOooGb3" : *CHANNELVOICE 8 VceMOooGb3
- tun%(8) = -4843
- WHEN "VceFemAahC" : *CHANNELVOICE 8 VceFemAahC
- tun%(8) = -10948
- WHEN "VceFMmmGb4" : *CHANNELVOICE 8 VceFMmmGb4
- tun%(8) = -8918
- WHEN "Bass" : *CHANNELVOICE 8 Bass
- tun%(8) = 0
- WHEN "ChurchBell" : *CHANNELVOICE 8 ChurchBell
- tun%(8) = -2731
- WHEN "mysound" : *CHANNELVOICE 8 mysound
- tun%(8) = 0
- WHEN "GuiroFast" : *CHANNELVOICE 8 GuiroFast
- tun%(8) = -4000
- WHEN "Clave" : *CHANNELVOICE 8 Clave
- tun%(8) = -8096
- WHEN "CowBell" : *CHANNELVOICE 8 CowBell
- tun%(8) = -5707
- WHEN "CymbRideHd" : *CHANNELVOICE 8 CymbRideHd
- tun%(8) = -8096
- WHEN "AcGuitar1" : *CHANNELVOICE 8 AcGuitar1
- tun%(8) = -7072
- WHEN "CongaHi" : *CHANNELVOICE 8 CongaHi
- tun%(8) = -4000
- WHEN "DrumExplo" : *CHANNELVOICE 8 DrumExplo
- tun%(8) = -4000
- WHEN "ElecTom1" : *CHANNELVOICE 8 ElecTom1
- tun%(8) = -8096
- WHEN "Harp1" : *CHANNELVOICE 8 Harp1
- tun%(8) = -10997
- WHEN "Harpsi" : *CHANNELVOICE 8 Harpsi
- tun%(8) = -6901
- WHEN "HiString" : *CHANNELVOICE 8 HiString
- tun%(8) = -10997
- WHEN "HonkyPiano" : *CHANNELVOICE 8 HonkyPiano
- tun%(8) = -6901
- WHEN "JapFlute" : *CHANNELVOICE 8 JapFlute
- tun%(8) = -10997
- WHEN "JazzOrgan" : *CHANNELVOICE 8 JazzOrgan
- tun%(8) = -10997
- WHEN "MidStrings" : *CHANNELVOICE 8 MidStrings
- tun%(8) = -6901
- WHEN "NoteArp1" : *CHANNELVOICE 8 NoteArp1
- tun%(8) = -4000
- WHEN "SnareEcho" : *CHANNELVOICE 8 SnareEcho
- tun%(8) = -4341
- WHEN "TablaHi" : *CHANNELVOICE 8 TablaHi
- tun%(8) = -7669
- WHEN "Timpani" : *CHANNELVOICE 8 Timpani
- tun%(8) = -928
- WHEN "Tomtom1" : *CHANNELVOICE 8 Tomtom1
- tun%(8) = -5365
- WHEN "Trombone1" : *CHANNELVOICE 8 Trombone1
- tun%(8) = -6901
- WHEN "Trumpet" : *CHANNELVOICE 8 Trumpet
- tun%(8) = -10997
- WHEN "Xylophone" : *CHANNELVOICE 8 Xylophone
- tun%(8) = -6901
- WHEN "AcouGtr2B" : *CHANNELVOICE 8 AcouGtr2B
- tun%(8) = -6560
- WHEN "AcuBassAb1" : *CHANNELVOICE 8 AcuBassAb1
- tun%(8) = -1610
- WHEN "BagPipeG" : *CHANNELVOICE 8 BagPipeG
- tun%(8) = -9291
- WHEN "BanjoChdBb" : *CHANNELVOICE 8 BanjoChdBb
- tun%(8) = -4000
- WHEN "BazookiE" : *CHANNELVOICE 8 BazookiE
- tun%(8) = -8267
- WHEN "BellC" : *CHANNELVOICE 8 BellC
- tun%(8) = -10997
- WHEN "BrassEns1B" : *CHANNELVOICE 8 BrassEns1B
- tun%(8) = -6560
- WHEN "ClavichdBb" : *CHANNELVOICE 8 ClavichdBb
- tun%(8) = -10315
- WHEN "ClavinetBb" : *CHANNELVOICE 8 ClavinetBb
- tun%(8) = -6219
- WHEN "CornetEb" : *CHANNELVOICE 8 CornetEb
- tun%(8) = -4000
- WHEN "EnsWodAb45" : *CHANNELVOICE 8 EnsWodAb45
- tun%(8) = -9632
- WHEN "EnsWodGb12" : *CHANNELVOICE 8 EnsWodGb12
- tun%(8) = -4853
- WHEN "Glock2Ab5" : *CHANNELVOICE 8 Glock2Ab5
- tun%(8) = -9632
- WHEN "GtMelobarC" : *CHANNELVOICE 8 GtMelobarC
- tun%(8) = -6901
- WHEN "GtWashbnBb" : *CHANNELVOICE 8 GtWashbnBb
- tun%(8) = -6219
- WHEN "HarmonicaE" : *CHANNELVOICE 8 HarmonicaE
- tun%(8) = -4171
- WHEN "Jew'sHarpA" : *CHANNELVOICE 8 Jew'sHarpA
- tun%(8) = -6219
- WHEN "MusetteB" : *CHANNELVOICE 8 MusetteB
- tun%(8) = -10656
- WHEN "OboeGb" : *CHANNELVOICE 8 OboeGb
- tun%(8) = -13131
- WHEN "OrchHit2B" : *CHANNELVOICE 8 OrchHit2B
- tun%(8) = -5451
- WHEN "OrcSusBb23" : *CHANNELVOICE 8 OrcSusBb23
- tun%(8) = -6304
- WHEN "PiccoloE" : *CHANNELVOICE 8 PiccoloE
- tun%(8) = -16544
- WHEN "SaxSoprnoE" : *CHANNELVOICE 8 SaxSoprnoE
- tun%(8) = -12448
- WHEN "StrngThkBb" : *CHANNELVOICE 8 StrngThkBb
- tun%(8) = -5792
- WHEN "TubaGb" : *CHANNELVOICE 8 TubaGb
- tun%(8) = -929
- WHEN "BassDrum" : *CHANNELVOICE 8 BassDrum
- tun%(8) = -4000
- WHEN "HiHat" : *CHANNELVOICE 8 HiHat
- tun%(8) = -4000
- WHEN "OrcHit" : *CHANNELVOICE 8 OrcHit
- tun%(8) = -4085
- WHEN "Piano" : *CHANNELVOICE 8 Piano
- tun%(8) = -4171
- WHEN "Sax" : *CHANNELVOICE 8 Sax
- tun%(8) = -4085
- WHEN "Snare" : *CHANNELVOICE 8 Snare
- tun%(8) = -8096
- WHEN "Choir1" : *CHANNELVOICE 8 Choir1
- tun%(8) = -6901
- WHEN "ChurOrgan" : *CHANNELVOICE 8 ChurOrgan
- tun%(8) = -6901
- WHEN "Opera" : *CHANNELVOICE 8 Opera
- tun%(8) = -13387
- WHEN "OrchChoir" : *CHANNELVOICE 8 OrchChoir
- tun%(8) = -6133
- WHEN "OrganHit" : *CHANNELVOICE 8 OrganHit
- tun%(8) = -5024
- WHEN "AgogoAfric" : *CHANNELVOICE 8 AgogoAfric
- tun%(8) = -6219
- WHEN "AgogoBrazi" : *CHANNELVOICE 8 AgogoBrazi
- tun%(8) = -10997
- WHEN "AgogoWood" : *CHANNELVOICE 8 AgogoWood
- tun%(8) = -13728
- WHEN "BDGatedRev" : *CHANNELVOICE 8 BDGatedRev
- tun%(8) = -5877
- WHEN "BDMarching" : *CHANNELVOICE 8 BDMarching
- tun%(8) = -8608
- WHEN "BDPiloMute" : *CHANNELVOICE 8 BDPiloMute
- tun%(8) = -7072
- WHEN "Cabasa" : *CHANNELVOICE 8 Cabasa
- tun%(8) = -7072
- WHEN "Cachichi1" : *CHANNELVOICE 8 Cachichi1
- tun%(8) = -4000
- WHEN "CachichiTr" : *CHANNELVOICE 8 CachichiTr
- tun%(8) = -8096
- WHEN "Castanets" : *CHANNELVOICE 8 Castanets
- tun%(8) = -4000
- WHEN "CongaMid" : *CHANNELVOICE 8 CongaMid
- tun%(8) = -4171
- WHEN "CongaSmCl" : *CHANNELVOICE 8 CongaSmCl
- tun%(8) = -4683
- WHEN "CymbalCrsh" : *CHANNELVOICE 8 CymbalCrsh
- tun%(8) = -4000
- WHEN "CymRideBel" : *CHANNELVOICE 8 CymRideBel
- tun%(8) = -16288
- WHEN "CymRStRoll" : *CHANNELVOICE 8 CymRStRoll
- tun%(8) = -6389
- WHEN "CymSplshCa" : *CHANNELVOICE 8 CymSplshCa
- tun%(8) = -9120
- WHEN "Flexitone" : *CHANNELVOICE 8 Flexitone
- tun%(8) = -8096
- WHEN "GongSoft" : *CHANNELVOICE 8 GongSoft
- tun%(8) = -5365
- WHEN "Gonza1" : *CHANNELVOICE 8 Gonza1
- tun%(8) = -12192
- WHEN "GuiroSlow" : *CHANNELVOICE 8 GuiroSlow
- tun%(8) = -6048
- WHEN "HandClaps" : *CHANNELVOICE 8 HandClaps
- tun%(8) = -4000
- WHEN "HiHatFoot" : *CHANNELVOICE 8 HiHatFoot
- tun%(8) = -6389
- WHEN "Maracas1" : *CHANNELVOICE 8 Maracas1
- tun%(8) = -8096
- WHEN "MarimbaSB3" : *CHANNELVOICE 8 MarimbaSB3
- tun%(8) = -4000
- WHEN "Ratchet" : *CHANNELVOICE 8 Ratchet
- tun%(8) = -6731
- WHEN "RotoTomRev" : *CHANNELVOICE 8 RotoTomRev
- tun%(8) = -6133
- WHEN "SimmonsBD1" : *CHANNELVOICE 8 SimmonsBD1
- tun%(8) = -8096
- WHEN "SimmonsSn1" : *CHANNELVOICE 8 SimmonsSn1
- tun%(8) = -5707
- WHEN "SleighBell" : *CHANNELVOICE 8 SleighBell
- tun%(8) = -4000
- WHEN "SuperGong" : *CHANNELVOICE 8 SuperGong
- tun%(8) = -4341
- WHEN "SynthSnare" : *CHANNELVOICE 8 SynthSnare
- tun%(8) = -4000
- WHEN "SynTom" : *CHANNELVOICE 8 SynTom
- tun%(8) = -9120
- WHEN "TimpCresBb" : *CHANNELVOICE 8 TimpCresBb
- tun%(8) = -5962
- WHEN "TimpLowBb" : *CHANNELVOICE 8 TimpLowBb
- tun%(8) = -5707
- WHEN "TimpRollEb" : *CHANNELVOICE 8 TimpRollEb
- tun%(8) = -4000
- WHEN "TomRoll" : *CHANNELVOICE 8 TomRoll
- tun%(8) = -4000
- WHEN "ToyHooter" : *CHANNELVOICE 8 ToyHooter
- tun%(8) = -9717
- WHEN "ToyWhistle" : *CHANNELVOICE 8 ToyWhistle
- tun%(8) = -4000
- ENDCASE
- ENDCASE
- :
- ELSE
- *CHANNELVOICE 1 WaveSynth-Beep
- *CHANNELVOICE 2 WaveSynth-Beep
- *CHANNELVOICE 3 WaveSynth-Beep
- *CHANNELVOICE 4 WaveSynth-Beep
- *CHANNELVOICE 5 WaveSynth-Beep
- *CHANNELVOICE 6 WaveSynth-Beep
- *CHANNELVOICE 7 WaveSynth-Beep
- *CHANNELVOICE 8 WaveSynth-Beep
- ENDIF
- :
- REM fill bar%() with starting bar nos for each voice
- PROCnewnotereception((vnumber%-1),startingbar%,startbeat%,0,0,0,0,0,0)
- CASE option% OF
- WHEN 1,3 : startcell% = 0
- WHEN 2 : startcell% = numusedcells%(vnumber%-1)
- WHEN 4 : start% = (startingbar%*10^3)+startbeat%
- voice% = vnumber%-1 : PROCsearch(start%)
- ENDCASE
- cell%(vnumber%-1) = startcell%
- bar%(vnumber%-1) = array%(cell%(vnumber%-1),0,vnumber%-1)DIV10^6
- NEXT
- :
- startbar% = startingbar% : preplaydisplay$ = "y" : PROCdisplay : preplaydisplay$ = "n"
- tempo% = tempi%(startingbar%)*960*0.681595
- IF waveload$ = "done" THEN tempo% = tempo%*1.23065
- TEMPO tempo%
- kount% = 1
- :
- FOR barnum% = startingbar% TO endbar%
- :
- IF playnewscreen$ = "y" AND ((startbar%+(numbars%*2)) <= nobars%) THEN
- IF barnum% = startingbar% + (numbars%*kount%) + 1 THEN
- startbar% += numbars% : preplaydisplay$ = "y" : PROCdisplay: kount% += 1
- preplaydisplay$ = "n"
- ENDIF
- ENDIF
- :
- tempo% = tempi%(barnum%-1)*960*0.681595
- IF waveload$ = "done" THEN tempo% = tempo%*1.23065
- TEMPO tempo%
- REPEAT UNTIL BEAT < 20
- :
- FOR count% = 1 TO nvoices%
- voicenum% = playvoices%(count%)-1
- lv$ = "n"
- IF lvdata%(count%,1)>0 THEN lv$ = "y"
- :
- WHILE bar%(voicenum%) = barnum%
- after% = ((array%(cell%(voicenum%),0,voicenum%) DIV 10^3) MOD 10^3) + 20
- pitchdata% = (array%(cell%(voicenum%),0,voicenum%)MOD10^3)
- notename% = pitchdata% DIV 100
- accid% = (pitchdata% MOD 100) DIV 10
- octave% = pitchdata%MOD10
- inflect% = (array%(cell%(voicenum%),2,voicenum%)MOD10^2) : inflect% -= 50
- :
- CASE notename% OF
- WHEN 6 : pitch% = 3755
- WHEN 5 : pitch% = 3072
- WHEN 4 : pitch% = 2389
- WHEN 3 : pitch% = 1707
- WHEN 2 : pitch% = 1365
- WHEN 1 : pitch% = 683
- WHEN 0 : pitch% = 0
- ENDCASE
- accid% = accid%-5
- accid% = accid%*85.34
- pitch% = pitch% + accid%
- pitch% = pitch% + (4096*octave%) + tun%(count%) + (inflect%*3.41)
- amp2% = (array%(cell%(voicenum%),2,voicenum%)DIV10^2)MOD10
- amp3% = (array%(cell%(voicenum%),2,voicenum%)DIV10^3)MOD10
- :
- dyn% = array%(cell%(voicenum%),1,voicenum%)MOD10
- dyn% = 257 + (16*dyn%)
- IF amp2% = 9 AND amp3% <> 0 THEN
- CASE amp3% OF
- WHEN 1 : dyn% += 1
- WHEN 2 : dyn% += 2
- WHEN 3 : dyn% += 4
- WHEN 4 : dyn% += 6
- WHEN 5 : dyn% += 8
- WHEN 6 : dyn% += 10
- WHEN 7 : dyn% += 12
- WHEN 8 : dyn% += 14
- WHEN 9 : dyn% += 15
- ENDCASE
- ENDIF
- IF dyn% > 383 THEN dyn% = 383
- :
- dur% = (array%(cell%(voicenum%),1,voicenum%)MOD10^4)DIV10
- IF waveload$ = "done" THEN dur% = dur%/1.23065
- IF dur% < 1 THEN dur% = 1
- IF lv$ = "n" THEN
- chan% = count%
- ELSE
- tic%(count%)+=1
- IF lvdata%(count%,tic%(count%)) = 0 THEN tic%(count%) = 1
- chan% = lvdata%(count%,tic%(count%))
- ENDIF
- :
- SOUND chan%, dyn%, pitch%, dur%, after%
- :
- IF amp2% <> 9 THEN PROCenv
- :
- cell%(voicenum%) += 1
- bar%(voicenum%) = array%(cell%(voicenum%),0,voicenum%) DIV 10^6
- :
- ENDWHILE
- :
- NEXT count%
- :
- REPEAT UNTIL BEAT > 20
- :
- NEXT barnum%
- :
- PROCpostdisplay
- :
- ENDPROC
- :
- REM*******************************
- :
- DEF PROCaddonenote
- :
- IF easiermenus$ = "n" THEN PROCwindow(20,72,72,55) ELSE PROCwindow(20,69,60,42)
- CLS
- INPUT' " Which voice (0 = top) "voice%
- IF voice% = 0 THEN PROCpressenter
- voice% -= 1
- INPUT '" Bar number (for 1 press 0) "barno%
- IF barno% = 0 THEN barno% = 1
- INPUT '" Beat number "beats%
- PROCalterbeats
- beatno% = beats%
- :
- PRINT '" Pitch name ";
- COLOUR 3
- CASE GET$ OF
- WHEN "C","c" : note% = 0 : PRINT "C"
- WHEN "D","d" : note% = 1 : PRINT "D"
- WHEN "E","e" : note% = 2 : PRINT "E"
- WHEN "F","f" : note% = 3 : PRINT "F"
- WHEN "G","g" : note% = 4 : PRINT "G"
- WHEN "A","a" : note% = 5 : PRINT "A"
- WHEN "B","b" : note% = 6 : PRINT "B"
- ENDCASE
- COLOUR 0
- PRINT '" Accidental ";
- COLOUR 3
- CASE GET$ OF
- WHEN "1" : accid% = 1 : PRINT "flat"
- WHEN "2" : accid% = 2 : PRINT "3/8flat"
- WHEN "3" : accid% = 3 : PRINT "1/4flat"
- WHEN "4" : accid% = 4 : PRINT "1/8flat"
- WHEN "5" : accid% = 5 : PRINT "nat"
- WHEN "6" : accid% = 6 : PRINT "1/8shrp"
- WHEN "7" : accid% = 7 : PRINT "1/4shrp"
- WHEN "8" : accid% = 8 : PRINT "3/8shrp"
- WHEN "9" : accid% = 9 : PRINT "shrp"
- ENDCASE
- COLOUR 0
- PRINT '" octave ";
- COLOUR 3
- CASE GET$ OF
- WHEN "0" : octave% = 0 : PRINT "0"
- WHEN "1" : octave% = 1 : PRINT "1"
- WHEN "2" : octave% = 2 : PRINT "2"
- WHEN "3" : octave% = 3 : PRINT "3"
- WHEN "4" : octave% = 4 : PRINT "4"
- WHEN "5" : octave% = 5 : PRINT "5"
- WHEN "6" : octave% = 6 : PRINT "6"
- WHEN "7" : octave% = 7 : PRINT "7"
- WHEN "8" : octave% = 8 : PRINT "8"
- ENDCASE
- COLOUR 0
- pitch% = (note%*100)+(accid%*10)+octave%
- INPUT '" Duration: bars "b%
- INPUT '" beats "beats% : PROCalterbeats
- dur% = (b%*960)+beats%
- :
- CLS
- :
- PRINT'" Envelope/glissando has how many phases? "
- INPUT'" (if no envelope/glissando type 0) "numphases%
- :
- CASE numphases% OF
- :
- WHEN 0 :
- INPUT'" ampitude is "amp$ : PROCconvertdynamics : amp1% = amp%
- ph2% = 0 : ph1% = 0 : amp4% = 0 : amp3% = 0 : amp2% = 9 : gliss3% = 10 : gliss2% = 50 : gliss1% = 50
- :
- WHEN 1 :
- INPUT'" starting amplitude is "amp$ : PROCconvertdynamics : amp1% = amp%
- INPUT " destination amplitude is "amp$ : PROCconvertdynamics : amp2% = amp%
- IF amp2% = amp1% THEN amp2% = 0
- INPUT'" glissando is (in 1/8 tones, max 48,-48) "gliss%
- gliss1% = 50-gliss%
- ph2% = 0 : ph1% = 0 : amp4% = 0 : amp3% = 0 : gliss3% = 10 : gliss2% = 50
- :
- WHEN 2 :
- INPUT'" starting amplitude is "amp$ : PROCconvertdynamics : amp1% = amp%
- PRINT'" phase 1 ends after what percentage "
- INPUT " of the note's duration "ph1%
- INPUT " phase 1's destination amplitude is "amp$ : PROCconvertdynamics : amp2% = amp%
- INPUT " phase 1's glissando is (in 1/8 tones, max 48,-48) "gliss%
- gliss1% = 50-gliss%
- INPUT'" phase 2's destination amplitude is "amp$ : PROCconvertdynamics : amp3% = amp%
- INPUT " phase 2's glissando is (in 1/8 tones, max 48,-48) "gliss%
- gliss2% = 50-gliss%
- ph2% = 0 : amp4% = 0 : gliss3% = 10
- :
- WHEN 3 :
- INPUT'" starting amplitude is "amp$ : PROCconvertdynamics : amp1% = amp%
- PRINT'" phase 1 ends after what percentage "
- INPUT " of the note's duration "ph1%
- INPUT " phase 1's destination amplitude is "amp$ : PROCconvertdynamics : amp2% = amp%
- INPUT " phase 1's glissando is (in 1/8 tones, max 48,-48) "gliss%
- gliss1% = 50-gliss%
- PRINT'" phase 2 ends after what percentage "
- INPUT " of the note's duration "ph2%
- INPUT'" phase 2's destination amplitude is "amp$ : PROCconvertdynamics : amp3% = amp%
- INPUT " phase 2's glissando is (in 1/8 tones, max 48,-48) "gliss%
- gliss2% = 50-gliss%
- INPUT'" phase 3's destination amplitude is "amp$ : PROCconvertdynamics : amp4% = amp%
- REPEAT
- INPUT " phase 3's glissando is (in 1/8 tones, max 10,-10) "gliss%
- gliss3% = 10-gliss%
- IF gliss3% > 20 THEN VDU7
- IF gliss3% < 0 THEN VDU7
- UNTIL gliss3% < 21 AND gliss3% >= 0
- :
- ENDCASE
- :
- env% = (ph2%*10^5)+(ph1%*10^3)+(amp4%*10^2)+(amp3%*10)+amp2%
- dyn% = amp1%
- gliss% = (gliss3%*10^4)+(gliss2%*10^2)+gliss1%
- :
- PRINT '" Microtonal inflection "
- INPUT'" (in cents, eg 1, -1, etc., max.49) "inf%
- inf% = 50+inf%
- :
- addingnotes$ = "y"
- PROCnewnotereception(voice%,barno%,beatno%,pitch%,dyn%,env%,dur%,gliss%,inf%)
- :
- PROCdisplay
- :
- ENDPROC
- :
- REM*************************************
- :
- DEF PROCinsertattacks
- :
- PROCundoprepare
- :
- destinationdone$ = "n"
- :
- CASE savevoice$ OF
- WHEN "Y" : PROCsavevoice
- OTHERWISE
- ENDCASE
- REM PROCwindow(20,69,70,55)
- CLS
- repeatposit$ = "n"
- IF method$ = "raw" THEN
- IF reordered$ = "n" THEN
- IF equalized$ = "n" THEN
- IF quiz$ = "yes" THEN
- IF copyit$ = "ON" THEN
- :
- IF copydownwards$ = "n" THEN
- PRINT ' " the passage is to be copied/moved to bar... "
- PRINT ' " (press 0 for same position as original "
- PRINT " or forward/back from it by so much) "
- INPUT ' " (press 0 twice for previous position) "bars%
- IF bars% <> 0 THEN memorybar% = bars%
- IF bars% = 0 THEN
- bars% = holdbar% : beats% = holdbeat% : repeatposit$ = "y"
- IF askprevious$ = "y" THEN
- thing$ = INKEY$(50)
- IF thing$ <> "" THEN
- bars% = memorybar% : beats% = memorybeat%
- COLOUR 3
- PRINT'" bar ";bars%;" beat ";beats%;"?"
- COLOUR 0
- PRINT '" (for OK press 0, if not OK press X) "
- destinationdone$ = "y"
- CASE GET$ OF
- WHEN "X","x" : PROCinsertattacks
- OTHERWISE
- ENDCASE
- ENDIF
- ENDIF
- ENDIF
- ELSE bars% = holdbar% : beats% = holdbeat% : repeatposit$ = "y"
- :
- ENDIF
- :
- ELSE
- :
- PRINT' " the passage is to start at bar "
- INPUT' " (0 = first bar displayed) "bars%
- IF bars% = 0 THEN
- bars% = startbar%
- COLOUR 3 : PRINT' bars% : COLOUR 0
- nothing$ = INKEY$(100)
- ENDIF
- :
- ENDIF : REM copyit$
- :
- IF repeatposit$ = "n" THEN
- INPUT' " beat "beats%
- IF beats% = 0 THEN
- COLOUR 3 : PRINT beats% : COLOUR 0
- nothing$ = INKEY$(100)
- ENDIF
- memorybeat% = beats%
- ELSE
- :
- IF copydownwards$ = "n" AND destinationdone$ = "n" THEN
- COLOUR 3
- PRINT'" bar ";bars%;" beat ";beats%;"?"
- COLOUR 0
- PRINT'" (press 0 for OK, B for Back"
- PRINT " F for Forward, X if not OK)"
- CASE GET$ OF
- WHEN "b", "B" : PROCmoveback
- WHEN "f", "F" : PROCmoveforward
- WHEN "x","X" : PROCinsertattacks
- OTHERWISE
- ENDCASE
- ELSE
- ENDIF
- :
- ENDIF : REM repeatposit$
- :
- ELSE
- bars% = funcbar% : beats% = funcbeat%
- ENDIF : REM quiz$
- :
- quiz$ = "yes"
- PROCalterbeats
- startat% = (bars%*(10^3))+beats%
- ENDIF : REM equalized$
- ENDIF : REM reordered$
- :
- reordered$ = "n" : equalized$ = "n"
- :
- attacks2%() = attacks1%()
- :
- attacks2%() = attacks2%() + (startat% MOD 10^3) : REM moves attacks further up bar, if necc
- :
- attacks3%() = attacks2%()
- FOR count% = 0 TO (manyattacks%-1)
- attacks3%(count%) = attacks3%(count%) DIV 960
- NEXT
- REM gives list of bar mos starting at 0
- :
- attacks3%() = attacks3%() * 960
- attacks2%() = attacks2%() - attacks3%()
- attacks3%() = attacks3%() / 960
- REM list of actual beat numbers
- :
- attacks3%() = attacks3%() + (startat% DIV 10^3) : REM list of actual bar nos
- :
- attacks3%() = attacks3%()*(10^3)
- attacks2%() = attacks2%() + attacks3%()
- REM list of actual bar/beat numbers
- :
- ENDIF : REM method$
- :
- : IF method$ <> "alreadyrhythmicized" THEN rhythmicized$ = "n"
- IF seeinfo$ = "y" THEN
- :
- IF printinfo$ = "y" THEN PROCprintattacks
- durat% = 0
- PROCwindow(10,60,90,5)
- VDU 14
- PRINT '" The group of attacks will be at "
- PRINT" "
- PRINT TAB(8) "ATTACKS AT";
- PRINT TAB(30) "DURATIONS";
- PRINT TAB(54) "RATIOS"
- FOR count% = 0 TO (manyattacks%-1)
- COLOUR 3 : PRINT TAB(1)(attacks2%(count%))DIV10^3;" ";
- COLOUR 0 : PRINT ;(attacks2%(count%))MOD10^3;
- IF count% > 0 THEN
- durat1% = durat%
- durat% = (attacks2%(count%)MOD10^3)-(attacks2%(count%-1)MOD10^3)
- addon% = ((attacks2%(count%)DIV(10^3))-(attacks2%(count%-1)DIV(10^3)))*960
- durat% = durat% + addon%
- PRINT TAB(26) durat%;
- IF count%>1 THEN
- IF direction$ = "rit" THEN ratio = durat%/durat1% ELSE ratio = durat1%/durat%
- CASE ratio OF
- WHEN 0.5 : PRINT TAB(52) "0.5"
- WHEN 1.0 : PRINT TAB(52) "1.0"
- WHEN 1.5 : PRINT TAB(52) "1.5"
- WHEN 2.0 : PRINT TAB(52) "2.0"
- WHEN 2.5 : PRINT TAB(52) "2.5"
- OTHERWISE PRINT TAB(52) ratio
- ENDCASE
- ENDIF
- ENDIF
- NEXT
- :
- VDU 15
- :
- ENDIF : REM seeinfo
- :
- IF method$ = "raw" THEN
- IF seereordery$ = "y" THEN
- PRINT'" Do you want this group to be re-ordered?"
- PRINT'" (Y/1 = yes, any other key = no) "
- :
- CASE GET$ OF
- WHEN "Y","y","1" : PROCreorderattacks
- OTHERWISE
- ENDCASE
- seereordery$ = "n"
- rhythmicized$ = "n"
- ENDIF
- IF seeequalizey$ = "y" THEN
- PRINT'" Do you want to equalize any durations? "
- PRINT'" (Y/0/1 = yes, N/2 = no) "
- CASE GET$ OF
- WHEN "n","N","2" :
- OTHERWISE PROCequalizedurats
- ENDCASE
- seeequalizey$ = "n"
- ENDIF
- IF seerhythmicize$ = "y" THEN
- PRINT'" Do you want this group to be rhythmicized? "
- CASE GET$ OF
- WHEN "Y","y" : PROCprerhythmicize
- rhythmicized$ = "y"
- OTHERWISE
- ENDCASE
- ENDIF
- ENDIF : REM method$ = raw?
- IF seequery$ = "y" THEN
- PRINT ' " Do you want to add this group to the array? "
- CASE GET$ OF
- WHEN "N","n" : PROCdisplay : REM attacks1%() remains intact until a new group of attacks is defined with PROCseriesattacks, and so may be add to array anywhere else
- OTHERWISE
- ENDCASE
- ENDIF : REM seequery
- :
- IF displayedfunc$ = "n" THEN
- :
- IF copydownwards$ = "n" THEN
- IF screenvoices$ = "n" THEN
- :
- IF copysuccessively$ = "y" THEN
- INPUT' " Which voice (0 = top)"voice%
- IF voice% <> 0 THEN succto% = voice% ELSE PROCpressenter
- ELSE
- INPUT'" Which voice (0 = top) "voice%
- IF voice% = 0 THEN PROCpressenter
- ENDIF : REM copysuccessively$
- :
- ELSE
- PRINT'" Which screen voice "
- CASE GET$ OF
- WHEN "1" : voice% = 1
- WHEN "2" : voice% = 2
- WHEN "3" : voice% = 3
- OTHERWISE PROCpressenter
- ENDCASE
- ENDIF
- IF screenvoices$ = "y" AND voice% > 0 THEN voice% = displayvoices%(startv%+voice%-1)
- voice% -= 1
- IF voice% >= 0 THEN samevoice% = voice%
- IF voice% = -1 THEN
- IF copysuccessively$ = "n" THEN
- voice% = samevoice%
- ELSE
- voice% = succto%-1
- ENDIF : REM copysucc
- ENDIF : REM if voice = -1
- :
- ELSE voice% = displayvoices%(startv%+downby%) : voice% = voice%-1
- ENDIF
- :
- ENDIF
- :
- IF copyit$ = "OFF" THEN
- IF paraset$ = "on" THEN
- PRINT'" Do you want to (re)define the values assigned "
- PRINT " to each parameter when inputting a group of "
- PRINT " attacks, use defaults or reset defaults? "
- PRINT " (press Y/N/D/R)"
- PRINT'" - press M/V/D/P again to go back to always "
- PRINT " using the assigned values without asking "
- CASE GET$ OF
- WHEN "R","r" : resetdefaults$ = "y"
- PRINT'" Please press the same key again to proceed"
- OTHERWISE
- PRINT'" Please press the same key again to proceed"
- ENDCASE
- :
- CASE GET$ OF
- WHEN "Y","y","R","r" :
- CLS : parasdefined$ = "yes" : PRINT' " all at pitch name ";
- COLOUR 3
- CASE GET$ OF
- WHEN "C","c" : note% = 0 : PRINT "C"
- WHEN "D","d" : note% = 1 : PRINT "D"
- WHEN "E","e" : note% = 2 : PRINT "E"
- WHEN "F","f" : note% = 3 : PRINT "F"
- WHEN "G","g" : note% = 4 : PRINT "G"
- WHEN "A","a" : note% = 5 : PRINT "A"
- WHEN "B","b" : note% = 6 : PRINT "B"
- ENDCASE
- COLOUR 0
- PRINT " accidental ";
- COLOUR 3
- CASE GET$ OF
- WHEN "1" : accid% = 1 : PRINT "flat"
- WHEN "2" : accid% = 2 : PRINT "3/8flat"
- WHEN "3" : accid% = 3 : PRINT "1/4flat"
- WHEN "4" : accid% = 4 : PRINT "1/8flat"
- WHEN "5" : accid% = 5 : PRINT "nat"
- WHEN "6" : accid% = 6 : PRINT "1/8shrp"
- WHEN "7" : accid% = 7 : PRINT "1/4shrp"
- WHEN "8" : accid% = 8 : PRINT "3/8shrp"
- WHEN "9" : accid% = 9 : PRINT "shrp"
- ENDCASE
- COLOUR 0
- PRINT " octave ";
- COLOUR 3
- CASE GET$ OF
- WHEN "0" : octave% = 0 : PRINT "0"
- WHEN "1" : octave% = 1 : PRINT "1"
- WHEN "2" : octave% = 2 : PRINT "2"
- WHEN "3" : octave% = 3 : PRINT "3"
- WHEN "4" : octave% = 4 : PRINT "4"
- WHEN "5" : octave% = 5 : PRINT "5"
- WHEN "6" : octave% = 6 : PRINT "6"
- WHEN "7" : octave% = 7 : PRINT "7"
- WHEN "8" : octave% = 8 : PRINT "8"
- ENDCASE
- COLOUR 0
- pitchset%(voice%) = (note%*100)+(accid%*10)+octave%
- IF resetdefaults$ = "y" THEN
- FOR count% = 0 TO (numparts%-1)
- pitchset%(count%) = pitchset%(voice%)
- NEXT
- ENDIF
- INPUT " all at duration: bars "b%
- INPUT " beats "beats% : PROCalterbeats
- dur% = (b%*960)+beats%
- durset%(voice%) = dur%
- IF resetdefaults$ = "y" THEN
- FOR count% = 0 TO (numparts%-1)
- durset%(count%) = durset%(voice%)
- NEXT
- ENDIF
- :
- INPUT " all at amplitude "amp$
- CASE amp$ OF
- WHEN "0" : ampset%(voice%) = 0
- WHEN "ppp" : ampset%(voice%) = 1
- WHEN "pp" : ampset%(voice%) = 2
- WHEN "p" : ampset%(voice%) = 3
- WHEN "mp" : ampset%(voice%) = 4
- WHEN "mf" : ampset%(voice%) = 5
- WHEN "f" : ampset%(voice%) = 6
- WHEN "ff" : ampset%(voice%) = 7
- WHEN "fff" : ampset%(voice%) = 8
- ENDCASE
- IF resetdefaults$ = "y" THEN
- FOR count% = 0 TO (numparts%-1)
- ampset%(count%) = ampset%(voice%)
- NEXT
- ENDIF
- :
- INPUT " all at microtonal inflection (in cents: 1,-1 etc) [max 49,-49]: "infset%
- infset%(voice%) = 50+infset%
- envset%(voice%) = 9
- glissset%(voice%) = 105050
- resetdefaults$ = "n"
- WHEN "D","d" : pitchset%(voice%) = 55
- ampset%(voice%) = 6
- envset%(voice%) = 9
- durset%(voice%) = 319
- glissset%(voice%) = 105050
- infset%(voice%) = 50
- OTHERWISE
- ENDCASE
- ENDIF
- ENDIF
- :
- addingnotes$ = "y"
- IF copyit$ = "OFF" THEN
- IF rhythmicized$ = "n" THEN
- FOR counter% = 0 TO (manyattacks%-1)
- PROCnewnotereception(voice%,(attacks2%(counter%)DIV10^3), (attacks2%(counter%) MOD 10^3), pitchset%(voice%), ampset%(voice%), envset%(voice%), durset%(voice%), glissset%(voice%), infset%(voice%))
- NEXT
- ELSE
- FOR counter% = 0 TO (manyattacks%-1)
- PROCnewnotereception(voice%,(attacks5%(counter%)DIV10^3), (attacks5%(counter%) MOD 10^3), pitchset%(voice%), ampset%(voice%), envset%(voice%), durset%(voice%), glissset%(voice%), infset%(voice%))
- NEXT
- PROCdisarrayfill
- ENDIF
- ELSE
- IF rhythmicized$ = "n" THEN
- FOR counter% = 0 TO (manyattacks%-1)
- PROCnewnotereception(voice%, (attacks2%(counter%)DIV10^3), (attacks2%(counter%)MOD10^3), pitches%(counter%), amplitudes%(counter%), envelopes%(counter%), durations%(counter%), glissandos%(counter%), inflections%(counter%))
- NEXT
- ELSE
- FOR counter% = 0 TO (manyattacks%-1)
- PROCnewnotereception(voice%, (attacks5%(counter%)DIV10^3), (attacks5%(counter%)MOD10^3), pitches%(counter%), amplitudes%(counter%), envelopes%(counter%), durations%(counter%), glissandos%(counter%), inflections%(counter%))
- NEXT
- PROCdisarrayfill
- ENDIF
- :
- ENDIF
- :
- copyit$ = "OFF" : displayedfunc$ = "n" : copydownwards$ = "n" : justone$ = "n"
- quickextract$ = "n"
- PROCdisplay
- :
- ENDPROC
- :
- REM*********************************************
- :
- DEF PROCseriespitches
- :
- IF easiermenus$ = "n" THEN PROCwindow(20,69,60,55) ELSE PROCwindow(20,69,60,42)
- :
- IF usebottomstave$ = "n" THEN
- :
- IF singlepitch$ = "m" THEN
- IF firstpitch$ = "y" THEN
- PRINT' " How many pitches "
- INPUT' " (for 1 press 0) "numpitches%
- ELSE
- PRINT' " How many pitches "
- PRINT' " (for 1 press 0,";
- PRINT " for "; prevnumpitches%;
- INPUT " press 0 twice) "numpitches%
- IF numpitches% = 0 THEN
- wait$ = INKEY$(50)
- IF wait$ <> "" THEN numpitches% = prevnumpitches%
- ENDIF
- ENDIF
- ELSE
- numpitches% = 1
- ENDIF
- :
- ELSE
- numpitches% = howmany%
- ENDIF
- :
- IF numpitches% = 0 THEN numpitches% = 1
- IF numpitches% > 1 THEN
- :
- IF askaboutpitches$ = "y" THEN
- PRINT'" Are the pitches all the same?"
- PRINT'" (0/1 count as yes, 2 counts as no) "
- CASE GET$ OF
- WHEN "N","n","2" :
- OTHERWISE PROCsamepitches
- ENDCASE
- ELSE PROCsamepitches
- ENDIF
- :
- ENDIF
- :
- FOR count% = 0 TO numpitches% - 1
- PRINT' " Note name for pitch ";count%+1;" is ";
- COLOUR 3
- CASE GET$ OF
- WHEN "C","c" : note% = 0 : PRINT "C"
- WHEN "D","d" : note% = 1 : PRINT "D"
- WHEN "E","e" : note% = 2 : PRINT "E"
- WHEN "F","f" : note% = 3 : PRINT "F"
- WHEN "G","g" : note% = 4 : PRINT "G"
- WHEN "A","a" : note% = 5 : PRINT "A"
- WHEN "B","b" : note% = 6 : PRINT "B"
- ENDCASE
- COLOUR 0
- PRINT' " accidental ";
- COLOUR 3
- CASE GET$ OF
- WHEN "1" : accid% = 1 : PRINT "flat"
- WHEN "2" : accid% = 2 : PRINT "3/8flat"
- WHEN "3" : accid% = 3 : PRINT "1/4flat"
- WHEN "4" : accid% = 4 : PRINT "1/8flat"
- WHEN "5" : accid% = 5 : PRINT "nat"
- WHEN "6" : accid% = 6 : PRINT "1/8shrp"
- WHEN "7" : accid% = 7 : PRINT "1/4shrp"
- WHEN "8" : accid% = 8 : PRINT "3/8shrp"
- WHEN "9" : accid% = 9 : PRINT "shrp"
- ENDCASE
- COLOUR 0
- PRINT '" octave ";
- COLOUR 3
- CASE GET$ OF
- WHEN "0" : octave% = 0 : PRINT "0"
- WHEN "1" : octave% = 1 : PRINT "1"
- WHEN "2" : octave% = 2 : PRINT "2"
- WHEN "3" : octave% = 3 : PRINT "3"
- WHEN "4" : octave% = 4 : PRINT "4"
- WHEN "5" : octave% = 5 : PRINT "5"
- WHEN "6" : octave% = 6 : PRINT "6"
- WHEN "7" : octave% = 7 : PRINT "7"
- WHEN "8" : octave% = 8 : PRINT "8"
- ENDCASE
- COLOUR 0
- pitches%(count%) = (note%*100)+(accid%*10)+octave%
- NEXT
- :
- prevnumpitches% = numpitches% : firstpitch$ = "n"
- REM function can feed pitches similarly into pitches%
- :
- PROCinsertpitches
- :
- ENDPROC
- :
- REM************************************************
- :
- DEF PROCinsertpitches
- :
- CLS
- :
- IF reorderpitches$ = "y" THEN
- PRINT'" Do you want to randomly re-order"
- PRINT " the pitches (0 = yes, 2 = no)"
- CASE GET$ OF
- WHEN "2" :
- OTHERWISE
- CLS
- PRINT'" Randomly reorder pitches in batches of "
- INPUT " between how many (0 = previous) "low%
- IF low% = 0 THEN
- low% = previouslow%
- COLOUR 3
- PRINT low%
- COLOUR 0
- wait$ = INKEY$(50)
- ENDIF
- INPUT'" and how many "high%
- IF high% = 0 THEN
- high% = previoushigh%
- COLOUR 3
- PRINT high%
- COLOUR 0
- wait$ = INKEY$(50)
- ENDIF
- :
- startingcell% = 0
- pitches1%() = 0
- pitches2%() = 0
- pitches1%() = pitches%()
- REPEAT
- diff% = high%-low%
- batchsize% = RND(diff%+1)-1
- batchsize% += low%
- counter% = 0
- REPEAT
- cell% = RND(batchsize%)
- cell% = startingcell% + cell% - 1
- IF pitches1%(cell%) <> 0 THEN
- pitches2%(startingcell%+counter%) = pitches1%(cell%)
- counter% += 1
- ENDIF
- pitches1%(cell%) = 0
- check% = 0
- FOR count% = 1 TO batchsize%
- check% += pitches1%(startingcell%+count%-1)
- NEXT
- UNTIL check% = 0
- startingcell% += batchsize%
- UNTIL (numpitches%-high%) < startingcell%
- FOR count% = 0 TO numpitches%-1
- IF pitches2%(count%) <> 0 THEN
- pitches%(count%) = pitches2%(count%)
- ENDIF
- NEXT
- previouslow% = low%
- previoushigh% = high%
- ENDCASE
- ENDIF : REM reorderpitches$
- :
- repeatposit$ = "n"
- IF seequery$ = "y" THEN
- PRINT ' " Do you want to read these pitches "
- PRINT " into the array? "
- CASE GET$ OF
- WHEN "N","n" : PROCdisplay : REM pitches% remains intact
- OTHERWISE
- ENDCASE
- ENDIF : REM seequery$
- :
- IF usebottomstave$ = "n" THEN
- IF screenvoices$ = "n" THEN
- :
- IF copysuccessively$ = "n" THEN
- INPUT'' " Which voice? (0 = top) "voice%
- IF voice% = 0 THEN PROCpressenter
- ELSE PROCcopysuccessively
- ENDIF
- :
- ELSE
- PRINT'" Which screen voice "
- CASE GET$ OF
- WHEN "1" : voice% = 1
- WHEN "2" : voice% = 2
- WHEN "3" : voice% = 3
- OTHERWISE PROCpressenter
- ENDCASE
- ENDIF
- ENDIF : REM usebottomstave$
- :
- IF screenvoices$ = "y" AND voice% > 0 THEN voice% = displayvoices%(startv%+voice%-1)
- IF usebottomstave$ = "y" THEN voice% = displayvoices%(startv%+2)
- voice% -= 1
- IF voice% >= 0 THEN samevoice% = voice%
- IF voice% = -1 THEN voice% = samevoice%
- :
- IF usebottomstave$ = "n" THEN
- :
- IF quickcopy$ = "y" THEN
- INPUT ' " starting at note number (0 counts as 1) "along%
- IF along% = 0 THEN along% = 1
- along%-=1
- bars% = array%(holdstartcell%(voice%)+along%,0,voice%)DIV10^6
- beats% = (array%(holdstartcell%(voice%)+along%,0,voice%)MOD10^6)DIV10^3
- holdbar% = bars%
- holdbeat% = beats%
- PROCalterbeats
- startat% = (bars%*(10^3))+beats%
- :
- ELSE
- :
- INPUT'" Starting at bar number "bars%
- IF bars% = 0 THEN
- bars% = holdbar% : beats% = holdbeat% : repeatposit$ = "y"
- ENDIF
- holdbar% = bars%
- IF repeatposit$ = "y" THEN
- PRINT'" bar ";bars%;" beat ";beats%;"?"
- PRINT'" (for OK press 0, if not OK press X)"
- CASE GET$ OF
- WHEN"X","x" : PROCinsertpitches
- OTHERWISE
- ENDCASE
- ELSE
- INPUT " beat "beats%
- holdbeat% = beats%
- ENDIF
- PROCalterbeats
- startat% = (bars%*(10^3))+beats%
- :
- ENDIF : REM quickcopy$
- :
- ELSE
- along% = 0
- bars% = array%(holdstartcell%(voice%)+along%,0,voice%)DIV10^6
- beats% = (array%(holdstartcell%(voice%)+along%,0,voice%)MOD10^6)DIV10^3
- holdbar% = bars%
- holdbeat% = beats%
- PROCalterbeats
- startat% = (bars%*(10^3))+beats%
- :
- ENDIF : REM usebottomstave$
- :
- PROCsearch(startat%)
- shunt$ = "N"
- :
- endcell% = startcell% + numpitches% -1
- IF endcell% >= numusedcells%(voice%) THEN endcell% = numusedcells%(voice%)-1
- FOR count% = startcell% TO endcell%
- PROCcellfill(count%,voice%,999,999,(pitches%(count%-startcell%)),9,999,999,99,99)
- NEXT
- :
- PROCdisplay
- :
- ENDPROC
- :
- REM*************************************************
- :
- DEF PROCfunctionprelude
- :
- IF seereorderx$ = "y" THEN seereordery$ = "y"
- IF seeequalizex$ = "y" THEN seeequalizey$ = "y"
- :
- IF easiermenus$ = "n" THEN PROCwindow(20,69,60,55) ELSE PROCwindow(20,69,60,42)
- CLS
- CASE startfinishdurats$ OF
- WHEN "N", "n" :
- INPUT' " rate "rate
- IF rate = 0 THEN rate = 1 : REM for quick inputting
- IF rate <> 1 THEN
- INPUT'" bias (for 3.7 press 0) "bias
- IF bias = 0 THEN bias = 3.7
- ENDIF
- INPUT'" number of attacks "manyattacks%
- IF manyattacks% = 0 THEN manyattacks% = prevmanyattacks%
- COLOUR 3 : PRINT'manyattacks% : COLOUR 0
- prevmanyattacks% = manyattacks%
- CASE funcinput$ OF
- WHEN "durat" :
- PRINT '" total duration "
- INPUT' " bars "bars%
- INPUT' " beats "beats%
- PROCalterbeats
- totaldur% = (bars%*960)+beats%
- WHEN "points" :
- INPUT '" first attack at bar "funcbar%
- INPUT '" beat "funcbeat%
- INPUT '" and last attack at bar "funcbar1%
- INPUT '" beat "funcbeat1%
- totaldur% = ((funcbar1%*960)+funcbeat1%)-((funcbar%*960)+funcbeat%)
- WHEN "displayed" :
- IF screenvoices$ = "n" THEN
- INPUT' " Which voice (0 = top) "voice%
- IF voice% = 0 THEN PROCpressenter
- :
- ELSE
- PRINT'" Which screen voice "
- CASE GET$ OF
- WHEN "1" : voice% = 1
- WHEN "2" : voice% = 2
- WHEN "3" : voice% = 3
- OTHERWISE PROCpressenter
- ENDCASE
- ENDIF
- IF screenvoices$ = "y" AND voice% > 0 THEN voice% = displayvoices%(startv%+voice%-1)
- voice% -= 1
- IF voice% = -1 THEN voice% = samevoice% ELSE samevoice% = voice%
- IF queryalong$ = "y" THEN
- INPUT' " Starting at note number (0 counts as 1) "along%
- IF along% = 0 THEN along% = 1
- along%-=1
- ENDIF
- funcbar% = array%(holdstartcell%(voice%)+along%,0,voice%)DIV10^6
- funcbeat% = (array%(holdstartcell%(voice%)+along%,0,voice%)MOD10^6)DIV10^3
- funcbar1% = array%(holdstartcell%(voice%)+1+along%,0,voice%)DIV10^6
- funcbeat1% = (array%(holdstartcell%(voice%)+1+along%,0,voice%)MOD10^6)DIV10^3
- totaldur% = ((funcbar1%*960)+funcbeat1%)-((funcbar%*960)+funcbeat%)
- displayedfunc$ = "y" : along% = 0
- OTHERWISE PROCfunctionprelude
- ENDCASE
- :
- result$ = "success"
- :
- PROCfunction
- IF rate <> 1 AND seegraph$ = "y" THEN
- REM PROCwindow(20,69,50,55)
- PRINT'" Do you want to see the graph? "
- CASE GET$ OF
- WHEN "Y","y" : PROCgraph
- OTHERWISE PROCfunctionpostlude
- ENDCASE
- ELSE
- PROCfunctionpostlude
- ENDIF
- ENDCASE
- :
- CASE funcinput$ OF
- WHEN "durat" :
- REM PROCwindow(20,69,69,55)
- PRINT' " total duration "
- INPUT' " bars "bars%
- INPUT' " beats "beats%
- PROCalterbeats
- totaldur% = (bars%*960)+beats%
- WHEN "points" :
- REM PROCwindow(20,69,69,55)
- INPUT' " first attack at bar "funcbar%
- INPUT' " beat "funcbeat%
- INPUT' " and last attack at bar "funcbar1%
- INPUT' " beat "funcbeat1%
- totaldur% = ((funcbar1%*960)+funcbeat1%)-((funcbar%*960)+funcbeat%)
- WHEN "displayed" :
- IF screenvoices$ = "n" THEN
- INPUT' " Which voice (0 = top) "voice%
- IF voice% = 0 THEN PROCpressenter
- ELSE
- PRINT'" Which screen voice "
- CASE GET$ OF
- WHEN "1" : voice% = 1
- WHEN "2" : voice% = 2
- WHEN "3" : voice% = 3
- OTHERWISE PROCpressenter
- ENDCASE
- ENDIF
- IF screenvoices$ = "y" AND voice% > 0 THEN voice% = displayvoices%(startv%+voice%-1)
- voice% -= 1
- IF voice% = -1 THEN voice% = samevoice%
- funcbar% = array%(holdstartcell%(voice%)+along%,0,voice%)DIV10^6
- funcbeat% = (array%(holdstartcell%(voice%)+along%,0,voice%)MOD10^6)DIV10^3
- funcbar1% = array%(holdstartcell%(voice%)+1+along%,0,voice%)DIV10^6
- funcbeat1% = (array%(holdstartcell%(voice%)+1+along%,0,voice%)MOD10^6)DIV10^3
- totaldur% = ((funcbar1%*960)+funcbeat1%)-((funcbar%*960)+funcbeat%)
- displayedfunc$ = "y" : along% = 0
- OTHERWISE PROCfunctionprelude
- ENDCASE
- :
- IF easiermenus$ = "n" THEN PROCwindow(20,69,69,54) ELSE PROCwindow(20,69,69,42)
- :
- IF firsttimequick$ = "y" THEN
- PRINT' " quick end duration to be... "
- INPUT' " bars "bars%
- INPUT' " beats "beats%
- ELSE
- PRINT' " quick end duration to be how many bars "
- PRINT' " (for ";prevbars%;" press 0) "
- INPUT " "bars%
- :
- IF bars% = 0 THEN
- COLOUR 3 : PRINT prevbars% : COLOUR 0
- ENDIF
- :
- PRINT' " and how many beats "
- PRINT' " (for ";prevbeats%;" press 0) "
- INPUT " "beats%
- :
- IF beats% = 0 THEN
- COLOUR 3 : PRINT prevbeats% : COLOUR 0
- ENDIF
- IF bars% = 0 AND beats% = 0 THEN
- bars% = prevbars% : beats% = prevbeats%
- ENDIF
- ENDIF
- prevbars% = bars%
- prevbeats% = beats%
- PROCalterbeats
- quickend% = (bars%*960)+beats%
- :
- IF firsttimequick$ = "y" THEN
- PRINT' " slow end duration to be... "
- INPUT' " bars "bars%
- INPUT' " beats "beats%
- ELSE
- PRINT' " slow end duration to be how many bars "
- PRINT' " (for ";prevslowbars%;" press 0) "
- INPUT " "bars%
- :
- IF bars% = 0 THEN
- COLOUR 3 : PRINT prevslowbars% : COLOUR 0
- ENDIF
- :
- PRINT' " and how many beats "
- PRINT' " (for ";prevslowbeats%;" press 0) "
- INPUT " "beats%
- :
- IF beats% = 0 THEN
- COLOUR 3 : PRINT prevslowbeats% : COLOUR 0
- nothing$ = INKEY$(100)
- ENDIF
- :
- IF bars% = 0 AND beats% = 0 THEN
- bars% = prevslowbars% : beats% = prevslowbeats%
- ENDIF
- ENDIF
- prevslowbars% = bars%
- prevslowbeats% = beats%
- PROCalterbeats
- slowend% = (bars%*960)+beats%
- :
- CLS
- IF firsttimequick$ = "y" THEN
- INPUT' " bias (0 = 3.7) "bias
- IF bias = 0 THEN bias = 3.7
- ELSE
- PRINT' " bias "
- PRINT' " (for ";bias;" press 0) "
- INPUT' " "newbias
- :
- IF newbias = 0 THEN
- COLOUR 3 : PRINT bias : COLOUR 0
- ELSE bias = newbias
- ENDIF
- :
- ENDIF
- :
- IF firsttimequick$ = "y" THEN
- INPUT' " estimated number of attacks "manyattacks%
- ELSE
- PRINT' " estimated number of attacks "
- PRINT' " (for ";prevest%;" press 0) "
- INPUT' " "manyattacks%
- :
- IF manyattacks% = 0 THEN
- COLOUR 3 : PRINT prevest% : COLOUR 0
- nothing$ = INKEY$(100)
- ENDIF
- :
- IF manyattacks% = 0 THEN manyattacks% = prevest%
- ENDIF
- prevest% = manyattacks%
- firsttimequick$ = "n"
- :
- rate = 5.1 : increment = 4
- increment2% = manyattacks%
- ratedir$ = "" : attacksdir$ = ""
- result$ = "noresult"
- doesitloop$ = "" : maybeloop$ = ""
- manyattacks1% = 0 : manyattacks2% = 0 : manyattacks3% = 0 : manyattacks4% = 0 : manyattacks5% = 0
- rate1=0 : rate2=0 : rate3=0 : rate4=0 : rate5=0
- testquickend1% = 0 : testslowend1% = 0
- testquickend% = 0 : testslowend% = 0
- numberoftries%=0
- goes% = 0 : goes1% = 0
- :
- REPEAT
- :
- PROCfunction
- testquickend1% = testquickend%
- testslowend1% = testslowend%
- testquickend% = functionattacks(1)
- testslowend% = functionattacks(manyattacks%-1) - functionattacks(manyattacks%-2)
- manyattacks5% = manyattacks4% : manyattacks4% = manyattacks3%
- manyattacks3% = manyattacks2% : manyattacks2% = manyattacks1%
- manyattacks1% = manyattacks%
- rate5=rate4 : rate4=rate3 : rate3=rate2 : rate2=rate1 : rate1=rate
- IF testquickend% =quickend% AND testslowend% = slowend% THEN
- result$ = "success"
- ENDIF
- :
- IF result$ = "noresult" THEN
- :
- IF testquickend% <= quickend% AND testslowend% >= slowend% THEN
- IF ratedir$ = "up" THEN increment = increment/2.1
- IF increment < 0.01 THEN increment = 0.01
- ratedir$ = "down"
- rate = rate-increment
- IF rate < 1.01 THEN rate = 1.01
- ENDIF
- :
- IF testquickend% >= quickend% AND testslowend% <= slowend% THEN
- IF ratedir$ = "down" THEN increment = increment/2.1
- IF increment < 0.01 THEN increment = 0.01
- ratedir$ = "up"
- rate = rate+increment
- ENDIF
- :
- IF testquickend% < quickend% AND testslowend% < slowend% THEN
- IF attacksdir$ = "up" THEN increment2% = increment2%/2
- IF increment2% < 1 THEN increment2% = 1
- attacksdir$ = "down"
- manyattacks% = manyattacks% - increment2%
- IF manyattacks% < 4 THEN manyattacks% = 4
- ENDIF
- :
- IF testquickend% > quickend% AND testslowend% > slowend% THEN
- IF attacksdir$ = "down" THEN increment2% = increment2%/2
- IF increment2% < 1 THEN increment2% = 1
- attacksdir$ = "up"
- manyattacks% = manyattacks% + increment2%
- IF manyattacks% < 4 THEN manyattacks% = 4
- ENDIF
- :
- ENDIF
- :
- IF manyattacks% = manyattacks2% AND manyattacks% = manyattacks4% AND manyattacks1% = manyattacks3% AND manyattacks1% = manyattacks5% AND manyattacks%<>manyattacks1% AND rate = rate1 AND rate = rate2 AND rate=rate3 AND rate=rate4 THEN
- doesitloop$ = "yes"
- ENDIF
- :
- IF(rate*10000)DIV1=(rate2*10000)DIV1AND(rate*10000)DIV1=(rate4*10000)DIV1 AND(rate1*10000)DIV1=(rate3*10000)DIV1AND(rate1*10000)DIV1=(rate5*10000)DIV1AND(rate*10000)DIV1<>(rate1*10000)DIV1THENmaybeloop$="yes"
- IF(rate*10000)DIV1=(rate3*10000)DIV1AND(rate1*10000)DIV1=(rate4*10000)DIV1AND(rate2*10000)DIV1=(rate5*10000)DIV1AND((rate*10000)DIV1<>(rate1*10000)DIV1OR(rate*10000)DIV1<>(rate2*10000)DIV1)THENmaybeloop$="yes" : REM 3-part loop
- IF maybeloop$="yes" AND manyattacks%=manyattacks1% AND manyattacks% = manyattacks2% AND manyattacks% = manyattacks3% AND manyattacks%=manyattacks4% AND manyattacks%=manyattacks5% THEN doesitloop$ = "yes"
- :
- IF doesitloop$ = "yes" THEN
- CLS
- IF quickend% >= testquickend1% THEN
- margin1 = (quickend%-testquickend1%)/quickend%*100
- ELSE
- margin1 = (testquickend1%-quickend%)/quickend%*100
- ENDIF
- IF slowend% >= testslowend1% THEN
- margin2 = (slowend%-testslowend1%)/slowend%*100
- ELSE
- margin2 = (testslowend1%-slowend%)/slowend%*100
- ENDIF
- IF quickend% >= testquickend% THEN
- margin3 = (quickend%-testquickend%)/quickend%*100
- ELSE
- margin3 = (testquickend%-quickend%)/quickend%*100
- ENDIF
- IF slowend%>=testslowend% THEN
- margin4 = (slowend%-testslowend%)/slowend%*100
- ELSE
- margin4 = (testslowend%-slowend%)/slowend%*100
- ENDIF
- IF ((margin1*10)DIV1)MOD10>4 THEN margin1% = margin1 ELSE margin1% = margin1
- IF ((margin2*10)DIV1)MOD10>4 THEN margin2% = margin2 ELSE margin2% = margin2
- IF ((margin3*10)DIV1)MOD10>4 THEN margin3% = margin3 ELSE margin3% = margin3
- IF ((margin4*10)DIV1)MOD10>4 THEN margin4% = margin4 ELSE margin4% = margin4
- VDU 7
- IF easiermenus$ = "n" THEN PROCwindow(10,69,90,48) ELSE PROCwindow(10,69,90,42)
- PRINT''" the search is looping between the two closest possible solutions, "
- PRINT " given the present bias (see below)"
- PRINT ' " do you want to opt for one of these, or carry on searching with"
- PRINT " a different bias (press A/B)"
- PRINT'" quickend ";testquickend1%;" (";margin1%;"% off ";quickend%;")"
- PRINT " slowend ";testslowend1%;" (";margin2%;"% off ";slowend%;")"
- PRINT " number of attacks ";manyattacks2%
- PRINT " rate ";rate2
- PRINT " bias ";bias
- PRINT'" quickend ";testquickend%;" (";margin3%;"% off ";quickend%;")"
- PRINT " slowend ";testslowend%;" (";margin4%;"% off ";slowend%;")"
- PRINT " number of attacks ";manyattacks1%
- PRINT " rate ";rate1
- PRINT " bias ";bias
- CASE GET$ OF
- WHEN "A","a" : numberoftries% = 3
- OTHERWISE
- ENDCASE
- numberoftries% +=1 : IF numberoftries% = 1 THEN bias=bias/2
- IF numberoftries% = 2 THEN bias =bias*4
- IF numberoftries% = 3 THEN
- PRINT'" three different biases now tried -"
- PRINT " to opt for one of the last three tries press A/B/C"
- PRINT " or to try again with fresh values press D"
- CASE GET$ OF
- WHEN "A","a" : bias = bias/2
- WHEN "B","b" : bias = bias/4
- WHEN "C","c" : result$ = "loop"
- WHEN "D","d" : PROCfunctionprelude
- ENDCASE
- ENDIF
- IF numberoftries% = 4 THEN result$ = "loop"
- IF result$ <> "loop" THEN
- manyattacks1% = 0 : manyattacks2% = 0 : manyattacks3% = 0 : manyattacks4% = 0 : manyattacks5% = 0
- rate1=0 : rate2=0 : rate3=0 : rate4=0 : rate5=0
- doesitloop$ = "" : maybeloop$ = ""
- ENDIF
- ENDIF
- ENDIF
- :
- UNTIL result$ <> "noresult"
- :
- CASE result$ OF
- WHEN "success" :
- PROCfunction
- IF easiermenus$ = "n" THEN PROCwindow(10,69,90,44) ELSE PROCwindow(10,69,90,42)
- PRINT''" quickend ";testquickend%
- PRINT' " slowend ";testslowend%
- PRINT " "
- PRINT'" rate ";rate
- PRINT'" bias ";bias
- PRINT'" number of attacks ";manyattacks%
- :
- IF seegraph$ = "y" THEN
- PRINT'" Do you want to see the graph? "
- CASE GET$ OF
- WHEN "Y","y" : PROCgraph
- OTHERWISE PROCfunctionpostlude
- ENDCASE
- ELSE PROCfunctionpostlude
- ENDIF
- :
- WHEN "loop" :
- PRINT'" - to opt for the first solution above press A, for the"
- PRINT " second press B, to try again with fresh values press F"
- CASE GET$ OF
- WHEN "A","a" : PROCfunction
- :
- IF seegraph$ = "y" THEN
- PRINT'" Do you want to see the graph? "
- CASE GET$ OF
- WHEN "Y","y" : PROCgraph
- OTHERWISE PROCfunctionpostlude
- ENDCASE
- ELSE PROCfunctionpostlude
- ENDIF
- :
- WHEN "B","b" : manyattacks%=manyattacks1% : rate = rate1
- PROCfunction
- IF seegraph$ = "y" THEN
- PRINT'" Do you want to see the graph? "
- CASE GET$ OF
- WHEN "Y","y" : PROCgraph
- OTHERWISE PROCfunctionpostlude
- ENDCASE
- ELSE PROCfunctionpostlude
- ENDIF
- WHEN "F","f" : PROCfunctionprelude
- ENDCASE
- ENDCASE
- :
- ENDPROC
- :
- REM**********************************************************
- :
- DEF PROCgraph
- :
- numplots% = 10000
- segment = numplots%/(manyattacks%-1)
- horizline = numplots% - segment
- count =1
- REM convolutions below necc simply to get a 'square' graph
- factor1 = numplots%/rate
- factor2 = rate/(rate-1)
- factor3 = rate/numplots%
- factor4 = numplots%/((FNfunction(1)*factor1)-(FNfunction(rate)*factor1))
- factor5 = FNfunction(rate)*factor1
- factor6 = (factor4*factor5)-factor5
- MODE 31 : CLG : CLS
- PRINT TAB(50) " rate ";rate
- PRINT TAB(50) " bias ";bias
- PRINT TAB(50) " number of attacks ";manyattacks%
- PRINT TAB(50) " quickend ";functionattacks(1)
- PRINT TAB(50) " slowend ";functionattacks(manyattacks%-1)-functionattacks(manyattacks%-2)
- PRINT TAB(50) " total duration ";totaldur%
- MOVE 1000,0 : DRAW 0,0 : DRAW 0,1000
- scaling = 900/numplots%
- FOR x = 1 TO rate STEP factor3
- xaxis = ((x*factor1)-factor1)*2
- yaxis = ((FNfunction(x)*factor1)*factor4)-(factor5 + factor6)
- xplot = xaxis*scaling : yplot = yaxis*scaling
- DRAW xplot,yplot
- REM the function uses x = 1 to rate, but the graph plots (xaxis & yaxis) run from 0 to 1000 in each axis
- IF yaxis <= horizline THEN
- LINE 0,yplot, xplot,yplot
- LINE xplot,yplot, xplot,0
- MOVE xplot,yplot
- count += 1
- horizline -= segment
- ENDIF
- NEXT
- PROCfunctionpostlude
- ENDPROC
- :
- REM***************************************
- :
- DEF PROCfunctionpostlude
- :
- IF rate <> 1 THEN
- PRINT '" Accel or rit"
- PRINT " (press A/R or 1/2)"
- CASE GET$ OF
- WHEN "A","a","1" :
- FOR count% = 0 TO (manyattacks%-1)
- attacks1%(count%) = totaldur% - (functionattacks((manyattacks%-1)-count%))
- NEXT
- direction$ = "accel"
- :
- OTHERWISE
- FOR count = 0 TO (manyattacks%-1)
- attacks1%(count) = functionattacks(count)
- NEXT
- direction$ = "rit"
- ENDCASE
- ELSE
- FOR count% = 0 TO (manyattacks%-1)
- attacks1%(count%) = functionattacks(count%)
- NEXT
- direction$ = "rit"
- ENDIF
- :
- method$ = "raw"
- IF funcinput$ = "points" OR funcinput$ = "displayed" THEN quiz$ = "no"
- COLOUR 0 : COLOUR 191 : CLS : PROCinsertattacks
- ENDPROC
- :
- REM***************************************
- :
- DEF FNfunction(x)
- = (rate/x)-(x/bias)+(rate/bias)
- :
- REM***************************************
- :
- DEF PROCprerhythmicize
- :
- PROCwindow(20,71,90,38)
- CLS : PRINT' " Do you want to re-define the criteria for irrational groups, "
- PRINT ' " keep them or use CAC's defaults (Y/K/D) "
- PRINT''" (criteria are: "
- PRINT' " GROUP LENGTHS ";shortirrat%;" beats - "; longirrat%;" beats "
- PRINT' " GROUP LOCATIONS any 1/";irratbeats%;" of a bar "
- PRINT' " FALLBACK LOCATIONS any 1/";irratbeats1%;" of a bar "
- PRINT' " SHORTEST DURATION ";mindur%;" beats "
- PRINT' " COMPLEXITY ";given%
- PRINT' " DEFAULT DIVISIONS 1/";defaultsieve;" of a bar) "
- CASE GET$ OF
- WHEN "Y","y" :
- PRINT''" Give GROUP LENGTH of the SHORTEST irrational group desired... "
- INPUT' " bars "bars%
- INPUT'" beats "beats%
- PROCalterbeats
- shortirrat% = (bars%*960)+beats%
- PRINT'" Give GROUP LENGTH of the LONGEST irrational group desired... "
- INPUT'" bars "bars%
- INPUT'" beats "beats%
- PROCalterbeats
- longirrat% = (bars%*960)+beats%
- IF longirrat%/beatfactor% > 999 THEN
- VDU 7 : PRINT'" !!Maximum length for irrational groups is 999 beats!! "
- PRINT'" (to try again press C) "
- CASE GET$ OF
- WHEN"C","c" : CLS :PROCprerhythmicize
- ENDCASE
- ENDIF
- :
- CLS
- PRINT''" (criteria are now: "
- PRINT' " GROUP LENGTHS ";shortirrat%;" beats - "; longirrat%;" beats "
- PRINT' " GROUP LOCATIONS any 1/";irratbeats%;" of a bar "
- PRINT' " FALLBACK LOCATIONS any 1/";irratbeats1%;" of a bar "
- PRINT' " SHORTEST DURATION ";mindur%;" beats "
- PRINT' " COMPLEXITY ";given%
- PRINT' " DEFAULT DIVISIONS 1/";defaultsieve;" of a bar) "
- :
- PRINT''" For GROUP LOCATION which beats of the bar is it acceptable to "
- PRINT '" begin irrational groups of attacks on (1 = first beat of bar only, "
- PRINT '" 2 = any 1/2 bar, 3 = any 1/3 bar etc) "
- INPUT '" (use this to control allowability of certain group lengths) "irratbeats%
- REM 1-16 make integers except 7,9,11,13 & 14
- PRINT''" And for FALLBACK LOCATIONS which beats of the bar is it acceptable "
- PRINT' " to begin 'fall back' groups, ie ones beginning or ending with "
- INPUT '" rests, on (1, 2, 3 etc - also for controlling lengths allowable) "irratbeats1%
- PROCwindow(20,71,90,35)
- CLS
- PRINT''" (criteria are now: "
- PRINT' " GROUP LENGTHS ";shortirrat%;" beats - "; longirrat%;" beats "
- PRINT' " GROUP LOCATIONS any 1/";irratbeats%;" of a bar "
- PRINT' " FALLBACK LOCATIONS any 1/";irratbeats1%;" of a bar "
- PRINT' " SHORTEST DURATION ";mindur%;" beats "
- PRINT' " COMPLEXITY ";given%
- PRINT' " DEFAULT DIVISIONS 1/";defaultsieve;" of a bar) "
- :
- PRINT''" What is the SHORTEST ALLOWABLE DURATION, in beats "
- INPUT' " (any less than this will be 'edited up') "mindur%
- PROCalterbeats
- sieve = 960/mindur%
- buffer% = 960/(sieve*2)
- PRINT''" What is the maximum allowable irrational COMPLEXITY, "
- PRINT '" eg, '5' allows upto 5 'in the time of' (this parameter "
- INPUT '" controls the trade-off between user-friendliness and accuracy) "given%
- :
- CLS
- PRINT''" (criteria are now: "
- PRINT' " GROUP LENGTHS ";shortirrat%;" beats - "; longirrat%;" beats "
- PRINT' " GROUP LOCATIONS any 1/";irratbeats%;" of a bar "
- PRINT' " FALLBACK LOCATIONS any 1/";irratbeats1%;" of a bar "
- PRINT' " SHORTEST DURATION ";mindur%;" beats "
- PRINT' " COMPLEXITY ";given%
- PRINT' " DEFAULT DIVISIONS 1/";defaultsieve;" of a bar) "
- :
- PRINT''" According to DEFAULT DIVISIONS, irrationals will avoid small "
- PRINT '" divisions beyond a certain point, unless required by the rhythm. "
- PRINT '" Confirm or re-set this default, which is currently at ";defaultsieve;" divisions "
- INPUT '" of the bar (same trade-off as above) "defaultsieve
- WHEN "D","d" :
- PROCrhythmdefaults
- OTHERWISE
- ENDCASE
- :
- PROCquantize
- :
- attacks5%() = attacks2%()
- attacks3%() = attacks3%()/(10^3) : REM list of actual bar nos
- FOR count% = 0 TO (manyattacks%-1)
- attacks4%(count%) = attacks2%(count%) MOD (10^3)
- NEXT : REM list of actual beat nos (attacks2 containing bar/beat nos remains intact)
- :
- REM routine to fill array nodes%() with acceptable beats of bar to start irrat groups on
- IF irratbeats% > 0 THEN
- nextbeat% = 960/irratbeats%
- FOR count% = 1 TO (irratbeats%-1)
- nodes%(count%) = nodes%(count%-1) + nextbeat%
- NEXT
- ENDIF
- :
- REM routine to fill nodes1%() with acceptable beats to start fallback groups on
- nextbeat% = 960/irratbeats1%
- FOR count% = 1 TO (irratbeats1% - 1)
- nodes1%(count%) = nodes1%(count%-1) + nextbeat%
- NEXT
- nodes1%(irratbeats1%) = 960
- :
- REM routine to test whether first attack is on an acceptable beat
- firstattack$ = "offbeat"
- count% = 0
- REPEAT
- IF attacks4%(0) = nodes%(count%) THEN firstattack$ = "onbeat"
- count% += 1
- UNTIL firstattack$ = "onbeat" OR count% > (irratbeats%-1)
- :
- IF firstattack$ = "onbeat" THEN
- endbeat% = attacks2%(0)
- endcell% = 0
- status$ = "onbeat"
- firstgroup$ = "y"
- ELSE
- word$ = ""
- count% = irratbeats1%
- REPEAT
- IF nodes1%(count%) < attacks4%(0) THEN
- endbeat% = (attacks3%(0)*(10^3)) + nodes1%(count%)
- word$ = "found"
- ENDIF
- count% -= 1
- UNTIL word$ = "found" OR count% < 0
- endcell% = 0
- status$ = ""
- firstgroup$ = "y"
- ENDIF
- PROCrhythmicize
- :
- ENDPROC
- :
- REM***************************************************************
- :
- DEF PROCfunction
- :
- IF rate = 1 THEN
- :
- unit = totaldur%/(manyattacks%-1)
- :
- FOR count% = 1 TO (manyattacks%-2)
- :
- attackpoint = unit * count%
- :
- REM rounding-off to nearest integer
- attackpoint = attackpoint * 10
- attackpoint = attackpoint DIV 1
- fraction = attackpoint MOD 10
- IF fraction > 4 THEN
- attackpoint = (attackpoint DIV 10) + 1
- ELSE
- attackpoint = attackpoint DIV 10
- ENDIF
- functionattacks(count%) = attackpoint
- REM list of 'real' attack-values 0-totaldur% rounded to nearest integer
- :
- NEXT
- :
- functionattacks(manyattacks%-1) = totaldur%
- :
- ELSE
- :
- yrange = FNfunction(1) - 1
- segment = yrange/(manyattacks%-1)
- ypoint = FNfunction(1)
- :
- FOR count% = 1 TO (manyattacks%-2)
- :
- ypoint -= segment
- xincrement = rate - 1
- xtry = 1 + (xincrement/2)
- :
- tolerance = yrange/100000 : REM this ought to give highly accurate results
- :
- IF result$ = "success" OR result$ = "loop" OR count% = 1 OR count% = (manyattacks%-2) THEN
- :
- WHILE FNfunction(xtry) > (ypoint+tolerance) OR FNfunction(xtry) < (ypoint-tolerance)
- :
- xincrement = xincrement/2
- IF FNfunction(xtry) < ypoint THEN
- xtry -= xincrement
- ELSE
- xtry += xincrement
- ENDIF
- :
- ENDWHILE
- :
- ENDIF
- :
- functionattacks(count%) = xtry
- :
- NEXT
- :
- functionattacks(0) = 1
- functionattacks(manyattacks%-1) = rate
- :
- REM scaling & rounding routine
- functionattacks() -= 1
- divider = rate-1
- FOR count% = 0 TO (manyattacks%-1)
- functionattacks(count%) = functionattacks(count%)/divider*totaldur%
- NEXT
- :
- FOR count% = 1 TO (manyattacks%-1)
- number = functionattacks(count%)
- number = number*10
- number = number DIV 1
- fraction = number MOD 10
- IF fraction > 4 THEN
- number = (number DIV 10) + 1
- ELSE
- number = number DIV 10
- ENDIF
- functionattacks(count%) = number
- REM list of 'real' attack-values 0-totaldur% rounded to nearest integer
- NEXT
- :
- ENDIF
- :
- ENDPROC
- :
- REM**************************************************************
- :
- DEF PROCrhythmicize
- :
- cant% = 0 : REM for notategroup%() subscript - poss change later
- notategroup%() = 0
- :
- REPEAT
- :
- status1$ = status$
- status$ = ""
- startbeat% = endbeat%
- :
- IF status1$ = "onbeat" OR firstgroup$ = "y" THEN
- startcell% = endcell%
- ELSE startcell% = endcell% + 1
- ENDIF
- firstgroup$ = "n"
- :
- cell% = startcell%
- count% = 0
- condition$ = "full"
- :
- PROCbuffers
- :
- WHILE status$ = "" AND attacks5%(cell%) <= rightbuffer% AND cell% < manyattacks%
- :
- IF attacks5%(cell%) >= leftbuffer% AND attacks5%(cell%) <= rightbuffer% THEN
- :
- IF attacks4%(cell%) >= (960-buffer%) THEN attacks4%(cell%) = (960-attacks4%(cell%))*-1 : REM catches attacks just before barline
- :
- REPEAT
- :
- IF attacks4%(cell%) >= (nodes%(count%)-(buffer%)) AND attacks4%(cell%) <= (nodes%(count%)+(buffer%)) THEN
- :
- IF attacks4%(cell%) < 0 THEN
- br% = attacks3%(cell%)+1
- attacks4%(cell%) = 960 - (attacks4%(cell%)*-1)
- beforebar$ = "y"
- ELSE
- br% = attacks3%(cell%)
- beforebar$ = "n"
- ENDIF
- :
- IF attacks5%(cell%) >= ((br%*10^3)+nodes%(count%)) THEN
- diff% = attacks4%(cell%) - nodes%(count%) + ((attacks3%(cell%)-br%)*960)
- ELSE
- diff% = nodes%(count%) - attacks4%(cell%) + ((br%-attacks3%(cell%))*960)
- ENDIF
- :
- IF attacks5%(cell%+1) >= ((br%*10^3)+nodes%(count%)) THEN
- diff1% = attacks4%(cell%+1)-nodes%(count%)+((attacks3%(cell%+1)-br%)*960)
- ELSE
- diff1% = nodes%(count%)-attacks4%(cell%+1)+((br%-attacks3%(cell%+1))*960)
- ENDIF
- :
- IF diff% <= diff1% THEN
- :
- status$ = "onbeat"
- IF beforebar$ = "y" THEN
- attacks5%(cell%) = (attacks3%(cell%)*10^3) + 1000 + nodes%(count%)
- ELSE
- attacks5%(cell%) = (attacks3%(cell%)*10^3) + nodes%(count%)
- ENDIF
- endbeat% = attacks5%(cell%)
- endcell% = cell%
- difference% = endcell% - startcell%
- IF status1$ = "onbeat" AND difference% = 1 THEN condition$ = "empty"
- IF status1$ = "" AND difference% = 0 THEN condition$ = "empty"
- :
- ENDIF
- :
- ENDIF
- :
- count% += 1
- :
- UNTIL count% = irratbeats% OR status$ = "onbeat"
- :
- ENDIF
- :
- cell% += 1
- count% = 0
- :
- ENDWHILE
- :
- :
- IF status$ = "" THEN
- word$ = ""
- leftbuffer% = leftbuffer% + buffer%
- :
- REPEAT
- :
- IF nodes1%(count%) >= (leftbuffer%MOD10^3) THEN
- :
- IF nodes1%(count%) = 960 THEN
- endbeat% = ((leftbuffer%DIV(10^3))*10^3)+(10^3)
- ELSE
- endbeat% = ((leftbuffer%DIV(10^3))*(10^3)) + nodes1%(count%)
- ENDIF
- :
- IF status1$ = "" AND attacks5%(startcell%) > endbeat% THEN
- condition$ = "empty"
- ENDIF
- IF status1$ = "onbeat" AND attacks5%(startcell%+1) > endbeat% THEN
- condition$ = "empty"
- ENDIF
- :
- IF condition$ = "full" THEN
- :
- searchcell% = startcell% - 1
- REPEAT
- searchcell% += 1
- UNTIL attacks5%(searchcell%) > endbeat% OR searchcell% = manyattacks%
- :
- endcell% = searchcell% - 1
- ENDIF
- word$ = "done"
- :
- ENDIF
- :
- count% += 1
- :
- UNTIL word$ = "done"
- :
- :
- ENDIF
- :
- PROCprechoosegroup
- :
- UNTIL endbeat% >= attacks5%(manyattacks%-1)
- :
- IF seeinfo$ = "y" THEN
- CLS
- durat% = 0
- counter% = 0
- thing$ = "on"
- PROCwindow(10,60,90,5) : CLS
- VDU 14
- PRINT '" The group of rhythmicised attacks will be at "
- PRINT" "
- PRINT TAB(28) "ATTACKS AT";
- PRINT TAB(46) "DURATIONS";
- PRINT TAB(64) "RATIOS"
- attacks5%(manyattacks%) = 10^9
- FOR count% = 0 TO manyattacks%
- IF counter% < cant% THEN
- item% = ((notategroup%(counter%,1)DIV10^4)*10^3)+(notategroup%(counter%,0)MOD10^3)
- IF item% = attacks5%(count%) THEN
- PRINT TAB(15) item%;
- counter% += 1
- thing$ = "on"
- ENDIF
- ENDIF
- IF counter% < cant% THEN
- item% = ((notategroup%(counter%,1)DIV10^4)*10^3)+(notategroup%(counter%,0)MOD10^3)
- IF item% < attacks5%(count%) THEN
- PRINT TAB(15) item%
- counter% += 1
- thing$ = "on"
- ENDIF
- ENDIF
- IF counter% < cant% THEN
- IF thing$ = "on" THEN
- IF (notategroup%(counter%,0)DIV1000)= attacks5%(count%) THEN
- PRINT " "
- PRINT " "
- PRINT TAB(0) (notategroup%(counter%,1)MOD10000);
- PRINT TAB(15) (notategroup%(counter%,0)DIV1000);
- thing$ = "off"
- ENDIF
- :
- IF (notategroup%(counter%,0)DIV1000)< attacks5%(count%) THEN
- PRINT " "
- PRINT " "
- PRINT TAB(0) ((notategroup%(counter%,1))MOD10000);
- PRINT TAB(15) (notategroup%(counter%,0)DIV1000)
- thing$ = "off"
- ENDIF
- ENDIF
- ENDIF
- :
- IF thing$ = "on" THEN PRINT'" "
- :
- IF count% < manyattacks% THEN
- PRINT TAB(25)attacks5%(count%);
- IF count% < (manyattacks%-1) THEN
- durat1% = durat%
- durat% = (attacks5%(count%+1)MOD10^3)-(attacks5%(count%)MOD10^3)
- addon% = ((attacks5%(count%+1)DIV(10^3))-(attacks5%(count%)DIV(10^3)))*960
- durat% = durat% + addon%
- PRINT TAB(42) durat%;
- IF count%>0 THEN
- IF direction$ = "rit" THEN ratio = durat%/durat1% ELSE ratio = durat1%/durat%
- CASE ratio OF
- WHEN 0.5 : PRINT TAB(65) "0.5"
- WHEN 1.0 : PRINT TAB(65) "1.0"
- WHEN 1.5 : PRINT TAB(65) "1.5"
- WHEN 2.0 : PRINT TAB(65) "2.0"
- WHEN 2.5 : PRINT TAB(65) "2.5"
- OTHERWISE PRINT TAB(65) ratio
- ENDCASE
- ENDIF
- ENDIF
- ENDIF
- NEXT
- :
- VDU 15
- ENDIF
- :
- CLS
- :
- ENDPROC
- :
- REM*******************************************
- :
- DEF PROCbuffers
- :
- beatnum% = (startbeat%MOD(10^3)) + shortirrat% - buffer%
- carrybars% = beatnum% DIV 960
- beatnum% = beatnum% - (carrybars%*960)
- leftbuffer% = ((startbeat%DIV(10^3))*10^3) + (carrybars%*(10^3)) + beatnum%
- :
- beatnum% = (startbeat%MOD(10^3)) + longirrat% + buffer%
- carrybars% = beatnum% DIV 960
- beatnum% = beatnum% - (carrybars%*960)
- rightbuffer% = ((startbeat%DIV(10^3))*10^3) + (carrybars%*(10^3)) + beatnum%
- :
- REM tolerance of 'buffer%' incorporated into buffers
- :
- ENDPROC
- :
- REM********************************************8
- :
- DEF PROCprechoosegroup
- :
- :
- IF condition$ = "full" THEN
- :
- REM routine to find grouplength%
- carrybars% = (endbeat% DIV (10^3)) - (startbeat% DIV (10^3))
- grouplength% = (endbeat% MOD (10^3)) - (startbeat% MOD (10^3)) + (carrybars% * 960)
- :
- REM routine to find first and last durats
- IF status1$ = "onbeat" THEN
- :
- carrybars% = attacks3%(startcell%+1)-attacks3%(startcell%)
- firstdur% = attacks4%(startcell%+1)-attacks4%(startcell%)+(carrybars%*960)
- ELSE
- carrybars% = attacks3%(startcell%)-(startbeat%DIV(10^3))
- firstdur% = attacks4%(startcell%)-(startbeat%MOD(10^3))+(carrybars%*960)
- ENDIF
- :
- IF status$ = "onbeat" THEN
- :
- carrybars% = attacks3%(endcell%)-attacks3%(endcell%-1)
- lastdur% = attacks4%(endcell%)-attacks4%(endcell%-1)+(carrybars%*960)
- ELSE
- carrybars% = (endbeat%DIV(10^3))-attacks3%(endcell%)
- lastdur% = (endbeat%MOD(10^3))-attacks4%(endcell%)+(carrybars%*960)
- ENDIF
- :
- :
- :
- REM routine to determine each individual duration
- IF status1$ = "onbeat" AND status$ = "onbeat" THEN
- numdurs% = endcell% - startcell%
- FOR count% = 2 TO (numdurs%-1)
- dur%(count%) = attacks1%(startcell%+count%)-attacks1%(startcell%+(count%-1))
- NEXT
- dur%(1) = firstdur%
- dur%(numdurs%) = lastdur%
- ENDIF
- :
- IF status1$ = "onbeat" AND status$ = "" THEN
- numdurs% = endcell% - startcell% + 1
- FOR count% = 2 TO (numdurs%-1)
- dur%(count%) = attacks1%(startcell%+count%)-attacks1%(startcell%+(count%-1))
- NEXT
- dur%(1) = firstdur%
- dur%(numdurs%) = lastdur%
- ENDIF
- :
- IF status1$ = "" AND status$ = "onbeat" THEN
- numdurs% = endcell% - startcell% + 1
- FOR count% = 2 TO (numdurs%-1)
- dur%(count%) = attacks1%(startcell%+(count%-1))-attacks1%(startcell%+(count%-2))
- NEXT
- dur%(1) = firstdur%
- dur%(numdurs%) = lastdur%
- ENDIF
- :
- IF status1$ = "" AND status$ = "" THEN
- numdurs% = endcell% - startcell% + 2
- FOR count% = 2 TO (numdurs%-1)
- dur%(count%) = attacks1%(startcell%+(count%-1))-attacks1%(startcell%+(count%-2))
- NEXT
- dur%(1) = firstdur%
- dur%(numdurs%) = lastdur%
- ENDIF
- :
- REM routine to find enddur (ie smallest duration)
- enddur = 10^9
- FOR count% = 1 TO numdurs%
- IF dur%(count%) < enddur THEN
- enddur = dur%(count%) : enddurnum% = count%
- ENDIF
- NEXT
- :
- REM routine to find numsubdivs of enddur poss, using a default min division, forcing that
- REM down with durats less than it, but not beyond the minimum div given by sieve
- defaultmindur% = 960/defaultsieve
- IF enddur < defaultmindur% THEN
- x = 960/enddur : defaultmindur% = 960/x
- ELSE x = defaultsieve
- ENDIF
- IF x > sieve THEN
- x = sieve : defaultmindur% = mindur%
- ENDIF
- numsubdivs = x * enddur / 960 * 1.04 : REM 1.04 catches numbers just below whole nos eg 1.96
- IF numsubdivs < 1 THEN numsubdivs% = 1 ELSE numsubdivs% = numsubdivs
- :
- REM repeat/until loop to keep increasing and decreasing enddur until a 'reasonable' proportiontotal% is found
- switch$ = "A" : nudge% = -5
- REPEAT
- nudge% += 5
- IF switch$ = "A" THEN enddur += (nudge%/100) ELSE enddur -= (nudge%/100)
- IF enddur < 1 THEN
- VDU 7 : PRINT''" !!!THE COMPLEXITY LEVEL IS TOO LOW "
- PRINT" FOR LONG GROUPS CONSISTING "
- PRINT" OF ODD NUMBERS OF BEATS, "
- PRINT" eg 13 QUAVERS, 31 SEMIS ETC. "
- PRINT" INCREASE THIS LEVEL OR SHORTEN "
- PRINT" GROUPS OR, BEST, REDUCE INPUTS 3/4!!! "
- PRINT" (press C to continue) "
- CASE GET$ OF
- WHEN"C","c" : PROCdisplay
- ENDCASE
- ENDIF
- :
- IF switch$ = "A" THEN switch$ = "B" ELSE switch$ = "A"
- numsubdivs1 = x*enddur/960*1.04
- IF numsubdivs1 < 1 THEN numsubdivs% = 1 ELSE numsubdivs% = numsubdivs1
- REM prev 2 lines allow 'stretched' enddurs to include more (or less) subdivs
- REM without altering original subdivs, which tends to vitiate the whole process
- :
- REM routine to create list of attacks 0 - totalduration
- FOR count% = 1 TO numdurs%
- groupattacks%(count%) = groupattacks%(count%-1)+dur%(count%)
- NEXT
- REM groupattacks%(numdurs%) SHOULD = grouplength%
- :
- timeround% = 1
- PROCchoosegroup
- :
- REM routine to place error-values in order
- errororder%() = 10000000
- FOR count% = 1 TO numsubdivs%
- tick% = 0
- REPEAT
- do$ = "n"
- tick%+=1 : inplace$ = "n"
- IF error%(count%) < errororder%(tick%) THEN
- FOR tock% = numsubdivs% TO tick% STEP -1
- errororder%(tock%+1) = errororder%(tock%)
- errororder1%(tock%+1) = errororder1%(tock%)
- NEXT
- errororder%(tick%) = error%(count%) : errororder1%(tick%) = count% : inplace$ = "y"
- ENDIF
- UNTIL inplace$ = "y"
- NEXT
- :
- timeround% = 2 : tog% = 0
- REPEAT
- tog%+=1 : closest% = errororder1%(tog%)
- PROCchoosegroup
- PROCcheckproportiontotal
- UNTIL proportiontotal$ = "OK" OR tog% = numsubdivs%
- UNTIL proportiontotal$ = "OK"
- REM routine to alter attacks5%() to closest group & to save notation in a parallel temp array
- IF status1$ = "onbeat" THEN
- FOR count% = 1 TO (numdurs%-1)
- totalbeat% = (startbeat%MOD(10^3))+rhythmicattacks%(count%)
- carrybars% = ((totalbeat%/960)DIV1)
- beat% = totalbeat%-(carrybars%*960)
- bar% = (carrybars%+(startbeat%DIV(10^3)))*(10^3)
- attacks5%(startcell%+count%) = beat% + bar%
- NEXT
- ENDIF
- :
- IF status1$ = "" THEN
- FOR count% = 1 TO (numdurs%-1)
- totalbeat% = (startbeat%MOD(10^3))+rhythmicattacks%(count%)
- carrybars% = ((totalbeat%/960)DIV1)
- beat% = totalbeat% - (carrybars%*960)
- bar% = (carrybars% + (startbeat%DIV(10^3))) * (10^3)
- attacks5%(startcell%+(count%-1)) = beat% + bar%
- NEXT
- ENDIF
- :
- notategroup%(cant%,0) = (startbeat%*10^3)+(endbeat%MOD10^3)
- notategroup%(cant%,1) = ((endbeat%DIV10^3)*10^4)+proportiontotal%
- cant% += 1
- :
- ENDIF
- :
- ENDPROC
- :
- REM******************************************************
- :
- DEF PROCchoosegroup
- :
- IF timeround% = 1 THEN
- start% = 1 : finish% = numsubdivs%
- ELSE start% = closest% : finish% = closest%
- ENDIF
- :
- error%() = 0
- FOR count% = start% TO finish%
- :
- FOR count1% = 1 TO numdurs%
- IF count1% = enddurnum% THEN thedur% = enddur ELSE thedur% = dur%(count1%)
- IF numsubdivs < 1 THEN
- proportion = thedur%/enddur*numsubdivs/1.04
- ELSE proportion = thedur%/enddur*count%
- ENDIF
- IF (((proportion*10)DIV1)MOD10) < 5 THEN
- proportion%(count1%) = (proportion) DIV 1
- ELSE proportion%(count1%) = ((proportion) DIV 1) + 1
- ENDIF
- IF proportion%(count1%) < 1 THEN proportion%(count1%) = 1
- NEXT
- :
- proportiontotal% = 0
- :
- FOR count2% = 1 TO numdurs%
- proportiontotal% = proportiontotal%+proportion%(count2%)
- NEXT
- :
- unit = grouplength%/proportiontotal%
- :
- rhythmicattack = 0
- FOR count3% = 1 TO numdurs%
- rhythmicattack = rhythmicattack + (proportion%(count3%)*unit)
- IF (((rhythmicattack*10)DIV1)MOD10) < 5 THEN
- rhythmicattacks%(count3%) = rhythmicattack DIV 1
- ELSE
- rhythmicattacks%(count3%) = ((rhythmicattack)DIV1)+1
- ENDIF
- NEXT : REM rhythmicattacks%(numdurs%) SHOULD = grouplength%
- :
- REM compare attackpoints with attackpoints
- FOR count4% = 1 TO (numdurs%-1)
- IF rhythmicattacks%(count4%) <= groupattacks%(count4%) THEN
- error%(count%) = error%(count%) + (groupattacks%(count4%) - rhythmicattacks%(count4%))
- ELSE
- error%(count%) = error%(count%)+(rhythmicattacks%(count4%)-groupattacks%(count4%))
- ENDIF
- NEXT
- :
- NEXT
- :
- ENDPROC
- :
- REM***************************************************************
- :
- DEF PROCseriesattacks
- :
- IF easiermenus$ = "n" THEN PROCwindow(20,69,70,55) ELSE PROCwindow(20,69,70,42)
- PRINT '" Raw beat numbers R "
- PRINT '" Already rhythmicized A "
- PRINT '" Multiplied by factors F "
- PRINT '" Played P "
- PRINT '" Single attack 1 "
- :
- CASE GET$ OF
- REM CASE 1
- WHEN "A","a" :
- count% = 0 : cant% = 0 :
- notategroup%() = 0 : finished$ = "n"
- :
- REPEAT
- :
- CLS
- PRINT '" single attack S "
- PRINT '" group of attacks (including all tuplets) G "
- PRINT '" finished F "
- CASE GET$ OF
- REM CASE 2
- WHEN "S","s","1","0" :
- :
- CLS
- INPUT' " bar"bar%
- INPUT' " beat"beats%
- PROCalterbeats
- attacks2%(count%) = (bar%*(10^3)) + beats%
- count% += 1
- :
- WHEN "G","g" :
- CLS
- INPUT' " starting at bar "bars%
- INPUT' " beat "beats%
- PROCalterbeats
- start% = (bars%*(10^3))+beats%
- INPUT' " ending at bar "bars%
- INPUT' " beat "beats%
- PROCalterbeats
- end% = (bars%*(10^3))+beats%
- INPUT '" number of divisions "numdivs%
- notategroup%(cant%,0) = (start%*10^3)+(end%MOD10^3)
- notategroup%(cant%,1) = ((end%DIV10^3)*10^4)+numdivs%
- cant% += 1
- beat% = (start%)MOD(10^3) : bar% = (start%)DIV(10^3)
- :
- grouplength% = ((end%MOD(10^3))-(start%MOD(10^3)))+(((end%DIV(10^3))-(start%DIV(10^3)))*960)
- unit = grouplength%/numdivs%
- :
- IF (grouplength%/beatfactor%) > 999 THEN
- PRINT'''" !!!Maximum group length is 999 macro-beats!!! "
- PRINT" (press C to try again) "
- CASE GET$ OF
- REM CASE 3
- WHEN "C","c": CLS : PROCseriesattacks
- OTHERWISE PROCdisplay
- ENDCASE
- REM ENDCASE 3
- ENDIF
- IF numdivs% > 9999 THEN
- PRINT'''" !!!Maximum number of divisions is 9999!!! "
- PRINT" (press C to try again) "
- CASE GET$ OF
- REM CASE 4
- WHEN "C","c": CLS : PROCseriesattacks
- OTHERWISE PROCdisplay
- ENDCASE
- REM ENDCASE 4
- ENDIF
- :
- INPUT '" how many attacks "numattacks%
- CLS
- FOR counter% = 1 TO numattacks%
- PRINT '" attack ";counter%;" is on "
- INPUT " division number "div%
- place = ((div%-1)*unit)
- IF (((place*10)DIV1)MOD10) < 5 THEN
- place% = (place)DIV1
- ELSE place% = ((place)DIV1)+1
- ENDIF
- :
- beatnum% = beat% + place%
- carrybars% = (beatnum%/960)DIV1
- beatnum% = beatnum% - (carrybars%*960)
- barnum% = carrybars% + bar%
- attacks2%(count%) = (barnum%*(10^3)) + beatnum%
- count% += 1
- NEXT
- :
- WHEN "F","f" : finished$ = "y"
- ENDCASE
- REM ENDCASE 2
- :
- UNTIL finished$ = "y"
- :
- method$ = "alreadyrhythmicized" : manyattacks% = count%
- attacks5%() = attacks2%() : rhythmicized$ = "y"
- :
- WHEN "R","r","0" :
- REM function will feed a sim string of beat values 0 - n into attacks1%()
- :
- attacks1%() = 0
- CLS
- INPUT' " How many attacks "manyattacks%
- :
- IF manyattacks% > 2 THEN
- PRINT'" Are the intervals between them the same? "
- CASE GET$ OF
- WHEN "N","n","2" : sameintervals$ = "n"
- OTHERWISE sameintervals$ = "y"
- ENDCASE
- ELSE sameintervals$ = "y"
- ENDIF
- :
- IF manyattacks% > 1 THEN
- :
- CASE sameintervals$ OF
- WHEN "n" :
- FOR count% = 1 TO (manyattacks% - 1)
- PRINT' " Give the interval between attacks ";count%;" and ";count%+1;"... "
- INPUT'" bars "bars%
- INPUT'" beats "beats%
- PROCalterbeats
- onbeat% = (bars%*960)+beats%
- attacks1%(count%) = attacks1%(count%-1) + onbeat%
- NEXT
- WHEN "y" :
- PRINT'" The interval between them is "
- INPUT'" bars "bars%
- INPUT'" bears "beats%
- PROCalterbeats
- onbeat% = (bars%*960)+beats%
- FOR count% = 1 TO (manyattacks%-1)
- attacks1%(count%) = attacks1%(count%-1) + onbeat%
- NEXT
- :
- ENDCASE
- :
- ENDIF
- method$ = "raw" : attacks1%(0) = 0
- WHEN "1" :
- REM function will feed a sim string of beat values 0 - n into attacks1%()
- :
- manyattacks% = 1
- :
- method$ = "raw" : attacks1%(0) = 0
- :
- WHEN "F","f" :
- REM function will feed a sim string of beat values 0 - n into attacks1%()
- :
- attacks1%() = 0
- INPUT' " How many attacks "manyattacks%
- :
- FOR count% = 1 TO (manyattacks% - 1)
- IF count% = 1 THEN
- PRINT' " Give the interval between attacks ";count%;" and ";count%+1;"... "
- INPUT'" bars "bars%
- INPUT " beats "beats%
- PROCalterbeats
- onbeat% = (bars%*960)+beats%
- attacks1%(count%) = attacks1%(count%-1) + onbeat%
- ELSE
- PRINT' " Multiply by ? to give the interval between attacks ";count%;" and ";count%+1;"... "
- IF count% = 2 THEN onbeat% = attacks1%(count%-1)
- CASE GET$ OF
- WHEN "0": onbeat% = onbeat% * 1.03
- WHEN "1": onbeat% = onbeat% * 1.04
- WHEN "2": onbeat% = onbeat% * 1.06
- WHEN "3": onbeat% = onbeat% * 1.09
- WHEN "4": onbeat% = onbeat% * 1.13
- WHEN "5": onbeat% = onbeat% * 1.19
- WHEN "6": onbeat% = onbeat% * 1.29
- WHEN "7": onbeat% = onbeat% * 1.41
- WHEN "8": onbeat% = onbeat% * 1.61
- WHEN "9": onbeat% = onbeat% * 1.91
- ENDCASE
- attacks1%(count%) = attacks1%(count%-1) + onbeat%
- ENDIF
- NEXT
- method$ = "raw" : attacks1%(0) = 0
- :
- WHEN "P","p" :
- CLS
- PRINT " Play the rhythm using any"
- PRINT " keys or the spacebar"
- PRINT'" When finished, press ~"
- :
- key$ = GET$ : TIME = 0 : VDU 7 : manyattacks% = 1
- :
- REPEAT
- manyattacks% += 1 : key$ = GET$
- attacks2%(manyattacks%-1) = TIME : VDU 7
- UNTIL key$ = "~" OR key$ = "`"
- :
- manyattacks% -= 1
- :
- FOR count% = 1 TO manyattacks% - 1
- attacks1%(count%) = attacks2%(count%)*960*MM%/6000
- NEXT
- :
- method$ = "raw"
- :
- ENDCASE
- REM ENDCASE 1
- :
- PROCinsertattacks
- :
- ENDPROC
- :
- REM***************************************************************
- :
- DEF PROCalterbeats
- :
- IF beats% < alterbeatsat% THEN beats% = beats% * beatfactor% * 8
- :
- ENDPROC
- :
- REM****************************************************************
- :
- DEF PROCdisarrayfill
- :
- FOR count% = 0 TO (cant%-1)
- :
- bar% = notategroup%(count%,0)DIV(10^6)
- carrybars% = (notategroup%(count%,1)DIV(10^4))-bar%
- carrybeats% = (notategroup%(count%,0)MOD(10^3))-((notategroup%(count%,0)MOD(10^6))DIV(10^3))
- grouplength% = (carrybars%*960)+carrybeats%
- grouplength% = grouplength%/beatfactor%
- :
- beat% = ((notategroup%(count%,0)MOD(10^6))DIV(10^3))/beatfactor%
- divs% = notategroup%(count%,1)MOD(10^4)
- :
- IF grouplength% > 99 OR divs% > 99 THEN bigirrat$ = "y" ELSE bigirrat$ = "n"
- :
- IF (disarray%(bar%,0,voice%) DIV(10^3)) MOD10^2 = 0 AND bigirrat$ = "n" THEN
- hold% = disarray%(bar%,0,voice%)MOD10^3
- add% = ((beat%*(10^4)) + (grouplength%*(10^2)) + divs%) * (10^3)
- disarray%(bar%,0,voice%) = hold% + add%
- ELSE
- IF (disarray%(bar%,1,voice%)DIV(10^6))MOD10^2=0 AND bigirrat$ = "n" THEN
- disarray%(bar%,0,voice%)=disarray%(bar%,0,voice%)+(beat%*10)+(grouplength%DIV10)
- hold% = disarray%(bar%,1,voice%)MOD10^6
- add% = (((grouplength%MOD10)*100)+divs%)*10^6
- disarray%(bar%,1,voice%) = hold% + add%
- ELSE
- IF disarray%(bar%,1,voice%)MOD10^2=0 AND bigirrat$ = "n" THEN
- disarray%(bar%,1,voice%)=disarray%(bar%,1,voice%)+(beat%*(10^4))+(grouplength%*(10^2))+divs%
- ELSE
- IF (disarray%(bar%,2,voice%)DIV(10^3))MOD10^2 = 0 AND bigirrat$ = "n" THEN
- hold% = disarray%(bar%,2,voice%)MOD10^3
- add% = ((beat%*(10^4)) + (grouplength%*(10^2)) + divs%) * (10^3)
- disarray%(bar%,2,voice%)= hold% + add%
- ELSE
- IF disarray%(bar%,3,voice%)=0 THEN
- disarray%(bar%,3,voice%)=(beat%*10^7)+(grouplength%*10^4)+divs%
- ELSE
- VDU 7
- PRINT''''" THERE ARE ALREADY 5 RHYTHMIC GROUPS IN THIS BAR"
- PRINT" (this is the maximum)"
- PRINT''" TO CONTINUE PRESS C"
- CASE GET$ OF
- WHEN "C","c" : PROCawait
- OTHERWISE
- PROCawait
- ENDCASE
- ENDIF
- ENDIF
- ENDIF
- ENDIF
- ENDIF
- :
- NEXT
- :
- ENDPROC
- :
- REM**********************************************
- :
- DEF PROCdelete
- :
- IF deleteone$ <> "none" THEN
- PROCdeleteone
- ELSE
- IF easiermenus$ = "n" THEN PROCwindow(20,69,80,55) ELSE PROCwindow(20,69,72,42)
- PRINT '" One or several notes LEAVING rhythmic notation - A"
- PRINT '" One or several notes DELETING rhythmic notation - B"
- PRINT '" One or several bars - C"
- PRINT '" Whole voice - D"
- PRINT '" Group of voices - G"
- :
- CASE GET$ OF
- WHEN "A","a" :
- :
- CLS
- IF screenvoices$ = "n" THEN
- INPUT' " Which voice (0 = top) "voice%
- IF voice% = 0 THEN PROCpressenter
- ELSE
- PRINT'" Which screen voice "
- CASE GET$ OF
- WHEN "1" : voice% = 1
- WHEN "2" : voice% = 2
- WHEN "3" : voice% = 3
- OTHERWISE PROCpressenter
- ENDCASE
- ENDIF
- IF screenvoices$ = "y" AND voice% > 0 THEN voice% = displayvoices%(startv%+voice%-1)
- voice% -= 1
- IF voice% >= 0 THEN samevoice% = voice%
- IF voice% = -1 THEN voice% = samevoice%
- :
- INPUT " how many notes (for 1 press 0) "numnotes%
- IF numnotes% = 0 THEN numnotes% = 1
- IF quickcopy$ = "n" THEN
- PRINT'" Starting at bar number "
- INPUT " (press 0 for first bar displayed) "bar%
- IF bar% = 0 THEN bar% = startbar%
- INPUT " beat "beats% : PROCalterbeats
- start% = (bar%*(10^3))+beats%
- ELSE
- INPUT ' " starting at note number (0 counts as 1) "along%
- IF along% = 0 THEN along% = 1
- along%-=1
- copystartbar% = array%(holdstartcell%(voice%)+along%,0,voice%)DIV10^6
- copystartbeat% = (array%(holdstartcell%(voice%)+along%,0,voice%)MOD10^6)DIV10^3
- beats% = copystartbeat%
- PROCalterbeats
- start% = (copystartbar%*(10^3))+beats%
- ENDIF
- PROCsearch(start%)
- PROCshuntleft(startcell%,numnotes%)
- :
- ENDIF
- :
- WHEN "B","b" :
- :
- CLS
- IF screenvoices$ = "n" THEN
- INPUT' " Which voice (0 = top) "voice%
- IF voice% = 0 THEN PROCpressenter
- ELSE
- PRINT'" Which screen voice "
- CASE GET$ OF
- WHEN "1" : voice% = 1
- WHEN "2" : voice% = 2
- WHEN "3" : voice% = 3
- OTHERWISE PROCpressenter
- ENDCASE
- ENDIF
- IF screenvoices$ = "y" AND voice% > 0 THEN voice% = displayvoices%(startv%+voice%-1)
- voice% -= 1
- IF voice% >= 0 THEN samevoice% = voice%
- IF voice% = -1 THEN voice% = samevoice%
- :
- INPUT " how many notes "numnotes%
- :
- IF quickcopy$ = "n" THEN
- PRINT'" Starting at bar number "
- INPUT " (press 0 for first bar displayed "bar%
- IF bar% = 0 THEN bar% = startbar%
- INPUT " beat "beats% : PROCalterbeats
- start% = (bar%*(10^3))+beats%
- ELSE
- INPUT ' " starting at note number (0 counts as 1) "along%
- IF along% = 0 THEN along% = 1
- along%-=1
- copystartbar% = array%(holdstartcell%(voice%)+along%,0,voice%)DIV10^6
- copystartbeat% = (array%(holdstartcell%(voice%)+along%,0,voice%)MOD10^6)DIV10^3
- beats% = copystartbeat%
- PROCalterbeats
- start% = (copystartbar%*(10^3))+beats%
- ENDIF
- PROCsearch(start%)
- FOR count% = startcell% TO (startcell%+(numnotes%-1))
- FOR counter% = 0 TO 1
- barno% = (array%(count%,0,voice%)DIV10^6)-counter%
- beatnum% = ((array%(count%,0,voice%)DIV10^3)MOD10^3)
- :
- group1start% = (disarray%(barno%,0,voice%)DIV10^7)*beatfactor%
- group1end% = group1start% + (((disarray%(barno%,0,voice%)DIV10^5)MOD10^2)*beatfactor%)-1
- IF beatnum%+(960*counter%) >= group1start% AND beatnum%+(960*counter%) <= group1end% THEN
- disarray%(barno%,0,voice%) = disarray%(barno%,0,voice%)MOD10^3
- ENDIF
- :
- group2start% = ((disarray%(barno%,0,voice%)DIV10)MOD10^2)*beatfactor%
- group2end% = group2start%+((((disarray%(barno%,0,voice%)MOD10)*10)+(disarray%(barno%,1,voice%)DIV10^8))*beatfactor%)-1
- IF beatnum%+(960*counter%) >= group2start% AND beatnum%+(960*counter%) <= group2end% THEN
- disarray%(barno%,0,voice%) = (disarray%(barno%,0,voice%)DIV10^3)*10^3
- disarray%(barno%,1,voice%) = disarray%(barno%,1,voice%)MOD10^6
- ENDIF
- :
- group3start%=((disarray%(barno%,1,voice%)DIV10^4)MOD10^2)*beatfactor%
- group3end% = group3start% + (((disarray%(barno%,1,voice%)MOD10^4)DIV10^2)*beatfactor%)-1
- IF beatnum%+(960*counter%) >= group3start% AND beatnum%+(960*counter%) <= group3end% THEN
- disarray%(barno%,1,voice%) = (disarray%(barno%,1,voice%)DIV10^6)*10^6
- ENDIF
- :
- group4start% = (disarray%(barno%,2,voice%)DIV10^7)*beatfactor%
- group4end% = group4start%+(((disarray%(barno%,2,voice%)DIV10^5)MOD10^2)*beatfactor%)-1
- IF beatnum%+(960*counter%) >= group4start% AND beatnum%+(960*counter%) <= group4end% THEN
- disarray%(barno%,2,voice%) = disarray%(barno%,2,voice%)MOD10^3
- ENDIF
- :
- group5start% = (disarray%(barno%,3,voice%)DIV10^7)*beatfactor%
- group5end% = group5start%+(((disarray%(barno%,3,voice%)DIV10^4)MOD10^3)*beatfactor%)-1
- IF beatnum%+(960*counter%) >= group5start% AND beatnum%+(960*counter%) <= group5end% THEN
- disarray%(barno%,2,voice%) = (disarray%(barno%,2,voice%)DIV10^3)*10^3
- disarray%(barno%,3,voice%) = 0
- ENDIF
- :
- NEXT
- :
- NEXT
- PROCshuntleft(startcell%,numnotes%)
- :
- WHEN "C","c" :
- CLS
- PRINT '" If rhythmic groups cross from the bar(s) in question "
- PRINT " to other bars, use A or B to delete those groups, "
- PRINT " in which case press X"
- PRINT'" Otherwise, press C to continue with deleting"
- PRINT" self-contained bar(s)"
- CASE GET$ OF
- WHEN "X","x" : PROCdelete
- OTHERWISE
- ENDCASE
- CLS
- INPUT '" how many bars (0 = 100) "NUMbars%
- IF NUMbars% = 0 THEN NUMbars% = 100
- PRINT '" starting at bar "
- INPUT "(press 0 for first bar displayed) "STARTbar%
- IF STARTbar% = 0 THEN STARTbar% = startbar%
- :
- IF screenvoices$ = "n" THEN
- INPUT' " Which voice (0 = top) "voice%
- IF voice% = 0 THEN PROCpressenter
- ELSE
- PRINT'" Which screen voice "
- CASE GET$ OF
- WHEN "1" : voice% = 1
- WHEN "2" : voice% = 2
- WHEN "3" : voice% = 3
- OTHERWISE PROCpressenter
- ENDCASE
- ENDIF
- IF screenvoices$ = "y" AND voice% > 0 THEN voice% = displayvoices%(startv%+voice%-1)
- voice% -= 1
- IF voice% >= 0 THEN samevoice% = voice%
- IF voice% = -1 THEN voice% = samevoice%
- :
- startcell% = 0
- :
- FOR bar% = STARTbar% TO (STARTbar%+(NUMbars%-1))
- :
- IF numusedcells%(voice%)-startcell% > 0 THEN
- :
- start% = bar%*(10^3)
- IF start% < (array%(0,0,voice%)DIV10^3) THEN
- startcell% = 0
- ELSE PROCsearch(start%)
- ENDIF
- :
- numnotes% = 0
- WHILE (array%((startcell%+numnotes%),0,voice%)DIV10^6) = bar%
- numnotes% += 1
- ENDWHILE
- IF numnotes% > 0 THEN PROCshuntleft(startcell%,numnotes%)
- :
- FOR count% = 0 TO 3
- disarray%(bar%,count%,voice%) = 0
- NEXT
- :
- ENDIF
- :
- NEXT
- :
- WHEN "D","d" :
- IF screenvoices$ = "n" THEN
- INPUT' " Which voice "voice%
- ELSE
- PRINT'" Which screen voice "
- CASE GET$ OF
- WHEN "1" : voice% = 1
- WHEN "2" : voice% = 2
- WHEN "3" : voice% = 3
- OTHERWISE PROCpressenter
- ENDCASE
- ENDIF
- IF screenvoices$ = "y" AND voice% > 0 THEN voice% = displayvoices%(startv%+voice%-1)
- voice% -= 1
- IF voice% >= 0 THEN samevoice% = voice%
- IF voice% = -1 THEN voice% = samevoice%
- :
- FOR count% = 0 TO (numusedcells%(voice%)-1)
- array%(count%,0,voice%) = 0
- array%(count%,1,voice%) = 0
- array%(count%,2,voice%) = 0
- NEXT
- numusedcells%(voice%) = 0
- :
- FOR count% = 1 TO nobars%
- FOR counter% = 0 TO 3
- disarray%(count%,counter%,voice%) = 0
- NEXT
- NEXT
- :
- WHEN "G","g" :
- INPUT'" Between which voice "voice1%
- INPUT'" and which voice "voice2%
- voice1% -= 1 : voice2% -= 1
- FOR whichvoice% = voice1% TO voice2%
- voice% = whichvoice%
- FOR count% = 0 TO (numusedcells%(voice%)-1)
- array%(count%,0,voice%) = 0
- array%(count%,1,voice%) = 0
- array%(count%,2,voice%) = 0
- NEXT
- numusedcells%(voice%) = 0
- FOR count% = 1 TO nobars%
- FOR counter% = 0 TO 3
- disarray%(count%,counter%,voice%) = 0
- NEXT
- NEXT
- NEXT
- :
- OTHERWISE VDU 7 : PROCdelete
- :
- ENDCASE
- PROCdisplay
- ENDPROC
- :
- REM************************************************
- :
- DEF PROCshuntleft(startcell%,numnotes%)
- :
- FOR count% = startcell% TO numusedcells%(voice%)-(numnotes%+1)
- array%(count%,0,voice%) = array%(count%+numnotes%,0,voice%)
- array%(count%,1,voice%) = array%(count%+numnotes%,1,voice%)
- array%(count%,2,voice%) = array%(count%+numnotes%,2,voice%)
- NEXT
- FOR count% = (numusedcells%(voice%)-1) TO (numusedcells%(voice%)-numnotes%) STEP -1
- array%(count%,0,voice%) = 0
- array%(count%,1,voice%) = 0
- array%(count%,2,voice%) = 0
- NEXT
- numusedcells%(voice%) = numusedcells%(voice%)-numnotes%
- ENDPROC
- :
- REM********************************************************
- :
- DEF PROCpredisplay
- :
- CLS
- methd$ = "second"
- INPUT '" How many bars "numbars%
- INPUT '" starting at bar "startbar%
- INPUT '" How many voices "numvoices%
- :
- requestedend% = startbar% + numbars%
- :
- IF requestedend% > nobars% THEN startbar% -= (requestedend%-nobars%)
- IF startbar% < 1 THEN
- startbar% = 1 : numbars% = nobars%-1
- ENDIF
- IF numvoices% > numparts% THEN numvoices% = numparts%
- holdnum% = numvoices%
- :
- IF numvoices% > 9 THEN
- PRINT '" Are the voice numbers"
- PRINT " successive?"
- CASE GET$ OF
- WHEN "Y","y" :
- INPUT " starting at voice number "vce%
- FOR count% = 1 TO numvoices%
- displayvoices%(count%) = vce% + count% - 1
- holddisplay%(count%) = vce% + count% - 1
- NEXT
- methd$ = "first"
- OTHERWISE
- ENDCASE
- ENDIF
- IF methd$ = "second" THEN
- FOR count% = 1 TO numvoices%
- PRINT '" voice ";count%;
- INPUT " is voice "vce%
- displayvoices%(count%) = vce%
- holddisplay%(count%) = vce%
- NEXT
- ENDIF
- startv% = 1 : holdstart% = 1
- PROCdisplay
- ENDPROC
- :
- REM********************************************
- :
- DEF PROCquickdisplay
- :
- FOR count% = 1 TO quicknum%
- prequickdisplay%(count%) = quickdisplay%(count%)
- NEXT
- prequicknum% = quicknum%
- :
- IF quickdisplaywindow$ = "y" THEN
- PROCwindow(20,63,48,55) : ON
- ENDIF
- :
- IF numvoicesgiven$ = "n" THEN
- REPEAT
- INPUT'" How many voices "numvoices%
- UNTIL numvoices% > 0 : REM stops a crash if 0 accidentally input
- quicknum% = numvoices%
- ENDIF
- :
- IF numvoices% > 1 THEN
- PRINT'" Are the voices successive "
- CASE GET$ OF
- WHEN "N","n","2" : succ$ = "n"
- OTHERWISE succ$ = "y"
- ENDCASE
- ELSE
- succ$ = "n"
- ENDIF
- :
- IF succ$ = "y" THEN
- INPUT'" starting at voice "vce%
- FOR count% = 1 TO numvoices%
- displayvoices%(count%) = vce%+count%-1
- quickdisplay%(count%) = vce%+count%-1
- NEXT
- :
- ELSE
- FOR count% = 1 TO numvoices%
- IF numvoices% = 1 THEN
- PRINT'" which voice "
- ELSE
- PRINT'" voice ";count%;" is voice "
- ENDIF
- REPEAT
- INPUT vce%
- UNTIL vce% > 0
- displayvoices%(count%) = vce%
- quickdisplay%(count%) = vce%
- NEXT
- ENDIF
- :
- quicknum% = numvoices%
- startv% = 1
- toggle$ = "quick" : numvoicesgiven$ = "n"
- quickdisplaywindow$ = "y"
- PROCdisplay
- ENDPROC
- :
- REM********************************************
- :
- DEF PROCdisplay
- :
- *CONFIGURE ScreenSize 256K
- MODE 31
- VDU 5
- ledgerkey% = 1 : height1% = 0 : wideness1% = 0 : along% = 0
- :
- VDU 23,17,7,6,7;7;0;
- REM penultimate and pre-penultimate values determine text size
- :
- endv% = startv% + numvoices% - 1
- IF longscore$ = "y" AND (endv%-startv%)>2 THEN endv% = startv%+2
- :
- IF printing$ = "n" THEN
- GCOL 0 : GCOL 191 : CLG
- ELSE
- GCOL 0 : GCOL 191 : CLG
- ENDIF
- :
- REM display of beatnumbers, notenumbers etc shuffle up to occupy empty space
- beatsheight% = 0 : numbersheight% = 0 : intheight% = 0
- IF amplitudes$ = "y" THEN
- beatsheight% += 40 : numbersheight% += 40 : intheight% += 40
- ENDIF
- IF beatnumbers$ = "y" THEN
- numbersheight% += 40 : intheight% += 40
- ENDIF
- IF notenumbers$ = "y" OR notenumbers$ = "from1" THEN intheight% += 40
- :
- IF longscore$ = "n" THEN width% = 1520 ELSE width% = 1480
- IF printing$ = "y" THEN width% -= 0
- factor = width%/((numbars%/2)*960)
- IF longscore$ = "y" THEN factor = factor/2
- :
- REM stave lines, barlines & beats for shortscore
- IF longscore$ = "n" THEN
- IF staves$ = "y" THEN
- FOR count% = 938 TO 874 STEP -16 : LINE 0,count%,2112,count% : NEXT
- IF lowerstave$ = "y" THEN
- FOR count% = 794 TO 730 STEP -16 : LINE 0,count%,2112,count% : NEXT
- ENDIF
- FOR count% = 414 TO 350 STEP -16 : LINE 0,count%,2112,count% : NEXT
- IF lowerstave$ = "y" THEN
- FOR count% = 270 TO 206 STEP -16 : LINE 0,count%,2112,count% : NEXT
- ENDIF
- ENDIF
- :
- REM barlines
- IF barlines$ = "y" THEN
- FOR system% = 0 TO 1
- FOR barline% = 1 TO (numbars%/2)
- horpos% = (960*barline%*factor)+40
- IF notehead$ = "small" THEN horpos% += 16
- IF notehead$ = "vsmall" THEN horpos% += 24
- FOR thickness% = 2 TO 8 STEP 2
- LINE horpos%+thickness%,874-(524*system%),horpos%+thickness%,794-(524*system%)
- NEXT
- REM bar nos
- IF printing$ = "n" THEN GCOL 3
- IF tempi%(startbar%) <> tempi%(startbar%-1) THEN
- MOVE 40,1145 : PRINT "b.";startbar%;" MM.";tempi%(startbar%)
- ELSE MOVE 40,1145 : PRINT "b.";startbar%;" (MM.";tempi%(startbar%);")"
- ENDIF
- IF remarks$(startbar%,0) <> "" OR remarks$(startbar%,1) <> "" THEN
- MOVE 40,1120 : PRINT remarks$(startbar%,0) : MOVE 40,1095 : PRINT remarks$(startbar%,1)
- ENDIF
- IF printing$ = "n" THEN GCOL 0
- barline1% = (system%*(numbars%/2))+barline%
- MOVE horpos%-125,1145-(533*system%)
- IF printing$ = "n" THEN GCOL 3
- IF tempi%(startbar% + barline1%) <> tempi%(startbar% + barline1% - 1) THEN
- PRINT startbar% + barline1%;" MM.";tempi%(startbar% + barline1%);
- ELSE IF barline1% MOD barnosoften% = 0 THEN PRINT startbar% + barline1%
- ENDIF
- IF remarks$(startbar%+barline1%,0) <> "" OR remarks$(startbar%+barline1%,1) <> "" THEN
- MOVE horpos%,1120-(533*system%) : PRINT remarks$(startbar%+barline1%,0)
- MOVE horpos%,1095-(533*system%) : PRINT remarks$(startbar%+barline1%,1)
- ENDIF
- REM print duration at bottom right
- IF seeduration$ = "y" THEN
- IF startbar% + barline1% = startbar% + numbars% - 1 THEN
- totaldur = 0
- FOR count% = 1 TO startbar% + numbars% - 1
- duration = 60/tempi%(count%)
- totaldur = totaldur + duration
- NEXT
- totaldur% = totaldur
- mins% = totaldur% DIV 60
- secs% = totaldur% - (mins%*60)
- MOVE 1200,50 : PRINT "duration ";mins%;" mins ";secs%;" secs"
- ENDIF
- ENDIF
- IF printing$ = "n" THEN GCOL 0
- NEXT
- NEXT
- REM bar no for system 2 first bar
- MOVE -70,612
- IF printing$ = "n" THEN GCOL 3
- IF tempi%(startbar%+(numbars%/2)) <> tempi%(startbar%+(numbars%/2)-1) THEN
- PRINT startbar%+(numbars%/2);" MM.";tempi%(startbar%+(numbars%/2))
- ELSE IF (numbars%/2) MOD barnosoften% = 0 THEN PRINT startbar%+(numbars%/2)
- ENDIF
- IF remarks$(startbar%+(numbars%/2),0) <> "" OR remarks$(startbar%+(numbars%/2),1) <> "" THEN
- MOVE 40,587 : PRINT remarks$(startbar%+(numbars%/2),0)
- MOVE 40,562 : PRINT remarks$(startbar%+(numbars%/2),1)
- ENDIF
- IF printing$ = "n" THEN GCOL 0
- ENDIF
- :
- REM beats
- IF beats$ = "y" THEN
- IF notehead$ = "big" THEN add% = 26
- IF notehead$ = "small" THEN add% = 34
- IF notehead$ = "vsmall" THEN add% = 38
- :
- FOR system% = 0 TO 1
- FOR br% = 0 TO (numbars%/2)-1
- horpos% = (960*br%*factor)+add%+40
- FOR bt% = 0 TO (factor%-1) STEP beatstep%
- CIRCLE horpos%+(bt%*960/factor%*factor),834-(524*system%),4
- NEXT
- NEXT
- NEXT
- ENDIF
- :
- ENDIF
- :
- REM staves, barlines, beats etc for longscore
- IF longscore$ = "y" THEN
- longinsts$() = ""
- REM staves
- lastcount% = numvoices%-1
- IF lastcount% > 2 THEN lastcount% = 2
- FOR count% = 0 TO lastcount%
- longinsts$(count%,0) = insts$(displayvoices%(startv%+count%),0)
- longinsts$(count%,1) = insts$(displayvoices%(startv%+count%),1)
- longinsts$(count%,2) = insts$(displayvoices%(startv%+count%),2)
- NEXT
- stavecombination$ = longinsts$(0,2) + longinsts$(1,2) + longinsts$(2,2)
- clefcombination$ = longinsts$(0,1)+longinsts$(1,1)+longinsts$(2,1)
- CASE stavecombination$ OF
- WHEN "111" :
- IF staves$ = "y" THEN
- FOR count% = 0 TO 64 STEP16 : LINE 0,938-count%,2112,938-count% : NEXT
- FOR count% = 0 TO 64 STEP16 : LINE 0,604-count%,2112,604-count% : NEXT
- FOR count% = 0 TO 64 STEP16 : LINE 0,270-count%,2112,270-count% : NEXT
- ENDIF
- PROCclef(3,938,604,270,0,0,0,clefcombination$)
- PROClongvalue(938,604,270,clefcombination$)
- WHEN "121" :
- IF staves$ = "y" THEN
- FOR count% = 0 TO 64 STEP16 : LINE 0,938-count%,2112,938-count% : NEXT
- FOR count% = 0 TO 64 STEP16 : LINE 0,652-count%,2112,652-count% : NEXT
- FOR count% = 0 TO 64 STEP16 : LINE 0,556-count%,2112,556-count% : NEXT
- FOR count% = 0 TO 64 STEP16 : LINE 0,270-count%,2112,270-count% : NEXT
- ENDIF
- PROCclef(4,938,652,556,270,0,0,clefcombination$)
- PROClongvalue(938,652,270,clefcombination$)
- WHEN "211" :
- IF staves$ = "y" THEN
- FOR count% = 0 TO 64 STEP16 : LINE 0,938-count%,2112,938-count% : NEXT
- FOR count% = 0 TO 64 STEP16 : LINE 0,842-count%,2112,842-count% : NEXT
- FOR count% = 0 TO 64 STEP16 : LINE 0,556-count%,2112,556-count% : NEXT
- FOR count% = 0 TO 64 STEP16 : LINE 0,270-count%,2112,270-count% : NEXT
- ENDIF
- PROCclef(4,938,842,556,270,0,0,clefcombination$)
- PROClongvalue(938,556,270,clefcombination$)
- WHEN "112" :
- IF staves$ = "y" THEN
- FOR count% = 0 TO 64 STEP16 : LINE 0,938-count%,2112,938-count% : NEXT
- FOR count% = 0 TO 64 STEP16 : LINE 0,652-count%,2112,652-count% : NEXT
- FOR count% = 0 TO 64 STEP16 : LINE 0,366-count%,2112,366-count% : NEXT
- FOR count% = 0 TO 64 STEP16 : LINE 0,270-count%,2112,270-count% : NEXT
- ENDIF
- PROCclef(4,938,652,366,270,0,0,clefcombination$)
- PROClongvalue(938,652,366,clefcombination$)
- WHEN "221" :
- IF staves$ = "y" THEN
- FOR count% = 0 TO 64 STEP16 : LINE 0,938-count%,2112,938-count% : NEXT
- FOR count% = 0 TO 64 STEP16 : LINE 0,842-count%,2112,842-count% : NEXT
- FOR count% = 0 TO 64 STEP16 : LINE 0,604-count%,2112,604-count% : NEXT
- FOR count% = 0 TO 64 STEP16 : LINE 0,508-count%,2112,508-count% : NEXT
- FOR count% = 0 TO 64 STEP16 : LINE 0,270-count%,2112,270-count% : NEXT
- ENDIF
- PROCclef(5,938,842,604,508,270,0,clefcombination$)
- PROClongvalue(938,604,270,clefcombination$)
- WHEN "222" :
- IF staves$ = "y" THEN
- FOR count% = 0 TO 64 STEP16 : LINE 0,938-count%,2112,938-count% : NEXT
- FOR count% = 0 TO 64 STEP16 : LINE 0,842-count%,2112,842-count% : NEXT
- FOR count% = 0 TO 64 STEP16 : LINE 0,652-count%,2112,652-count% : NEXT
- FOR count% = 0 TO 64 STEP16 : LINE 0,556-count%,2112,556-count% : NEXT
- FOR count% = 0 TO 64 STEP16 : LINE 0,366-count%,2112,366-count% : NEXT
- FOR count% = 0 TO 64 STEP16 : LINE 0,270-count%,2112,270-count% : NEXT
- ENDIF
- PROCclef(6,938,842,652,556,366,270,clefcombination$)
- PROClongvalue(938,652,366,clefcombination$)
- WHEN "122" :
- IF staves$ = "y" THEN
- FOR count% = 0 TO 64 STEP16 : LINE 0,938-count%,2112,938-count% : NEXT
- FOR count% = 0 TO 64 STEP16 : LINE 0,700-count%,2112,700-count% : NEXT
- FOR count% = 0 TO 64 STEP16 : LINE 0,604-count%,2112,604-count% : NEXT
- FOR count% = 0 TO 64 STEP16 : LINE 0,366-count%,2112,366-count% : NEXT
- FOR count% = 0 TO 64 STEP16 : LINE 0,270-count%,2112,270-count% : NEXT
- ENDIF
- PROCclef(5,938,700,604,366,270,0,clefcombination$)
- PROClongvalue(938,700,366,clefcombination$)
- WHEN "212" :
- IF staves$ = "y" THEN
- FOR count% = 0 TO 64 STEP16 : LINE 0,938-count%,2112,938-count% : NEXT
- FOR count% = 0 TO 64 STEP16 : LINE 0,842-count%,2112,842-count% : NEXT
- FOR count% = 0 TO 64 STEP16 : LINE 0,604-count%,2112,604-count% : NEXT
- FOR count% = 0 TO 64 STEP16 : LINE 0,366-count%,2112,366-count% : NEXT
- FOR count% = 0 TO 64 STEP16 : LINE 0,270-count%,2112,270-count% : NEXT
- ENDIF
- PROCclef(5,938,842,604,366,270,0,clefcombination$)
- PROClongvalue(938,604,366,clefcombination$)
- WHEN "1" :
- IF staves$ = "y" THEN
- FOR count% = 0 TO 64 STEP16 : LINE 0,938-count%,2112,938-count% : NEXT
- ENDIF
- PROCclef(1,938,0,0,0,0,0,clefcombination$)
- PROClongvalue(938,0,0,clefcombination$)
- WHEN "2" :
- IF staves$ = "y" THEN
- FOR count% = 0 TO 64 STEP16 : LINE 0,938-count%,2112,938-count% : NEXT
- FOR count% = 0 TO 64 STEP16 : LINE 0,842-count%,2112,842-count% : NEXT
- ENDIF
- PROCclef(2,938,842,0,0,0,0,clefcombination$)
- PROClongvalue(938,0,0,clefcombination$)
- WHEN "11" :
- IF staves$ = "y" THEN
- FOR count% = 0 TO 64 STEP16 : LINE 0,938-count%,2112,938-count% : NEXT
- FOR count% = 0 TO 64 STEP16 : LINE 0,604-count%,2112,604-count% : NEXT
- ENDIF
- PROCclef(2,938,604,0,0,0,0,clefcombination$)
- PROClongvalue(938,604,0,clefcombination$)
- WHEN "12" :
- IF staves$ = "y" THEN
- FOR count% = 0 TO 64 STEP16 : LINE 0,938-count%,2112,938-count% : NEXT
- FOR count% = 0 TO 64 STEP16 : LINE 0,652-count%,2112,652-count% : NEXT
- FOR count% = 0 TO 64 STEP16 : LINE 0,556-count%,2112,556-count% : NEXT
- ENDIF
- PROCclef(3,938,652,556,0,0,0,clefcombination$)
- PROClongvalue(938,652,0,clefcombination$)
- WHEN "21" :
- IF staves$ = "y" THEN
- FOR count% = 0 TO 64 STEP16 : LINE 0,938-count%,2112,938-count% : NEXT
- FOR count% = 0 TO 64 STEP16 : LINE 0,842-count%,2112,842-count% : NEXT
- FOR count% = 0 TO 64 STEP16 : LINE 0,556-count%,2112,556-count% : NEXT
- ENDIF
- PROCclef(3,938,842,556,0,0,0,clefcombination$)
- PROClongvalue(938,556,0,clefcombination$)
- WHEN "22" :
- IF staves$ = "y" THEN
- FOR count% = 0 TO 64 STEP16 : LINE 0,938-count%,2112,938-count% : NEXT
- FOR count% = 0 TO 64 STEP16 : LINE 0,842-count%,2112,842-count% : NEXT
- FOR count% = 0 TO 64 STEP16 : LINE 0,556-count%,2112,556-count% : NEXT
- FOR count% = 0 TO 64 STEP16 : LINE 0,460-count%,2112,460-count% : NEXT
- ENDIF
- PROCclef(4,938,842,556,460,0,0,clefcombination$)
- PROClongvalue(938,556,0,clefcombination$)
- ENDCASE
- :
- REM time signature
- beatstothebar% = (960/beatfactor%)/8
- CASE beams% OF
- WHEN 1 : whichvalue% = 1
- WHEN 2 : whichvalue% = 2
- WHEN 3 : whichvalue% = 4
- WHEN 4 : whichvalue% = 8
- WHEN 5 : whichvalue% = 16
- WHEN 6 : whichvalue% = 32
- ENDCASE
- MOVE 15,1050
- PRINT "meter"
- MOVE 15,1030
- PRINT" ";beatstothebar%;"/";whichvalue%
- :
- REM beats
- IF beats$ = "y" THEN
- IF notehead$ = "big" THEN add% = 26
- IF notehead$ = "small" THEN add% = 34
- IF notehead$ = "vsmall" THEN add% = 38
- :
- FOR br% = 0 TO (numbars%-1)
- horpos% = (960*br%*factor)+add%+80
- FOR bt% = 0 TO (factor%-1) STEP beatstep%
- CIRCLE horpos%+(bt%*960/factor%*factor),longbeatsupper%,4:CIRCLE horpos%+(bt%*960/factor%*factor),longbeatslower%,4
- NEXT
- NEXT
- ENDIF
- ENDIF
- :
- IF longscore$ = "n" THEN number% = 2 ELSE number% = 1
- FOR system% = 1 TO number%
- :
- FOR count% = startv% TO endv%
- :
- voice% = (displayvoices%(count%))-1
- addingnotes$ = "n"
- current% = 0 : lowernumber% = 0
- IF system% = 1 THEN firstbar% = startbar%
- IF system% = 2 THEN firstbar% = startbar%+(numbars%/2)
- PROCnewnotereception(voice%,firstbar%,0,0,0,0,0,0,0)
- CASE option% OF
- WHEN 1 : startcell% = 0
- WHEN 2 : startcell% = numusedcells%(voice%)
- WHEN 3 : startcell% = 0
- WHEN 4 : start% = firstbar%*10^3 : PROCsearch(start%)
- ENDCASE
- holdstartcell%(voice%) = startcell%
- :
- IF array%(startcell%,0,voice%)DIV10^6 > 0 THEN
- :
- howmany% = 0
- REPEAT
- howmany% += 1
- :
- carrybars% = (array%(startcell%,0,voice%)DIV10^6) - firstbar%
- beat% = ((array%(startcell%,0,voice%)DIV10^3)MOD10^3)+(carrybars%*960)
- hposn% = (beat%*factor)+50 : REM gives horiz co-ordinate
- :
- IF howmany% = 1 THEN firsttrack% = hposn%
- :
- IF longscore$ = "y" THEN hposn% += 40
- :
- octave% = (array%(startcell%,0,voice%)MOD10)
- IF longscore$ = "n" THEN
- IF octave% < 4 AND system% = 1 THEN value% = 586
- IF octave% >= 4 AND system% = 1 THEN value% = 858
- IF octave% < 4 AND system% = 2 THEN value% = 62
- IF octave% >= 4 AND system% = 2 THEN value% = 334
- IF octave% > 3 THEN octave% = octave%-4
- ENDIF
- :
- ENDCASE
- IF longscore$ = "y" THEN value% = value%(count%-startv%)
- :
- vposn% = value%+(((array%(startcell%,0,voice%)MOD10^3)DIV10^2)*8)+(octave%*56) : REM gives vert co-ordinate
- :
- REM notehead
- IF redpitches$ = "y" THEN PROCredpitches
- IF notehead$ = "big" THEN
- LINE hposn%+12,vposn%+8,hposn%+26,vposn%+8
- LINE hposn%+4,vposn%+4,hposn%+30,vposn%+4
- LINE hposn%,vposn%,hposn%+32,vposn%
- LINE hposn%+2,vposn%-4,hposn%+28,vposn%-4
- LINE hposn%+6,vposn%-8,hposn%+20,vposn%-8
- ENDIF
- IF notehead$ = "small" THEN
- LINE hposn%+24,vposn%+8,hposn%+28,vposn%+8
- LINE hposn%+20,vposn%+4,hposn%+30,vposn%+4
- LINE hposn%+16,vposn%,hposn%+32,vposn%
- LINE hposn%+18,vposn%-4,hposn%+28,vposn%-4
- LINE hposn%+20,vposn%-8,hposn%+24,vposn%-8
- ENDIF
- IF notehead$ = "vsmall" THEN
- LINE hposn%+28,vposn%+8,hposn%+28,vposn%+8
- LINE hposn%+27,vposn%+6,hposn%+29,vposn%+6
- LINE hposn%+26,vposn%+4,hposn%+30,vposn%+4
- LINE hposn%+25,vposn%+2,hposn%+31,vposn%+2
- LINE hposn%+24,vposn%,hposn%+32,vposn%
- LINE hposn%+25,vposn%-2,hposn%+31,vposn%-2
- LINE hposn%+26,vposn%-4,hposn%+30,vposn%-4
- LINE hposn%+27,vposn%-6,hposn%+29,vposn%-6
- LINE hposn%+28,vposn%-8,hposn%+28,vposn%-8
- ENDIF
- IF printing$ = "n" THEN GCOL 0
- :
- REM beatnumbers
- IF beatnumbers$ = "y" OR (beatnumbers$ = "first" AND howmany% = 1) THEN
- PROCnotenumbersep
- IF longscore$ = "y" THEN
- MOVE hposn%-100,actamppos%(voice%+1)-beatsheight%-lower%-lowernumber%
- PROCbeatnumbers
- ELSE MOVE hposn%-100,674+shortamppos%(voice%)-((system%-1)*524)-beatsheight%+40-lower%
- PROCbeatnumbers
- ENDIF
- ENDIF
- :
- REM notenumbers
- IF notenumbers$ = "y" THEN
- PROCnotenumbersep
- IF longscore$ = "y" THEN
- MOVE hposn%-100,actamppos%(voice%+1)-numbersheight%-lowernumber%
- PRINT startcell%+1
- ELSE MOVE hposn%-100,(674+shortamppos%(voice%)-((system%-1)*524))-numbersheight%+40
- PRINT startcell%+1
- ENDIF
- ENDIF
- :
- IF notenumbers$ = "last" THEN
- IF (array%(startcell%+1,0,voice%) DIV10^6) >= (numbars%+firstbar%) OR array%(startcell%+1,0,voice%) = 0 THEN print$ = "y" ELSE print$ = "n"
- IF print$ = "y" THEN
- MOVE hposn%-100,actamppos%(voice%+1)-numbersheight%
- PRINT startcell%+1
- ENDIF
- ENDIF
- :
- IF notenumbers$ = "from1" THEN
- PROCnotenumberfreq
- PROCnotenumbersep
- IF printnumber$ = "y" THEN
- IF longscore$ = "y" THEN
- MOVE hposn%-100,actamppos%(voice%+1)-numbersheight%-lowernumber%
- PRINT howmany%
- ELSE MOVE hposn%-100,(674+shortamppos%(voice%)-((system%-1)*524))-numbersheight%+40
- PRINT howmany%
- ENDIF
- ENDIF
- ENDIF
- :
- REM intervals
- IF displayintervals$ = "y" THEN
- pitch% = array%(startcell%,0,voice%)MOD10^3
- CASE typeintervals$ OF
- WHEN "s" : PROCconvertpitch
- WHEN "q" : PROCconvertquarter
- WHEN "e" : PROCconverteighth
- WHEN "c" : cent% = (array%(startcell%,2,voice%)MOD10^2)-50 : PROCconvertcent
- OTHERWISE
- ENDCASE
- currentpitch% = note%
- FOR cout% = 1 TO numintervals%
- IF (startcell%-cout%) >= 0 THEN
- pitch% = array%((startcell%-cout%),0,voice%)MOD10^3
- CASE typeintervals$ OF
- WHEN "s" : PROCconvertpitch
- WHEN "q" : PROCconvertquarter
- WHEN "e" : PROCconverteighth
- WHEN "c" : cent% = (array%((startcell%-cout%),2,voice%)MOD10^2)-50 : PROCconvertcent
- OTHERWISE
- ENDCASE
- comparepitch% = note%
- IF currentpitch% >= comparepitch% THEN
- interval% = currentpitch% - comparepitch%
- ELSE interval% = comparepitch% - currentpitch%
- ENDIF
- REPEAT : IF interval% > compoundint% THEN interval% -= chunk% : UNTIL interval% <= compoundint%
- IF longscore$ = "y" THEN
- MOVE hposn%-125,actamppos%(voice%+1)-(intheight%+(40*(cout%-1)))
- PRINT interval%
- ELSE MOVE hposn%-125,(674+shortamppos%(voice%)-((system%-1)*524))-(intheight%+(40*(cout%-1))-40)
- PRINT interval%
- ENDIF
- ENDIF
- NEXT
- ENDIF
- :
- REM note names
- IF notenames$ = "y" THEN
- whichnote% = (array%(startcell%,0,voice%)MOD10^3)DIV10^2
- CASE whichnote% OF
- WHEN 0 : name$ = "C"
- WHEN 1 : name$ = "D"
- WHEN 2 : name$ = "E"
- WHEN 3 : name$ = "F"
- WHEN 4 : name$ = "G"
- WHEN 5 : name$ = "A"
- WHEN 6 : name$ = "B"
- OTHERWISE
- ENDCASE
- MOVE hposn%+10,actamppos%(voice%+1)-(numbersheight%+32)
- PRINT name$;array%(startcell%,0,voice%)MOD10
- ENDIF
- :
- REM durations/glissandos
- IF durations$ = "y" THEN
- dur% = (array%(startcell%,1,voice%)DIV10)MOD10^3
- brrr% = array%(startcell%,0,voice%)DIV10^6 : PROCreconvertdur
- IF notehead$ = "big" THEN pointplus% = 16
- IF notehead$ = "small" THEN pointplus% = 24
- IF notehead$ = "vsmall" THEN pointplus% = 28
- point% = (dur%*factor)+hposn%+pointplus%
- thirdphase$ = "n"
- :
- number% = array%(startcell%,2,voice%)DIV10^5
- IF number% = 0 THEN numphases% = 1
- IF number% > 0 AND number% < 100 THEN numphases% = 2
- IF number% > 99 THEN numphases% = 3
- :
- CASE numphases% OF
- :
- WHEN 1 :
- gl% = (array%(startcell%,1,voice%)DIV10^4)MOD10^2
- IF gl% <> 50 THEN
- PROCroundgliss
- LINE hposn%+40,vposn%+4,point%,vposn%+4+gl%
- hp% = ((point%-hposn%)/2)+hposn%
- vp% = vposn%+44+(gl%/2)
- MOVE hp%,vp% : PRINT "gl.";gl1%
- ELSE
- LINE hposn%+40,vposn%+4,point%,vposn%+4
- ENDIF
- :
- WHEN 2 :
- REM extra horizontal point in middle
- ph1% = number% MOD 10^2
- point1% = ((dur%*ph1%/100)*factor)+hposn%+pointplus%
- :
- REM first phase
- gl% = (array%(startcell%,1,voice%)DIV10^4)MOD10^2
- IF gl% <> 50 THEN
- PROCroundgliss
- LINE hposn%+40,vposn%+4,point1%,vposn%+4+gl%
- hp% = ((point1%-hposn%)/2)+hposn%
- vp% = vposn%+44+(gl%/2)
- MOVE hp%,vp% : PRINT "gl.";gl1%
- ELSE
- gl% = 0
- LINE hposn%+40,vposn%+4,point1%,vposn%+4
- ENDIF
- IF envelopedata$ <> "none" THEN
- hp% = point1%-130
- vp% = vposn%-10
- MOVE hp%,vp%
- CASE envelopedata$ OF
- WHEN "percentage" :PRINT ph1%;"%"
- WHEN "marker" : PRINT hp%
- ENDCASE
- ENDIF
- :
- REM second phase
- vposn1% = vposn%+gl%
- gl% = (array%(startcell%,1,voice%)DIV10^6)MOD10^2
- IF gl% <> 50 THEN
- PROCroundgliss
- LINE point1%,vposn1%+4,point%,vposn1%+4+gl%
- hp% = ((point%-point1%)/2)+point1%
- vp% = vposn1%+44+(gl%/2)
- MOVE hp%,vp% : PRINT "gl.";gl1%
- ELSE
- LINE point1%,vposn1%+4,point%,vposn1%+4
- ENDIF
- :
- WHEN 3 :
- REM two extra horizontal points in middle
- ph1% = number% MOD 10^2
- point1% = ((dur%*ph1%/100)*factor)+hposn%+pointplus%
- ph2% = number% DIV 10^2
- point2% = ((dur%*ph2%/100)*factor)+hposn%+pointplus%
- :
- REM first phase
- gl% = (array%(startcell%,1,voice%)DIV10^4)MOD10^2
- IF gl% <> 50 THEN
- PROCroundgliss
- LINE hposn%+40,vposn%+4,point1%,vposn%+4+gl%
- hp% = ((point1%-hposn%)/2)+hposn%
- vp% = vposn%+44+(gl%/2)
- MOVE hp%,vp% : PRINT "gl.";gl1%
- ELSE
- gl% = 0
- LINE hposn%+40,vposn%+4,point1%,vposn%+4
- ENDIF
- IF envelopedata$ <> "none" THEN
- hp% = point1%-130
- vp% = vposn%-10
- MOVE hp%,vp%
- CASE envelopedata$ OF
- WHEN "percentage" :PRINT ph1%;"%"
- WHEN "marker" : PRINT hp%
- ENDCASE
- ENDIF
- :
- REM second phase
- vposn1% = vposn%+gl%
- gl% = (array%(startcell%,1,voice%)DIV10^6)MOD10^2
- IF gl% <> 50 THEN
- PROCroundgliss
- LINE point1%,vposn1%+4,point2%,vposn1%+4+gl%
- hp% = ((point2%-point1%)/2)+point1%
- vp% = vposn1%+44+(gl%/2)
- MOVE hp%,vp% : PRINT "gl.";gl1%
- ELSE
- gl% = 0
- LINE point1%,vposn1%+4,point2%,vposn1%+4
- ENDIF
- IF envelopedata$ <> "none" THEN
- hp% = point2%-130
- vp% = vposn%-10
- MOVE hp%,vp%
- CASE envelopedata$ OF
- WHEN "percentage" :PRINT ph2%;"%"
- WHEN "marker" : PRINT hp%
- ENDCASE
- ENDIF
- :
- REM third phase
- vposn2% = vposn1%+gl%
- gl% = array%(startcell%,1,voice%)DIV10^8
- IF gl% <> 10 THEN
- thirdphase$ = "y" : PROCroundgliss : thirdphase$ = "n"
- LINE point2%,vposn2%+4,point%,vposn2%+4+gl%
- hp% = ((point%-point2%)/2)+point2%
- vp% = vposn2%+44+(gl%/2)
- MOVE hp%,vp% : PRINT "gl.";gl1%
- ELSE
- LINE point2%,vposn2%+4,point%,vposn2%+4
- ENDIF
- :
- ENDCASE
- :
- ENDIF
- :
- REM next block of code added just to print durations
- IF seedurinbts$ = "y" OR seedurinbts$ = "stepped" THEN
- IF seedurinbts$ = "stepped" THEN
- IF lower% = 0 THEN lower% = 23 ELSE lower% = 0
- ENDIF
- IF longscore$ = "y" THEN
- MOVE hposn%,actamppos%(voice%+1)-lower%
- PRINT dur%
- ELSE MOVE hposn%,714+shortamppos%(voice%)-((system%-1)*524)-lower%
- PRINT dur%
- ENDIF
- ENDIF
- IF seedurincrots$ = "y" OR seedurincrots$ = "stepped" THEN
- REM dur = (((dur%/480)*100)DIV1)/100
- dur = (((dur%/(beatfactor%*8))*100)DIV1)/100
- IF seedurincrots$ = "stepped" THEN
- IF lower% = 0 THEN lower% = 23 ELSE lower% = 0
- ENDIF
- IF longscore$ = "y" THEN
- MOVE hposn%,actamppos%(voice%+1)-lower%
- PRINT dur
- ELSE MOVE hposn%,714+shortamppos%(voice%)-((system%-1)*524)-lower%
- PRINT dur
- ENDIF
- ENDIF
- :
- REM amplitudes
- :
- IF amplitudes$ = "y" OR amplitudes$ = "stepped" THEN
- amp$=""
- amp1% = array%(startcell%,1,voice%)MOD10
- amp2% = (array%(startcell%,2,voice%)DIV10^2)MOD10
- amp3% = (array%(startcell%,2,voice%)DIV10^3)MOD10
- amp4% = (array%(startcell%,2,voice%)DIV10^4)MOD10
- FOR something% = 1 TO 4
- IF something% = 1 THEN amp% = amp1%
- IF something% = 2 THEN amp% = amp2%
- IF something% = 3 THEN amp% = amp3%
- IF something% = 4 THEN amp% = amp4%
- CASE amp% OF
- WHEN 0 :
- IF amp1% = 0 AND amp2% = 9 THEN
- amp$ = "" : x% = 22 : y% = 20 : REM releases
- ELSE
- amp$ = "0" : x% = 22 : y% = 20
- ENDIF
- WHEN 1 : amp$ = "ppp" : x% = 8 : y% = 50
- WHEN 2 : amp$ = "pp" : x% = 15 : y% = 35
- WHEN 3 : amp$ = "p" : x% = 22 : y% = 20
- WHEN 4 : amp$ = "mp" : x% = 15 : y% = 35
- WHEN 5 : amp$ = "mf" : x% = 15 : y% = 35
- WHEN 6 : amp$ = "f" : x% = 22 : y% = 20
- WHEN 7 : amp$ = "ff" : x% = 15 : y% = 35
- WHEN 8 : amp$ = "fff" : x% = 8 : y% = 50
- ENDCASE
- IF something% = 1 THEN amp1$ = amp$ : x1% = x% : y1% = y%
- IF something% = 2 THEN amp2$ = amp$ : x2% = x% : y2% = y%
- IF something% = 3 THEN amp3$ = amp$ : x3% = x% : y3% = y%
- IF something% = 4 THEN amp4$ = amp$ : x4% = x% : y4% = y%
- NEXT
- :
- IF amplitudes$ = "stepped" THEN
- IF lower% = 0 THEN lower% = 23 ELSE lower% = 0
- ENDIF
- :
- IF longscore$ = "y" THEN
- MOVE hposn%+x1%,actamppos%(voice%+1)-lower%
- PRINT amp1$
- :
- IF amp2% = 9 AND amp3% <> 0 THEN
- MOVE hposn%+20,(actamppos%(voice%+1)-lower%)-20
- PRINT "+";amp3%
- ENDIF
- :
- ELSE MOVE hposn%+x1%,714+shortamppos%(voice%)-((system%-1)*524)-lower%
- PRINT amp1$
- ENDIF
- :
- dur% = (array%(startcell%,1,voice%)DIV10)MOD10^3
- brrr% = array%(startcell%,0,voice%)DIV10^6 : PROCreconvertdur
- IF notehead$ = "big" THEN pointplus% = 16
- IF notehead$ = "small" THEN pointplus% = 24
- IF notehead$ = "vsmall" THEN pointplus% = 28
- point% = (dur%*factor)+hposn%+pointplus%
- :
- number% = array%(startcell%,2,voice%)DIV10^5
- IF amp2% = 9 THEN numphases% = 0
- IF amp2% <> 9 AND number% = 0 THEN numphases% = 1
- IF number% > 0 AND number% < 100 THEN numphases% = 2
- IF number% > 99 THEN numphases% = 3
- :
- CASE numphases% OF
- :
- WHEN 1 :
- IF amp2% < amp1% THEN
- IF longscore$ = "y" THEN
- LINE hposn%+x1%+y1%,actamppos%(voice%+1)+8,point%-90+(x2%*2),actamppos%(voice%+1)-8
- LINE hposn%+x1%+y1%,actamppos%(voice%+1)-24,point%-90+(x2%*2),actamppos%(voice%+1)-8
- MOVE point%-80+(x2%*2),actamppos%(voice%+1) : PRINT amp2$
- ELSE LINE hposn%+x1%+y1%,714+shortamppos%(voice%)-((system%-1)*524)+8,point%-90+(x2%*2),714+shortamppos%(voice%)-((system%-1)*524)-8
- LINE hposn%+x1%+y1%,714+shortamppos%(voice%)-((system%-1)*524)-24,point%-90+(x2%*2),714+shortamppos%(voice%)-((system%-1)*524)-8
- MOVE point%-80+(x2%*2),714+shortamppos%(voice%)-((system%-1)*524) : PRINT amp2$
- ENDIF
- ENDIF
- IF amp2% > amp1% THEN
- IF longscore$ = "y" THEN
- LINE hposn%+x1%+y1%,actamppos%(voice%+1)-8,point%-90+(x2%*2),actamppos%(voice%+1)+8
- LINE hposn%+x1%+y1%,actamppos%(voice%+1)-8,point%-90+(x2%*2),actamppos%(voice%+1)-24
- MOVE point%-80+(x2%*2),actamppos%(voice%+1) : PRINT amp2$
- ELSE LINE hposn%+x1%+y1%,714+shortamppos%(voice%)-((system%-1)*524)-8,point%-90+(x2%*2),714+shortamppos%(voice%)-((system%-1)*524)+8
- LINE hposn%+x1%+y1%,714+shortamppos%(voice%)-((system%-1)*524)-8,point%-90+(x2%*2),714+shortamppos%(voice%)-((system%-1)*524)-24
- MOVE point%-80+(x2%*2),714+shortamppos%(voice%)-((system%-1)*524) : PRINT amp2$
- ENDIF
- ENDIF
- :
- WHEN 2 :
- ph1% = number% MOD 10^2
- point1% = ((dur%*ph1%/100)*factor)+hposn%+pointplus%
- :
- REM first phase
- IF amp2% < amp1% THEN
- IF longscore$ = "y" THEN
- LINE hposn%+x1%+y1%,actamppos%(voice%+1)+8,point1%-35+x2%,actamppos%(voice%+1)-8
- LINE hposn%+x1%+y1%,actamppos%(voice%+1)-24,point1%-35+x2%,actamppos%(voice%+1)-8
- MOVE point1%-25+x2%,actamppos%(voice%+1) : PRINT amp2$
- ELSE LINE hposn%+x1%+y1%,714+shortamppos%(voice%)-((system%-1)*524)+8,point1%-35+x2%,714+shortamppos%(voice%)-((system%-1)*524)-8
- LINE hposn%+x1%+y1%,714+shortamppos%(voice%)-((system%-1)*524)-24,point1%-35+x2%,714+shortamppos%(voice%)-((system%-1)*524)-8
- MOVE point1%-25+x2%,714+shortamppos%(voice%)-((system%-1)*524) : PRINT amp2$
- ENDIF
- ENDIF
- IF amp2% > amp1% THEN
- IF longscore$ = "y" THEN
- LINE hposn%+x1%+y1%,actamppos%(voice%+1)-8,point1%-35+x2%,actamppos%(voice%+1)+8
- LINE hposn%+x1%+y1%,actamppos%(voice%+1)-8,point1%-35+x2%,actamppos%(voice%+1)-24
- MOVE point1%-25+x2%,actamppos%(voice%+1) : PRINT amp2$
- ELSE LINE hposn%+x1%+y1%,714+shortamppos%(voice%)-((system%-1)*524)-8,point1%-35+x2%,714+shortamppos%(voice%)-((system%-1)*524)+8
- LINE hposn%+x1%+y1%,714+shortamppos%(voice%)-((system%-1)*524)-8,point1%-35+x2%,714+shortamppos%(voice%)-((system%-1)*524)-24
- MOVE point1%-25+x2%,714+shortamppos%(voice%)-((system%-1)*524) : PRINT amp2$
- ENDIF
- ENDIF
- :
- REM second phase
- IF amp1% <> amp2% THEN start% = point1%-25+x2%+y2% ELSE start% = point1%
- IF amp3% < amp2% THEN
- IF longscore$ = "y" THEN
- LINE start%,actamppos%(voice%+1)+8,point%-90+(x3%*2),actamppos%(voice%+1)-8
- LINE start%,actamppos%(voice%+1)-24,point%-90+(x3%*2),actamppos%(voice%+1)-8
- MOVE point%-80+(x3%*2),actamppos%(voice%+1) : PRINT amp3$
- ELSE LINE start%,714+shortamppos%(voice%)-((system%-1)*524)+8,point%-90+(x3%*2),714+shortamppos%(voice%)-((system%-1)*524)-8
- LINE start%,714+shortamppos%(voice%)-((system%-1)*524)-24,point%-90+(x3%*2),714+shortamppos%(voice%)-((system%-1)*524)-8
- MOVE point%-80+(x3%*2),714+shortamppos%(voice%)-((system%-1)*524) : PRINT amp3$
- ENDIF
- ENDIF
- IF amp3% > amp2% THEN
- IF longscore$ = "y" THEN
- LINE start%,actamppos%(voice%+1)-8,point%-90+(x3%*2),actamppos%(voice%+1)+8
- LINE start%,actamppos%(voice%+1)-8,point%-90+(x3%*2),actamppos%(voice%+1)-24
- MOVE point%-80+(x3%*2),actamppos%(voice%+1) : PRINT amp3$
- ELSE LINE start%,714+shortamppos%(voice%)-((system%-1)*524)-8,point%-90+(x3%*2),714+shortamppos%(voice%)-((system%-1)*524)+8
- LINE start%,714+shortamppos%(voice%)-((system%-1)*524)-8,point%-90+(x3%*2),714+shortamppos%(voice%)-((system%-1)*524)-24
- MOVE point%-80+(x3%*2),714+shortamppos%(voice%)-((system%-1)*524) : PRINT amp3$
- ENDIF
- ENDIF
- :
- WHEN 3 :
- ph1% = number% MOD 10^2
- point1% = ((dur%*ph1%/100)*factor)+hposn%+pointplus%
- ph2% = number% DIV 10^2
- point2% = ((dur%*ph2%/100)*factor)+hposn%+pointplus%
- :
- REM first phase
- IF amp2% < amp1% THEN
- IF longscore$ = "y" THEN
- LINE hposn%+x1%+y1%,actamppos%(voice%+1)+8,point1%-35+x2%,actamppos%(voice%+1)-8
- LINE hposn%+x1%+y1%,actamppos%(voice%+1)-24,point1%-35+x2%,actamppos%(voice%+1)-8
- MOVE point1%-25+x2%,actamppos%(voice%+1) : PRINT amp2$
- ELSE LINE hposn%+x1%+y1%,714+shortamppos%(voice%)-((system%-1)*524)+8,point1%-35+x2%,714+shortamppos%(voice%)-((system%-1)*524)-8
- LINE hposn%+x1%+y1%,714+shortamppos%(voice%)-((system%-1)*524)-24,point1%-35+x2%,714+shortamppos%(voice%)-((system%-1)*524)-8
- MOVE point1%-25+x2%,714+shortamppos%(voice%)-((system%-1)*524) : PRINT amp2$
- ENDIF
- ENDIF
- IF amp2% > amp1% THEN
- IF longscore$ = "y" THEN
- LINE hposn%+x1%+y1%,actamppos%(voice%+1)-8,point1%-35+x2%,actamppos%(voice%+1)+8
- LINE hposn%+x1%+y1%,actamppos%(voice%+1)-8,point1%-35+x2%,actamppos%(voice%+1)-24
- MOVE point1%-25+x2%,actamppos%(voice%+1) : PRINT amp2$
- ELSE LINE hposn%+x1%+y1%,714+shortamppos%(voice%)-((system%-1)*524)-8,point1%-35+x2%,714+shortamppos%(voice%)-((system%-1)*524)+8
- LINE hposn%+x1%+y1%,714+shortamppos%(voice%)-((system%-1)*524)-8,point1%-35+x2%,714+shortamppos%(voice%)-((system%-1)*524)-24
- MOVE point1%-25+x2%,714+shortamppos%(voice%)-((system%-1)*524) : PRINT amp2$
- ENDIF
- ENDIF
- :
- REM second phase
- IF amp1% <> amp2% THEN start% = point1%-25+x2%+y2% ELSE start% = point1%
- IF amp3% < amp2% THEN
- IF longscore$ = "y" THEN
- LINE start%,actamppos%(voice%+1)+8,point2%-35+x3%,actamppos%(voice%+1)-8
- LINE start%,actamppos%(voice%+1)-24,point2%-35+x3%,actamppos%(voice%+1)-8
- MOVE point2%-25+x3%,actamppos%(voice%+1) : PRINT amp3$
- ELSE LINE start%,714+shortamppos%(voice%)-((system%-1)*524)+8,point2%-35+x3%,714+shortamppos%(voice%)-((system%-1)*524)-8
- LINE start%,714+shortamppos%(voice%)-((system%-1)*524)-24,point2%-35+x3%,714+shortamppos%(voice%)-((system%-1)*524)-8
- MOVE point2%-25+x3%,714+shortamppos%(voice%)-((system%-1)*524) : PRINT amp3$
- ENDIF
- ENDIF
- IF amp3% > amp2% THEN
- IF longscore$ = "y" THEN
- LINE start%,actamppos%(voice%+1)-8,point2%-35+x3%,actamppos%(voice%+1)+8
- LINE start%,actamppos%(voice%+1)-8,point2%-35+x3%,actamppos%(voice%+1)-24
- MOVE point2%-25+x3%,actamppos%(voice%+1) : PRINT amp3$
- ELSE LINE start%,714+shortamppos%(voice%)-((system%-1)*524)-8,point2%-35+x3%,714+shortamppos%(voice%)-((system%-1)*524)+8
- LINE start%,714+shortamppos%(voice%)-((system%-1)*524)-8,point2%-35+x3%,714+shortamppos%(voice%)-((system%-1)*524)-24
- MOVE point2%-25+x3%,714+shortamppos%(voice%)-((system%-1)*524) : PRINT amp3$
- ENDIF
- ENDIF
- :
- REM third phase
- IF amp2% <> amp3% THEN start% = point2%-25+x3%+y3% ELSE start% = point2%
- IF amp4% < amp3% THEN
- IF longscore$ = "y" THEN
- LINE start%,actamppos%(voice%+1)+8,point%-90+(x4%*2),actamppos%(voice%+1)-8
- LINE start%,actamppos%(voice%+1)-24,point%-90+(x4%*2),actamppos%(voice%+1)-8
- MOVE point%-80+(x4%*2),actamppos%(voice%+1) : PRINT amp4$
- ELSE LINE start%,714+shortamppos%(voice%)-((system%-1)*524)+8,point%-90+(x4%*2),714+shortamppos%(voice%)-((system%-1)*524)-8
- LINE start%,714+shortamppos%(voice%)-((system%-1)*524)-24,point%-90+(x4%*2),714+shortamppos%(voice%)-((system%-1)*524)-8
- MOVE point%-80+(x4%*2),714+shortamppos%(voice%)-((system%-1)*524) : PRINT amp4$
- ENDIF
- ENDIF
- IF amp4% > amp3% THEN
- IF longscore$ = "y" THEN
- LINE start%,actamppos%(voice%+1)-8,point%-90+(x4%*2),actamppos%(voice%+1)+8
- LINE start%,actamppos%(voice%+1)-8,point%-90+(x4%*2),actamppos%(voice%+1)-24
- MOVE point%-80+(x4%*2),actamppos%(voice%+1) : PRINT amp4$
- ELSE LINE start%,714+shortamppos%(voice%)-((system%-1)*524)-8,point%-90+(x4%*2),714+shortamppos%(voice%)-((system%-1)*524)+8
- LINE start%,714+shortamppos%(voice%)-((system%-1)*524)-8,point%-90+(x4%*2),714+shortamppos%(voice%)-((system%-1)*524)-24
- MOVE point%-80+(x4%*2),714+shortamppos%(voice%)-((system%-1)*524) : PRINT amp4$
- ENDIF
- ENDIF
- :
- ENDCASE
- :
- ENDIF
- :
- :
- REM ledger lines
- IF staves$ = "y" THEN
- IF notehead$ = "big" THEN
- lend% = -12 : rend% = 44
- ENDIF
- IF notehead$ = "small" THEN
- lend% = 8 : rend% = 40
- ENDIF
- IF notehead$ = "vsmall" THEN
- lend% = 18 : rend% = 38
- ENDIF
- :
- IF longscore$ = "n" THEN
- IF value% = 858 THEN
- IF vposn% >= 954 THEN
- numledgers% = (vposn%-938)/16
- FOR ct% = 1 TO numledgers%
- LINE hposn%+lend%,954+((ct%-1)*16),hposn%+rend%,954+((ct%-1)*16)
- NEXT
- ENDIF
- IF vposn% = 858 THEN LINE hposn%+lend%,858,hposn%+rend%,858
- ENDIF
- IF value% = 586 THEN
- IF vposn% <= 714 THEN
- numledgers% = (730-vposn%)/16
- FOR ct% = 1 TO numledgers%
- LINE hposn%+lend%,714-((ct%-1)*16),hposn%+rend%,714-((ct%-1)*16)
- NEXT
- ENDIF
- ENDIF
- IF value% = 334 THEN
- IF vposn% >= 430 THEN
- numledgers% = (vposn%-414)/16
- FOR ct% = 1 TO numledgers%
- LINE hposn%+lend%,430+((ct%-1)*16),hposn%+rend%,430+((ct%-1)*16)
- NEXT
- ENDIF
- IF vposn% = 334 THEN LINE hposn%+lend%,334,hposn%+rend%,334
- ENDIF
- IF value% = 62 THEN
- IF vposn% <= 190 THEN
- numledgers% = (206-vposn%)/16
- FOR ct% = 1 TO numledgers%
- LINE hposn%+lend%,190-((ct%-1)*16),hposn%+rend%,190-((ct%-1)*16)
- NEXT
- ENDIF
- ENDIF
- ENDIF
- :
- IF longscore$ = "y" THEN
- CASE MID$(clefcombination$,ledgerkey%,1) OF
- WHEN "T" : num% = 320
- WHEN "P" : num% = 376
- WHEN "B" : num% = 224
- WHEN "D" : num% = 168
- ENDCASE
- IF vposn% - value% >= num% THEN
- numledgers% = ((vposn%-value%)-(num%-16))/16
- FOR ct% = 1 TO numledgers%
- LINE hposn% + lend%,value%+(num%-16)+(16*ct%),hposn%+rend%,value%+(num%-16)+(16*ct%)
- NEXT
- ENDIF
- IF vposn%-value% <= (num%-96) THEN
- numledgers% = ((num%-80)-(vposn%-value%))/16
- FOR ct% = 1 TO numledgers%
- LINE hposn%+lend%,(value%+(num%-80))-(16*ct%),hposn%+rend%,(value%+(num%-80))-(16*ct%)
- NEXT
- ENDIF
- ENDIF
- :
- ENDIF : REM applies to 'IF staves$ = "y" '
- :
- REM stems
- IF stems$ = "y" THEN
- IF longscore$ = "n" THEN
- IF notehead$ = "big" THEN
- LINE hposn%+30,vposn%,hposn%+30,938+shortbeamposn%(voice%)-(524*(system%-1))
- ENDIF
- LINE hposn%+32,vposn%,hposn%+32,938+shortbeamposn%(voice%)-(524*(system%-1))
- ENDIF
- :
- IF longscore$ = "y" THEN
- IF notehead$ = "big" THEN
- LINE hposn%+30,vposn%,hposn%+30,actbeamposn%(count%-startv%)
- ENDIF
- LINE hposn%+32,vposn%,hposn%+32,actbeamposn%(count%-startv%)
- ENDIF
- ENDIF
- :
- REM accidentals
- IF accidentals$ = "y" THEN
- acc% = (array%(startcell%,0,voice%)MOD100)DIV10
- IF notehead$ = "big" THEN
- CASE acc% OF
- WHEN 9 : REM sharp
- LINE hposn%-30,vposn%-24,hposn%-30,vposn%+24
- LINE hposn%-28,vposn%-24,hposn%-28,vposn%+24
- LINE hposn%-16,vposn%-24,hposn%-16,vposn%+24
- LINE hposn%-14,vposn%-24,hposn%-14,vposn%+24
- LINE hposn%-36,vposn%+4,hposn%-8,vposn%+12
- LINE hposn%-36,vposn%-12,hposn%-8,vposn%-4
- WHEN 8 : REM 3/8 sharp
- LINE hposn%-30,vposn%-24,hposn%-30,vposn%+24
- LINE hposn%-28,vposn%-24,hposn%-28,vposn%+24
- LINE hposn%-16,vposn%-24,hposn%-16,vposn%+24
- LINE hposn%-14,vposn%-24,hposn%-14,vposn%+24
- LINE hposn%-36,vposn%+4,hposn%-8,vposn%+12
- LINE hposn%-36,vposn%-12,hposn%-8,vposn%-4
- LINE hposn%-20,vposn%-20,hposn%-16,vposn%-28
- LINE hposn%-14,vposn%-28,hposn%-10,vposn%-20
- LINE hposn%-18,vposn%-20,hposn%-16,vposn%-28
- LINE hposn%-14,vposn%-28,hposn%-12,vposn%-20
- WHEN 1 : REM flat
- LINE hposn%-28,vposn%-12,hposn%-28,vposn%+28
- LINE hposn%-26,vposn%-12,hposn%-26,vposn%+28
- LINE hposn%-20,vposn%+8,hposn%-10,vposn%+8
- LINE hposn%-24,vposn%+4,hposn%-22,vposn%+4
- LINE hposn%-12,vposn%+4,hposn%-8,vposn%+4
- LINE hposn%-28,vposn%,hposn%-26,vposn%
- LINE hposn%-12,vposn%,hposn%-8,vposn%
- LINE hposn%-16,vposn%-4,hposn%-12,vposn%-4
- LINE hposn%-28,vposn%-8,hposn%-18,vposn%-8
- WHEN 2 : REM 3/8 flat
- LINE hposn%-28,vposn%-12,hposn%-28,vposn%+28
- LINE hposn%-26,vposn%-12,hposn%-26,vposn%+28
- LINE hposn%-20,vposn%+8,hposn%-10,vposn%+8
- LINE hposn%-24,vposn%+4,hposn%-22,vposn%+4
- LINE hposn%-12,vposn%+4,hposn%-8,vposn%+4
- LINE hposn%-28,vposn%,hposn%-26,vposn%
- LINE hposn%-12,vposn%,hposn%-8,vposn%
- LINE hposn%-16,vposn%-4,hposn%-12,vposn%-4
- LINE hposn%-28,vposn%-8,hposn%-18,vposn%-8
- LINE hposn%-32,vposn%+20,hposn%-28,vposn%+28
- LINE hposn%-26,vposn%+28,hposn%-22,vposn%+20
- LINE hposn%-30,vposn%+20,hposn%-28,vposn%+28
- LINE hposn%-26,vposn%+28,hposn%-24,vposn%+20
- WHEN 7 : REM quartersharp
- LINE hposn%-18,vposn%+24,hposn%-18,vposn%-24
- LINE hposn%-16,vposn%+24,hposn%-16,vposn%-24
- LINE hposn%-26,vposn%+4,hposn%-8,vposn%+12
- LINE hposn%-26,vposn%-12,hposn%-8,vposn%-4
- WHEN 3 : REM quarterflat
- LINE hposn%-12,vposn%-12,hposn%-12,vposn%+28
- LINE hposn%-10,vposn%-12,hposn%-10,vposn%+28
- LINE hposn%-28,vposn%+8,hposn%-18,vposn%+8
- LINE hposn%-30,vposn%+4,hposn%-26,vposn%+4
- LINE hposn%-16,vposn%+4,hposn%-14,vposn%+4
- LINE hposn%-30,vposn%,hposn%-26,vposn%
- LINE hposn%-26,vposn%-4,hposn%-22,vposn%-4
- LINE hposn%-20,vposn%-8,hposn%-10,vposn%-8
- WHEN 5 : REM natural
- LINE hposn%-30,vposn%+24,hposn%-30,vposn%-8
- LINE hposn%-28,vposn%+24,hposn%-28,vposn%-8
- LINE hposn%-12,vposn%+8,hposn%-12,vposn%-24
- LINE hposn%-10,vposn%+8,hposn%-10,vposn%-24
- LINE hposn%-30,vposn%+4,hposn%-24,vposn%+4
- LINE hposn%-22,vposn%+8,hposn%-18,vposn%+8
- LINE hposn%-16,vposn%+12,hposn%-10,vposn%+12
- LINE hposn%-30,vposn%-12,hposn%-24,vposn%-12
- LINE hposn%-22,vposn%-8,hposn%-18,vposn%-8
- LINE hposn%-16,vposn%-4,hposn%-10,vposn%-4
- WHEN 4 : REM 1/8 flat
- LINE hposn%-30,vposn%+24,hposn%-30,vposn%-8
- LINE hposn%-28,vposn%+24,hposn%-28,vposn%-8
- LINE hposn%-12,vposn%+8,hposn%-12,vposn%-24
- LINE hposn%-10,vposn%+8,hposn%-10,vposn%-24
- LINE hposn%-30,vposn%+4,hposn%-24,vposn%+4
- LINE hposn%-22,vposn%+8,hposn%-18,vposn%+8
- LINE hposn%-16,vposn%+12,hposn%-10,vposn%+12
- LINE hposn%-30,vposn%-12,hposn%-24,vposn%-12
- LINE hposn%-22,vposn%-8,hposn%-18,vposn%-8
- LINE hposn%-16,vposn%-4,hposn%-10,vposn%-4
- LINE hposn%-16,vposn%-20,hposn%-12,vposn%-28
- LINE hposn%-10,vposn%-28,hposn%-6,vposn%-20
- LINE hposn%-14,vposn%-20,hposn%-12,vposn%-28
- LINE hposn%-10,vposn%-28,hposn%-8,vposn%-20
- WHEN 6 : REM 1/8 sharp
- LINE hposn%-30,vposn%+24,hposn%-30,vposn%-8
- LINE hposn%-28,vposn%+24,hposn%-28,vposn%-8
- LINE hposn%-12,vposn%+8,hposn%-12,vposn%-24
- LINE hposn%-10,vposn%+8,hposn%-10,vposn%-24
- LINE hposn%-30,vposn%+4,hposn%-24,vposn%+4
- LINE hposn%-22,vposn%+8,hposn%-18,vposn%+8
- LINE hposn%-16,vposn%+12,hposn%-10,vposn%+12
- LINE hposn%-30,vposn%-12,hposn%-24,vposn%-12
- LINE hposn%-22,vposn%-8,hposn%-18,vposn%-8
- LINE hposn%-16,vposn%-4,hposn%-10,vposn%-4
- LINE hposn%-34,vposn%+20,hposn%-30,vposn%+28
- LINE hposn%-32,vposn%+20,hposn%-30,vposn%+28
- LINE hposn%-26,vposn%+20,hposn%-28,vposn%+28
- LINE hposn%-24,vposn%+20,hposn%-28,vposn%+28
- ENDCASE
- ENDIF
- IF notehead$ = "vsmall" THEN
- CASE acc% OF
- WHEN 5 : REM natural
- LINE hposn%+12,vposn%+24,hposn%+12,vposn%-4
- LINE hposn%+20,vposn%+4,hposn%+20,vposn%-24
- LINE hposn%+12,vposn%+4,hposn%+20,vposn%+8
- LINE hposn%+12,vposn%-8,hposn%+20,vposn%-4
- WHEN 6 : REM 1/8 sharp
- LINE hposn%+12,vposn%+24,hposn%+12,vposn%-4
- LINE hposn%+20,vposn%+4,hposn%+20,vposn%-24
- LINE hposn%+12,vposn%+4,hposn%+20,vposn%+8
- LINE hposn%+12,vposn%-8,hposn%+20,vposn%-4
- LINE hposn%+10,vposn%+20,hposn%+12,vposn%+28
- LINE hposn%+14,vposn%+20,hposn%+12,vposn%+28
- LINE hposn%+8,vposn%+20,hposn%+12,vposn%+28
- LINE hposn%+16,vposn%+20,hposn%+12,vposn%+28
- WHEN 9 : REM sharp
- LINE hposn%+12,vposn%+24,hposn%+12,vposn%-24
- LINE hposn%+18,vposn%+24,hposn%+18,vposn%-24
- LINE hposn%+10,vposn%+4,hposn%+20,vposn%+8
- LINE hposn%+10,vposn%-8,hposn%+20,vposn%-4
- WHEN 8 : REM 3/8 sharp
- LINE hposn%+12,vposn%+24,hposn%+12,vposn%-24
- LINE hposn%+18,vposn%+24,hposn%+18,vposn%-24
- LINE hposn%+10,vposn%+4,hposn%+20,vposn%+8
- LINE hposn%+10,vposn%-8,hposn%+20,vposn%-4
- LINE hposn%+14,vposn%-20,hposn%+18,vposn%-28
- LINE hposn%+16,vposn%-20,hposn%+18,vposn%-28
- LINE hposn%+20,vposn%-20,hposn%+18,vposn%-28
- LINE hposn%+22,vposn%-20,hposn%+18,vposn%-28
- WHEN 4 : REM 1/8 flat
- LINE hposn%+12,vposn%+24,hposn%+12,vposn%-4
- LINE hposn%+20,vposn%+4,hposn%+20,vposn%-24
- LINE hposn%+12,vposn%+4,hposn%+20,vposn%+8
- LINE hposn%+12,vposn%-8,hposn%+20,vposn%-4
- LINE hposn%+16,vposn%-20,hposn%+20,vposn%-28
- LINE hposn%+18,vposn%-20,hposn%+20,vposn%-28
- LINE hposn%+22,vposn%-20,hposn%+20,vposn%-28
- LINE hposn%+24,vposn%-20,hposn%+20,vposn%-28
- WHEN 7 : REM quartersharp
- LINE hposn%+18,vposn%+24,hposn%+18,vposn%-24
- LINE hposn%+16,vposn%+4,hposn%+20,vposn%+8
- LINE hposn%+16,vposn%-8,hposn%+20,vposn%-4
- WHEN 2 : REM 3/8 flat
- LINE hposn%+12,vposn%+28,hposn%+12,vposn%-12
- LINE hposn%+16,vposn%+8,hposn%+18,vposn%+8
- LINE hposn%+14,vposn%+4,hposn%+14,vposn%+4
- LINE hposn%+20,vposn%+4,hposn%+20,vposn%+4
- LINE hposn%+20,vposn%,hposn%+20,vposn%
- LINE hposn%+18,vposn%-4,hposn%+18,vposn%-4
- LINE hposn%+12,vposn%-8,hposn%+16,vposn%-8
- LINE hposn%+8,vposn%+20,hposn%+12,vposn%+28
- LINE hposn%+10,vposn%+20,hposn%+12,vposn%+28
- LINE hposn%+14,vposn%+20,hposn%+12,vposn%+28
- LINE hposn%+16,vposn%+20,hposn%+12,vposn%+28
- WHEN 1 : REM flat
- LINE hposn%+12,vposn%+28,hposn%+12,vposn%-12
- LINE hposn%+16,vposn%+8,hposn%+18,vposn%+8
- LINE hposn%+14,vposn%+4,hposn%+14,vposn%+4
- LINE hposn%+20,vposn%+4,hposn%+20,vposn%+4
- LINE hposn%+20,vposn%,hposn%+20,vposn%
- LINE hposn%+18,vposn%-4,hposn%+18,vposn%-4
- LINE hposn%+12,vposn%-8,hposn%+16,vposn%-8
- WHEN 3 : REM quarterflat
- LINE hposn%+20,vposn%+28,hposn%+20,vposn%-12
- LINE hposn%+14,vposn%+8,hposn%+16,vposn%+8
- LINE hposn%+12,vposn%+4,hposn%+12,vposn%+4
- LINE hposn%+18,vposn%+4,hposn%+18,vposn%+4
- LINE hposn%+12,vposn%,hposn%+12,vposn%
- LINE hposn%+14,vposn%-4,hposn%+14,vposn%-4
- LINE hposn%+16,vposn%-8,hposn%+20,vposn%-8
- ENDCASE
- inf% = (array%(startcell%,2,voice%)MOD100)-50
- IF inf% < 0 THEN
- MOVE hposn%-125,vposn%-30 : PRINT inf%;"c"
- ENDIF
- IF inf% > 0 THEN
- MOVE hposn%-16,vposn%+45 : PRINT "+";inf%;"c"
- ENDIF
- ENDIF
- :
- IF notehead$ = "small" THEN
- CASE acc% OF
- WHEN 1 : REM flat
- LINE hposn%-2,vposn%+28,hposn%-2,vposn%-12
- LINE hposn%+4,vposn%+8,hposn%+8,vposn%+8
- LINE hposn%,vposn%+4,hposn%+2,vposn%+4
- LINE hposn%+8,vposn%+4,hposn%+10,vposn%+4
- LINE hposn%+8,vposn%,hposn%+10,vposn%
- LINE hposn%+4,vposn%-4,hposn%+6,vposn%-4
- LINE hposn%-2,vposn%-8,hposn%+2,vposn%-8
- WHEN 2 : REM 3/8 flat
- LINE hposn%-2,vposn%+28,hposn%-2,vposn%-12
- LINE hposn%+4,vposn%+8,hposn%+8,vposn%+8
- LINE hposn%,vposn%+4,hposn%+2,vposn%+4
- LINE hposn%+8,vposn%+4,hposn%+10,vposn%+4
- LINE hposn%+8,vposn%,hposn%+10,vposn%
- LINE hposn%+4,vposn%-4,hposn%+6,vposn%-4
- LINE hposn%-2,vposn%-8,hposn%+2,vposn%-8
- LINE hposn%-6,vposn%+20,hposn%-2,vposn%+28
- LINE hposn%-4,vposn%+20,hposn%-2,vposn%+28
- LINE hposn%,vposn%+20,hposn%-2,vposn%+28
- LINE hposn%+2,vposn%+20,hposn%-2,vposn%+28
- WHEN 3 : REM quarterflat
- LINE hposn%+10,vposn%+28,hposn%+10,vposn%-12
- LINE hposn%,vposn%+8,hposn%+4,vposn%+8
- LINE hposn%-2,vposn%+4,hposn%,vposn%+4
- LINE hposn%+6,vposn%+4,hposn%+8,vposn%+4
- LINE hposn%-2,vposn%,hposn%,vposn%
- LINE hposn%+2,vposn%-4,hposn%+4,vposn%-4
- LINE hposn%+6,vposn%-8,hposn%+10,vposn%-8
- WHEN 5 : REM natural
- LINE hposn%,vposn%+24,hposn%,vposn%-4
- LINE hposn%+10,vposn%+4,hposn%+10,vposn%-24
- LINE hposn%,vposn%+4,hposn%+10,vposn%+8
- LINE hposn%,vposn%-8,hposn%+10,vposn%-4
- WHEN 6 : REM 1/8 sharp
- LINE hposn%,vposn%+24,hposn%,vposn%-4
- LINE hposn%+10,vposn%+4,hposn%+10,vposn%-24
- LINE hposn%,vposn%+4,hposn%+10,vposn%+8
- LINE hposn%,vposn%-8,hposn%+10,vposn%-4
- LINE hposn%-4,vposn%+20,hposn%,vposn%+28
- LINE hposn%-2,vposn%+20,hposn%,vposn%+28
- LINE hposn%+2,vposn%+20,hposn%,vposn%+28
- LINE hposn%+4,vposn%+20,hposn%,vposn%+28
- WHEN 7 : REM quartersharp
- LINE hposn%+6,vposn%+24,hposn%+6,vposn%-24
- LINE hposn%+2,vposn%+4,hposn%+10,vposn%+8
- LINE hposn%+2,vposn%-8,hposn%+10,vposn%-4
- WHEN 4 : REM 1/8 flat
- LINE hposn%,vposn%+24,hposn%,vposn%-4
- LINE hposn%+10,vposn%+4,hposn%+10,vposn%-24
- LINE hposn%,vposn%+4,hposn%+10,vposn%+8
- LINE hposn%,vposn%-8,hposn%+10,vposn%-4
- LINE hposn%+6,vposn%-20,hposn%+10,vposn%-28
- LINE hposn%+8,vposn%-20,hposn%+10,vposn%-28
- LINE hposn%+12,vposn%-20,hposn%+10,vposn%-28
- LINE hposn%+14,vposn%-20,hposn%+10,vposn%-28
- WHEN 9 : REM sharp
- LINE hposn%-2,vposn%+24,hposn%-2,vposn%-24
- LINE hposn%+6,vposn%+24,hposn%+6,vposn%-24
- LINE hposn%-6,vposn%+4,hposn%+10,vposn%+8
- LINE hposn%-6,vposn%-8,hposn%+10,vposn%-4
- WHEN 8 : REM 3/8 sharp
- LINE hposn%-2,vposn%+24,hposn%-2,vposn%-24
- LINE hposn%+6,vposn%+24,hposn%+6,vposn%-24
- LINE hposn%-6,vposn%+4,hposn%+10,vposn%+8
- LINE hposn%-6,vposn%-8,hposn%+10,vposn%-4
- LINE hposn%+2,vposn%-20,hposn%+6,vposn%-28
- LINE hposn%+4,vposn%-20,hposn%+6,vposn%-28
- LINE hposn%+8,vposn%-20,hposn%+6,vposn%-28
- LINE hposn%+10,vposn%-20,hposn%+6,vposn%-28
- ENDCASE
- :
- ENDIF
- ENDIF
- startcell% += 1
- IF longscore$ = "n" THEN div% = 2 ELSE div% = 1
- :
- UNTIL (array%(startcell%,0,voice%) DIV10^6) >= ((numbars%/div%)+firstbar%) OR array%(startcell%,0,voice%) = 0
- ENDIF
- :
- IF stems$ = "y" THEN PROCrhythmdisplay
- :
- IF longscore$ = "y" THEN ledgerkey% += EVAL(MID$(stavecombination$,count%-startv%+1,1))
- :
- NEXT
- :
- NEXT
- :
- VDU 4 : OFF : box$ = "n" : biga% = 10^5 : bigb% = 0 : bigc% = 0 : bigd% = 10^5
- IF printing$ = "n" AND preplaydisplay$ = "n" THEN PROCpostdisplay
- ENDPROC
- :
- REM*************************************************
- :
- DEF PROCroundgliss
- :
- IF thirdphase$ = "n" THEN gl1% = 50-gl% ELSE gl1% = 10-gl%
- gl% = gl1%*1.1665 : gl% = (gl%DIV4)*4
- IF gl% = 0 THEN
- IF gl1% > 0 THEN gl% = 4 ELSE gl% = -4
- ENDIF
- IF gl% < 0 THEN g% = gl%*-1 ELSE g% = gl%
- rem = g%/8
- IF (rem*10)MOD10 <> 0 THEN
- IF gl% > 0 THEN gl% += 4 ELSE gl% -= 4
- ENDIF
- :
- ENDPROC
- :
- REM**************************************************
- :
- DEF PROCpostdisplay
- :
- distort$ = "OFF"
- REM in case of Escaping from a distort routine before switching it off
- :
- OFF
- CASE GET$ OF
- :
- WHEN "i" :
- PROCwindow(20,69,60,55)
- CLS : PRINT'" Copy-extract or move-extract? (C/M) "
- CASE GET$ OF
- WHEN "C","c" : copymove$ = "EC"
- OTHERWISE copymove$ = "EM"
- ENDCASE
- savevoice$ = "N"
- PROCcopy2
- :
- WHEN "{" : quickcopy$ = "y" : PROCdisplay
- WHEN "}" : quickcopy$ = "n" : PROCdisplay
- WHEN "¬" :
- PROCwindow(20,69,60,55) : CLS
- INPUT'" Display from which voice "startv%
- PROCdisplay
- :
- WHEN "@" :
- IF easiermenus$ = "y" THEN easiermenus$ = "n" ELSE easiermenus$ = "y"
- PROCdisplay
- WHEN "`" :
- distort$ = "ON" : distortpara$ = "attacks" : ON
- PROCwindow(20,69,60,55) : CLS : OFF :
- incre$ = INKEY$(50)
- IF incre$ = "`" THEN
- distortpara$ = "pitches"
- ENDIF
- PROCcopy
- :
- WHEN "+" :
- numvoices% = numparts%
- FOR count% = 1 TO numvoices%
- displayvoices%(count%) = 1 + count% - 1
- holddisplay%(count%) = 1 + count% - 1
- NEXT
- holdnum% = numvoices%
- PROCdisplay
- :
- WHEN "!" : copydownwards% = 1 :
- IF addten$ = "y" THEN copydownwards% +=10
- IF addten$ = "twenty" THEN copydownwards% += 20
- incre$ = INKEY$(downwardsspeed%)
- IF incre$ <> "" THEN
- CASE incre$ OF
- WHEN "!" : downby% = 1
- WHEN """" : downby% = 2
- WHEN "£" : downby% = 3
- WHEN "$" : downby% = 4
- WHEN "%" : downby% = 5
- WHEN "^" : downby% = 6
- WHEN "&" : downby% = 7
- WHEN "*" : downby% = 8
- WHEN "(" : downby% = 9
- WHEN ")" : downby% = 10
- ENDCASE
- ELSE downby% = 1
- ENDIF
- PROCcopydownwards
- WHEN """" : copydownwards% = 2 :
- IF addten$ = "y" THEN copydownwards% +=10
- IF addten$ = "twenty" THEN copydownwards% +=20
- incre$ = INKEY$(downwardsspeed%)
- IF incre$ <> "" THEN
- CASE incre$ OF
- WHEN "!" : downby% = 1
- WHEN """" : downby% = 2
- WHEN "£" : downby% = 3
- WHEN "$" : downby% = 4
- WHEN "%" : downby% = 5
- WHEN "^" : downby% = 6
- WHEN "&" : downby% = 7
- WHEN "*" : downby% = 8
- WHEN "(" : downby% = 9
- ENDCASE
- ELSE downby% = 1
- ENDIF
- PROCcopydownwards
- WHEN "£" : copydownwards% = 3 :
- IF addten$ = "y" THEN copydownwards% +=10
- IF addten$ = "twenty" THEN copydownwards% +=20
- incre$ = INKEY$(downwardsspeed%)
- IF incre$ <> "" THEN
- CASE incre$ OF
- WHEN "!" : downby% = 1
- WHEN """" : downby% = 2
- WHEN "£" : downby% = 3
- WHEN "$" : downby% = 4
- WHEN "%" : downby% = 5
- WHEN "^" : downby% = 6
- WHEN "&" : downby% = 7
- WHEN "*" : downby% = 8
- WHEN "(" : downby% = 9
- ENDCASE
- ELSE downby% = 1
- ENDIF
- PROCcopydownwards
- WHEN "$" : copydownwards% = 4 :
- IF addten$ = "y" THEN copydownwards% +=10
- IF addten$ = "twenty" THEN copydownwards% +=20
- incre$ = INKEY$(downwardsspeed%)
- IF incre$ <> "" THEN
- CASE incre$ OF
- WHEN "!" : downby% = 1
- WHEN """" : downby% = 2
- WHEN "£" : downby% = 3
- WHEN "$" : downby% = 4
- WHEN "%" : downby% = 5
- WHEN "^" : downby% = 6
- WHEN "&" : downby% = 7
- WHEN "*" : downby% = 8
- WHEN "(" : downby% = 9
- ENDCASE
- ELSE downby% = 1
- ENDIF
- PROCcopydownwards
- WHEN "%" : copydownwards% = 5 :
- IF addten$ = "y" THEN copydownwards% +=10
- IF addten$ = "twenty" THEN copydownwards% +=20
- incre$ = INKEY$(downwardsspeed%)
- IF incre$ <> "" THEN
- CASE incre$ OF
- WHEN "!" : downby% = 1
- WHEN """" : downby% = 2
- WHEN "£" : downby% = 3
- WHEN "$" : downby% = 4
- WHEN "%" : downby% = 5
- WHEN "^" : downby% = 6
- WHEN "&" : downby% = 7
- WHEN "*" : downby% = 8
- WHEN "(" : downby% = 9
- ENDCASE
- ELSE downby% = 1
- ENDIF
- PROCcopydownwards
- WHEN "^" : copydownwards% = 6 :
- IF addten$ = "y" THEN copydownwards% +=10
- IF addten$ = "twenty" THEN copydownwards% +=20
- incre$ = INKEY$(downwardsspeed%)
- IF incre$ <> "" THEN
- CASE incre$ OF
- WHEN "!" : downby% = 1
- WHEN """" : downby% = 2
- WHEN "£" : downby% = 3
- WHEN "$" : downby% = 4
- WHEN "%" : downby% = 5
- WHEN "^" : downby% = 6
- WHEN "&" : downby% = 7
- WHEN "*" : downby% = 8
- WHEN "(" : downby% = 9
- ENDCASE
- ELSE downby% = 1
- ENDIF
- PROCcopydownwards
- WHEN "&" : copydownwards% = 7 :
- IF addten$ = "y" THEN copydownwards% +=10
- IF addten$ = "twenty" THEN copydownwards% +=20
- incre$ = INKEY$(downwardsspeed%)
- IF incre$ <> "" THEN
- CASE incre$ OF
- WHEN "!" : downby% = 1
- WHEN """" : downby% = 2
- WHEN "£" : downby% = 3
- WHEN "$" : downby% = 4
- WHEN "%" : downby% = 5
- WHEN "^" : downby% = 6
- WHEN "&" : downby% = 7
- WHEN "*" : downby% = 8
- WHEN "(" : downby% = 9
- ENDCASE
- ELSE downby% = 1
- ENDIF
- PROCcopydownwards
- WHEN "*" : copydownwards% = 8 :
- IF addten$ = "y" THEN copydownwards% +=10
- IF addten$ = "twenty" THEN copydownwards% +=20
- incre$ = INKEY$(downwardsspeed%)
- IF incre$ <> "" THEN
- CASE incre$ OF
- WHEN "!" : downby% = 1
- WHEN """" : downby% = 2
- WHEN "£" : downby% = 3
- WHEN "$" : downby% = 4
- WHEN "%" : downby% = 5
- WHEN "^" : downby% = 6
- WHEN "&" : downby% = 7
- WHEN "*" : downby% = 8
- WHEN "(" : downby% = 9
- ENDCASE
- ELSE downby% = 1
- ENDIF
- PROCcopydownwards
- WHEN "(" : copydownwards% = 9 :
- IF addten$ = "y" THEN copydownwards% +=10
- IF addten$ = "twenty" THEN copydownwards% +=20
- incre$ = INKEY$(downwardsspeed%)
- IF incre$ <> "" THEN
- CASE incre$ OF
- WHEN "!" : downby% = 1
- WHEN """" : downby% = 2
- WHEN "£" : downby% = 3
- WHEN "$" : downby% = 4
- WHEN "%" : downby% = 5
- WHEN "^" : downby% = 6
- WHEN "&" : downby% = 7
- WHEN "*" : downby% = 8
- WHEN "(" : downby% = 9
- ENDCASE
- ELSE downby% = 1
- ENDIF
- PROCcopydownwards
- WHEN ")" : copydownwards% = 10 :
- IF addten$ = "y" THEN copydownwards% +=10
- IF addten$ = "twenty" THEN copydownwards% +=20
- incre$ = INKEY$(downwardsspeed%)
- IF incre$ <> "" THEN
- CASE incre$ OF
- WHEN "!" : downby% = 1
- WHEN """" : downby% = 2
- WHEN "£" : downby% = 3
- WHEN "$" : downby% = 4
- WHEN "%" : downby% = 5
- WHEN "^" : downby% = 6
- WHEN "&" : downby% = 7
- WHEN "*" : downby% = 8
- WHEN "(" : downby% = 9
- ENDCASE
- ELSE downby% = 1
- ENDIF
- PROCcopydownwards
- :
- WHEN "c" : PROCincrementcalc
- WHEN "k" : ON : PROCkeyboardshortcuts
- WHEN "I" : copymove$ = "C" : savevoice$ = "N" : PROCwindow(20,69,60,55) : PROCimportvoice
- WHEN "0",")" : PROCseriesattacks
- WHEN "a" : PROCfunctionprelude
- WHEN "m" : ON : PROCawait
- WHEN "n" : ON : rerun$ = "n" : PROCrandomnumber
- WHEN "N" : ON : rerun$ = "y" : PROCrandomnumber
- WHEN "o" : ON : PROCdisplaysubmenu
- WHEN "O" : deleteone$ = "top" : PROCdelete
- WHEN "K" : deleteone$ = "middle" : PROCdelete
- WHEN "M" : deleteone$ = "bottom" : PROCdelete
- WHEN "r" : play$ = "replay" : PROCplay
- WHEN "u" : ON : PROCseriesdurations
- WHEN "G", "g" : ON : numdurations% = 111 : PROCdurationsbetween
- WHEN "\" : ON : PROCshortmove
- WHEN "|" : ON : PROCshortmoveone
- WHEN "y" : ON : PROCseriespitches
- WHEN "Y" :
- IF addpitches$ = "y" THEN
- PROCwindow(20,69,60,55)
- ON
- CLS
- PROCinsertpitches
- ELSE
- voix% = 1 : son% = 5 : PROCedit
- ENDIF
- WHEN "l" : ON : PROCseriesamplitudes
- WHEN "J","j" : ON : PROCseriesenvelopes
- WHEN "h" : ON : PROCwindow(20,57,74,55)
- PRINT'" Have you previously allocated at least 260K memory "
- PRINT " for system sprites and double-clicked !Paint "
- CASE GET$ OF
- WHEN "N","n" : PROCdisplay
- WHEN "Y","y" :
- printing$ = "y" : printno% += 1 : PROCdisplay
- MOVE 0,0
- MOVE 1800,1223
- *SGet mysprite
- OSCLI "SSave SDFS::RISCOSpi.$.CAC.Printing.print"+STR$(printno%)
- printing$ = "n" : PROCdisplay
- ENDCASE
- WHEN "v" : startv% += updisplay%
- incre$ = INKEY$(vertscroll%)
- IF incre$ <> "" THEN
- CASE incre$ OF
- WHEN "V","v" :
- IF screenmovesby% = 10 THEN startv%+=9 ELSE startv%+=2
- WHEN "0" : startv%+=49
- OTHERWISE startv% += EVAL(incre$)-1
- ENDCASE
- ENDIF
- IF startv% > (numvoices%-lastcount%) THEN startv%= numvoices%-lastcount%
- PROCdisplay
- WHEN "6" :
- startv% -= updisplay%
- decre$ = INKEY$(vertscroll%)
- IF decre$ <> "" THEN
- CASE decre$ OF
- WHEN "6" :
- IF screenmovesby% = 10 THEN startv%-=9 ELSE startv%-=2
- WHEN "0" : startv%-=49
- OTHERWISE startv% -= EVAL(decre$)-1
- ENDCASE
- ENDIF
- IF startv% < 1 THEN startv% = 1
- PROCdisplay
- WHEN "." : startbar% += 1
- incre$ = INKEY$(horizscroll%)
- IF incre$ <> "" THEN
- IF incre$ = ">" OR incre$ = "." THEN startbar% += numbars%-1 ELSE startbar% += EVAL(incre$)-1
- ENDIF
- requestedend% = startbar% + numbars%
- IF requestedend% > nobars% THEN startbar% -= (requestedend%-nobars%)
- PROCdisplay
- WHEN "," : startbar% -= 1
- decre$ = INKEY$(horizscroll%)
- IF decre$ <> "" THEN
- IF decre$ = "<" OR decre$ = "," THEN startbar% -= numbars%-1 ELSE startbar% -= EVAL(decre$)-1
- ENDIF
- IF startbar%<1 THEN startbar% = 1
- PROCdisplay
- WHEN "V" : ON : PROCwindow(20,69,60,55)
- IF namestaves$ = "nameone" THEN PROCnamestaves ELSE PROCdeletenames
- PROCdisplay
- WHEN "b" :
- PROCwindow(20,57,34,55) : ON : INPUT'" Go to bar "startbar%
- requestedend% = startbar% + numbars%
- IF requestedend% > nobars% THEN startbar% -= (requestedend% - nobars%)
- PROCdisplay
- WHEN "s" :
- CASE sequalssection$ OF
- WHEN "y" :
- PROCwindow(20,17,38,15) : ON : INPUT'" Go to section "section$
- count% = 0 : found$ = "n"
- REPEAT
- count% += 1
- IF remarks$(count%,0) = "SECTION "+section$ OR remarks$(count%,1) = "SECTION "+section$ THEN
- startbar% = count% : found$ = "y"
- ENDIF
- UNTIL found$ = "y" OR count% > nobars%
- PROCdisplay
- WHEN "n" :
- copysuccessively$ = "y" : PROCcopygroupofnotes
- ENDCASE : REM sequalussection
- WHEN "d" : PROCwindow(20,58,45,55) : ON
- INPUT'" Display how many bars? "numbars%
- requestedend% = startbar% + numbars%
- IF requestedend% > nobars% THEN startbar% -= (requestedend%-nobars%)
- IF startbar% < 1 THEN
- startbar% = 1 : numbars% = nobars%-1
- ENDIF
- PROCdisplay
- WHEN "=" : numbars% = numbars%*2
- requestedend% = startbar% + numbars%
- IF requestedend% > nobars% THEN startbar% -= (requestedend%-nobars%)
- IF startbar% < 1 THEN
- startbar% = 1 : numbars% = nobars%-1
- ENDIF
- PROCdisplay
- WHEN "q" :
- PROCquickdisplay
- WHEN "w" :
- CASE toggle$ OF
- WHEN "prevquick" : toggle$ = "orig"
- WHEN "quick" : toggle$ = "prevquick"
- WHEN "orig" : toggle$ = "quick"
- ENDCASE
- CASE toggle$ OF
- WHEN "prevquick" :
- numvoices% = prequicknum%
- FOR count% = 1 TO numvoices%
- displayvoices%(count%) = prequickdisplay%(count%)
- NEXT
- startv% = prequickstart%
- WHEN "quick" :
- numvoices% = quicknum%
- FOR count% = 1 TO numvoices%
- displayvoices%(count%) = quickdisplay%(count%)
- NEXT
- startv% = quickstart%
- WHEN "orig" :
- numvoices% = holdnum%
- FOR count% = 1 TO numvoices%
- displayvoices%(count%) = holddisplay%(count%)
- NEXT
- startv% = holdstart%
- ENDCASE
- PROCdisplay
- WHEN "p" :
- play$ = "playscreen" : startingbar% = startbar% : startbeat% = 0
- endbar% = nobars% : nvoices% = quickplay%
- FOR count% = 1 TO quickplay%
- playvoices%(count%) = displayvoices%(startv%+count%-1)
- NEXT
- PROCplay
- WHEN ";" :
- play$ = "playscreen" : startingbar% = startbar% : startbeat% = 0
- endbar% = nobars% : nvoices% = 1
- playvoices%(1) = displayvoices%(startv%+1)
- PROCplay
- WHEN "/" :
- play$ = "playscreen" : startingbar% = startbar% : startbeat% = 0
- endbar% = nobars% : nvoices% = 1
- playvoices%(1) = displayvoices%(startv%+2)
- PROCplay
- WHEN "P" :
- play$ = "playscreen" : startingbar% = startbar% : startbeat% = 0
- endbar% = startbar%+numbars%-1 : nvoices% = quickplay%
- FOR count% = 1 TO quickplay%
- playvoices%(count%) = displayvoices%(startv%+count%-1)
- NEXT
- PROCplay
- WHEN ":" :
- play$ = "playscreen" : startingbar% = startbar% : startbeat% = 0
- endbar% = startbar%+numbars%-1 : nvoices% = 1
- playvoices%(1) = displayvoices%(startv%+1)
- PROCplay
- WHEN "?" :
- play$ = "playscreen" : startingbar% = startbar% : startbeat% = 0
- endbar% = startbar%+numbars%-1 : nvoices% = 1
- playvoices%(1) = displayvoices%(startv%+2)
- PROCplay
- WHEN "z" : PROCcopyonenote
- WHEN "x" : PROCcopygroupofnotes
- WHEN "-" :
- IF numbars% > 1 THEN numbars% = numbars%/2
- PROCdisplay
- WHEN "t" : funcinput$ = "durat" : PROCdisplay
- WHEN "e" : funcinput$ = "points" : PROCdisplay
- WHEN "f" : funcinput$ = "displayed" : PROCdisplay
- :
- WHEN "1" :
- IF setalong$ = "y" THEN along% = 0 : PROCpostdisplay
- IF setalong$ = "n" THEN numvoices% = 1 : numvoicesgiven$ = "y" : PROCquickdisplay
- IF setalong$ = "playnovoices" THEN quickplay% = 1 : PROCdisplay
- WHEN "2" :
- IF setalong$ = "y" THEN along% = 1 : PROCpostdisplay
- IF setalong$ = "n" THEN numvoices% = 2 : numvoicesgiven$ = "y" : PROCquickdisplay
- IF setalong$ = "playnovoices" THEN quickplay% = 2 : PROCdisplay
- WHEN "3" :
- IF setalong$ = "y" THEN along% = 2 : PROCpostdisplay
- IF setalong$ = "n" THEN numvoices% = 3 : numvoicesgiven$ = "y" : PROCquickdisplay
- IF setalong$ = "playnovoices" THEN quickplay% = 3 : PROCdisplay
- WHEN "4" :
- IF setalong$ = "y" THEN along% = 3 : PROCpostdisplay
- IF setalong$ = "n" THEN numvoices% = 4 : numvoicesgiven$ = "y" : PROCquickdisplay
- IF setalong$ = "playnovoices" THEN quickplay% = 4 : PROCdisplay
- WHEN "5" :
- IF setalong$ = "y" THEN along% = 4 : PROCpostdisplay
- IF setalong$ = "n" THEN numvoices% = 5 : numvoicesgiven$ = "y" : PROCquickdisplay
- IF setalong$ = "playnovoices" THEN quickplay% = 5 : PROCdisplay
- WHEN "7" :
- IF setalong$ = "y" THEN along% = 6 : PROCpostdisplay
- IF setalong$ = "n" THEN numvoices% = 7 : numvoicesgiven$ = "y" : PROCquickdisplay
- IF setalong$ = "playnovoices" THEN quickplay% = 7 : PROCdisplay
- WHEN "8" :
- IF setalong$ = "y" THEN along% = 7 : PROCpostdisplay
- IF setalong$ = "n" THEN numvoices% = 8 : numvoicesgiven$ = "y" : PROCquickdisplay
- IF setalong$ = "playnovoices" THEN quickplay% = 8 : PROCdisplay
- WHEN "9" :
- IF setalong$ = "y" THEN along% = 8 : PROCpostdisplay
- IF setalong$ = "n" THEN numvoices% = 9 : numvoicesgiven$ = "y" : PROCquickdisplay
- IF setalong$ = "playnovoices" THEN
- PROCwindow(20,69,60,55)
- PRINT'" The maximum number of voices "
- PRINT " that can be played is 8 "
- PRINT'" (press a key to continue) "
- CASE GET$ OF
- OTHERWSE PROCdisplay
- ENDCASE
- ENDIF
- WHEN "]" :
- IF squarebracket$ = "remarks" THEN
- count% = startbar%-1
- REPEAT
- count%+=1
- IF remarks$(count%,0) <> "" THEN itt% = count%
- UNTIL remarks$(count%,0) <> ""
- remarks$(itt%+1,0) = remarks$(itt%,0)
- remarks$(itt%,0) = ""
- ELSE
- addten$ = "y"
- ENDIF
- PROCdisplay
- WHEN "}" :
- count% = startbar%-1
- REPEAT
- count%+=1
- IF remarks$(count%,0) <> "" THEN itt% = count%
- UNTIL remarks$(count%,0) <> ""
- remarks$(itt%+10,0) = remarks$(itt%,0)
- remarks$(itt%,0) = ""
- PROCdisplay
- WHEN "[" :
- IF squarebracket$ = "remarks" THEN
- count% = startbar%-1
- REPEAT
- count%+=1
- IF remarks$(count%,0) <> "" THEN itt% = count%
- UNTIL remarks$(count%,0) <> ""
- remarks$(itt%-1,0) = remarks$(itt%,0)
- remarks$(itt%,0) = ""
- ELSE
- addten$ = "n"
- ENDIF
- PROCdisplay
- WHEN "{" :
- count% = startbar%-1
- REPEAT
- count%+=1
- IF remarks$(count%,0) <> "" THEN itt% = count%
- UNTIL remarks$(count%,0) <> ""
- remarks$(itt%-10,0) = remarks$(itt%,0)
- remarks$(itt%,0) = ""
- PROCdisplay
- WHEN "#" :
- IF squarebracket$ = "remarks" THEN
- count% = startbar%-1
- REPEAT
- count%+=1
- IF remarks$(count%,1) <> "" THEN itt% = count%
- UNTIL remarks$(count%,1) <> ""
- remarks$(itt%+1,1) = remarks$(itt%,1)
- remarks$(itt%,1) = ""
- ENDIF
- PROCdisplay
- WHEN "'" :
- IF squarebracket$ = "remarks" THEN
- count% = startbar%-1
- REPEAT
- count%+=1
- IF remarks$(count%,1) <> "" THEN itt% = count%
- UNTIL remarks$(count%,1) <> ""
- remarks$(itt%-1,1) = remarks$(itt%,1)
- remarks$(itt%,1) = ""
- ELSE
- addten$ = "twenty"
- ENDIF
- PROCdisplay
- WHEN "L" : slavemethod$ = "random" : quickslave$ = "y" : PROCslave
- WHEN "Q" : voix% = 1 : son% = 0 : PROCedit
- WHEN "W" : voix% = 1 : son% = 1 : PROCedit
- WHEN "E" : voix% = 1 : son% = 2 : PROCedit
- WHEN "R" : voix% = 1 : son% = 3 : PROCedit
- WHEN "T" : voix% = 1 : son% = 4 : PROCedit
- WHEN "A" : voix% = 2 : son% = 0 : PROCedit
- WHEN "S" : voix% = 2 : son% = 1 : PROCedit
- WHEN "D" : voix% = 2 : son% = 2 : PROCedit
- WHEN "F" : voix% = 2 : son% = 3 : PROCedit
- WHEN "G" : voix% = 2 : son% = 4 : PROCedit
- WHEN "H" : voix% = 2 : son% = 5 : PROCedit
- WHEN "Z" : voix% = 3 : son% = 0 : PROCedit
- WHEN "X" : voix% = 3 : son% = 1 : PROCedit
- WHEN "C" : voix% = 3 : son% = 2 : PROCedit
- WHEN "V" : voix% = 3 : son% = 3 : PROCedit
- WHEN "B" : voix% = 3 : son% = 4 : PROCedit
- WHEN "N" : voix% = 3 : son% = 5 : PROCedit
- WHEN ">" :
- voice% = displayvoices%(voix%+(startv%-1))-1
- CASE editwhat$ OF
- WHEN "1stenvelope" :
- array%(holdstartcell%(voice%)+son%,2,voice%) = array%(holdstartcell%(voice%)+son%,2,voice%) + 100000
- WHEN "2ndenvelope" :
- array%(holdstartcell%(voice%)+son%,2,voice%) = array%(holdstartcell%(voice%)+son%,2,voice%) + 10000000
- WHEN "1stamplitude" :
- array%(holdstartcell%(voice%)+son%,1,voice%) = array%(holdstartcell%(voice%)+son%,1,voice%) + 1
- IF array%(holdstartcell%(voice%)+son%,1,voice%)MOD10 = 9 THEN
- array%(holdstartcell%(voice%)+son%,1,voice%) = array%(holdstartcell%(voice%)+son%,1,voice%) - 9
- ENDIF
- WHEN "2ndamplitude" :
- array%(holdstartcell%(voice%)+son%,2,voice%) = array%(holdstartcell%(voice%)+son%,2,voice%) + 100
- IF (array%(holdstartcell%(voice%)+son%,2,voice%)DIV10^2)MOD10 = 9 THEN
- array%(holdstartcell%(voice%)+son%,2,voice%) = array%(holdstartcell%(voice%)+son%,2,voice%) - 900
- ENDIF
- WHEN "3rdamplitude" :
- array%(holdstartcell%(voice%)+son%,2,voice%) = array%(holdstartcell%(voice%)+son%,2,voice%) + 1000
- IF (array%(holdstartcell%(voice%)+son%,2,voice%)DIV10^3)MOD10 = 9 THEN
- array%(holdstartcell%(voice%)+son%,2,voice%) = array%(holdstartcell%(voice%)+son%,2,voice%) - 9000
- ENDIF
- WHEN "4thamplitude" :
- array%(holdstartcell%(voice%)+son%,2,voice%) = array%(holdstartcell%(voice%)+son%,2,voice%) + 10000
- IF (array%(holdstartcell%(voice%)+son%,2,voice%)DIV10^4)MOD10 = 9 THEN
- array%(holdstartcell%(voice%)+son%,2,voice%) = array%(holdstartcell%(voice%)+son%,2,voice%) - 90000
- ENDIF
- WHEN "movetwo" :
- array%(holdstartcell%(voice%)+son%,0,voice%) = array%(holdstartcell%(voice%)+son%,0,voice%) + 60000
- IF (array%(holdstartcell%(voice%)+son%,0,voice%)DIV10^3)MOD10^3 > 900 THEN
- number% = (array%(holdstartcell%(voice%)+son%,0,voice%)DIV10^3)MOD10^3
- array%(holdstartcell%(voice%)+son%,0,voice%) = array%(holdstartcell%(voice%)+son%,0,voice%) - (number%*1000)
- array%(holdstartcell%(voice%)+son%,0,voice%) = array%(holdstartcell%(voice%)+son%,0,voice%) + 1000000
- ENDIF
- array%(holdstartcell%(voice%)+son%+1,0,voice%) = array%(holdstartcell%(voice%)+son%+1,0,voice%) + 60000
- IF (array%(holdstartcell%(voice%)+son%+1,0,voice%)DIV10^3)MOD10^3 > 900 THEN
- number% = (array%(holdstartcell%(voice%)+son%+1,0,voice%)DIV10^3)MOD10^3
- array%(holdstartcell%(voice%)+son%+1,0,voice%) = array%(holdstartcell%(voice%)+son%+1,0,voice%) - (number%*1000)
- array%(holdstartcell%(voice%)+son%+1,0,voice%) = array%(holdstartcell%(voice%)+son%+1,0,voice%) + 1000000
- ENDIF
- WHEN "move&drag" :
- array%(holdstartcell%(voice%)+son%,0,voice%) = array%(holdstartcell%(voice%)+son%,0,voice%) + 60000
- IF (array%(holdstartcell%(voice%)+son%,0,voice%)DIV10^3)MOD10^3 > 900 THEN
- number% = (array%(holdstartcell%(voice%)+son%,0,voice%)DIV10^3)MOD10^3
- array%(holdstartcell%(voice%)+son%,0,voice%) = array%(holdstartcell%(voice%)+son%,0,voice%) - (number%*1000)
- array%(holdstartcell%(voice%)+son%,0,voice%) = array%(holdstartcell%(voice%)+son%,0,voice%) + 1000000
- ENDIF
- bar1% = (array%(holdstartcell%(voice%)+son%,0,voice%)DIV10^6)
- beat1% = (array%(holdstartcell%(voice%)+son%,0,voice%)DIV10^3)MOD10^3
- position1% = (bar1%*960) + beat1%
- bar2% = (array%(holdstartcell%(voice%)+son%-1,0,voice%)DIV10^6)
- beat2% = (array%(holdstartcell%(voice%)+son%-1,0,voice%)DIV10^3)MOD10^3
- position2% = (bar2%*960) + beat2%
- dur% = position1% - position2%
- PROCconvertdur
- number% = (array%(holdstartcell%(voice%)+son%-1,1,voice%)DIV10)MOD10^3
- array%(holdstartcell%(voice%)+son%-1,1,voice%) = array%(holdstartcell%(voice%)+son%-1,1,voice%) - (number%*10)
- array%(holdstartcell%(voice%)+son%-1,1,voice%) = array%(holdstartcell%(voice%)+son%-1,1,voice%) + (dur%*10)
- WHEN "duration" :
- array%(holdstartcell%(voice%)+son%,1,voice%) = array%(holdstartcell%(voice%)+son%,1,voice%) + 10
- IF (array%(holdstartcell%(voice%)+son%,1,voice%)DIV10)MOD10^3 > 998 THEN (array%(holdstartcell%(voice%)+son%,1,voice%)DIV10)MOD10^3 = 998
- ENDCASE
- PROCdisplay
- WHEN "<" :
- voice% = displayvoices%(voix%+(startv%-1))-1
- CASE editwhat$ OF
- WHEN "1stenvelope" :
- array%(holdstartcell%(voice%)+son%,2,voice%) = array%(holdstartcell%(voice%)+son%,2,voice%) - 100000
- WHEN "2ndenvelope" :
- array%(holdstartcell%(voice%)+son%,2,voice%) = array%(holdstartcell%(voice%)+son%,2,voice%) - 10000000
- WHEN "1stamplitude" :
- array%(holdstartcell%(voice%)+son%,1,voice%) = array%(holdstartcell%(voice%)+son%,1,voice%) - 1
- IF array%(holdstartcell%(voice%)+son%,1,voice%)MOD10 = 9 THEN
- array%(holdstartcell%(voice%)+son%,1,voice%) = array%(holdstartcell%(voice%)+son%,1,voice%) + 9
- ENDIF
- WHEN "2ndamplitude" :
- IF (array%(holdstartcell%(voice%)+son%,2,voice%)DIV10^2)MOD10 = 0 THEN
- array%(holdstartcell%(voice%)+son%,2,voice%) = array%(holdstartcell%(voice%)+son%,2,voice%) + 800
- ELSEarray%(holdstartcell%(voice%)+son%,2,voice%) = array%(holdstartcell%(voice%)+son%,2,voice%) - 100
- ENDIF
- WHEN "3rdamplitude" :
- array%(holdstartcell%(voice%)+son%,2,voice%) = array%(holdstartcell%(voice%)+son%,2,voice%) - 1000
- IF (array%(holdstartcell%(voice%)+son%,2,voice%)DIV10^3)MOD10 = 9 THEN
- array%(holdstartcell%(voice%)+son%,2,voice%) = array%(holdstartcell%(voice%)+son%,2,voice%) + 9000
- ENDIF
- WHEN "4thamplitude" :
- array%(holdstartcell%(voice%)+son%,2,voice%) = array%(holdstartcell%(voice%)+son%,2,voice%) - 10000
- IF (array%(holdstartcell%(voice%)+son%,2,voice%)DIV10^4)MOD10 = 9 THEN
- array%(holdstartcell%(voice%)+son%,2,voice%) = array%(holdstartcell%(voice%)+son%,2,voice%) + 90000
- ENDIF
- WHEN "movetwo" :
- array%(holdstartcell%(voice%)+son%,0,voice%) = array%(holdstartcell%(voice%)+son%,0,voice%) - 60000
- IF (array%(holdstartcell%(voice%)+son%,0,voice%)DIV10^3)MOD10^3 > 900 THEN
- number% = (array%(holdstartcell%(voice%)+son%,0,voice%)DIV10^3)MOD10^3
- array%(holdstartcell%(voice%)+son%,0,voice%) = array%(holdstartcell%(voice%)+son%,0,voice%) - (number%*1000)
- array%(holdstartcell%(voice%)+son%,0,voice%) = array%(holdstartcell%(voice%)+son%,0,voice%) + 900000
- ENDIF
- array%(holdstartcell%(voice%)+son%+1,0,voice%) = array%(holdstartcell%(voice%)+son%+1,0,voice%) - 60000
- IF (array%(holdstartcell%(voice%)+son%+1,0,voice%)DIV10^3)MOD10^3 > 900 THEN
- number% = (array%(holdstartcell%(voice%)+son%+1,0,voice%)DIV10^3)MOD10^3
- array%(holdstartcell%(voice%)+son%+1,0,voice%) = array%(holdstartcell%(voice%)+son%+1,0,voice%) - (number%*1000)
- array%(holdstartcell%(voice%)+son%+1,0,voice%) = array%(holdstartcell%(voice%)+son%+1,0,voice%) + 900000
- ENDIF
- WHEN "move&drag" :
- array%(holdstartcell%(voice%)+son%,0,voice%) = array%(holdstartcell%(voice%)+son%,0,voice%) - 60000
- IF (array%(holdstartcell%(voice%)+son%,0,voice%)DIV10^3)MOD10^3 > 900 THEN
- number% = (array%(holdstartcell%(voice%)+son%,0,voice%)DIV10^3)MOD10^3
- array%(holdstartcell%(voice%)+son%,0,voice%) = array%(holdstartcell%(voice%)+son%,0,voice%) - (number%*1000)
- array%(holdstartcell%(voice%)+son%,0,voice%) = array%(holdstartcell%(voice%)+son%,0,voice%) + 900000
- ENDIF
- bar1% = (array%(holdstartcell%(voice%)+son%,0,voice%)DIV10^6)
- beat1% = (array%(holdstartcell%(voice%)+son%,0,voice%)DIV10^3)MOD10^3
- position1% = (bar1%*960) + beat1%
- bar2% = (array%(holdstartcell%(voice%)+son%-1,0,voice%)DIV10^6)
- beat2% = (array%(holdstartcell%(voice%)+son%-1,0,voice%)DIV10^3)MOD10^3
- position2% = (bar2%*960) + beat2%
- dur% = position1% - position2%
- PROCconvertdur
- number% = (array%(holdstartcell%(voice%)+son%-1,1,voice%)DIV10)MOD10^3
- array%(holdstartcell%(voice%)+son%-1,1,voice%) = array%(holdstartcell%(voice%)+son%-1,1,voice%) - (number%*10)
- array%(holdstartcell%(voice%)+son%-1,1,voice%) = array%(holdstartcell%(voice%)+son%-1,1,voice%) + (dur%*10)
- WHEN "duration" :
- array%(holdstartcell%(voice%)+son%,1,voice%) = array%(holdstartcell%(voice%)+son%,1,voice%) - 10
- ENDCASE
- PROCdisplay
- :
- OTHERWISE PROCawait
- :
- ENDCASE
- ENDPROC
- :
- REM**********************************************
- :
- DEF PROCrhythmdisplay
- :
- IF longscore$ = "n" THEN finalbar% = (firstbar%+((numbars%/2)))-1 ELSE finalbar% = (firstbar%+(numbars%))-1
- FOR bar% = firstbar% TO finalbar%
- :
- rgroup%(1) = disarray%(bar%,0,voice%)DIV10^3
- rgroup%(2) = ((disarray%(bar%,0,voice%)MOD10^3)*10^3)+(disarray%(bar%,1,voice%)DIV10^6)
- rgroup%(3) = disarray%(bar%,1,voice%)MOD10^6
- rgroup%(4) = disarray%(bar%,2,voice%)DIV10^3
- rgroup%(5) = disarray%(bar%,3,voice%)
- :
- FOR group% = 1 TO 5
- :
- IF rgroup%(group%) <> 0 THEN
- IF group% < 5 THEN
- beat% = rgroup%(group%)DIV10^4
- addition% = (960*factor)*(bar%-firstbar%)
- leftend% = (beat%*beatfactor%)
- grouplength% = ((rgroup%(group%)MOD10^4)DIV10^2)*beatfactor%
- divs% = (rgroup%(group%)MOD10^2)
- rightend% = leftend%+((grouplength%/divs%)*(divs%-1))
- ELSE
- beat% = rgroup%(group%)DIV10^7
- addition% = (960*factor)*(bar%-firstbar%)
- leftend% = (beat%*beatfactor%)
- grouplength% = ((rgroup%(group%)MOD10^7)DIV10^4)*beatfactor%
- divs% = (rgroup%(group%)MOD10^4)
- rightend% = leftend%+((grouplength%/divs%)*(divs%-1))
- ENDIF
- :
- value = divs%/(grouplength%/beatfactor%)
- :
- IF value >= 1 AND value < 2 THEN change% = 0
- IF value >= 2 AND value < 4 THEN change% = 1
- IF value >= 4 AND value < 8 THEN change% = 2
- IF value >= 8 AND value < 16 THEN change% = 3
- IF value >= 0.5 AND value < 1 THEN change% = -1
- IF value >= 0.25 AND value < 0.5 THEN change% = -2
- IF value >= 0.125 AND value < 0.25 THEN change% = -3
- IF value >= 0.0625 AND value < 0.125 THEN change% = -4
- IF value >= 0.03125 AND value < 0.0625 THEN change% = -5
- numbeams% = beams% + change%
- IF numbeams% < 0 THEN numbeams% = 0
- :
- IF longscore$ = "n" THEN v% = 938 + shortbeamposn%(voice%) ELSE v% = actbeamposn%(count%-startv%)
- IF longscore$ = "n" THEN
- IF shortstemdir$(voice%) = "D" THEN x% = -12 ELSE x% = 12
- ELSE IF longstemdir$(voice%) = "D" THEN x% = -12 ELSE x% = 12
- ENDIF
- IF longscore$ = "n" THEN inc% = 80 ELSE inc% = 120
- :
- IF numbeams% > 0 THEN
- :
- left% = (leftend%*factor)+inc%+addition%
- right% = (rightend%*factor)+inc%+addition%
- gap% = (right% - left%)/(divs%-1)
- FOR times% = 1 TO numbeams%
- pt1% = left%
- space = grouplength%/divs%
- pt2% = ((leftend%*factor)+(inc%+2)+((space*factor)))+addition%
- ct% = -1
- power% = (5-times%)
- IF power% < 1 THEN power% = 1
- n% = 2^power%
- WHILE pt2%<= (right%+10)
- ct% += 1
- IF ((ct%+1)/n%*10)MOD10 <> 0 OR times% = 1 THEN
- LINE pt1%,((v%-(524*(system%-1)))-(x%*(times%-1))),pt2%,((v%-(524*(system%-1)))-(x%*(times%-1)))
- LINE pt1%,(((v%-2)-(524*(system%-1)))-(x%*(times%-1))),pt2%,(((v%-2)-(524*(system%-1)))-(x%*(times%-1)))
- LINE pt1%,(((v%-4)-(524*(system%-1)))-(x%*(times%-1))),pt2%,(((v%-4)-(524*(system%-1)))-(x%*(times%-1)))
- REM for beams crossing systems
- IF right% > 1600 THEN crossing$ = "y" ELSE crossing$ = "n"
- IF crossing$ = "y" AND longscore$ = "n" AND system% = 1 THEN
- LINE pt1%-1600+inc%,((v%-(524*(system%-1)))-(x%*(times%-1)))-524,pt2%-1600+inc%,((v%-(524*(system%-1)))-(x%*(times%-1)))-524
- LINE pt1%-1600+inc%,(((v%-2)-(524*(system%-1)))-(x%*(times%-1)))-524,pt2%-1600+inc%,(((v%-2)-(524*(system%-1)))-(x%*(times%-1)))-524
- LINE pt1%-1600+inc%,(((v%-4)-(524*(system%-1)))-(x%*(times%-1)))-524,pt2%-1600+inc%,(((v%-4)-(524*(system%-1)))-(x%*(times%-1)))-524
- ENDIF
- ENDIF
- pt1% = pt2%
- pt2% = ((leftend%*factor)+(inc%+2)+((ct%+2)*(space*factor)))+addition%
- ENDWHILE
- NEXT
- ENDIF
- :
- space = grouplength%/divs%
- IF longscore$ = "y" THEN
- IF longstemdir$(voice%) = "U" THEN dir% = 1 ELSE dir% = -1
- ELSE
- IF shortstemdir$(voice%) = "U" THEN dir% = 1 ELSE dir% = -1
- ENDIF
- :
- FOR counter% = 0 TO (divs%-1)
- REM grouping% adds to length of stems to group in 2's, 4's etc
- grouping% = 0
- CASE shortstemdir$(voice%) OF
- WHEN "D" :
- IF (counter%/2*10)MOD10 = 0 THEN grouping% = -20
- IF (counter%/4*10)MOD10 = 0 THEN grouping% = -40
- IF (counter%/8*10)MOD10 = 0 THEN grouping% = -60
- OTHERWISE
- IF (counter%/2*10)MOD10 = 0 THEN grouping% = 20
- IF (counter%/4*10)MOD10 = 0 THEN grouping% = 40
- IF (counter%/8*10)MOD10 = 0 THEN grouping% = 60
- ENDCASE
- LINE ((leftend%*factor)+(inc%+2)+(counter%*(space*factor)))+addition%,(((v%)-(524*(system%-1)))),((leftend%*factor)+(inc%+2)+(counter%*(space*factor)))+addition%,((((v%)-(524*(system%-1))))-(((numbeams%*12)+32)*dir%)-grouping%)
- NEXT
- REM routine for groups crossing systems
- IF system% = 1 AND longscore$ = "n" AND crossing$ = "y" THEN
- FOR counter% = 0 TO (divs%-1)
- LINE (((leftend%*factor)+(inc%+2)+(counter%*(space*factor)))+addition%)-1600+inc%,(((v%)-(524*(system%-1))))-524,(((leftend%*factor)+(inc%+2)+(counter%*(space*factor)))+addition%)-1600+inc%,(((v%)-(524*(system%-1))))-(((numbeams%*12)+32)*dir%)-524
- :
- NEXT
- ENDIF
- :
- hposition% = (leftend%*factor)+inc%+addition%+(grouplength%/divs%*(divs%-1)/2*factor)
- vposition% =((v%+32)-(524*(system%-1)))
- REM routine for groups crossing systems
- IF hposition% > 2112 THEN
- hposition% = hposition% - 2062
- vposition% = vposition% - 524
- ENDIF
- IF longscore$ = "y" THEN
- IF longstemdir$(voice%) = "D" THEN vposition% -= 50
- ELSE
- IF shortstemdir$(voice%) ="D" THEN vposition% -= 50
- ENDIF
- IF longstemdir$(voice%) = "U" THEN vposition% -= 6
- IF shortstemdir$(voice%) ="U" THEN vposition% -= 6
- :
- grouplength% = grouplength%/beatfactor%
- lownum% = grouplength%
- IF change% = 0 THEN decimal% = 0
- IF change% = 1 THEN lownum% = lownum%*2 : decimal% = 0
- IF change% = 2 THEN lownum% = lownum%*4 : decimal% = 0
- IF change% = 3 THEN lownum% = lownum%*8 : decimal% = 0
- IF change% = -1 THEN lownum = lownum%/2 : decimal% = (lownum*10)MOD10 : lownum% = lownum*1
- IF change% = -2 THEN lownum = lownum%/4 : decimal% = (lownum*10)MOD10 : lownum% = lownum*1
- IF change% = -3 THEN lownum = lownum%/8 : decimal% = (lownum*10)MOD10 : lownum% = lownum*1
- IF change% = -4 THEN lownum = lownum%/16 :decimal% = (lownum*10)MOD10 : lownum% = lownum*1
- IF change% = -5 THEN lownum = lownum%/32 :decimal% = (lownum*10)MOD10 : lownum% = lownum*1
- :
- printname$ = "n"
- WHILE ((divs%/2)*10)MOD10 = 0 AND ((lownum%/2)*10)MOD10 = 0 AND decimal% = 0
- divs% = divs%/2 : lownum% = lownum%/2 : change% -= 1 : printname$ = "y"
- ENDWHILE
- IF change% < -2 THEN printname$ = "y"
- :
- VDU 23,128,32,32,32,32,32,32,32,32
- VDU 23,129,48,40,36,34,32,32,32,32
- VDU 23,130,48,40,36,50,40,36,34,32
- VDU 23,131,36,34,32,32,32,32,32,32
- VDU 23,132,48,40,36,50,40,36,50,40
- VDU 23,133,36,50,40,36,50,32,32,32
- VDU 23,134,36,50,40,36,50,40,36,34
- VDU 23,135,1,1,1,29,63,63,62,28
- VDU 23,136,0,0,1,1,1,1,1,1
- VDU 23,137,1,1,1,29,35,35,34,28
- VDU 23,138,0,0,0,28,34,34,34,28
- :
- MOVE hposition%,vposition%
- IF divs% < 10 THEN VDU 8
- IF divs% >= 10 THEN
- VDU 8 : VDU 8
- ENDIF
- :
- IF decimal% = 0 THEN
- IF divs% <> lownum% THEN
- IF printname$ = "y" THEN
- PRINT ,;divs%;":";lownum%;
- CASE change% OF
- WHEN 3 : PRINT"//////"
- WHEN 2 : PRINT CHR$(134) : MOVE hposition%,vposition%+16
- IF divs% < 10 THEN VDU 8
- IF divs% >= 10 THEN
- VDU 8 : VDU 8
- ENDIF
- REM IF printing$ = "n" THEN GCOL 63 ELSE GCOL 0
- PRINT ,;" ";
- REM IF printing$ = "n" THEN GCOL 0 ELSE GCOL 63
- PRINT CHR$(132)
- WHEN 1 : PRINT CHR$(133) : MOVE hposition%,vposition%+16
- IF divs% < 10 THEN VDU 8
- IF divs% >= 10 THEN
- VDU 8 : VDU 8
- ENDIF
- REM IF printing$ = "n" THEN GCOL 63 ELSE GCOL 0
- PRINT ,;" ";
- REM IF printing$ = "n" THEN GCOL 0 ELSE GCOL 63
- PRINT CHR$(132)
- WHEN 0 : PRINT CHR$(131) : MOVE hposition%,vposition%+16
- IF divs% < 10 THEN VDU 8
- IF divs% >= 10 THEN
- VDU 8 : VDU 8
- ENDIF
- REM IF printing$ = "n" THEN GCOL 63 ELSE GCOL 0
- PRINT ,;" ";
- REM IF printing$ = "n" THEN GCOL 0 ELSE GCOL 63
- PRINT CHR$(132)
- WHEN -1 : PRINT CHR$(128) : MOVE hposition%,vposition%+16
- IF divs% < 10 THEN VDU 8
- IF divs% >= 10 THEN
- VDU 8 : VDU 8
- ENDIF
- REM IF printing$ = "n" THEN GCOL 63 ELSE GCOL 0
- PRINT ,;" ";
- REM IF printing$ = "n" THEN GCOL 0 ELSE GCOL 63
- PRINT CHR$(130)
- WHEN -2 : PRINT CHR$(128) : MOVE hposition%,vposition%+16
- IF divs% < 10 THEN VDU 8
- IF divs% >= 10 THEN
- VDU 8 : VDU 8
- ENDIF
- REM IF printing$ = "n" THEN GCOL 63 ELSE GCOL 0
- PRINT ,;" ";
- REM IF printing$ = "n" THEN GCOL 0 ELSE GCOL 63
- PRINT CHR$(129)
- WHEN -3 : PRINT CHR$(135) : MOVE hposition%,vposition%+16
- IF divs% < 10 THEN VDU 8
- IF divs% >= 10 THEN
- VDU 8 : VDU 8
- ENDIF
- REM IF printing$ = "n" THEN GCOL 63 ELSE GCOL 0
- PRINT ,;" ";
- REM IF printing$ = "n" THEN GCOL 0 ELSE GCOL 63
- PRINT CHR$(136)
- WHEN -4 : PRINT CHR$(137) : MOVE hposition%,vposition%+16
- IF divs% < 10 THEN VDU 8
- IF divs% >= 10 THEN
- VDU 8 : VDU 8
- ENDIF
- REM IF printing$ = "n" THEN GCOL 63 ELSE GCOL 0
- PRINT ,;" ";
- REM IF printing$ = "n" THEN GCOL 0 ELSE GCOL 63
- PRINT CHR$(136)
- WHEN -5 : PRINT CHR$(138)
- OTHERWISE
- ENDCASE
- ELSE PRINT ,;divs%;":";lownum%
- ENDIF
- ENDIF
- ELSE PRINT ,;divs%;":";lownum%;".";decimal%;
- CASE change% OF
- WHEN -1 : PRINT CHR$(128) : MOVE hposition%,vposition%+16
- IF divs% < 10 THEN VDU 8
- IF divs% >= 10 THEN
- VDU 8 : VDU 8
- ENDIF
- REM IF printing$ = "n" THEN GCOL 63 ELSE GCOL 0
- PRINT ,;" ";".";decimal%;
- REM IF printing$ = "n" THEN GCOL 0 ELSE GCOL 63
- PRINT CHR$(130)
- WHEN -2 : PRINT CHR$(128) : MOVE hposition%,vposition%+16
- IF divs% < 10 THEN VDU 8
- IF divs% >= 10 THEN
- VDU 8 : VDU 8
- ENDIF
- REM IF printing$ = "n" THEN GCOL 63 ELSE GCOL 0
- PRINT ,;" ";".";decimal%;
- REM IF printing$ = "n" THEN GCOL 0 ELSE GCOL 63
- PRINT CHR$(129)
- WHEN -3 : PRINT CHR$(135) : MOVE hposition%,vposition%+16
- IF divs% < 10 THEN VDU 8
- IF divs% >= 10 THEN
- VDU 8 : VDU 8
- ENDIF
- REM IF printing$ = "n" THEN GCOL 63 ELSE GCOL 0
- PRINT ,;" ";".";decimal%;
- REM IF printing$ = "n" THEN GCOL 0 ELSE GCOL 63
- PRINT CHR$(136)
- WHEN -4 : PRINT CHR$(137) : MOVE hposition%,vposition%+16
- IF divs% < 10 THEN VDU 8
- IF divs% >= 10 THEN
- VDU 8 : VDU 8
- ENDIF
- REM IF printing$ = "n" THEN GCOL 63 ELSE GCOL 0
- PRINT ,;" ";".";decimal%;
- REM IF printing$ = "n" THEN GCOL 0 ELSE GCOL 63
- PRINT CHR$(136)
- WHEN -5 : PRINT CHR$(138)
- OTHERWISE
- ENDCASE
- ENDCASE
- ENDIF
- :
- REM routine for groups crossing systems
- IF system% = 1 AND longscore$ = "n" AND crossing$ = "y" THEN
- MOVE hposition%-1600+inc%,vposition%-524
- IF divs% < 10 THEN VDU 8
- IF divs% >= 10 THEN
- VDU 8 : VDU 8
- ENDIF
- :
- IF decimal% = 0 THEN
- IF divs% <> lownum% THEN
- IF printname$ = "y" THEN
- PRINT ,;divs%;":";lownum%;
- CASE change% OF
- WHEN 3 : PRINT"//////"
- WHEN 2 : PRINT CHR$(134) : MOVE hposition%-1600+inc%,vposition%+16-524
- IF divs% < 10 THEN VDU 8
- IF divs% >= 10 THEN
- VDU 8 : VDU 8
- ENDIF
- REM IF printing$ = "n" THEN GCOL 63 ELSE GCOL 0
- PRINT ,;" ";
- REM IF printing$ = "n" THEN GCOL 0 ELSE GCOL 63
- PRINT CHR$(132)
- WHEN 1 : PRINT CHR$(133) : MOVE hposition%-1600+inc%,vposition%+16-524
- IF divs% < 10 THEN VDU 8
- IF divs% >= 10 THEN
- VDU 8 : VDU 8
- ENDIF
- REM IF printing$ = "n" THEN GCOL 63 ELSE GCOL 0
- PRINT ,;" ";
- REM IF printing$ = "n" THEN GCOL 0 ELSE GCOL 63
- PRINT CHR$(132)
- WHEN 0 : PRINT CHR$(131) : MOVE hposition%-1600+inc%,vposition%+16-524
- IF divs% < 10 THEN VDU 8
- IF divs% >= 10 THEN
- VDU 8 : VDU 8
- ENDIF
- REM IF printing$ = "n" THEN GCOL 63 ELSE GCOL 0
- PRINT ,;" ";
- REM IF printing$ = "n" THEN GCOL 0 ELSE GCOL 63
- PRINT CHR$(132)
- WHEN -1 : PRINT CHR$(128) : MOVE hposition%-1600+inc%,vposition%+16-524
- IF divs% < 10 THEN VDU 8
- IF divs% >= 10 THEN
- VDU 8 : VDU 8
- ENDIF
- REM IF printing$ = "n" THEN GCOL 63 ELSE GCOL 0
- PRINT ,;" ";
- REM IF printing$ = "n" THEN GCOL 0 ELSE GCOL 63
- PRINT CHR$(130)
- WHEN -2 : PRINT CHR$(128) : MOVE hposition%-1600+inc%,vposition%+16-524
- IF divs% < 10 THEN VDU 8
- IF divs% >= 10 THEN
- VDU 8 : VDU 8
- ENDIF
- REM IF printing$ = "n" THEN GCOL 63 ELSE GCOL 0
- PRINT ,;" ";
- REM IF printing$ = "n" THEN GCOL 0 ELSE GCOL 63
- PRINT CHR$(129)
- WHEN -3 : PRINT CHR$(135) : MOVE hposition%-1600+inc%,vposition%+16-524
- IF divs% < 10 THEN VDU 8
- IF divs% >= 10 THEN
- VDU 8 : VDU 8
- ENDIF
- REM IF printing$ = "n" THEN GCOL 63 ELSE GCOL 0
- PRINT ,;" ";
- REM IF printing$ = "n" THEN GCOL 0 ELSE GCOL 63
- PRINT CHR$(136)
- WHEN -4 : PRINT CHR$(137) : MOVE hposition%-1600+inc%,vposition%+16-524
- IF divs% < 10 THEN VDU 8
- IF divs% >= 10 THEN
- VDU 8 : VDU 8
- ENDIF
- REM IF printing$ = "n" THEN GCOL 63 ELSE GCOL 0
- PRINT ,;" ";
- REM IF printing$ = "n" THEN GCOL 0 ELSE GCOL 63
- PRINT CHR$(136)
- WHEN -5 : PRINT CHR$(138)
- OTHERWISE
- ENDCASE
- ELSE PRINT ,;divs%;":";lownum%
- ENDIF
- ENDIF
- ELSE PRINT ,;divs%;":";lownum%;".";decimal%;
- CASE change% OF
- WHEN -1 : PRINT CHR$(128) : MOVE hposition%-1600+inc%,vposition%+16-524
- IF divs% < 10 THEN VDU 8
- IF divs% >= 10 THEN
- VDU 8 : VDU 8
- ENDIF
- REM IF printing$ = "n" THEN GCOL 63 ELSE GCOL 0
- PRINT ,;" ";".";decimal%;
- REM IF printing$ = "n" THEN GCOL 0 ELSE GCOL 63
- PRINT CHR$(130)
- WHEN -2 : PRINT CHR$(128) : MOVE hposition%-1600+inc%,vposition%+16-524
- IF divs% < 10 THEN VDU 8
- IF divs% >= 10 THEN
- VDU 8 : VDU 8
- ENDIF
- REM IF printing$ = "n" THEN GCOL 63 ELSE GCOL 0
- PRINT ,;" ";".";decimal%;
- REM IF printing$ = "n" THEN GCOL 0 ELSE GCOL 63
- PRINT CHR$(129)
- WHEN -3 : PRINT CHR$(135) : MOVE hposition%-1600,+inc%,vposition%+16-524
- IF divs% < 10 THEN VDU 8
- IF divs% >= 10 THEN
- VDU 8 : VDU 8
- ENDIF
- REM IF printing$ = "n" THEN GCOL 63 ELSE GCOL 0
- PRINT ,;" ";".";decimal%;
- REM IF printing$ = "n" THEN GCOL 0 ELSE GCOL 63
- PRINT CHR$(136)
- WHEN -4 : PRINT CHR$(137) : MOVE hposition%-1600+inc%,vposition%+16-524
- IF divs% < 10 THEN VDU 8
- IF divs% >= 10 THEN
- VDU 8 : VDU 8
- ENDIF
- REM IF printing$ = "n" THEN GCOL 63 ELSE GCOL 0
- PRINT ,;" ";".";decimal%;
- REM IF printing$ = "n" THEN GCOL 0 ELSE GCOL 63
- PRINT CHR$(136)
- WHEN -5 : PRINT CHR$(138)
- OTHERWISE
- ENDCASE
- ENDCASE
- ENDIF
- ENDIF
- :
- ENDIF
- NEXT
- :
- NEXT
- :
- ENDPROC
- :
- REM*******************************************************
- :
- DEF PROCdisplaysubmenu
- :
- IF easiermenus$ = "n" THEN
- PROCwindow(20,66,60,39)
- CLS : OFF
- PRINT'" Notehead sizes N"
- PRINT " Longscore/Shortscore L"
- PRINT " Stem lengths S"
- PRINT " Beats posns/frequecy P"
- PRINT " Beat numbers/diffs I"
- PRINT " Beat numbers/diffs unit J"
- PRINT " Dynamics positions F"
- PRINT " Note number freq G"
- PRINT " Bar numbers Z"
- PRINT " Intervals settings Q"
- PRINT " Remove: "
- PRINT " staves, ledgers, clefs C"
- PRINT " lower stave (shrt sc) U"
- PRINT " barlines B"
- PRINT " beats T"
- PRINT " names, voice numbers V"
- PRINT " accidentals A"
- PRINT " stems, beams R"
- PRINT " durations D"
- PRINT " amplitudes M"
- PRINT " beat numbers (n,1st,y) O"
- PRINT " notenumbers H"
- PRINT " notenames E"
- PRINT " intervals K"
- PRINT " play screen renew Y"
- PRINT " all except noteheads X"
- ELSE
- PROCwindow(20,66,60,12)
- CLS : OFF
- PRINT'" Notehead sizes N"
- PRINT '" Longscore/Shortscore L"
- PRINT '" Stem lengths S"
- PRINT '" Beats posns/frequecy P"
- PRINT '" Beat numbers/diffs I"
- PRINT '" Beat numbers/diffs unit J"
- PRINT '" Dynamics positions F"
- PRINT '" Note number freq G"
- PRINT '" Bar numbers Z"
- PRINT '" Intervals settings Q"
- PRINT '" Remove: "
- PRINT '" staves, ledgers, clefs C"
- PRINT '" lower stave (shrt sc) U"
- PRINT '" barlines B"
- PRINT '" beats T"
- PRINT '" names, voice numbers V"
- PRINT '" accidentals A"
- PRINT '" stems, beams R"
- PRINT '" durations D"
- PRINT '" dynamics M"
- PRINT '" beat numbers (n,1st,y) O"
- PRINT '" notenumbers H"
- PRINT '" notenames E"
- PRINT '" intervals K"
- PRINT '" play screen renew Y"
- PRINT '" all except noteheads X"
- ENDIF
- :
- CASE GET$ OF
- WHEN "E","e" :
- IF notenames$ = "y" THEN notenames$ = "n" ELSE notenames$ = "y"
- WHEN "N","n" :
- CLS
- PRINT'" What size note-heads? (B/S/V) "
- CASE GET$ OF
- WHEN "B","b" : notehead$ = "big"
- WHEN "S","s" : notehead$ = "small"
- WHEN "V","v" : notehead$ = "vsmall"
- ENDCASE
- WHEN "L","l" :
- IF longscore$ = "n" THEN longscore$ = "y" ELSE longscore$ = "n"
- IF longscore$ = "n" THEN
- startv1% = startv% : startv% =1
- ELSE startv% = startv1%
- ENDIF
- WHEN "S","s" :
- CLS
- INPUT'" Which voice "voys%
- voys% -= 1
- PRINT'" stems to end how many"
- PRINT" octaves from top"
- INPUT" stave-line (0,1,-1 etc) "st
- INPUT " stems up or down (U/D)"stemdir$
- IF longscore$ = "n" THEN
- shortbeamposn%(voys%) = st*56
- IF shortbeamposn%(voys%) <= -112 THEN shortbeamposn%(voys%)-=48
- shortstemdir$(voys%) = stemdir$
- ENDIF
- IF longscore$ = "y" THEN
- longbeamposn%(voys%) = st*56
- longstemdir$(voys%) = stemdir$
- ENDIF
- :
- WHEN "P","p" :
- CLS
- PRINT'" Beats positions or frequecy (P/F)"
- CASE GET$ OF
- WHEN "P","p" :
- INPUT'" Upper or lower beats (U/L)"whichset$
- PRINT '" up or down by how many"
- INPUT " stave-lines (1,-1 etc)"move%
- IF whichset$ = "U" THEN
- longbeatsupper% += (move%*16)
- ELSE longbeatslower% += (move%*16)
- ENDIF
- OTHERWISE
- PRINT'" Beats frequency doubled/halved (+/-) "
- CASE GET$ OF
- WHEN "+","=" : beatstep% = beatstep%/2
- WHEN "_","-" : beatstep% = beatstep%*2
- OTHERWISE
- ENDCASE
- :
- ENDCASE
- :
- WHEN "Z","z" : CLS : INPUT'" Bar nos how often (1,2 etc) "barnosoften%
- WHEN "Y","y" :
- IF playnewscreen$ = "y" THEN playnewscreen$ = "n" ELSE playnewscreen$ = "y"
- WHEN "I","i" :
- IF beatnum_diff$ = "num" THEN beatnum_diff$ = "diff" ELSE beatnum_diff$ = "num"
- WHEN "J","j" :
- IF beatunits$ = "big" THEN beatunits$ = "small" ELSE beatunits$ = "big"
- WHEN "C","c" :
- IF staves$ = "y" THEN staves$ = "n" ELSE staves$ = "y"
- WHEN "B","b" :
- IF barlines$ = "y" THEN barlines$ = "n" ELSE barlines$ = "y"
- WHEN "T","t" :
- IF beats$ = "y" THEN beats$ = "n" ELSE beats$ = "y"
- WHEN "U","u" :
- IF lowerstave$ = "y" THEN lowerstave$ = "n" ELSE lowerstave$ = "y"
- WHEN "V","v" :
- IF names$ = "y" THEN names$ = "n" ELSE names$ = "y"
- WHEN "A","a" :
- IF accidentals$ = "y" THEN accidentals$ = "n" ELSE accidentals$ = "y"
- WHEN "R","r" :
- IF stems$ = "y" THEN stems$ = "n" ELSE stems$ = "y"
- WHEN "D","d" :
- IF durations$ = "y" THEN durations$ = "n" ELSE durations$ = "y"
- WHEN "M","m" :
- CASE amplitudes$ OF
- WHEN "n" : amplitudes$ = "y"
- WHEN "y" : amplitudes$ = "stepped"
- WHEN "stepped" : amplitudes$ = "n"
- ENDCASE
- WHEN "O","o" :
- CASE beatnumbers$ OF
- WHEN "y" : beatnumbers$ = "n"
- WHEN "n" : beatnumbers$ = "first"
- WHEN "first" : beatnumbers$ = "y"
- ENDCASE
- WHEN "H","h" :
- CASE notenumbers$ OF
- WHEN "last" : notenumbers$ = "n"
- WHEN "y" : notenumbers$ = "last"
- WHEN "from1" : notenumbers$ = "y"
- WHEN "n" : notenumbers$ = "from1"
- ENDCASE
- WHEN "F","f" :
- CLS
- INPUT'" Which voice "voys%
- voys% -= 1
- PRINT' " dynamics up/down by how many "
- INPUT " stave-lines (1,-1 etc) "dy%
- dy% = dy%*16
- IF longscore$ = "y" THEN
- longamppos%(voys%) += dy%
- ELSE shortamppos%(voys%) += dy%
- ENDIF
- WHEN "G","g" :
- CLS
- PRINT'" Note numbers every 1/2/4/10 notes (0 = 10) "
- CASE GET$ OF
- WHEN "1" : nosevery% = 1
- WHEN "2" : nosevery% = 2
- WHEN "4" : nosevery% = 4
- OTHERWISE nosevery% = 10
- ENDCASE
- INPUT' " starting at note number "startnos%
- :
- WHEN "Q","q" :
- CLS
- PRINT'" Set number/type of intervals displayed"
- PRINT" or compound reduction point? (N/C)"
- CASE GET$ OF
- WHEN "N","n" :
- PRINT'" Display intervals for how"
- INPUT" many previous notes "numintervals%
- PRINT'" Semitones, quartertones, "
- PRINT" eighthtones or cents (S/Q/E/C) "
- CASE GET$ OF
- WHEN "S","s" : typeintervals$ = "s"
- WHEN "Q","q" : typeintervals$ = "q"
- WHEN "E","e" : typeintervals$ = "e"
- WHEN "C","c" : typeintervals$ = "c"
- ENDCASE
- WHEN "C","c" :
- PRINT'" Above which interval should"
- PRINT" compounds be reduced for "
- INPUT" the current interval type "compound%
- CASE typeintervals$ OF
- WHEN "s" : compoundpitch% = compound%
- WHEN "q" : compoundquarter% = compound%
- WHEN "e" : compoundeighth% = compound%
- WHEN "c" : compoundcent% = compound%
- ENDCASE
- ENDCASE
- WHEN "K","k" :
- IF displayintervals$ = "y" THEN displayintervals$ = "n" ELSE displayintervals$ = "y"
- WHEN "X","x" :
- IF xoption$ = "y" THEN xoption$ = "n" ELSE xoption$ = "y"
- IF xoption$ = "y" THEN
- staves$ = "y" : barlines$ = "y" : beats$ = "y" : names$ = "y"
- accidentals$ = "y" : stems$ = "y" : durations$ = "y"
- amplitudes$ = "y" : envelopes$ = "y" : glissandos$ = "y"
- beatnumbers$ = "y"
- ELSE
- staves$ = "n" : barlines$ = "n" : beats$ = "n" : names$ = "n"
- accidentals$ = "n" : stems$ = "n" : durations$ = "n"
- amplitudes$ = "n" : envelopes$ = "n" : glissandos$ = "n"
- beatnumbers$ = "n"
- ENDIF
- OTHERWISE VDU 7 : PROCdisplaysubmenu
- ENDCASE
- ON
- PROCdisplay
- ENDPROC
- :
- REM*********************************************************
- :
- DEF PROCclef(numstaves%,staves%(1),staves%(2),staves%(3),staves%(4),staves%(5),staves%(6),clefcomb$)
- :
- IF staves$ = "y" THEN
- FOR count% = 1 TO numstaves%
- IF MID$(clefcomb$,count%,1) = "T" OR MID$(clefcomb$,count%,1) = "P" THEN
- LINE 48,staves%(count%)+20,52,staves%(count%)+20
- LINE 44,staves%(count%)+16,56,staves%(count%)+16
- LINE 42,staves%(count%)+12,52,staves%(count%)+12
- LINE 58,staves%(count%)+12,58,staves%(count%)+12
- LINE 40,staves%(count%)+8,48,staves%(count%)+8
- LINE 58,staves%(count%)+8,58,staves%(count%)+8
- LINE 40,staves%(count%)+4,42,staves%(count%)+4
- LINE 58,staves%(count%)+4,58,staves%(count%)+4
- LINE 38,staves%(count%)+0,40,staves%(count%)+0
- LINE 54,staves%(count%)+0,56,staves%(count%)+0
- LINE 38,staves%(count%)-4,38,staves%(count%)-4
- LINE 50,staves%(count%)-4,54,staves%(count%)-4
- LINE 38,staves%(count%)-8,38,staves%(count%)-8
- LINE 46,staves%(count%)-8,52,staves%(count%)-8
- LINE 36,staves%(count%)-12,52,staves%(count%)-12
- LINE 32,staves%(count%)-16,50,staves%(count%)-16
- LINE 24,staves%(count%)-20,44,staves%(count%)-20
- LINE 20,staves%(count%)-24,42,staves%(count%)-24
- LINE 14,staves%(count%)-28,26,staves%(count%)-28
- LINE 42,staves%(count%)-28,42,staves%(count%)-28
- LINE 12,staves%(count%)-32,22,staves%(count%)-32
- LINE 42,staves%(count%)-32,42,staves%(count%)-32
- LINE 12,staves%(count%)-36,22,staves%(count%)-36
- LINE 34,staves%(count%)-36,52,staves%(count%)-36
- LINE 10,staves%(count%)-40,18,staves%(count%)-40
- LINE 30,staves%(count%)-40,56,staves%(count%)-40
- LINE 10,staves%(count%)-44,14,staves%(count%)-44
- LINE 24,staves%(count%)-44,32,staves%(count%)-44
- LINE 42,staves%(count%)-44,42,staves%(count%)-44
- LINE 56,staves%(count%)-44,60,staves%(count%)-44
- LINE 10,staves%(count%)-48,14,staves%(count%)-48
- LINE 24,staves%(count%)-48,32,staves%(count%)-48
- LINE 42,staves%(count%)-48,42,staves%(count%)-48
- LINE 56,staves%(count%)-48,60,staves%(count%)-48
- LINE 10,staves%(count%)-52,16,staves%(count%)-52
- LINE 24,staves%(count%)-52,26,staves%(count%)-52
- LINE 42,staves%(count%)-52,42,staves%(count%)-52
- LINE 56,staves%(count%)-52,60,staves%(count%)-52
- LINE 12,staves%(count%)-56,16,staves%(count%)-56
- LINE 28,staves%(count%)-56,30,staves%(count%)-56
- LINE 42,staves%(count%)-56,42,staves%(count%)-56
- LINE 56,staves%(count%)-56,60,staves%(count%)-56
- LINE 18,staves%(count%)-60,22,staves%(count%)-60
- LINE 42,staves%(count%)-60,42,staves%(count%)-60
- LINE 52,staves%(count%)-60,58,staves%(count%)-60
- LINE 22,staves%(count%)-64,54,staves%(count%)-64
- LINE 42,staves%(count%)-68,42,staves%(count%)-68
- LINE 42,staves%(count%)-72,42,staves%(count%)-72
- LINE 22,staves%(count%)-76,28,staves%(count%)-76
- LINE 42,staves%(count%)-76,42,staves%(count%)-76
- LINE 18,staves%(count%)-80,32,staves%(count%)-80
- LINE 42,staves%(count%)-80,42,staves%(count%)-80
- LINE 14,staves%(count%)-84,28,staves%(count%)-84
- LINE 44,staves%(count%)-84,44,staves%(count%)-84
- LINE 14,staves%(count%)-88,22,staves%(count%)-88
- LINE 44,staves%(count%)-88,44,staves%(count%)-88
- LINE 24,staves%(count%)-92,42,staves%(count%)-92
- IF MID$(clefcomb$,count%,1) = "P" THEN
- MOVE 42,staves%(count%)+44
- PRINT;"8"
- ENDIF
- ENDIF
- IF MID$(clefcomb$,count%,1) = "B" OR MID$(clefcomb$,count%,1) = "D" THEN
- LINE 20,staves%(count%)-4,38,staves%(count%)-4
- LINE 16,staves%(count%)-8,18,staves%(count%)-8
- LINE 38,staves%(count%)-8,44,staves%(count%)-8
- LINE 58,staves%(count%)-8,60,staves%(count%)-8
- LINE 12,staves%(count%)-12,24,staves%(count%)-12
- LINE 40,staves%(count%)-12,48,staves%(count%)-12
- LINE 12,staves%(count%)-16,28,staves%(count%)-16
- LINE 40,staves%(count%)-16,48,staves%(count%)-16
- LINE 16,staves%(count%)-20,28,staves%(count%)-20
- LINE 40,staves%(count%)-20,48,staves%(count%)-20
- LINE 20,staves%(count%)-24,24,staves%(count%)-24
- LINE 40,staves%(count%)-24,48,staves%(count%)-24
- LINE 58,staves%(count%)-24,60,staves%(count%)-24
- LINE 40,staves%(count%)-28,48,staves%(count%)-28
- LINE 40,staves%(count%)-32,48,staves%(count%)-32
- LINE 36,staves%(count%)-36,44,staves%(count%)-36
- LINE 32,staves%(count%)-40,40,staves%(count%)-40
- LINE 28,staves%(count%)-44,34,staves%(count%)-44
- LINE 20,staves%(count%)-48,30,staves%(count%)-48
- LINE 10,staves%(count%)-52,18,staves%(count%)-52
- IFMID$(clefcomb$,count%,1) = "D" THEN
- MOVE 10,staves%(count%)-56
- PRINT;"8"
- ENDIF
- ENDIF
- NEXT
- ENDIF
- :
- IF names$ = "y" THEN
- stave% = 1
- FOR count% = 0 TO lastcount%
- IF MID$(clefcomb$,count%+1,1) = "P" THEN MOVE 20,staves%(stave%)+78 ELSE MOVE 20,staves%(stave%)+58
- PRINT longinsts$(count%,0);
- PRINT;"(";displayvoices%(startv%+count%);")" : REM voice number
- stave% += EVAL(MID$(stavecombination$,count%+1,1))
- NEXT
- ENDIF
- :
- REM defining actamppos%() values
- stave% = 1
- FOR count% = 0 TO lastcount%
- IF MID$(stavecombination$,count%+1,1) = "1" THEN
- actamppos%(displayvoices%(startv%+count%)) = staves%(stave%)-128+longamppos%(displayvoices%(startv%+count%)-1)
- ELSE actamppos%(displayvoices%(startv%+count%)) = staves%(stave%)-224+longamppos%(displayvoices%(startv%+count%)-1)
- ENDIF
- stave% += EVAL(MID$(stavecombination$,count%+1,1))
- NEXT
- :
- :
- REM barlines
- IF barlines$ = "y" THEN
- stave% = 1
- FOR system% = 0 TO lastcount%
- FOR barline% = 1 TO numbars%
- horpos% = (960*barline%*factor)+80
- IF notehead$ = "small" THEN horpos% += 16
- IF notehead$ = "vsmall" THEN horpos% += 24
- FOR thickness% = 2 TO 8 STEP 2
- IF MID$(stavecombination$,system%+1,1) = "1" THEN
- LINE horpos%+thickness%,staves%(stave%),horpos%+thickness%,staves%(stave%)-64
- ELSE
- LINE horpos%+thickness%,staves%(stave%),horpos%+thickness%,staves%(stave%)-160
- ENDIF
- NEXT
- REM bar nos
- IF printing$ = "n" THEN GCOL 3
- IF tempi%(startbar%) <> tempi%(startbar%-1) THEN
- MOVE 40,1145 : PRINT "b.";startbar%;" MM.";tempi%(startbar%)
- ELSE MOVE 40,1145 : PRINT "b.";startbar%;" (MM.";tempi%(startbar%);")"
- ENDIF
- IF remarks$(startbar%,0) <> "" OR remarks$(startbar%,1) <> "" THEN
- MOVE 40,1120 : PRINT remarks$(startbar%,0) : MOVE 40,1095 : PRINT remarks$(startbar%,1)
- ENDIF
- IF printing$ = "n" THEN GCOL 0
- IF system% = 0 THEN
- IF printing$ = "n" THEN GCOL 3
- IF tempi%(startbar%+barline%) <> tempi%(startbar%+barline%-1) THEN
- MOVE horpos%-125,1145 : PRINT startbar%+barline%;" MM.";tempi%(startbar%+barline%)
- ELSE IF barline% MOD barnosoften% = 0 THEN MOVE horpos%-125,1145 : PRINT startbar%+barline%
- ENDIF
- IF remarks$(startbar%+barline%,0) <> "" OR remarks$(startbar%+barline%,1) <> "" THEN
- MOVE horpos%,1120 : PRINT remarks$(startbar%+barline%,0)
- MOVE horpos%,1095 : PRINT remarks$(startbar%+barline%,1)
- ENDIF
- REM print duration at bottom right
- IF seeduration$ = "y" THEN
- IF startbar% + barline% = startbar% + numbars% - 1 THEN
- totaldur = 0
- FOR count% = 1 TO startbar% + numbars% - 1
- duration = 60/tempi%(count%)
- totaldur = totaldur + duration
- NEXT
- totaldur% = totaldur
- mins% = totaldur% DIV 60
- secs% = totaldur% - (mins%*60)
- MOVE 1200,50 : PRINT "duration ";mins%;" mins ";secs%;" secs"
- ENDIF
- ENDIF
- IF printing$ = "n" THEN GCOL 0
- ENDIF
- NEXT
- stave% += EVAL(MID$(stavecombination$,system%+1,1))
- NEXT
- ENDIF
- :
- ENDPROC
- :
- REM*************************************************
- :
- DEF PROClongvalue(pos%(0),pos%(1),pos%(2),clefcomb$)
- :
- staff% = 1
- finish% = endv%-startv%
- IF finish% > 2 THEN finish% = 2
- FOR ct% = 0 TO finish%
- CASE MID$(clefcomb$,staff%,1) OF
- WHEN "P" : decrement% = 360
- WHEN "T" : decrement% = 304
- WHEN "B" : decrement% = 208
- WHEN "D" : decrement% = 152
- ENDCASE
- value%(ct%) = pos%(ct%) - decrement%
- staff% += EVAL(MID$(stavecombination$,ct%+1,1))
- NEXT
- :
- FOR ct% = 0 TO finish%
- actbeamposn%(ct%) = longbeamposn%(displayvoices%(startv%+ct%)-1) + pos%(ct%)
- NEXT
- ENDPROC
- :
- REM*************************************************
- :
- DEF PROCconvertdur
- :
- REM converts dur% from beats to 1/20ths of a second
- converter = (60 * 20)/(tempi%(barno%) * 960)
- dur = dur% * converter
- fraction = ((dur*10)DIV1)MOD10
- IF fraction>4 THEN dur% = dur+1 ELSE dur% = dur
- IF dur% = 0 THEN dur% = 1
- IF dur% > 999 THEN dur% = 998 : REM max 3 array cells available
- :
- ENDPROC
- :
- REM**********************************************
- :
- DEF PROCreconvertdur
- :
- converter = (60 * 20)/(tempi%(brrr%) * 960)
- dur% = dur%/converter
- :
- ENDPROC
- :
- REM************************************************
- :
- DEF PROCseriesdurations
- :
- IF easiermenus$ = "n" THEN PROCwindow(20,69,60,55) ELSE PROCwindow(20,69,60,42)
- CLS
- PRINT'" How many durations (for 1 press 0) "
- PRINT'" (to fill gaps between attacks "
- PRINT'" press 111 or to half-fill gaps "
- INPUT'" between attacks press 222) "numdurations%
- IF numdurations% = 0 THEN numdurations% = 1
- IF numdurations% = 111 OR numdurations% = 222 THEN PROCdurationsbetween
- :
- IF numdurations% = 1 THEN
- PRINT'" the duration is:" : INPUT' " bars "b% : INPUT' " beats "beats%
- PROCalterbeats : dur% = (b%*960)+beats%
- durations%(0) = dur%
- ELSE
- PRINT'" Are all the durations the same?"
- PRINT'" (no = n/2)"
- CASE GET$ OF
- WHEN "N","n","2"
- FOR count% = 0 TO (numdurations% - 1)
- PRINT'" duration ";count%;" is:"
- INPUT'" bars "b%
- INPUT'" beats "beats% : PROCalterbeats
- dur% = (b%*960)+beats%
- durations%(count%) = dur%
- NEXT
- OTHERWISE
- : PRINT'" the duration is:" : INPUT' " bars "b% : INPUT' " beats "beats%
- PROCalterbeats : dur% = (b%*960)+beats%
- FOR count% = 0 TO (numdurations%-1) : durations%(count%) = dur% : NEXT
- ENDCASE
- ENDIF
- :
- REM function can feed durats similarly into durations%()
- :
- PROCinsertdurations
- :
- ENDPROC
- :
- REM***********************************************
- :
- DEF PROCinsertdurations
- :
- CLS
- IF seequery$ = "y" THEN
- PRINT'" Do you want to read these "
- PRINT " durations into the array? "
- CASE GET$ OF
- WHEN "N","n" : PROCdisplay : REM durations%() remains intact
- OTHERWISE
- ENDCASE
- ENDIF : REM seequery$
- :
- IF screenvoices$ = "n" THEN
- INPUT' " Which voice (0 = top)"voice%
- IF voice% = 0 THEN PROCpressenter
- ELSE
- PRINT'" Which screen voice "
- CASE GET$ OF
- WHEN "1" : voice% = 1
- WHEN "2" : voice% = 2
- WHEN "3" : voice% = 3
- OTHERWISE PROCpressenter
- ENDCASE
- ENDIF
- IF screenvoices$ = "y" AND voice% > 0 THEN voice% = displayvoices%(startv%+voice%-1)
- voice% -= 1
- IF voice% >= 0 THEN samevoice% = voice%
- IF voice% = -1 THEN voice% = samevoice%
- :
- IF quickcopy$ = "n" THEN
- INPUT'" Starting at bar number "bars%
- INPUT " beat "beats% : PROCalterbeats
- startat% = (bars%*(10^3))+beats%
- ELSE
- INPUT ' " starting at note number (0 counts as 1) "along%
- IF along% = 0 THEN along% = 1
- along%-=1
- copystartbar% = array%(holdstartcell%(voice%)+along%,0,voice%)DIV10^6
- copystartbeat% = (array%(holdstartcell%(voice%)+along%,0,voice%)MOD10^6)DIV10^3
- beats% = copystartbeat%
- PROCalterbeats
- startat% = (copystartbar%*(10^3))+beats%
- ENDIF
- :
- PROCsearch(startat%)
- shunt$ = "N"
- :
- FOR count% = startcell% TO (startcell%+(numdurations%-1))
- PROCcellfill(count%,voice%,999,999,999,9,999,durations%(count%-startcell%),99,99)
- NEXT
- :
- PROCdisplay
- :
- ENDPROC
- :
- REM*************************************************
- :
- DEF PROCinsertamplitudes
- :
- CLS
- repeatposit$ = "n"
- IF seequery$ = "y" THEN
- PRINT'" Do you want to read these amplitudes "
- PRINT " into the array? "
- CASE GET$ OF
- WHEN "N","n" : PROCdisplay : REM amplitudes%()) remains intact
- OTHERWISE
- ENDCASE
- ENDIF : REM seequery$
- :
- IF ampmethod$ = "sample" THEN
- IF screenvoices$ = "n" THEN
- INPUT' " Which voice (0 = top)"voice%
- IF voice% = 0 THEN PROCpressenter
- ELSE
- PRINT'" Which screen voice "
- CASE GET$ OF
- WHEN "1" : voice% = 1
- WHEN "2" : voice% = 2
- WHEN "3" : voice% = 3
- OTHERWISE PROCpressenter
- ENDCASE
- ENDIF
- IF screenvoices$ = "y" AND voice% > 0 THEN voice% = displayvoices%(startv%+voice%-1)
- voice% -= 1
- IF voice% >= 0 THEN samevoice% = voice%
- IF voice% = -1 THEN voice% = samevoice%
- :
- IF quickcopy$ = "y" THEN
- INPUT ' " starting at note number (0 counts as 1) "along%
- IF along% = 0 THEN along% = 1
- along%-=1
- bars% = array%(holdstartcell%(voice%)+along%,0,voice%)DIV10^6
- beats% = (array%(holdstartcell%(voice%)+along%,0,voice%)MOD10^6)DIV10^3
- holdbar% = bars%
- holdbeat% = beats%
- PROCalterbeats
- startat% = (bars%*(10^3))+beats%
- :
- ELSE
- :
- INPUT'" Starting at bar number "bars%
- IF bars% = 0 THEN
- bars% = holdbar% : beats% = holdbeat% : repeatposit$ = "y"
- ENDIF
- holdbar% = bars%
- IF repeatposit$ = "y" THEN
- PRINT'" bar ";bars%;" beat ";beats%;"?"
- PRINT'" (for OK press 0, if not OK press X)"
- CASE GET$ OF
- WHEN"X","x" : PROCinsertpitches
- OTHERWISE
- ENDCASE
- ELSE
- INPUT " beat "beats%
- holdbeat% = beats%
- ENDIF
- PROCalterbeats
- startat% = (bars%*(10^3))+beats%
- :
- ENDIF
- :
- ENDIF
- :
- PROCsearch(startat%)
- shunt$ = "N"
- :
- FOR count% = startcell% TO (startcell%+(numamplitudes%-1))
- PROCcellfill(count%,voice%,999,999,999,amplitudes%(count%-startcell%),999,999,99,99)
- NEXT
- :
- PROCdisplay
- :
- ENDPROC
- :
- REM************************************************
- :
- DEF PROCassignvoices
- :
- IF defaultvoices$ = "y" THEN
- waveforms$() = "WaveSynth-Beep"
- ELSE
- CLS
- PRINT '" Assign waveforms to"
- INPUT" how many voices "vcesx%
- FOR count% = 1 TO vcesx%
- PRINT'" voice ";count%;" is which voice number"
- INPUT vcen%
- PRINT'" voice ";vcen%;
- IF insts$(vcen%,0) <> "" THEN PRINT " (";insts$(vcen%,0);")"
- PRINT" is assigned which waveform?"
- INPUT waveform$
- waveforms$(vcen%) = waveform$
- NEXT
- ENDIF
- :
- ENDPROC
- :
- REM************************************************
- :
- DEF PROCseriesenvelopes
- :
- REM envelopes%() and glissandos%() are always input at the same time
- IF easiermenus$ = "n" THEN PROCwindow(20,69,73,45) ELSE PROCwindow(20,69,73,42)
- IF gradations$ = "y" THEN PRINT'" Input gradations as if envelopes with 4 phases "
- PRINT'" How many envelopes/glissandos "
- INPUT'" (for 1 press 0) "numenvelopes%
- IF numenvelopes% = 0 THEN numenvelopes% = 1
- :
- IF numenvelopes% > 1 THEN
- PRINT '" are the envelopes all the same? "
- PRINT '" (Y/0/1, N/2) "
- CASE GET$ OF
- WHEN "N","n","2" : sameenvelopes$ = "n"
- OTHERWISE sameenvelopes$ = "y"
- ENDCASE
- ELSE
- sameenvelopes$ = "y"
- ENDIF
- :
- FOR count% = 0 TO (numenvelopes%-1)
- IF sameenvelopes$ = "n" OR (sameenvelopes$ ="y" AND count% = 0) THEN
- IF numphases% <> 4 THEN
- PRINT'" Envelope ";count%+1;" has how many phases? "
- INPUT'" (for 1 press 0, for 0 press 9) "numphases%
- IF numphases% = 0 THEN numphases% = 1
- IF numphases% = 9 THEN numphases% = 0
- ENDIF
- :
- CASE numphases% OF
- :
- WHEN 0 :
- INPUT'" amplitude is "amp$ : PROCconvertdynamics : amp1% = amp%
- amp2% = 9
- gliss1% = 50
- ph2% = 0 : ph1% = 0 : amp4% = 0 : amp3% = 0 : gliss3% = 10 : gliss2% = 50
- :
- WHEN 4 :
- INPUT'" amplitude is (0 = previous) "amp$
- IF amp$ = "" THEN amp$ = prevamp$
- COLOUR 3 : PRINT'" ";amp$
- wait$ = INKEY$(20) : COLOUR 0
- PROCconvertdynamics : amp1% = amp%
- INPUT'" gradation is (select from 1-9) "gradation%
- IF gradation% = 0 THEN gradation% = prevgradation%
- COLOUR 3 : PRINT' gradation%
- wait$ = INKEY$(20) : COLOUR 0
- amp2% = 9
- amp3% = gradation%
- gliss1% = 50
- ph2% = 0 : ph1% = 0 : amp4% = 0 : gliss3% = 10 : gliss2% = 50
- prevamp$ = amp$ : prevgradation% = gradation%
- :
- WHEN 1 :
- INPUT'" starting amplitude is "amp$ : PROCconvertdynamics : amp1% = amp%
- INPUT'" destination amplitude is "amp$ : PROCconvertdynamics : amp2% = amp%
- INPUT'" glissando is (in 1/8 tones, max 48,-48) "gliss%
- gliss1% = 50-gliss%
- ph2% = 0 : ph1% = 0 : amp4% = 0 : amp3% = 0 : gliss3% = 10 : gliss2% = 50
- :
- WHEN 2 :
- INPUT'" starting amplitude is "amp$ : PROCconvertdynamics : amp1% = amp%
- PRINT'" phase 1 ends after what percentage "
- INPUT'" of the note's duration "ph1%
- INPUT'" phase 1's destination amplitude is "amp$ : PROCconvertdynamics : amp2% = amp%
- INPUT'" phase 1's glissando is (in 1/8 tones, max 48,-48) "gliss%
- gliss1% = 50-gliss%
- INPUT'" phase 2's destination amplitude is "amp$ : PROCconvertdynamics : amp3% = amp%
- INPUT'" phase 2's glissando is (in 1/8 tones, max 48,-48) "gliss%
- gliss2% = 50-gliss%
- ph2% = 0 : amp4% = 0 : gliss3% = 10
- :
- WHEN 3 :
- INPUT'" starting amplitude is "amp$ : PROCconvertdynamics : amp1% = amp%
- PRINT'" phase 1 ends after what percentage "
- INPUT'" of the note's duration "ph1%
- INPUT'" phase 1's destination amplitude is "amp$ : PROCconvertdynamics : amp2% = amp%
- INPUT'" phase 1's glissando is (in 1/8 tones, max 48,-48) "gliss%
- gliss1% = 50-gliss%
- PRINT'" phase 2 ends after what percentage "
- INPUT'" of the note's duration "ph2%
- INPUT'" phase 2's destination amplitude is "amp$ : PROCconvertdynamics : amp3% = amp%
- INPUT'" phase 2's glissando is (in 1/8 tones, max 48,-48) "gliss%
- gliss2% = 50-gliss%
- INPUT'" phase 3's destination amplitude is "amp$ : PROCconvertdynamics : amp4% = amp%
- REPEAT
- INPUT'" phase 3's glissando is (in 1/8 tones, max 10,-10) "gliss%
- gliss3% = 10-gliss%
- IF gliss3% > 20 THEN VDU7
- IF gliss3% < 0 THEN VDU7
- UNTIL gliss3% < 21 AND gliss3% >= 0
- :
- ENDCASE
- :
- envelopes%(count%) = (ph2%*10^5)+(ph1%*10^3)+(amp4%*10^2)+(amp3%*10)+amp2%
- amplitudes%(count%) = amp1%
- glissandos%(count%) = (gliss3%*10^4)+(gliss2%*10^2)+gliss1%
- :
- :
- ENDIF
- NEXT
- :
- IF sameenvelopes$ = "y" THEN
- FOR count% = 1 TO (numenvelopes%-1)
- envelopes%(count%) = (ph2%*10^5)+(ph1%*10^3)+(amp4%*10^2)+(amp3%*10)+amp2%
- amplitudes%(count%) = amp1%
- glissandos%(count%) = (gliss3%*10^4)+(gliss2%*10^2)+gliss1%
- NEXT
- ENDIF
- :
- gradations$ = "n"
- REM function can feed envelopes similarly into envelopes%()
- :
- PROCinsertenvelopes
- :
- ENDPROC
- :
- REM*******************************************
- :
- DEF PROCconvertdynamics
- CASE amp$ OF
- WHEN "0" : amp% = 0
- WHEN "ppp" : amp% = 1
- WHEN "pp" : amp% = 2
- WHEN "p" : amp% = 3
- WHEN "mp" : amp% = 4
- WHEN "mf" : amp% = 5
- WHEN "f" : amp% = 6
- WHEN "ff" : amp% = 7
- WHEN "fff" : amp% = 8
- ENDCASE
- ENDPROC
- :
- REM*******************************************
- :
- DEF PROCinsertenvelopes
- :
- CLS
- repeatposit$ = "n"
- IF seequery$ = "y" THEN
- PRINT '" Do you want to read these envelopes into the array?"
- CASE GET$ OF
- WHEN "N","n" : PROCdisplay : REM envelopes%() stays intact
- OTHERWISE
- ENDCASE
- ENDIF : REM seequery$
- :
- IF screenvoices$ = "n" THEN
- INPUT' " Which voice (0 = top)"voice%
- IF voice% = 0 THEN PROCpressenter
- ELSE
- PRINT'" Which screen voice "
- CASE GET$ OF
- WHEN "1" : voice% = 1
- WHEN "2" : voice% = 2
- WHEN "3" : voice% = 3
- OTHERWISE PROCpressenter
- ENDCASE
- ENDIF
- IF screenvoices$ = "y" AND voice% > 0 THEN voice% = displayvoices%(startv%+voice%-1)
- voice% -= 1
- IF voice% >= 0 THEN samevoice% = voice%
- IF voice% = -1 THEN voice% = samevoice%
- :
- IF quickcopy$ = "y" THEN
- INPUT ' " starting at note number (0 counts as 1) "along%
- IF along% = 0 THEN along% = 1
- along%-=1
- bars% = array%(holdstartcell%(voice%)+along%,0,voice%)DIV10^6
- beats% = (array%(holdstartcell%(voice%)+along%,0,voice%)MOD10^6)DIV10^3
- holdbar% = bars%
- holdbeat% = beats%
- PROCalterbeats
- startat% = (bars%*(10^3))+beats%
- :
- ELSE
- :
- INPUT'" Starting at bar number "bars%
- IF bars% = 0 THEN
- bars% = holdbar% : beats% = holdbeat% : repeatposit$ = "y"
- ENDIF
- holdbar% = bars%
- IF repeatposit$ = "y" THEN
- PRINT'" bar ";bars%;" beat ";beats%;"?"
- PRINT" (for OK press 0, if not OK press X)"
- CASE GET$ OF
- WHEN"X","x" : PROCinsertpitches
- OTHERWISE
- ENDCASE
- ELSE
- INPUT " beat "beats%
- holdbeat% = beats%
- ENDIF
- PROCalterbeats
- startat% = (bars%*(10^3))+beats%
- :
- ENDIF
- :
- PROCsearch(startat%)
- shunt$ = "N"
- :
- FOR count% = startcell% TO (startcell%+(numenvelopes%-1))
- PROCcellfill(count%,voice%,999,999,999,amplitudes%(count%-startcell%),envelopes%(count%-startcell%),999,glissandos%(count%-startcell%),99)
- NEXT
- :
- PROCdisplay
- :
- ENDPROC
- :
- REM**********************************************
- :
- DEF PROCseriesinflections
- :
- IF easiermenus$ = "n" PROCwindow(20,69,88,45) ELSE PROCwindow(20,69,88,42)
- PRINT'" semitone = 100 cents quartertone = 50 cents eigthtone = 25 cents"
- PRINT " sixteenthtone = 12 cents sixthtone = 33 cents"
- PRINT'" harmonic 3 = perfect 5th + 2 cents"
- PRINT " harmonic 5 = major 3rd eigthtone flat + 11 cents "
- PRINT " harmonic 7 = minor 7th eightone flat -6 cents"
- PRINT " harmonic 9 = major 2nd + 4 cents"
- PRINT " harmonic 11 = perfect 4th quartertone sharp + 1 cent"
- PRINT " harmonic 13 = major 6th quartertone flat - 9 cents"
- PRINT " harmonic 15 = major 7th - 12 cents"
- INPUT'" How many inflections "numinflections%
- FOR count% = 0 TO (numinflections%-1)
- PRINT'" inflection ";count%+1;" is (in cents:"
- INPUT'" 1,-1 etc; max 49,-49) "inf%
- inf% = 50+inf%
- inflections%(count%) = inf%
- NEXT
- :
- REM function can feed similarly into inflections%()
- :
- PROCinsertinflections
- :
- ENDPROC
- :
- REM**********************************************
- :
- DEF PROCinsertinflections
- :
- CLS
- repeatposit$ = "n"
- IF seequery$ = "y" THEN
- PRINT'" Do you want to read these inflections into the array?"
- CASE GET$ OF
- WHEN "N","n" : PROCdisplay : REM inflections%() remains intact
- OTHERWISE
- ENDCASE
- ENDIF : REM seequery$
- IF screenvoices$ = "n" THEN
- INPUT' " Which voice (0 = top) "voice%
- IF voice% = 0 THEN PROCpressenter
- ELSE
- PRINT'" Which screen voice "
- CASE GET$ OF
- WHEN "1" : voice% = 1
- WHEN "2" : voice% = 2
- WHEN "3" : voice% = 3
- OTHERWISE PROCpressenter
- ENDCASE
- ENDIF
- IF screenvoices$ = "y" AND voice% > 0 THEN voice% = displayvoices%(startv%+voice%-1)
- voice% -= 1
- IF voice% >= 0 THEN samevoice% = voice%
- IF voice% = -1 THEN voice% = samevoice%
- :
- IF quickcopy$ = "y" THEN
- INPUT ' " starting at note number (0 counts as 1) "along%
- IF along% = 0 THEN along% = 1
- along%-=1
- bars% = array%(holdstartcell%(voice%)+along%,0,voice%)DIV10^6
- beats% = (array%(holdstartcell%(voice%)+along%,0,voice%)MOD10^6)DIV10^3
- holdbar% = bars%
- holdbeat% = beats%
- PROCalterbeats
- startat% = (bars%*(10^3))+beats%
- :
- ELSE
- :
- INPUT'" Starting at bar number "bars%
- IF bars% = 0 THEN
- bars% = holdbar% : beats% = holdbeat% : repeatposit$ = "y"
- ENDIF
- holdbar% = bars%
- IF repeatposit$ = "y" THEN
- PRINT'" bar ";bars%;" beat ";beats%;"?"
- PRINT" (for OK press 0, if not OK press X)"
- CASE GET$ OF
- WHEN"X","x" : PROCinsertpitches
- OTHERWISE
- ENDCASE
- ELSE
- INPUT " beat "beats%
- holdbeat% = beats%
- ENDIF
- PROCalterbeats
- startat% = (bars%*(10^3))+beats%
- :
- ENDIF
- :
- PROCsearch(startat%)
- shunt$ = "N"
- :
- FOR count% = startcell% TO (startcell%+(numinflections%-1))
- PROCcellfill(count%,voice%,999,999,999,9,999,999,99,inflections%(count%-startcell%))
- NEXT
- PROCdisplay
- ENDPROC
- :
- REM****************************************************
- :
- DEF PROCenv
- :
- temp = tempi%(brrr%)
- IF waveload$ = "done" THEN temp = temp*1.23065
- converter = 1200/(temp*960)
- dur1 = dur%/converter
- dur2 = dur1*10
- dur3 = dur2 MOD 10
- IF dur3 >= 5 THEN dur% = dur1+1 ELSE dur% = dur1
- :
- dyn1% = dyn% + 128
- :
- number% = array%(cell%(voicenum%),2,voicenum%)DIV10^5
- IF number% = 0 THEN numphases% = 1
- IF number% > 0 AND number% < 100 THEN numphases% = 2
- IF number% > 99 THEN numphases% = 3
- :
- CASE nvoices% OF
- WHEN 1 : st% = 1
- OTHERWISE st% = 2
- ENDCASE
- :
- CASE numphases% OF
- :
- WHEN 1 :
- :
- gliss1% = (array%(cell%(voicenum%),1,voicenum%)DIV10^4)MOD10^2
- gliss1% = 50 - gliss1%
- gliss1% = gliss1% * 85.5
- pitchinc = gliss1%/dur%
- :
- amp2% = (array%(cell%(voicenum%),2,voicenum%)DIV10^2)MOD10
- dyn2% = 384 + (16*amp2%)
- IF dyn2% = 512 THEN dyn2% = 511
- dynspan% = dyn2% - dyn1%
- dyninc = dynspan%/dur%
- :
- FOR loop% = 10 TO dur% STEP (dur%/32)*st%
- loud% = dyninc*loop%
- high% = pitchinc*loop%
- SOUND count%, dyn1%+loud%, pitch%+high%, 0, after%+loop%
- NEXT
- :
- WHEN 2 :
- ph1% = number% MOD 10^2
- point1% = dur%*ph1%/100
- :
- REM first phase
- gliss1% = (array%(cell%(voicenum%),1,voicenum%)DIV10^4)MOD10^2
- gliss1% = 50 - gliss1%
- gliss1% = gliss1% * 85.5
- pitchinc = gliss1%/point1%
- :
- amp2% = (array%(cell%(voicenum%),2,voicenum%)DIV10^2)MOD10
- dyn2% = 384 + (16*amp2%)
- IF dyn2% = 512 THEN dyn2% = 511
- dynspan% = dyn2% - dyn1%
- dyninc = dynspan%/point1%
- :
- FOR loop% = 10 TO point1%-10 STEP ((point1%)/32)*st%
- loud% = dyninc*loop%
- high% = pitchinc*loop%
- SOUND count%, dyn1%+loud%, pitch%+high%, 0, after%+loop%
- NEXT
- :
- REM second phase
- gliss2% = (array%(cell%(voicenum%),1,voicenum%)DIV10^6)MOD10^2
- gliss2% = 50 - gliss2%
- gliss2% = gliss2% * 85.5
- pitchinc = gliss2%/(dur%-point1%)
- :
- amp3% = (array%(cell%(voicenum%),2,voicenum%)DIV10^3)MOD10
- dyn3% = 384 + (16*amp3%)
- IF dyn3% = 512 THEN dyn2% = 511
- dynspan% = dyn3% - dyn2%
- dyninc = dynspan%/(dur%-point1%)
- :
- FOR loop% = 0 TO dur%-point1% STEP ((dur%-point1%)/32)*st%
- loud% = dyninc*loop%
- high% = pitchinc*loop%
- SOUND count%, dyn2%+loud%, pitch%+gliss1%+high%, 0, after%+point1%+loop%
- NEXT
- :
- WHEN 3 :
- ph1% = number% MOD 10^2
- point1% = dur%*ph1%/100
- ph2% = number% DIV 10^2
- point2% = dur%*ph2%/100
- :
- REM first phase
- gliss1% = (array%(cell%(voicenum%),1,voicenum%)DIV10^4)MOD10^2
- gliss1% = 50 - gliss1%
- gliss1% = gliss1% * 85.5
- pitchinc = gliss1%/point1%
- :
- amp2% = (array%(cell%(voicenum%),2,voicenum%)DIV10^2)MOD10
- dyn2% = 384 + (16*amp2%)
- IF dyn2% = 512 THEN dyn2% = 511
- dynspan% = dyn2% - dyn1%
- dyninc = dynspan%/point1%
- :
- FOR loop% = 10 TO point1%-10 STEP ((point1%)/32)*st%
- loud% = dyninc*loop%
- high% = pitchinc*loop%
- SOUND count%, dyn1%+loud%, pitch%+high%, 0, after%+loop%
- NEXT
- :
- REM second phase
- gliss2% = (array%(cell%(voicenum%),1,voicenum%)DIV10^6)MOD10^2
- gliss2% = 50 - gliss2%
- gliss2% = gliss2% * 85.5
- pitchinc = gliss2%/(point2%-point1%)
- :
- amp3% = (array%(cell%(voicenum%),2,voicenum%)DIV10^3)MOD10
- dyn3% = 384 + (16*amp3%)
- IF dyn3% = 512 THEN dyn3% = 511
- dynspan% = dyn3% - dyn2%
- dyninc = dynspan%/(point2%-point1%)
- :
- FOR loop% = 0 TO point2%-point1%-10 STEP ((point2%-point1%)/32)*st%
- loud% = dyninc*loop%
- high% = pitchinc*loop%
- SOUND count%, dyn2%+loud%, pitch%+gliss1%+high%, 0, after%+point1%+loop%
- NEXT
- :
- REM third phase
- gliss3% = (array%(cell%(voicenum%),1,voicenum%)DIV10^8)
- gliss3% = 10 - gliss3%
- gliss3% = gliss3% * 85.5
- pitchinc = gliss3%/(dur%-point2%)
- :
- amp4% = (array%(cell%(voicenum%),2,voicenum%)DIV10^4)MOD10
- dyn4% = 384 + (16*amp4%)
- IF dyn4% = 512 THEN dyn4% = 511
- dynspan% = dyn4% - dyn3%
- dyninc = dynspan%/(dur%-point2%)
- :
- FOR loop% = 0 TO dur%-point2% STEP ((dur%-point2%)/32)*st%
- loud% = dyninc*loop%
- high% = pitchinc*loop%
- SOUND count%, dyn3%+loud%, pitch%+gliss1%+gliss2%+high%, 0, after%+point2%+loop%
- NEXT
- :
- ENDCASE
- :
- ENDPROC
- :
- REM******************************************************
- :
- DEF PROCquit
- :
- CLS
- PRINT''''" Do you want to SAVE"
- PRINT" before quitting?"
- CASE GET$ OF
- WHEN "N","n" :
- REM this line and next two 'deleted' for now - IF wavefilingsystem$ = "loaded" THEN
- REM *RMKill WFS
- REM ENDIF
- *NoDir
- QUIT
- OTHERWISE
- quitnow$ = "y"
- PROCsave
- ENDCASE
- ENDPROC
- :
- REM******************************************************
- :
- DEF PROCsave
- :
- firstnaming$ = "n"
- CLS
- IF filename$ = "" THEN
- INPUT'" filename "filename$
- firstnaming$ = "y"
- DIM lastfilename$(9)
- housekeepingdimmed$ = "y"
- PROChousekeeping
- ENDIF
- IF firstnaming$ = "n" THEN
- PRINT'" as '";filename$;"'?"
- CASE GET$ OF
- WHEN "N","n" :
- INPUT'" filename "filename$
- OTHERWISE
- ENDCASE
- ENDIF
- :
- *Dir SDFS::RISCOSpi.$.CAC.Files
- :
- channel = OPENOUT filename$
- PRINT#channel, manynotes%
- PRINT#channel, numparts%
- PRINT#channel, nobars%
- PRINT#channel, startv%
- PRINT#channel, startv1%
- PRINT#channel, numbars%
- PRINT#channel, startbar%
- PRINT#channel, numvoices%
- PRINT#channel, factor%
- PRINT#channel, beatfactor%
- PRINT#channel, beams%
- PRINT#channel, longbeatsupper%
- PRINT#channel, longbeatslower%
- PRINT#channel, tempo%
- PRINT#channel, MM%
- PRINT#channel, notehead$
- PRINT#channel, longscore$
- PRINT#channel, barlines$
- PRINT#channel, staves$
- PRINT#channel, beats$
- PRINT#channel, amplitudes$
- PRINT#channel, names$
- PRINT#channel, accidentals$
- PRINT#channel, stems$
- PRINT#channel, xoption$
- PRINT#channel, durations$
- PRINT#channel, envelopes$
- PRINT#channel, glissandos$
- PRINT#channel, numwaves%
- PRINT#channel, manywaves%
- PRINT#channel, barnosoften%
- FOR c% = 0 TO (numparts%-1)
- PRINT#channel, numusedcells%(c%)
- NEXT
- FOR e% = 0 TO (numparts%-1)
- FOR d% = 0 TO 2
- FOR c% = 0 TO numusedcells%(e%)
- PRINT#channel, array%(c%,d%,e%)
- NEXT
- NEXT
- NEXT
- FOR c% = 0 TO numparts%
- FOR d% = 0 TO 2
- PRINT#channel, insts$(c%,d%)
- NEXT
- NEXT
- FOR c% = 0 TO nobars%
- FOR d% = 0 TO 3
- FOR e% = 0 TO (numparts%-1)
- PRINT#channel, disarray%(c%,d%,e%)
- NEXT
- NEXT
- NEXT
- FOR c% = 0 TO numparts%
- PRINT#channel, longbeamposn%(c%)
- NEXT
- FOR c% = 0 TO numparts%
- PRINT#channel, shortbeamposn%(c%)
- NEXT
- FOR c% = 0 TO numparts%
- PRINT#channel, shortamppos%(c%)
- NEXT
- FOR c% = 0 TO numparts%
- PRINT#channel, longamppos%(c%)
- NEXT
- FOR c% = 0 TO (numparts%-1)
- PRINT#channel, longstemdir$(c%)
- NEXT
- FOR c% = 0 TO (numparts%-1)
- PRINT#channel, shortstemdir$(c%)
- NEXT
- FOR c% = 0 TO numparts%
- PRINT#channel, waveforms$(c%)
- NEXT
- FOR c% = 0 TO numvoices%
- PRINT#channel, displayvoices%(c%)
- NEXT
- FOR c% = 0 TO 19
- PRINT#channel, wforms$(c%)
- NEXT
- FOR c% = 0 TO 8
- FOR d% = 0 TO 9
- PRINT#channel, lvdata%(c%,d%)
- NEXT
- NEXT
- FOR a% = 0 TO 47
- PRINT#channel, pitchset%(a%)
- NEXT
- FOR a% = 0 TO 47
- PRINT#channel, durset%(a%)
- NEXT
- FOR a% = 0 TO 47
- PRINT#channel, ampset%(a%)
- NEXT
- FOR a% = 0 TO 47
- PRINT#channel, glissset%(a%)
- NEXT
- FOR a% = 0 TO 47
- PRINT#channel, envset%(a%)
- NEXT
- FOR a% = 0 TO nobars%
- PRINT#channel, tempi%(a%)
- NEXT
- FOR a% = 0 TO nobars%
- FOR b% = 0 TO 1
- PRINT#channel, remarks$(a%,b%)
- NEXT
- NEXT
- :
- CLOSE#channel
- *NoDir
- :
- goproc$ = "y"
- FOR count% = 1 TO 9
- IF lastfilename$(count%) = filename$ THEN
- goproc$ = "n" : theone% = count%
- ENDIF
- NEXT
- IF goproc$ = "n" THEN
- IF theone% > 1 THEN
- PROCspecialshunt : PROCfornexttime
- ENDIF
- ENDIF
- IF goproc$ = "y" THEN
- PROCshuntlastfilename : PROCfornexttime
- ENDIF
- :
- IF quitnow$ = "y" THEN
- *NoDir
- QUIT
- ELSE
- PROCdisplay
- ENDIF
- :
- ENDPROC
- :
- REM******************************************
- :
- DEF PROCloadfile
- :
- housekeepingdimmed$ = "n"
- PROChousekeeping
- PRINT'" The most recent files saved were "
- FOR count% = 1 TO 9
- PRINT'count%;". ";lastfilename$(count%)
- NEXT
- PRINT'" To open one press its number, for another press 0 "
- CASE GET$ OF
- WHEN "1" : filename$ = lastfilename$(1)
- WHEN "2" : filename$ = lastfilename$(2)
- WHEN "3" : filename$ = lastfilename$(3)
- WHEN "4" : filename$ = lastfilename$(4)
- WHEN "5" : filename$ = lastfilename$(5)
- WHEN "6" : filename$ = lastfilename$(6)
- WHEN "7" : filename$ = lastfilename$(7)
- WHEN "8" : filename$ = lastfilename$(8)
- WHEN "9" : filename$ = lastfilename$(9)
- OTHERWISE
- INPUT'" the one you want is "filename$
- ENDCASE
- :
- *Dir SDFS::RISCOSpi.$.CAC.Files
- channel = OPENIN filename$
- REPEAT
- INPUT#channel, manynotes%
- INPUT#channel, numparts%
- INPUT#channel, nobars%
- instsdimmed$ = "n"
- PROCarraysetup
- INPUT#channel, startv%
- INPUT#channel, startv1%
- INPUT#channel, numbars%
- INPUT#channel, startbar%
- INPUT#channel, numvoices%
- INPUT#channel, factor%
- INPUT#channel, beatfactor%
- INPUT#channel, beams%
- INPUT#channel, longbeatsupper%
- INPUT#channel, longbeatslower%
- INPUT#channel, tempo%
- INPUT#channel, MM%
- INPUT#channel, notehead$
- INPUT#channel, longscore$
- INPUT#channel, barlines$
- INPUT#channel, staves$
- INPUT#channel, beats$
- INPUT#channel, amplitudes$
- INPUT#channel, names$
- INPUT#channel, accidentals$
- INPUT#channel, stems$
- INPUT#channel, xoption$
- INPUT#channel, durations$
- INPUT#channel, envelopes$
- INPUT#channel, glissandos$
- INPUT#channel, numwaves%
- INPUT#channel, manywaves%
- INPUT#channel, barnosoften%
- FOR c% = 0 TO (numparts%-1)
- INPUT#channel, numusedcells%(c%)
- NEXT
- FOR e% = 0 TO (numparts%-1)
- FOR d% = 0 TO 2
- FOR c% = 0 TO numusedcells%(e%)
- INPUT#channel, array%(c%,d%,e%)
- NEXT
- NEXT
- NEXT
- FOR c% = 0 TO numparts%
- FOR d% = 0 TO 2
- INPUT#channel, insts$(c%,d%)
- NEXT
- NEXT
- FOR c% = 0 TO nobars%
- FOR d% = 0 TO 3
- FOR e% = 0 TO (numparts%-1)
- INPUT#channel, disarray%(c%,d%,e%)
- NEXT
- NEXT
- NEXT
- FOR c% = 0 TO numparts%
- INPUT#channel, longbeamposn%(c%)
- NEXT
- FOR c% = 0 TO numparts%
- INPUT#channel, shortbeamposn%(c%)
- NEXT
- FOR c% = 0 TO numparts%
- INPUT#channel, shortamppos%(c%)
- NEXT
- FOR c% = 0 TO numparts%
- INPUT#channel, longamppos%(c%)
- NEXT
- FOR c% = 0 TO (numparts%-1)
- INPUT#channel, longstemdir$(c%)
- NEXT
- FOR c% = 0 TO (numparts%-1)
- INPUT#channel, shortstemdir$(c%)
- NEXT
- FOR c% = 0 TO numparts%
- INPUT#channel, waveforms$(c%)
- NEXT
- FOR c% = 0 TO numvoices%
- INPUT#channel, displayvoices%(c%)
- NEXT
- FOR c% = 0 TO 19
- INPUT#channel, wforms$(c%)
- NEXT
- FOR c% = 0 TO 8
- FOR d% = 0 TO 9
- INPUT#channel, lvdata%(c%,d%)
- NEXT
- NEXT
- FOR a% = 0 TO 47
- INPUT#channel, pitchset%(a%)
- NEXT
- FOR a% = 0 TO 47
- INPUT#channel, durset%(a%)
- NEXT
- FOR a% = 0 TO 47
- INPUT#channel, ampset%(a%)
- NEXT
- FOR a% = 0 TO 47
- INPUT#channel, glissset%(a%)
- NEXT
- FOR a% = 0 TO 47
- INPUT#channel, envset%(a%)
- NEXT
- FOR a% = 0 TO nobars%
- INPUT#channel, tempi%(a%)
- tempi%(0) = tempi%(1)
- NEXT
- FOR a% = 0 TO nobars%
- FOR b% = 0 TO 1
- INPUT#channel, remarks$(a%,b%)
- NEXT
- NEXT
- :
- holdnum% = numvoices% : holdstart% = startv%
- FOR count% = 1 TO numvoices% : holddisplay%(count%) = displayvoices%(count%) : NEXT
- :
- UNTIL EOF#channel
- CLOSE#channel
- *NoDir
- :
- alterbeatsat% = (960/beatfactor%)/8
- :
- PROCdisplay
- :
- ENDPROC
- :
- REM******************************************************
- :
- DEF PROCplaysubmenu
- :
- IF easiermenus$ = "n" THEN
- PROCwindow(20,71,60,54)
- COLOUR 63
- PRINT'" Load waveforms W"
- COLOUR 0
- PRINT " Assign waveforms to voices A"
- PRINT " Set tempo T"
- PRINT " Set l.v. L"
- PRINT " Beats input B"
- PRINT " Memory setup M"
- PRINT " Display pitches in colours C"
- PRINT " Display options D"
- PRINT " Remarks R"
- PRINT " Rename staves S"
- PRINT " Change a stave's clef K"
- PRINT " Quickplay options Q"
- PRINT " Set stereo positions P"
- PRINT " Set key response speeds E"
- PRINT " Tutorial U"
- PRINT " Re-set parameter defaults V"
- ELSE
- PROCwindow(20,69,60,37)
- COLOUR 63
- PRINT'" Load waveforms W"
- COLOUR 0
- PRINT '" Assign waveforms to voices A"
- PRINT '" Set tempo T"
- PRINT '" Set l.v. L"
- PRINT '" Beats input B"
- PRINT '" Memory setup M"
- PRINT '" Display pitches in colours C"
- PRINT '" Display options D"
- PRINT '" Remarks R"
- PRINT '" Rename staves S"
- PRINT '" Change a stave's clef K"
- PRINT '" Quickplay options Q"
- PRINT '" Set stereo positions P"
- PRINT '" Set key response speeds E"
- PRINT '" Tutorial U"
- PRINT '" Re-set parameter defaults V"
- ENDIF
- CASE GET$ OF
- WHEN "v" : CLS
- PRINT'" Amplitude A"
- CASE GET$ OF
- WHEN "a" :
- PRINT'" Re-set default amplitude"
- INPUT " in a batch between which voice "firstvoice%
- INPUT'" and which voice "secondvoice%
- INPUT'" And set it at which amplitude "value$
- CASE value$ OF
- WHEN "fff" : value% = 8
- WHEN "ff" : value% = 7
- WHEN "f" : value% = 6
- WHEN "mf" : value% = 5
- WHEN "mp" : value% = 4
- WHEN "p" : value% = 3
- WHEN "pp" : value% = 2
- WHEN "ppp" : value% = 1
- WHEN "0" : value% = 0
- ENDCASE
- FOR count% = (firstvoice%-1) TO (secondvoice%-1)
- ampset%(count%) = value%
- NEXT
- ENDCASE
- PROCdisplay
- :
- WHEN "U","u" : PROCtutorial
- :
- WHEN "E","e" : CLS
- PRINT '" To set response time for downward "
- PRINT " copying from top stave press D "
- PRINT '" To set response time for "
- PRINT " move left/right press M "
- PRINT '" To set response time for "
- PRINT " move up/down press U "
- PRINT '" To set response time for pause "
- PRINT " after first digit input press F "
- PRINT '" To set response time for pause "
- PRINT " after second digit input press S "
- CASE GET$ OF
- WHEN "D","d" :
- CLS
- PRINT'" delay how many hundredths of a second "
- PRINT " (default is 50,";
- PRINT " currently set at ";downwardsspeed%;")"
- INPUT ' downwardsspeed%
- WHEN "M","m" :
- PRINT'" delay how many hundredths of a second "
- PRINT " (default is 25, currently set at ";horizscroll%;")"
- INPUT horizscroll%
- WHEN "U","u" :
- PRINT'" delay how many hundredths of a second "
- PRINT " (default is 25, currently set at ";vertscroll%;")"
- INPUT vertscroll%
- WHEN "F","f" :
- PRINT'" pause for how many hundredths "
- PRINT " of a second (currently ";waitafterfirst%;")"
- INPUT waitafterfirst%
- waitaftersecond% = waitafterfirst% : REM stops waiting unnecessarily for a 3rd digit
- WHEN "S","s" :
- PRINT'" pause for how many hundredths "
- PRINT " of a second (currently ";waitaftersecond%;")"
- INPUT waitaftersecond%
- ENDCASE
- PROCdisplay
- :
- WHEN "A","a" :
- PROCwindow(20,72,83,25)
- VDU 14
- PRINT'" Current assignations are "
- PRINT'" (press Ctrl-Shift to scroll down) "
- PRINT " "
- FOR count% = 1 TO numparts%
- IF waveforms$(count%) <> "" THEN
- PRINT'" voice ";count%;
- IF insts$(count%,0)<> "" THEN PRINT " (";insts$(count%,0);")";
- PRINT " - ";waveforms$(count%)
- ENDIF
- NEXT
- VDU 15
- PRINT''" Do you want to "
- PRINT' " Keep these K "
- PRINT' " Reassign R "
- PRINT' " Use WaveSynth-Beep defaults W "
- PRINT' " Randomly assign sustaining instruments, "
- PRINT " dry instruments or drums S/D/M "
- PRINT' " Assign in groups G "
- :
- CASE GET$ OF
- WHEN "R","r" : defaultvoices$ = "n" : PROCassignvoices : PROCdisplay
- WHEN "W","w" : defaultvoices$ = "y" : PROCassignvoices : PROCdisplay
- WHEN "K","k" : defaultvoices$ = "n" : PROCdisplay
- WHEN "S","s" : defaultvoices$ = "n" : type$ = "sustaining" : PROCrandomassign : PROCdisplay
- WHEN "M","m" : defaultvoices$ = "n" : type$ = "drums" : PROCrandomassign : PROCdisplay
- WHEN "D","d" : defaultvoices$ = "n" : PROCrandomdry : PROCdisplay
- WHEN "G","g" : defaultvoices$ = "n" : PROCgroupassign : PROCdisplay
- ENDCASE
- WHEN "T","t" : PROCtempo
- WHEN "L","l" : PROClv
- WHEN "W","w" : PROCloadwaveforms
- WHEN "B","b" :
- CLS : PRINT' " Typing numbers up to ";((960/beatfactor%)/8)-1
- PRINT " should be read as macro-beats "
- PRINT" or micro-beats? (+/-) "
- CASE GET$ OF
- WHEN "+","=" : alterbeatsat% = (960/beatfactor%)/8
- OTHERWISE
- alterbeatsat% = 0
- ENDCASE
- :
- PROCdisplay
- WHEN "M","m" :
- CLS : PRINT '" This file was set up as follows:"
- PRINT" Number of bars - ";nobars%
- PRINT" Notes per bar in busiest - ";manynotes%/nobars%
- PRINT" Number of voices - ";numparts%
- PRINT'" (Press a key to continue)"
- CASE GET$ OF
- WHEN "C","c" :
- OTHERWISE
- ENDCASE
- PROCdisplay
- WHEN "C","c" :
- CLS : PRINT'" Do you want any pitches displayed in "
- PRINT " in colours? "
- CASE GET$ OF
- WHEN "Y","y" :
- PRINT'" Re-define these, or use previous "
- PRINT " settings? (R/P)"
- CASE GET$ OF
- WHEN "R","r" :
- INPUT'" How many colours "numcols%
- FOR tt% = 1 TO numcols%
- PRINT'" Colour ";tt%;" has how many pitches "
- INPUT numredpitches%(tt%)
- FOR ttt% = 1 TO numredpitches%(tt%)
- PRINT' " Note name for pitch ";ttt%;" is ";
- COLOUR 3
- CASE GET$ OF
- WHEN "C","c" : note% = 0 : PRINT "C"
- WHEN "D","d" : note% = 1 : PRINT "D"
- WHEN "E","e" : note% = 2 : PRINT "E"
- WHEN "F","f" : note% = 3 : PRINT "F"
- WHEN "G","g" : note% = 4 : PRINT "G"
- WHEN "A","a" : note% = 5 : PRINT "A"
- WHEN "B","b" : note% = 6 : PRINT "B"
- ENDCASE
- COLOUR 0
- PRINT " accidental ";
- COLOUR 3
- CASE GET$ OF
- WHEN "1" : accid% = 1 : PRINT "flat"
- WHEN "2" : accid% = 2 : PRINT "3/8flat"
- WHEN "3" : accid% = 3 : PRINT "1/4flat"
- WHEN "4" : accid% = 4 : PRINT "1/8flat"
- WHEN "5" : accid% = 5 : PRINT "nat"
- WHEN "6" : accid% = 6 : PRINT "1/8shrp"
- WHEN "7" : accid% = 7 : PRINT "1/4shrp"
- WHEN "8" : accid% = 8 : PRINT "3/8shrp"
- WHEN "9" : accid% = 9 : PRINT "shrp"
- ENDCASE
- COLOUR 0
- PRINT " octave ";
- COLOUR 3
- CASE GET$ OF
- WHEN "0" : octave% = 0 : PRINT "0"
- WHEN "1" : octave% = 1 : PRINT "1"
- WHEN "2" : octave% = 2 : PRINT "2"
- WHEN "3" : octave% = 3 : PRINT "3"
- WHEN "4" : octave% = 4 : PRINT "4"
- WHEN "5" : octave% = 5 : PRINT "5"
- WHEN "6" : octave% = 6 : PRINT "6"
- WHEN "7" : octave% = 7 : PRINT "7"
- WHEN "8" : octave% = 8 : PRINT "8"
- ENDCASE
- COLOUR 0
- redpitches%(tt%,ttt%) = (note%*100)+(accid%*10)+octave%
- NEXT
- NEXT
- redpitches$ = "y"
- OTHERWISE
- redpitches$ = "n"
- FOR count% = 0 TO 9
- IF numredpitches%(count%) <> 0 THEN redpitches$ = "y"
- NEXT
- ENDCASE
- OTHERWISE redpitches$ = "n"
- ENDCASE
- PROCdisplay
- :
- WHEN "D","d" : PROCdisplayoptions : PROCdisplay
- WHEN "R","r" : PROCremarks : PROCdisplay
- WHEN "S","s" : PROCnamestaves : PROCdisplay
- WHEN "K","k" : PROCchangeclef : PROCdisplay
- WHEN "Q","q" :
- CLS
- PRINT '" Quickplay (by pressing P)"
- PRINT '" how many voices downwards"
- INPUT '" from top of screen "quickplay%
- PROCdisplay
- WHEN "P","p" :
- CLS
- PRINT' " (Voices are assigned to channels 1-8 "
- PRINT " according to the order in which "
- PRINT " they are typed into Play) "
- PRINT' " Set the 8 channels to stereo "
- PRINT " positions 12344567, keep mono default, "
- PRINT " set the 8 channels to random positions "
- PRINT " or define channels' stereo positions "
- PRINT " (S/M/R/D) "
- CASE GET$ OF
- WHEN "S","s" :
- STEREO 1, -127
- STEREO 2, -79
- STEREO 3, -47
- STEREO 4, -15
- STEREO 5, -15
- STEREO 6, +16
- STEREO 7, +48
- STEREO 8, +80
- WHEN "M","m" :
- STEREO 1, -15
- STEREO 2, -15
- STEREO 3, -15
- STEREO 4, -15
- STEREO 5, -15
- STEREO 6, -15
- STEREO 7, -15
- STEREO 8, -15
- WHEN "D","d" :
- CLS
- PRINT '" Define positions for how many "
- INPUT " channels "numchannels%
- FOR count% = 1 TO numchannels%
- PRINT' " Channel ";count%;" is set to which "
- INPUT " stereo position of the 7 available "position%
- CASE count% OF
- WHEN 1 :
- CASE position% OF
- WHEN 1 : STEREO 1, -127
- WHEN 2 : STEREO 1, -79
- WHEN 3 : STEREO 1, -47
- WHEN 4 : STEREO 1, -15
- WHEN 5 : STEREO 1, +16
- WHEN 6 : STEREO 1, +48
- WHEN 7 : STEREO 1, +80
- ENDCASE
- WHEN 2 :
- CASE position% OF
- WHEN 1 : STEREO 2, -127
- WHEN 2 : STEREO 2, -79
- WHEN 3 : STEREO 2, -47
- WHEN 4 : STEREO 2, -15
- WHEN 5 : STEREO 2, +16
- WHEN 6 : STEREO 2, +48
- WHEN 7 : STEREO 2, +80
- ENDCASE
- WHEN 3 :
- CASE position% OF
- WHEN 1 : STEREO 3, -127
- WHEN 2 : STEREO 3, -79
- WHEN 3 : STEREO 3, -47
- WHEN 4 : STEREO 3, -15
- WHEN 5 : STEREO 3, +16
- WHEN 6 : STEREO 3, +48
- WHEN 7 : STEREO 3, +80
- ENDCASE
- WHEN 4 :
- CASE position% OF
- WHEN 1 : STEREO 4, -127
- WHEN 2 : STEREO 4, -79
- WHEN 3 : STEREO 4, -47
- WHEN 4 : STEREO 4, -15
- WHEN 5 : STEREO 4, +16
- WHEN 6 : STEREO 4, +48
- WHEN 7 : STEREO 4, +80
- ENDCASE
- WHEN 5 :
- CASE position% OF
- WHEN 1 : STEREO 5, -127
- WHEN 2 : STEREO 5, -79
- WHEN 3 : STEREO 5, -47
- WHEN 4 : STEREO 5, -15
- WHEN 5 : STEREO 5, +16
- WHEN 6 : STEREO 5, +48
- WHEN 7 : STEREO 5, +80
- ENDCASE
- WHEN 6 :
- CASE position% OF
- WHEN 1 : STEREO 6, -127
- WHEN 2 : STEREO 6, -79
- WHEN 3 : STEREO 6, -47
- WHEN 4 : STEREO 6, -15
- WHEN 5 : STEREO 6, +16
- WHEN 6 : STEREO 6, +48
- WHEN 7 : STEREO 6, +80
- ENDCASE
- WHEN 7 :
- CASE position% OF
- WHEN 1 : STEREO 7, -127
- WHEN 2 : STEREO 7, -79
- WHEN 3 : STEREO 7, -47
- WHEN 4 : STEREO 7, -15
- WHEN 5 : STEREO 7, +16
- WHEN 6 : STEREO 7, +48
- WHEN 7 : STEREO 7, +80
- ENDCASE
- WHEN 8 :
- CASE position% OF
- WHEN 1 : STEREO 8, -127
- WHEN 2 : STEREO 8, -79
- WHEN 3 : STEREO 8, -47
- WHEN 4 : STEREO 8, -15
- WHEN 5 : STEREO 8, +16
- WHEN 6 : STEREO 8, +48
- WHEN 7 : STEREO 8, +80
- ENDCASE
- ENDCASE
- NEXT
- WHEN "R","r" :
- position% = RND(7)
- CASE position% OF
- WHEN 1 : STEREO 1, -127
- WHEN 2 : STEREO 1, -79
- WHEN 3 : STEREO 1, -47
- WHEN 4 : STEREO 1, -15
- WHEN 5 : STEREO 1, +16
- WHEN 6 : STEREO 1, +48
- WHEN 7 : STEREO 1, +80
- ENDCASE
- position% = RND(7)
- CASE position% OF
- WHEN 1 : STEREO 2, -127
- WHEN 2 : STEREO 2, -79
- WHEN 3 : STEREO 2, -47
- WHEN 4 : STEREO 2, -15
- WHEN 5 : STEREO 2, +16
- WHEN 6 : STEREO 2, +48
- WHEN 7 : STEREO 2, +80
- ENDCASE
- position% = RND(7)
- CASE position% OF
- WHEN 1 : STEREO 3, -127
- WHEN 2 : STEREO 3, -79
- WHEN 3 : STEREO 3, -47
- WHEN 4 : STEREO 3, -15
- WHEN 5 : STEREO 3, +16
- WHEN 6 : STEREO 3, +48
- WHEN 7 : STEREO 3, +80
- ENDCASE
- position% = RND(7)
- CASE position% OF
- WHEN 1 : STEREO 4, -127
- WHEN 2 : STEREO 4, -79
- WHEN 3 : STEREO 4, -47
- WHEN 4 : STEREO 4, -15
- WHEN 5 : STEREO 4, +16
- WHEN 6 : STEREO 4, +48
- WHEN 7 : STEREO 4, +80
- ENDCASE
- position% = RND(7)
- CASE position% OF
- WHEN 1 : STEREO 5, -127
- WHEN 2 : STEREO 5, -79
- WHEN 3 : STEREO 5, -47
- WHEN 4 : STEREO 5, -15
- WHEN 5 : STEREO 5, +16
- WHEN 6 : STEREO 5, +48
- WHEN 7 : STEREO 5, +80
- ENDCASE
- position% = RND(7)
- CASE position% OF
- WHEN 1 : STEREO 6, -127
- WHEN 2 : STEREO 6, -79
- WHEN 3 : STEREO 6, -47
- WHEN 4 : STEREO 6, -15
- WHEN 5 : STEREO 6, +16
- WHEN 6 : STEREO 6, +48
- WHEN 7 : STEREO 6, +80
- ENDCASE
- position% = RND(7)
- CASE position% OF
- WHEN 1 : STEREO 7, -127
- WHEN 2 : STEREO 7, -79
- WHEN 3 : STEREO 7, -47
- WHEN 4 : STEREO 7, -15
- WHEN 5 : STEREO 7, +16
- WHEN 6 : STEREO 7, +48
- WHEN 7 : STEREO 7, +80
- ENDCASE
- position% = RND(7)
- CASE position% OF
- WHEN 1 : STEREO 8, -127
- WHEN 2 : STEREO 8, -79
- WHEN 3 : STEREO 8, -47
- WHEN 4 : STEREO 8, -15
- WHEN 5 : STEREO 8, +16
- WHEN 6 : STEREO 8, +48
- WHEN 7 : STEREO 8, +80
- ENDCASE
- :
- ENDCASE
- PROCdisplay
- OTHERWISE VDU 7 : PROCplaysubmenu
- ENDCASE
- :
- ENDPROC
- :
- REM*******************************************
- :
- DEF PROClv
- :
- CLS
- lvdata%() = 0
- PRINT'" How many sound channels"
- INPUT'" are to generate lv "nlv%
- IF nlv% = 0 THEN
- lvdata%() = 0
- ELSE
- FOR count% = 1 TO nlv%
- PRINT '" lv channel ";count%;" is to use"
- INPUT '" how many other channels? "numchans%
- FOR c% = 1 TO numchans%
- PRINT '" of these, channel ";c%;
- INPUT " is channel "ch%
- lvdata%(count%,c%+1) = ch%
- NEXT
- lvdata%(count%,1) = count%
- NEXT
- ENDIF
- :
- PROCdisplay
- :
- ENDPROC
- :
- REM***********************************
- :
- DEF PROCloadwaveforms
- :
- CLS
- IF waveload$ = "done" THEN
- PROCwindow(20,71,60,35) : CLS
- PRINT'" These waveforms have already been loaded"
- PRINT " (press Ctrl-Shft to scroll down)"
- VDU 14
- FOR count% = 1 TO manywaves%
- PRINT'wforms$(count%)
- NEXT
- VDU 15
- PRINT' " Do you want to load a fresh group?"
- CASE GET$ OF
- WHEN "Y","y" : PRINT' " Press M then quit, to"
- PRINT " flush present waveforms"
- CASE GET$ OF
- WHEN "M","m" : PROCawait
- ENDCASE
- OTHERWISE PROCdisplay
- ENDCASE
- ELSE
- load$ = "new"
- IF filename$ <> "" AND wforms$(1) <> "" THEN
- PROCwindow(20,71,60,45)
- PRINT'" The waveforms previously "
- PRINT" loaded for this file were"
- PRINT" (press Ctrl-Shift to scroll down)"
- VDU 14
- FOR count% = 1 TO manywaves%
- PRINT'wforms$(count%)
- NEXT
- VDU 15
- PRINT'" Do you want to reload"
- PRINT " these or choose new ones (R/N)"
- CASE GET$ OF
- WHEN "R","r" : load$ = "previous"
- OTHERWISE
- ENDCASE
- ENDIF
- :
- IF load$ = "new" THEN
- :
- PRINT '" load individually or from lists? (I/L) "
- CASE GET$ OF
- WHEN "I","i" :
- PRINT '" How many waveforms do you want to load"
- PRINT " (the maximum for this file is ";numwaves%;")"
- INPUT manywaves%
- FOR count% = 1 TO manywaves%
- PRINT '" waveform ";count%;" is "
- INPUT wform$
- wforms$(count%) = wform$
- NEXT
- OTHERWISE
- PRINT'" Sustaining insts A "
- PRINT'" Percussion insts B "
- PRINT'" Percussion insts C "
- PRINT " (press A/B/C) "
- CASE GET$ OF
- WHEN "A","a" :
- manywaves% = 19
- wforms$(1) = "RecorderGb"
- wforms$(2) = "PiccoloE"
- wforms$(3) = "SaxSoprnoE"
- wforms$(4) = "JapFlute"
- wforms$(5) = "SaxBbTenrE"
- wforms$(6) = "BugleC"
- wforms$(7) = "Trombone1"
- wforms$(8) = "Trumpet"
- wforms$(9) = "EngHornGb"
- wforms$(10) = "ClarinetBb"
- wforms$(11) = "ClarVibEb"
- wforms$(12) = "BassoonEb"
- wforms$(13) = "FlugelHnEb"
- wforms$(14) = "CornetEb"
- wforms$(15) = "TubaGb"
- wforms$(16) = "HiString"
- wforms$(17) = "MidStrings"
- wforms$(18) = "BassBowAb"
- wforms$(19) = "SaxEbBarC"
- WHEN "B","b" :
- manywaves% = 19
- wforms$(1) = "Harp1"
- wforms$(2) = "Piano"
- wforms$(3) = "Vibe"
- wforms$(4) = "Timpani"
- wforms$(5) = "TimpRollEb"
- wforms$(6) = "Xylophone"
- wforms$(7) = "TablaHi"
- wforms$(8) = "BDPiloMute"
- wforms$(9) = "Snare"
- wforms$(10) = "TablaHi"
- wforms$(11) = "CymRStRoll"
- wforms$(12) = "CowBell"
- wforms$(13) = "AcuBassAb1"
- wforms$(14) = "GongSoft"
- wforms$(15) = "RotoTomRev"
- wforms$(16) = "HiHat"
- wforms$(17) = "Maracas1"
- wforms$(18) = "SimmonsBD1"
- wforms$(19) = "HiHatFoot"
- WHEN "C","c" :
- manywaves% = 19
- wforms$(1) = "CymSplshCa"
- wforms$(2) = "BassBowAb"
- wforms$(3) = "Bass"
- wforms$(4) = "HiHat"
- wforms$(5) = "HiHatFoot"
- wforms$(6) = "Maracas1"
- wforms$(7) = "CachichiTr"
- wforms$(8) = "BDPiloMute"
- wforms$(9) = "AcuBassAb1"
- wforms$(10) = "SimmonsBD1"
- wforms$(11) = "CymRideBel"
- wforms$(12) = "CowBell"
- wforms$(13) = "AcouBass"
- wforms$(14) = "RotoTomRev"
- wforms$(15) = "Castanets"
- wforms$(16) = "ElecTom1"
- wforms$(17) = "CymbalCrsh"
- wforms$(18) = "CymRStRoll"
- wforms$(19) = "Tomtom1"
- ENDCASE
- :
- ENDCASE
- :
- ENDIF
- :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Voices
- *RMLOAD WFS 500000
- wavefilingsystem$ = "loaded"
- :
- FOR count% = 1 TO manywaves%
- wave$ = wforms$(count%)
- CASE wave$ OF
- WHEN "BassBowAb" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations2
- *WLOAD BassBowAb
- *WINSTALL BassBowAb
- WHEN "Vibe" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations1
- *WLOAD Vibe
- *WINSTALL Vibe
- WHEN "AcouBass" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations1
- *WLOAD AcouBass
- *WINSTALL AcouBass
- WHEN "BugleC" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations2
- *WLOAD BugleC
- *WINSTALL BugleC
- WHEN "CornetEb" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations2
- *WLOAD CornetEb
- *WINSTALL CornetEb
- WHEN "SaxEbBarC" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations2
- *WLOAD SaxEbBarC
- *WINSTALL SaxEbBarC
- WHEN "SaxBbTenrE" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations2
- *WLOAD SaxBbTenrE
- *WINSTALL SaxBbTenrE
- WHEN "BassoonEb" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations2
- *WLOAD BassoonEb
- *WINSTALL BassoonEb
- WHEN "ClarinetBb" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations2
- *WLOAD ClarinetBb
- *WINSTALL ClarinetBb
- WHEN "EngHornGb" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations2
- *WLOAD EngHornGb
- *WINSTALL EngHornGb
- WHEN "MandolinDb" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations2
- *WLOAD MandolinDb
- *WINSTALL MandolinDb
- WHEN "Piano2B" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations2
- *WLOAD Piano2B
- *WINSTALL Piano2B
- WHEN "ClarVibEb" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations2
- *WLOAD ClarVibEb
- *WINSTALL ClarVibEb
- WHEN "GtrDobroB" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations2
- *WLOAD GtrDobroB
- *WINSTALL GtrDobroB
- WHEN "RecorderGb" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations2
- *WLOAD RecorderGb
- *WINSTALL RecorderGb
- WHEN "FlugelHnEb" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations2
- *WLOAD FlugelHnEb
- *WINSTALL FlugelHnEb
- WHEN "VceMmmGb23" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations3
- *WLOAD VceMmmGb23
- *WINSTALL VceMmmGb23
- WHEN "VceMOooGb3" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations3
- *WLOAD VceMOooGb3
- *WINSTALL VceMOooGb3
- WHEN "VceFemAahC" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations3
- *WLOAD VceFemAahC
- *WINSTALL VceFemAahC
- WHEN "VceFMmmGb4" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations3
- *WLOAD VceFMmmGb4
- *WINSTALL VceFMmmGb4
- WHEN "Bass" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.SoundSynth
- *WLOAD Bass
- *WINSTALL Bass
- WHEN "ChurchBell" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.SoundSynth
- *WLOAD ChurchBell
- *WINSTALL ChurchBell
- WHEN "GuiroFast" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations6
- *WLOAD GuiroFast
- *WINSTALL GuiroFast
- WHEN "Clave" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations6
- *WLOAD Clave
- *WINSTALL Clave
- WHEN "CowBell" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations6
- *WLOAD CowBell
- *WINSTALL CowBell
- WHEN "CymbRideHd" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations6
- *WLOAD CymbRideHd
- *WINSTALL CymbRideHd
- WHEN "AcGuitar1" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations1
- *WLOAD AcGuitar1
- *WINSTALL AcGuitar1
- WHEN "CongaHi" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations1
- *WLOAD CongaHi
- *WINSTALL CongaHi
- WHEN "DrumExplo" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations1
- *WLOAD DrumExplo
- *WINSTALL DrumExplo
- WHEN "ElecTom1" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations1
- *WLOAD ElecTom1
- *WINSTALL ElecTom1
- WHEN "Harp1" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations1
- *WLOAD Harp1
- *WINSTALL Harp1
- WHEN "Harpsi" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations1
- *WLOAD Harpsi
- *WINSTALL Harpsi
- WHEN "HiString" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations1
- *WLOAD HiString
- *WINSTALL HiString
- WHEN "HonkyPiano" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations1
- *WLOAD HonkyPiano
- *WINSTALL HonkyPiano
- WHEN "JapFlute" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations1
- *WLOAD JapFlute
- *WINSTALL JapFlute
- WHEN "JazzOrgan" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations1
- *WLOAD JazzOrgan
- *WINSTALL JazzOrgan
- WHEN "MidStrings" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations1
- *WLOAD MidStrings
- *WINSTALL MidStrings
- WHEN "NoteArp1" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations1
- *WLOAD NoteArp1
- *WINSTALL NoteArp1
- WHEN "SnareEcho" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations1
- *WLOAD SnareEcho
- *WINSTALL SnareEcho
- WHEN "TablaHi" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations1
- *WLOAD TablaHi
- *WINSTALL TablaHi
- WHEN "Timpani" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations1
- *WLOAD Timpani
- *WINSTALL Timpani
- WHEN "Tomtom1" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations1
- *WLOAD Tomtom1
- *WINSTALL Tomtom1
- WHEN "Trombone1" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations1
- *WLOAD Trombone1
- *WINSTALL Trombone1
- WHEN "Trumpet" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations1
- *WLOAD Trumpet
- *WINSTALL Trumpet
- WHEN "Xylophone" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations1
- *WLOAD Xylophone
- *WINSTALL Xylophone
- WHEN "AcouGtr2B" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations2
- *WLOAD AcouGtr2B
- *WINSTALL AcouGtr2B
- WHEN "AcuBassAb1" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations2
- *WLOAD AcuBassAb1
- *WINSTALL AcuBassAb1
- WHEN "BagPipeG" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations2
- *WLOAD BagPipeG
- *WINSTALL BagPipeG
- WHEN "BanjoChdBb" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations2
- *WLOAD BanjoChdBb
- *WINSTALL BanjoChdBb
- WHEN "BazookiE" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations2
- *WLOAD BazookiE
- *WINSTALL BazookiE
- WHEN "BellC" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations2
- *WLOAD BellC
- *WINSTALL BellC
- WHEN "BrassEns1B" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations2
- *WLOAD BrassEns1B
- *WINSTALL BrassEns1B
- WHEN "ClavichdBb" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations2
- *WLOAD ClavichdBb
- *WINSTALL ClavichdBb
- WHEN "ClavinetBb" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations2
- *WLOAD ClavinetBb
- *WINSTALL ClavinetBb
- WHEN "CornetEb" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations2
- *WLOAD CornetEb
- *WINSTALL CornetEb
- WHEN "EnsWodAb45" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations2
- *WLOAD EnsWodAb45
- *WINSTALL EnsWodAb45
- WHEN "EnsWodGb12" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations2
- *WLOAD EnsWodGb12
- *WINSTALL EnsWodGb12
- WHEN "Glock2Ab5" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations2
- *WLOAD Glock2Ab5
- *WINSTALL Glock2Ab5
- WHEN "GtMelobarC" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations2
- *WLOAD GtMelobarC
- *WINSTALL GtMelobarC
- WHEN "GtWashbnBb" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations2
- *WLOAD GtWashbnBb
- *WINSTALL GtWashbnBb
- WHEN "HarmonicaE" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations2
- *WLOAD HarmonicaE
- *WINSTALL HarmonicaE
- WHEN "Jew'sHarpA" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations2
- *WLOAD Jew'sHarpA
- *WINSTALL Jew'sHarpA
- WHEN "MusetteB" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations2
- *WLOAD MusetteB
- *WINSTALL MusetteB
- WHEN "OboeGb" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations2
- *WLOAD OboeGb
- *WINSTALL OboeGb
- WHEN "OrchHit2B" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations2
- *WLOAD OrchHit2B
- *WINSTALL OrchHit2B
- WHEN "OrcSusBb23" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations2
- *WLOAD OrcSusBb23
- *WINSTALL OrcSusBb23
- WHEN "PiccoloE" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations2
- *WLOAD PiccoloE
- *WINSTALL PiccoloE
- WHEN "SaxSoprnoE" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations2
- *WLOAD SaxSoprnoE
- *WINSTALL SaxSoprnoE
- WHEN "StrngThkBb" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations2
- *WLOAD StrngThkBb
- *WINSTALL StrngThkBb
- WHEN "TubaGb" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations2
- *WLOAD TubaGb
- *WINSTALL TubaGb
- WHEN "BassDrum" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.SoundSynth
- *WLOAD BassDrum
- *WINSTALL BassDrum
- WHEN "HiHat" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.SoundSynth
- *WLOAD HiHat
- *WINSTALL HiHat
- WHEN "OrcHit" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.SoundSynth
- *WLOAD OrcHit
- *WINSTALL OrcHit
- WHEN "Piano" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.SoundSynth
- *WLOAD Piano
- *WINSTALL Piano
- WHEN "Sax" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.SoundSynth
- *WLOAD Sax
- *WINSTALL Sax
- WHEN "Snare" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.SoundSynth
- *WLOAD Snare
- *WINSTALL Snare
- WHEN "Choir1" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations1
- *WLOAD Choir1
- *WINSTALL Choir1
- WHEN "ChurOrgan" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations1
- *WLOAD ChurOrgan
- *WINSTALL ChurOrgan
- WHEN "Opera" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations1
- *WLOAD Opera
- *WINSTALL Opera
- WHEN "OrchChoir" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations1
- *WLOAD OrchChoir
- *WINSTALL OrchChoir
- WHEN "OrganHit" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations1
- *WLOAD OrganHit
- *WINSTALL OrganHit
- WHEN "AgogoAfric" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations6
- *WLOAD AgogoAfric
- *WINSTALL AgogoAfric
- WHEN "AgogoBrazi" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations6
- *WLOAD AgogoBrazi
- *WINSTALL AgogoBrazi
- WHEN "AgogoWood" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations6
- *WLOAD AgogoWood
- *WINSTALL AgogoWood
- WHEN "BDGatedRev" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations6
- *WLOAD BDGatedRev
- *WINSTALL BDGatedRev
- WHEN "BDMarching" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations6
- *WLOAD BDMarching
- *WINSTALL BDMarching
- WHEN "BDPiloMute" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations6
- *WLOAD BDPiloMute
- *WINSTALL BDPiloMute
- WHEN "Cabasa" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations6
- *WLOAD Cabasa
- *WINSTALL Cabasa
- WHEN "Cachichi1" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations6
- *WLOAD Cachichi1
- *WINSTALL Cachichi1
- WHEN "CachichiTr" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations6
- *WLOAD CachichiTr
- *WINSTALL CachichiTr
- WHEN "Castanets" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations6
- *WLOAD Castanets
- *WINSTALL Castanets
- WHEN "CongaMid" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations6
- *WLOAD CongaMid
- *WINSTALL CongaMid
- WHEN "CongaSmCl" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations6
- *WLOAD CongaSmCl
- *WINSTALL CongaSmCl
- WHEN "CymbalCrsh" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations6
- *WLOAD CymbalCrsh
- *WINSTALL CymbalCrsh
- WHEN "CymRideBel" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations6
- *WLOAD CymRideBel
- *WINSTALL CymRideBel
- WHEN "CymRStRoll" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations6
- *WLOAD CymRStRoll
- *WINSTALL CymRStRoll
- WHEN "CymSplshCa" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations6
- *WLOAD CymSplshCa
- *WINSTALL CymSplshCa
- WHEN "Flexitone" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations6
- *WLOAD Flexitone
- *WINSTALL Flexitone
- WHEN "GongSoft" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations6
- *WLOAD GongSoft
- *WINSTALL GongSoft
- WHEN "Gonza1" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations6
- *WLOAD Gonza1
- *WINSTALL Gonza1
- WHEN "GuiroSlow" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations6
- *WLOAD GuiroSlow
- *WINSTALL GuiroSlow
- WHEN "HandClaps" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations6
- *WLOAD HandClaps
- *WINSTALL HandClaps
- WHEN "HiHatFoot" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations6
- *WLOAD HiHatFoot
- *WINSTALL HiHatFoot
- WHEN "Maracas1" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations6
- *WLOAD Maracas1
- *WINSTALL Maracas1
- WHEN "Ratchet" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations6
- *WLOAD Ratchet
- *WINSTALL Ratchet
- WHEN "RotoTomRev" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations6
- *WLOAD RotoTomRev
- *WINSTALL RotoTomRev
- WHEN "SimmonsBD1" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations6
- *WLOAD SimmonsBD1
- *WINSTALL SimmonsBD1
- WHEN "SimmonsSn1" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations6
- *WLOAD SimmonsSn1
- *WINSTALL SimmonsSn1
- WHEN "SuperGong" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations6
- *WLOAD SuperGong
- *WINSTALL SuperGong
- WHEN "SynTom" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations6
- *WLOAD SynTom
- *WINSTALL SynTom
- WHEN "TimpCresBb" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations6
- *WLOAD TimpCresBb
- *WINSTALL TimpCresBb
- WHEN "TimpLowBb" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations6
- *WLOAD TimpLowBb
- *WINSTALL TimpLowBb
- WHEN "TimpRollEb" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations6
- *WLOAD TimpRollEb
- *WINSTALL TimpRollEb
- WHEN "TomRoll" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations6
- *WLOAD TomRoll
- *WINSTALL TomRoll
- WHEN "ToyHooter" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations6
- *WLOAD ToyHooter
- *WINSTALL ToyHooter
- WHEN "ToyWhistle" :
- *Dir SDFS::RISCOSpi.$.CAC.CACvar.Creations.Creations6
- *WLOAD ToyWhistle
- *WINSTALL ToyWhistle
- OTHERWISE VDU 7 : PRINT''" !!! ";wave$;" not loaded !!!"
- PRINT'" Press C to continue loading"
- CASE GET$ OF
- WHEN"C","c" :
- ENDCASE
- ENDCASE
- NEXT
- REM waveload$ = "done" !! remove REM if loading waveforms reinstated
- ENDIF
- *NoDir
- PROCdisplay
- ENDPROC
- :
- REM*********************************************
- :
- DEF PROCtempo
- :
- warning$ = "y"
- CLS
- PRINT'" Tempo to start at which bar "
- INPUT' " (for 1 type 0)"sbar%
- PRINT'" and last until which bar "
- INPUT' " (for end type 0) "ebar%
- IF ebar% = 0 THEN ebar% = nobars%
- INPUT'" Tempo per bar is "MM%
- :
- REM convert durations to new tempo
- FOR count% = 0 TO numparts%-1
- FOR counter% = 0 TO numusedcells%(count%)
- bar% = array%(counter%,0,count%)DIV10^6
- IF bar% >= sbar% AND bar% <= ebar% THEN
- oldtempo% = tempi%(bar%)
- dur% = (array%(counter%,1,count%)DIV10)MOD10^3
- converter = oldtempo%/MM%
- dur = dur% * converter
- fraction = ((dur*10)DIV1)MOD10
- IF fraction>4 THEN dur% = dur+1 ELSE dur% = dur
- IF dur% > 999 THEN
- dur% = 998 : REM only 3 array cells available
- IF warning$ = "y" THEN
- VDU 7
- CLS
- PRINT'" This tempo change has resulted in some "
- PRINT " voices, starting with voice ";count%+1;", being "
- PRINT " given a duration which will now be "
- PRINT " permanently too short (max = 50 secs). "
- PRINT'" If this is okay simply continue, "
- PRINT " otherwise now QUIT and reload the file. "
- PRINT'" (to continue press a key - NOT Esc)"
- CASE GET$ OF
- WHEN "c" : warning$ = "n"
- OTHERWISE warning$ = "n"
- ENDCASE
- ENDIF
- ENDIF
- part1% = (array%(counter%,1,count%)DIV10^4)*10^4
- part2% = dur% * 10
- part3% = array%(counter%,1,count%)MOD10
- array%(counter%,1,count%) = part1% + part2% + part3%
- ENDIF
- NEXT
- NEXT
- :
- FOR count% = sbar% TO ebar%
- tempi%(count%) = MM%
- NEXT
- IF sbar% = 1 THEN tempi%(0) = MM% : REM anticipates a bug when bars 1 - 1 PLAYed
- :
- PROCdisplay
- :
- ENDPROC
- :
- REM************************************************
- :
- DEF PROCerror
- :
- CASE errorbeforedisplay$ OF
- WHEN "y":
- CLS
- REPORT
- PRINT " at line ";ERL
- PRINT '" To continue press Q to quit"
- PRINT '" then allocate more memory in "
- PRINT '" Tasks before starting CAC "
- CASE GET$ OF
- WHEN "Q","q" : QUIT
- ENDCASE
- WHEN "debug" :
- PROCwindow(20,69,60,54)
- REPORT
- PRINT " at line ";ERL
- PRINT'" To continue press a key"
- PRINT'" or to quit press Q "
- CASE GET$ OF
- WHEN "Q","q": QUIT
- OTHERWISE
- PROCdisplay
- ENDCASE
- OTHERWISE
- PROCdisplay
- ENDCASE
- :
- ENDPROC
- :
- REM*************************************************
- :
- DEF PROCtobegin
- :
- PRINT''''" Open a new file or an existing one? (N/E)"
- CASE GET$ OF
- WHEN "N","n" : PROCprearraysetup : PROCarraysetup
- alterbeatsat% = (960/beatfactor%)/8 : PROCdisplay
- WHEN "E","e" : PROCloadfile
- OTHERWISE VDU 7 : PROCtobegin
- ENDCASE
- :
- ENDPROC
- :
- REM************************************************
- :
- DEF PROCfunctionreception
- :
- IF easiermenus$ = "n" THEN
- PROCwindow(20,69,60,54)
- CLS : OFF
- :
- PRINT'" Accel/rit A"
- PRINT " Layered attacks L"
- PRINT " Pitch string P"
- PRINT " Pitch string 2 S"
- PRINT " Pitch string 3 N"
- PRINT " Pitch string 4 (trill/trem) T"
- PRINT " pitch string 5 (pattern) R"
- PRINT " pitch string 6 (equal steps) C"
- PRINT " Interval string I"
- PRINT " Distort D"
- PRINT " Slave voice V"
- PRINT " Double-stop B"
- ELSE
- PROCwindow(20,69,60,42)
- CLS : OFF
- :
- PRINT'" Accel/rit A"
- PRINT '" Layered attacks L"
- PRINT '" Pitch string P"
- PRINT '" Pitch string 2 S"
- PRINT '" Pitch string 3 N"
- PRINT '" Pitch string 4 (trill/trem) T"
- PRINT '" pitch string 5 (pattern) R"
- PRINT '" pitch string 6 (equal steps) C"
- PRINT '" Interval string I"
- PRINT '" Distort D"
- PRINT '" Slave voice V"
- PRINT '" Double-stop B"
- ENDIF
- CASE GET$ OF
- WHEN "A","a" : PROCfunctionprelude
- WHEN "L","l" : PROCprelayeredattacks
- WHEN "P","p" : PROCpitchstring
- WHEN "S","s" : PROCpitchstring2
- WHEN "N","n" : PROCpitchstring3
- WHEN "T","t" : PROCpitchstring4
- WHEN "R","r" : PROCpitchstring5
- WHEN "C","c" : PROCpitchstring6
- WHEN "I","i" : PROCpreintervalstring
- WHEN "D","d" : distort$ = "ON" : CLS
- IF easiermenus$ = "n" THEN
- PROCwindow(20,69,60,54)
- CLS : OFF
- PRINT''" Distort"
- PRINT'" ATTACKS A"
- PRINT " PITCHES P"
- PRINT " DURATIONS D"
- PRINT " AMPLITUDES M"
- PRINT " ENVELOPES E"
- PRINT " INFLECTIONS I"
- ELSE
- PROCwindow(20,69,60,42)
- CLS : OFF
- PRINT''" Distort"
- PRINT'" ATTACKS A"
- PRINT' " PITCHES P"
- PRINT '" DURATIONS D"
- PRINT '" AMPLITUDES M"
- PRINT '" ENVELOPES E"
- PRINT '" INFLECTIONS I"
- ENDIF
- :
- CASE GET$ OF
- WHEN "A","a" : distortpara$ = "attacks"
- WHEN "P","p" : distortpara$ = "pitches"
- WHEN "D","d" : distortpara$ = "durations"
- WHEN "M","m" : distortpara$ = "amplitudes"
- WHEN "E","e" : distortpara$ = "envelopes"
- WHEN "I","i" : distortpara$ = "inflections"
- OTHERWISE VDU 7 : PROCfunctionreception
- ENDCASE
- PROCcopy
- WHEN "V","v" : quickslave$ = "n" : PROCslave
- WHEN "B","b" : PROCdoublestop
- WHEN "E", "e" : PROCconvertoldenvelopes
- WHEN "O", "o" : PROCroguenotes
- OTHERWISE VDU 7 : PROCfunctionreception
- ENDCASE
- ON
- :
- ENDPROC
- :
- REM**********************************************
- :
- DEF PROCprelayeredattacks
- :
- IF easiermenus$ = "n" THEN PROCwindow(20,69,70,55) ELSE PROCwindow(20,69,70,42)
- :
- PRINT'" Re-run current settings, or edit current settings,"
- PRINT" or create new ones, or load a file? (R/E/N/F)"
- CASE GET$ OF
- WHEN "R","r" : PROClayeredattacks
- WHEN "E","e" : PROCeditlayers
- WHEN "F","f" : PROCloadlayers :PROCeditlayers
- OTHERWISE
- filenamelyr$ = ""
- :
- chanceoflayer%(1) = 1 : numlayersections% = 1 : numlayerOKsects%() = 0
- :
- INPUT'" Total duration is how many bars "bars%
- INPUT'" and how many beats "beats%
- PROCalterbeats : totallength% = (bars%*960)+beats%
- PRINT''" LAYERS -"
- INPUT'" How many layers "numlayers%
- PRINT'" Are the layers to appear equally frequently,"
- PRINT " or in certain proportions (E/P) "
- :
- CASE GET$ OF
- :
- WHEN "P","p" :
- PRINT'" Piece is divided into how many sections"
- INPUT " of different contribution-proportions "numlayersections%
- :
- IF numlayersections% > 1 THEN
- :
- FOR count% = 2 TO numlayersections%
- PRINT'" Section ";count%;" starts at beat number "
- INPUT beats%
- PROCalterbeats : startoflayersection%(count%) = beats%
- NEXT
- ENDIF
- :
- FOR count% = 1 TO numlayersections%
- FOR count1% = 1 TO numlayers%
- PRINT '"In section ";count%;", layer ";count1%;" has "
- PRINT "how many proportions?"
- INPUT shareoflayers%(count%,count1%)
- NEXT
- NEXT
- :
- OTHERWISE shareoflayers%() = 1
- ENDCASE
- :
- PRINT''" Are number of attacks or unit durations to be"
- PRINT " divided into sections or appearance numbers?"
- CASE GET$ OF
- WHEN "Y","y" : bysections$ = "y"
- OTHERWISE bysections$ = "n"
- ENDCASE
- PRINT'" Are unit durations in any layers to be multiplied?"
- CASE GET$ OF
- WHEN "Y","y" : tomultiply$ = "y"
- OTHERWISE tomultiply$ = "n"
- ENDCASE
- PRINT'" Are the occurance of layers to be controlled?"
- CASE GET$ OF
- WHEN "Y","y" : tooccur$ = "y"
- OTHERWISE tooccur$ = "n"
- ENDCASE
- PRINT'" Does the number of attacks ever exceed 1?"
- CASE GET$ OF
- WHEN "Y","y" : exceed1$ = "y"
- OTHERWISE exceed1$ = "n"
- ENDCASE
- :
- FOR count% = 1 TO numlayers%
- :
- PRINT''" NUMBER OF ATTACKS -"
- :
- IF bysections$ = "y" THEN
- PRINT'" In layer ";count%;" are the number of attacks controlled"
- PRINT " by sections or by appearance number (S/A)"
- CASE GET$ OF
- WHEN "S","s" :
- attackscontrol$(count%) = "S"
- INPUT'" How many sections "numattackssections%(count%)
- IF numattackssections%(count%) > 1 THEN
- FOR count1% = 2 TO numattackssections%(count%)
- PRINT'" (layer ";count%;") section ";count1%;" starts at beat"
- INPUT beats%
- PROCalterbeats : startofattackssection%(count%,count1%) = beats%
- NEXT
- ENDIF
- :
- IF exceed1$ = "y" THEN
- FOR count1% = 1 TO numattackssections%(count%)
- PRINT'" In layer ";count%;", section ";count1%;" the number"
- PRINT" of attacks varies between..."
- INPUT numattax%(count%,count1%,0)
- INPUT" and..."numattax%(count%,count1%,1)
- NEXT
- ELSE numattax%() = 1
- ENDIF
- :
- WHEN "A","a" :
- attackscontrol$(count%) = "A"
- INPUT'" How many 'sections' of appearances "numattackssections1%(count%)
- IF numattackssections1%(count%) > 1 THEN
- FOR count1% = 2 TO numattackssections1%(count%)
- PRINT'" (layer ";count%;") section ";count1%;" starts at appearance "
- INPUT startofattackssection1%(count%,count1%)
- NEXT
- ENDIF
- :
- IF exceed1$ = "y" THEN
- FOR count1% = 1 TO numattackssections1%(count%)
- PRINT'" In layer ";count%;", section ";count1%;" the number"
- PRINT" of attacks varies between..."
- INPUT numattax1%(count%,count1%,0)
- INPUT" and... "numattax1%(count%,count1%,1)
- NEXT
- ELSE numattax1%() = 1
- ENDIF
- ENDCASE
- :
- ELSE
- attackscontrol$(count%) = "S" : numattackssections%(count%) = 1
- IF exceed1$ = "y" THEN
- PRINT'" In layer ";count%;" the number"
- PRINT" of attacks varies between "
- INPUT numattax%(count%,1,0)
- INPUT" and..."numattax%(count%,1,1)
- ELSE numattax%() = 1
- ENDIF
- ENDIF
- :
- PRINT''" DURATIONS"
- :
- IF bysections$ = "y" THEN
- :
- PRINT'" In layer ";count%;" are the unit durations controlled"
- PRINT" by sections or by appearance number (S/A)"
- CASE GET$ OF
- WHEN "S","s" :
- durationscontrol$(count%) = "S"
- INPUT'" How many sections "numdurationssections%(count%)
- IF numdurationssections%(count%) > 1 THEN
- FOR count1% = 2 TO numdurationssections%(count%)
- PRINT'" (layer ";count%;") section ";count1%;" starts at beat "
- INPUT beats%
- PROCalterbeats : startofdurationssection%(count%,count1%) = beats%
- NEXT
- ENDIF
- :
- FOR count1% = 1 TO numdurationssections%(count%)
- PRINT'" In layer ";count%;", section ";count1%;" the unit duration is"
- INPUT beats%
- PROCalterbeats : doorations%(count%,count1%) = beats%
- NEXT
- :
- WHEN "A","a" :
- durationscontrol$(count%) = "A"
- INPUT'" How many 'sections' "numdurationssections1%(count%)
- IF numdurationssections1%(count%) > 1 THEN
- FOR count1% = 2 TO numdurationssections1%(count%)
- PRINT'" (layer ";count%;") section ";count1%;" starts at appearance "
- INPUT startofdurationssection1%(count%,count1%)
- NEXT
- ENDIF
- FOR count1% = 1 TO numdurationssections1%(count%)
- PRINT'" In layer ";count%;", section ";count1%;" the unit duration is "
- INPUT beats%
- PROCalterbeats : doorations1%(count%,count1%) = beats%
- NEXT
- ENDCASE
- :
- ELSE durationscontrol$(count%) = "S" : numdurationssections%(count%) = 1
- PRINT'" In layer ";count%;" the unit duration is"
- INPUT beats%
- PROCalterbeats : doorations%(count%,1) = beats%
- ENDIF
- :
- IF tomultiply$ = "y" THEN
- :
- PRINT'" Do you want the unit duration to be multiplied"
- PRINT " by a given series of values (Y/N) "
- CASE GET$ OF
- WHEN "Y","y" :
- multiplier$(count%) = "Y"
- PRINT'" starting fresh at each appearance or irrespective (F/I) "
- CASE GET$ OF
- WHEN "F","f" :
- multipliermode$(count%) = "F"
- OTHERWISE multipliermode$(count%) = "I"
- ENDCASE
- :
- PRINT'" How many values "
- INPUT numvalues%(count%)
- FOR count1% = 1 TO numvalues%(count%)
- PRINT'" value ";count1%;" is "
- INPUT values(count%,count1%)
- NEXT
- OTHERWISE multiplier$(count%) = "N"
- ENDCASE
- :
- ELSE multiplier$(count%) = "N"
- ENDIF
- :
- IF tooccur$ = "y" THEN
- :
- PRINT'" Do you want this layer to reoccur according"
- PRINT " to minimum and maximum intervals (eg to"
- PRINT " control phrase-lengths)?"
- CASE GET$ OF
- WHEN "Y","y" :
- INPUT'" How many sections of this "numlayerOKsects%(count%)
- FOR count1% = 1 TO numlayerOKsects%(count%)
- IF numlayerOKsects%(count%) > 1 THEN
- PRINT'" section ";count1%;" begins at beat "
- INPUT beats%
- PROCalterbeats : x% = beats%
- ELSE x% = 0
- ENDIF
- PRINT'" in this section the layer should NOT reoccur"
- PRINT" until at least how many beats from the"
- PRINT" end of its previous occurence?"
- INPUT beats%
- PROCalterbeats : y% = beats%
- PRINT'" but SHOULD be made to reoccur after how "
- PRINT" many beats from the end of its previous"
- PRINT" occurence?"
- INPUT beats%
- PROCalterbeats : z% = beats%
- layersOK%(count%,count1%,0) = x%
- layersOK%(count%,count1%,1) = y%
- layersOK%(count%,count1%,2) = z%
- NEXT
- OTHERWISE
- ENDCASE
- :
- ENDIF
- :
- NEXT
- :
- ENDCASE
- :
- PROClayeredattacks
- :
- ENDPROC
- :
- REM**************************************************
- :
- DEF PROClayeredattacks
- :
- REM line below to come BEFORE the loop
- cellsused% = 0 : attacks1%() = 0 : layer% = 0 : appearances%() = 0
- valuescounter%() = 1 : layerends%() = 0
- :
- REPEAT
- REM WHICH LAYER (loop starts here)
- layer1% = layer%
- layerends%(layer1%) = attacks1%(cellsused%)
- :
- REM fill OKtouselayers%() according to which section you're in
- :
- FOR count% = 1 TO numlayers%
- IF numlayerOKsects%(count%) > 0 THEN
- FOR counter% = 1 TO numlayerOKsects%(count%)
- IF attacks1%(cellsused%) >= layersOK%(count%,counter%,0) THEN
- OKtouselayers%(count%,0) = layerends%(count%) + layersOK%(count%,counter%,1)
- OKtouselayers%(count%,1) = layerends%(count%) + layersOK%(count%,counter%,2)
- ENDIF
- NEXT
- ENDIF
- NEXT
- :
- REM use any layers due
- FOR count% = 1 TO numlayers%
- IF numlayerOKsects%(count%) > 0 THEN
- IF attacks1%(cellsused%) >= OKtouselayers%(count%,1) THEN layer% = count%
- ENDIF
- NEXT
- :
- IF layer1% = layer% THEN
- :
- REPEAT
- :
- REM fill layershare%() according to which section you're in
- FOR count% = 1 TO numlayersections%
- :
- IF attacks1%(cellsused%) >= startoflayersection%(count%) THEN
- FOR count1% = 1 TO numlayers%
- layershare%(count1%) = shareoflayers%(count%,count1%)
- NEXT
- ENDIF
- NEXT
- :
- FOR count% = 1 TO numlayers%
- chanceoflayer%(count%+1) = chanceoflayer%(count%)+layershare%(count%)
- NEXT
- x% = RND((chanceoflayer%(numlayers%+1))-1)
- FOR count% = 1 TO numlayers%
- IF x% >= chanceoflayer%(count%) THEN layer% = count%
- NEXT
- :
- REM exclude layers coming too soon
- IF numlayerOKsects%(layer%) > 0 THEN
- IF attacks1%(cellsused%) < OKtouselayers%(layer%,0) THEN layerOK$ = "n" ELSE layerOK$ = "y"
- ELSE layerOK$ = "y"
- ENDIF
- UNTIL layer% <> layer1% AND layerOK$ = "y"
- :
- ENDIF
- appearances%(layer%) += 1
- :
- REM NUMBER OF ATTACKS
- IF attackscontrol$(layer%) = "S" THEN
- FOR count% = 1 TO numattackssections%(layer%)
- IF attacks1%(cellsused%) >= startofattackssection%(layer%,count%) THEN
- a% = numattax%(layer%,count%,0) : b% = numattax%(layer%,count%,1)
- IF (b%-a%) = 0 THEN
- noattax% = 1
- ELSE
- noattax% = RND((b%-a%)+1)
- ENDIF
- noattax% += (a%-1)
- ENDIF
- NEXT
- ELSE
- FOR count% = 1 TO numattackssections1%(layer%)
- IF appearances%(layer%) >= startofattackssection1%(layer%,count%) THEN
- a% = numattax1%(layer%,count%,0) : b% = numattax1%(layer%,count%,1)
- IF (b%-a%) = 0 THEN
- noattax% = 1
- ELSE
- noattax% = RND((b%-a%)+1)
- ENDIF
- noattax% += (a%-1)
- ENDIF
- NEXT
- ENDIF
- :
- IF durationscontrol$(layer%) = "S" THEN
- FOR count% = 1 TO numdurationssections%(layer%)
- IF attacks1%(cellsused%) >= startofdurationssection%(layer%,count%) THEN
- duration% = doorations%(layer%,count%)
- ENDIF
- NEXT
- ELSE
- FOR count% = 1 TO numdurationssections1%(layer%)
- IF appearances%(layer%) >= startofdurationssection1%(layer%,count%) THEN
- duration% = doorations1%(layer%,count%)
- ENDIF
- NEXT
- ENDIF
- :
- IF multiplier$(layer%) = "N" THEN
- FOR count% = 1 TO noattax%
- attacks1%(cellsused%+1) = attacks1%(cellsused%)+duration%
- cellsused% += 1
- NEXT
- ELSE
- IF multipliermode$(layer%) = "F" THEN
- FOR count% = 1 TO noattax%
- attacks1%(cellsused%+1)=attacks1%(cellsused%)+(duration%*values(layer%,count%))
- cellsused% += 1
- NEXT
- ELSE
- FOR count% = 1 TO noattax%
- attacks1%(cellsused%+1)=attacks1%(cellsused%)+(duration%*values(layer%,valuescounter%(layer%)))
- cellsused% += 1
- valuescounter%(layer%) += 1
- IF valuescounter%(layer%) > numvalues%(layer%) THEN valuescounter%(layer%) = 1
- NEXT
- ENDIF
- ENDIF
- :
- UNTIL attacks1%(cellsused%) >= totallength%
- manyattacks% = cellsused%+1
- :
- PRINT'" Do you want to save these settings?"
- CASE GET$ OF
- WHEN "Y","y" : PROCsavelayers
- OTHERWISE
- ENDCASE
- :
- method$ = "raw" : PROCinsertattacks
- :
- ENDPROC
- :
- REM*********************************************************
- :
- DEF PROCconvertsamplenote
- :
- pitchclass% = samplenote% DIV 100
- CASE pitchclass% OF
- WHEN 0 : eighthtone% = 1
- WHEN 1 : eighthtone% = 9
- WHEN 2 : eighthtone% = 17
- WHEN 3 : eighthtone% = 21
- WHEN 4 : eighthtone% = 29
- WHEN 5 : eighthtone% = 37
- WHEN 6 : eighthtone% = 45
- ENDCASE
- octave% = samplenote% MOD 10
- eighthtone% += (octave%*48)
- accidental% = ((samplenote% MOD 100)DIV10)-1
- eighthtone% += accidental%
- samplenote% = eighthtone%
- ENDPROC
- :
- REM*******************************************
- :
- DEF PROCconvertsimplenote
- :
- IF simplenote% > 2 THEN oct% = 0
- IF simplenote% > 50 THEN oct% = 1
- IF simplenote% > 98 THEN oct% = 2
- IF simplenote% > 146 THEN oct% = 3
- IF simplenote% > 194 THEN oct% = 4
- IF simplenote% > 242 THEN oct% = 5
- IF simplenote% > 290 THEN oct% = 6
- IF simplenote% > 338 THEN oct% = 7
- IF simplenote% > 386 THEN oct% = 8
- :
- WHILE simplenote% > 50
- simplenote% -= 48
- ENDWHILE
- :
- CASE simplenote% OF
- WHEN 3 : pitch% = 3
- WHEN 4 : pitch% = 4
- WHEN 5 : pitch% = 5
- WHEN 6 : pitch% = 6
- WHEN 7 : pitch% = 7
- WHEN 8 : pitch% = 8
- WHEN 9 : pitch% = 11
- WHEN 10 : pitch% = 12
- WHEN 11 : pitch% = 13
- WHEN 12 : pitch% = 14
- WHEN 13 : pitch% = 15
- WHEN 14 : pitch% = 16
- WHEN 15 : pitch% = 17
- WHEN 16 : pitch% = 18
- WHEN 17 : pitch% = 21
- WHEN 18 : pitch% = 22
- WHEN 19 : pitch% = 23
- WHEN 20 : pitch% = 24
- WHEN 21 : pitch% = 25
- WHEN 22 : pitch% = 26
- WHEN 23 : pitch% = 27
- WHEN 24 : pitch% = 34
- WHEN 25 : pitch% = 35
- WHEN 26 : pitch% = 36
- WHEN 27 : pitch% = 37
- WHEN 28 : pitch% = 38
- WHEN 29 : pitch% = 39
- WHEN 30 : pitch% = 42
- WHEN 31 : pitch% = 43
- WHEN 32 : pitch% = 44
- WHEN 33 : pitch% = 45
- WHEN 34 : pitch% = 46
- WHEN 35 : pitch% = 47
- WHEN 36 : pitch% = 48
- WHEN 37 : pitch% = 51
- WHEN 38 : pitch% = 52
- WHEN 39 : pitch% = 53
- WHEN 40 : pitch% = 54
- WHEN 41 : pitch% = 55
- WHEN 42 : pitch% = 56
- WHEN 43 : pitch% = 57
- WHEN 44 : pitch% = 58
- WHEN 45 : pitch% = 61
- WHEN 46 : pitch% = 62
- WHEN 47 : pitch% = 63
- WHEN 48 : pitch% = 64
- WHEN 49 : pitch% = 65
- WHEN 50 : pitch% = 66
- ENDCASE
- :
- simplenote% = (pitch%*10)+oct%
- ENDPROC
- :
- REM**************************************
- :
- :
- DEF PROCpitchstring
- :
- PROCwindow(20,25,70,35)
- :
- :
- PRINT'" Create a new pitch string or edit the"
- PRINT " current one, or load a file (N/E/F)"
- CASE GET$ OF
- WHEN "E","e" : loadstring$ = "n" :PROCeditpitchstring
- WHEN "F","f" : loadstring$ = "y" :PROCeditpitchstring
- OTHERWISE
- ENDCASE
- :
- filenamestg$ = ""
- contoursequences%() = 0
- transpositionsequences%() = 0
- octavesequences%() = 0
- PRINT'" Total number of notes in the"
- INPUT " pitch string (inc. sample) "numpitches%
- PRINT'" Is the grid semi, quarter or eighth-tone (S/Q/E) "
- PRINT'" (0 = semi) "
- CASE GET$ OF
- WHEN "S","s" : grid$ = "s"
- WHEN "Q","q" : grid$ = "q"
- WHEN "E","e" : grid$ = "e"
- OTHERWISE grid$ = "s"
- ENDCASE
- CLS
- :
- PRINT'" SAMPLE "
- INPUT'" How many notes in the sample? "samplesize%
- FOR count% = 1 TO samplesize%
- PRINT'" note ";count%;" is pitchclass ";
- COLOUR 3
- CASE GET$ OF
- WHEN "C","c" : samplenote% = 0 : PRINT "C"
- WHEN "D","d" : samplenote% = 1 : PRINT "D"
- WHEN "E","e" : samplenote% = 2 : PRINT "E"
- WHEN "F","f" : samplenote% = 3 : PRINT "F"
- WHEN "G","g" : samplenote% = 4 : PRINT "G"
- WHEN "A","a" : samplenote% = 5 : PRINT "A"
- WHEN "B","b" : samplenote% = 6 : PRINT "B"
- ENDCASE
- samplenote% = samplenote%*100
- COLOUR 0
- PRINT " accidental ";
- COLOUR 3
- CASE GET$ OF
- WHEN "1" : samplenote% += 10 : PRINT "flat"
- WHEN "2" : samplenote% += 20 : PRINT "3/8 flat"
- WHEN "3" : samplenote% += 30 : PRINT "1/4 flat"
- WHEN "4" : samplenote% += 40 : PRINT "1/8 flat"
- WHEN "5" : samplenote% += 50 : PRINT "nat"
- WHEN "6" : samplenote% += 60 : PRINT "1/8 shrp"
- WHEN "7" : samplenote% += 70 : PRINT "1/4 shrp"
- WHEN "8" : samplenote% += 80 : PRINT "3/8 shrp"
- WHEN "9" : samplenote% += 90 : PRINT "shrp"
- ENDCASE
- COLOUR 0
- samplenote% += 5
- PROCconvertsamplenote
- sample%(count%) = samplenote%
- :
- NEXT
- :
- CLS
- PRINT'" OCTAVE SEQUENCES"
- PRINT'" How many different sections of"
- INPUT " octave sequences are there "octavesections%
- IF octavesections% > 1 THEN
- FOR count% = 2 TO octavesections%
- PRINT'" section ";count%;" begins at note number "
- INPUT x%
- octavesequences%(count%,0,0) = x%
- NEXT
- ENDIF
- :
- FOR count% = 1 TO octavesections%
- FOR pitch% = 0 TO 47
- entry$ = "n"
- IF pitch% MOD 4 = 0 AND grid$<>"s" THEN entry$ = "y"
- IF (pitch%-2)MOD4 = 0 THEN entry$ = "y"
- IF (pitch%-1)MOD2 = 0 AND grid$ = "e" THEN entry$ = "y"
- IF entry$ = "y" THEN
- PRINT '"In section ";count%;" the sequence of octaves for ";
- COLOUR 3 : PRINT pitchnames$(pitch%)
- COLOUR 0 : PRINT "has how many elements "
- INPUT e%
- PRINT""
- octavesequences%(count%,pitch%+1,0) = e%
- FOR counter% = 1 TO e%
- PRINT " element ";counter%;
- INPUT " is octave "o%
- octavesequences%(count%,pitch%+1,counter%) = o%
- NEXT
- ENDIF
- NEXT
- NEXT
- :
- CLS
- PRINT'" TRANSPOSITION LEVELS"
- PRINT'" How many different sections of"
- INPUT" transposition are there "transpositionsections%
- IF transpositionsections% > 1 THEN
- FOR count% = 2 TO transpositionsections%
- PRINT'" Section ";count%;
- INPUT " begins at note number "n%
- transpositionsequences%(count%,0) = n%
- PRINT" and transposes up/down by how many ";
- CASE grid$ OF
- WHEN "e" : PRINT "eighthtones" : INPUT " (+/- 1 etc) "x%
- transpositionsequences%(count%,1) = x%
- WHEN "q" : PRINT "quartertones" : INPUT " (+/- 1 etc) "x%
- transpositionsequences%(count%,1) = x% * 2
- WHEN "s" : PRINT "semitones" : INPUT " (+/- 1 etc) "x%
- transpositionsequences%(count%,1) = x% * 4
- ENDCASE
- NEXT
- ENDIF
- :
- CLS
- PRINT'" CONTOUR SEQUENCES"
- PRINT'" How many different sections of "
- INPUT " contour sequences are there "contoursections%
- IF contoursections%>1 THEN
- FOR count% = 2 TO contoursections%
- PRINT'" Section ";count%;
- INPUT " begins at note number "n%
- contoursequences%(count%,0) = n%
- NEXT
- ENDIF
- :
- FOR count% = 1 TO contoursections%
- PRINT'" In section ";count%;
- INPUT " there are how many contours "c%
- contoursequences%(count%,1) = c%
- PRINT""
- FOR counter% = 1 TO c%
- PRINT " number ";counter%;
- INPUT " is contour "contoor%
- contoursequences%(count%,counter%+1) = contoor%
- NEXT
- NEXT
- :
- contoursize% = 0 : seriesnote% = 1 : samplenote% = 0
- contoursequence% = 1 : transpositionsequence% = 1
- octavesequence% = 1 : transpositionsequences%(1,1) = 0
- contourloop% = 0 : octaveloop%() = 0
- :
- REPEAT
- seriesnote% += contoursize%
- IF seriesnote% >= contoursequences%(contoursequence%+1,0) AND contoursequences%(contoursequence%+1,0) <> 0 THEN
- contoursequence% += 1
- contourloop% = 0
- ENDIF
- :
- contourloop% += 1
- IF contourloop% > contoursequences%(contoursequence%,1) THEN contourloop% = 1
- contour% = contoursequences%(contoursequence%,contourloop%+1)
- contoursize% = contours%(contour%,0)
- :
- IF seriesnote% >= transpositionsequences%(transpositionsequence%+1,0) AND transpositionsequences%(transpositionsequence%+1,0) <> 0 THEN
- transpositionsequence% += 1
- ENDIF
- transposition% = transpositionsequences%(transpositionsequence%,1)
- :
- FOR count% = 1 TO contoursize%
- samplenote% += 1
- IF samplenote% > samplesize% THEN samplenote% = 1
- group%(count%) = sample%(samplenote%) + transposition%
- NEXT
- :
- IF seriesnote% >= octavesequences%(octavesequence%+1,0,0) AND octavesequences%(octavesequence%+1,0,0) <> 0 THEN
- octavesequence% += 1
- octaveloop%() = 0
- ENDIF
- :
- FOR count% = 1 TO contoursize%
- pitchclass% = group%(count%)
- REPEAT
- pitchclass% -= 48
- UNTIL pitchclass% < 51
- pitchclass% -= 2
- octaveloop%(pitchclass%) += 1
- IF octaveloop%(pitchclass%) > octavesequences%(octavesequence%,pitchclass%,0) THEN octaveloop%(pitchclass%) = 1
- oxtave% = octavesequences%(octavesequence%,pitchclass%,octaveloop%(pitchclass%))
- group%(count%) = (pitchclass%+2) + (48*oxtave%)
- NEXT
- :
- IF contoursize% > 1 THEN
- REPEAT
- FOR count% = 1 TO (contoursize%-1)
- IF group%(count%) >= group%(count%+1) THEN
- save% = group%(count%)
- group%(count%) = group%(count%+1)
- group%(count%+1) = save%
- ENDIF
- NEXT
- no% = 0
- FOR count% = 1 TO (contoursize%-1)
- IF group%(count%) > group%(count%+1) THEN no% = 1
- NEXT
- UNTIL no% = 0
- ENDIF
- :
- FOR count% = 1 TO contoursize%
- simplenote% = group%(contours%(contour%,count%))
- PROCconvertsimplenote
- pitches%((seriesnote%+count%)-1) = simplenote%
- NEXT
- :
- UNTIL ((seriesnote%+contoursize%)-1) >= numpitches%
- :
- FOR count% = 0 TO numpitches%-1 : pitches%(count%) = pitches%(count%+1) : NEXT
- PRINT'" Do you want to save this pitch string?"
- CASE GET$ OF
- WHEN "Y","y","+" : PROCsavepitchstring
- OTHERWISE
- ENDCASE
- :
- PROCinsertpitches
- :
- ENDPROC
- :
- REM*******************************************************
- :
- DEF PROCcopy
- :
- CLS : OFF
- repeatposit$ = "n"
- IF distort$ = "OFF" THEN dothis$ = "YES"
- IF distort$ = "ON" THEN
- IF distortpara$ = "attacks" THEN dothis$ = "YES" ELSE dothis$ = "NO"
- ENDIF
- IF dothis$ = "YES" THEN
- IF easiermenus$ = "n" THEN
- PRINT'" Copy one note - C "
- PRINT " Copy passage - c "
- PRINT " Move one note - M "
- PRINT " Move passage - m "
- PRINT " Extract - E "
- PRINT " Copy rhythm - R "
- PRINT " Save - S "
- PRINT " Import - I "
- ELSE
- PRINT'" Copy one note - C "
- PRINT '" Copy passage - c "
- PRINT '" Move one note - M "
- PRINT '" Move passage - m "
- PRINT '" Extract - E "
- PRINT '" Copy rhythm - R "
- PRINT '" Save - S "
- PRINT '" Import - I "
- ENDIF
- CASE GET$ OF
- WHEN "c" : copymove$ = "C" : savevoice$ = "N" : justone$ = "n"
- WHEN "m" : copymove$ = "M" : savevoice$ = "N" : justone$ = "n"
- WHEN "C" : copymove$ = "C" : savevoice$ = "N" : justone$ = "y"
- WHEN "M" : copymove$ = "M" : savevoice$ = "N" : justone$ = "y"
- WHEN "E","e" :
- CLS : PRINT'" Copy-extract or move-extract? (C/M) "
- CASE GET$ OF
- WHEN "C","c" : copymove$ = "EC" : justone$ = "n"
- OTHERWISE copymove$ = "EM" : justone$ = "n"
- ENDCASE
- savevoice$ = "N"
- WHEN "R","r" : PROCcopyrhythm
- WHEN "S","s" : copymove$ = "C" : savevoice$ = "Y"
- WHEN "I","i" : copymove$ = "C" : savevoice$ = "N" : PROCimportvoice
- OTHERWISE
- copymove$ = "C" : savevoice$ = "N" : justone$ = "n"
- ENDCASE
- ELSE copymove$ = "C"
- ENDIF
- :
- PROCcopy2
- IF quickextract$ = "y" THEN quickextract$ = "n"
- :
- ENDPROC
- :
- *******************************************************************
- :
- DEF PROCcopy2
- :
- IF easiermenus$ = "n" THEN PROCwindow(20,69,67,54) ELSE PROCwindow(20,69,67,42)
- CLS
- :
- IF quickcopy$ = "n" THEN
- :
- IF screenvoices$ = "n" THEN
- INPUT'" Which voice? (0 = 1) "voice%
- IF voice% = 0 THEN PROCpressenter
- ELSE
- PRINT'" Which screen voice "
- CASE GET$ OF
- WHEN "1" : voice% = 1
- WHEN "2" : voice% = 2
- WHEN "3" : voice% = 3
- OTHERWISE PROCpressenter
- ENDCASE
- ENDIF
- :
- IF copymove$ = "EC" OR copymove$ = "EM" THEN
- IF screenvoices$ = "y" THEN extractvoice% = displayvoices%(startv%+voice%-1) ELSE extractvoice% = voice%
- ENDIF : REM copymove$
- :
- IF screenvoices$ = "y" THEN voice% = displayvoices%(startv%+voice%-1)
- voice% -= 1
- samevoice% = voice%
- :
- CLS
- INPUT'" Starting at bar "copystartbar%
- IF copystartbar% = 0 THEN
- copystartbar% = holdbar1% : copystartbeat% = holdbeat1% : repeatposit$ = "y"
- ENDIF
- holdbar% = copystartbar%
- holdbar1% = copystartbar%
- IF repeatposit$ = "y" THEN
- PRINT'" bar ";copystartbar%;" beat ";copystartbeat%;"?"
- PRINT'" (for OK press 0, if not OK press X)"
- CASE GET$ OF
- WHEN"X","x" : PROCcopy
- OTHERWISE
- ENDCASE
- ELSE
- INPUT" beat "beats%
- PROCalterbeats : copystartbeat% = beats%
- holdbeat% = copystartbeat%
- holdbeat1% = copystartbeat%
- ENDIF : REM repeatposit$
- :
- IF justone$ = "n" THEN
- PRINT'" Ending at bar "
- PRINT '" (for last bar press 0, for previous "
- INPUT " last bar press 0 twice) "copyendbar%
- IF copyendbar% > 0 THEN savethisbar% = copyendbar%
- IF copyendbar% > 0 THEN
- INPUT " beat "beats%
- PROCalterbeats : copyendbeat% = beats% : savethisbeats% = beats%
- :
- ELSE
- thing$ = INKEY$(50)
- IF thing$ <> "" THEN
- copyendbar% = savethisbar% : copyendbeat% = savethisbeats%
- COLOUR 3
- PRINT'" bar ";copyendbar%;" beat ";copyendbeat%;"?"
- COLOUR 0
- PRINT '" (for OK press 0, if not OK press X)"
- CASE GET$ OF
- WHEN "X","x" : PROCcopy2
- OTHERWISE
- ENDCASE
- ENDIF : REM thing$
- :
- ENDIF : REM copyendbar%
- :
- ELSE
- copyendbar% = copystartbar%
- copyendbeat% = copystartbeat%
- ENDIF : REM justone$
- :
- IF copymove$ = "EC" OR copymove$ = "EM" THEN PROCextractinfo
- :
- ELSE : REM quickcopy$
- :
- IF screenvoices$ = "n" THEN
- :
- IF copysuccessively$ = "n" THEN
- INPUT ' ' " Which voice? (0 = top) "voice%
- :
- IF voice% = 0 THEN
- :
- IF nodelay$ = "y" THEN voice% = displayvoices%(startv%) ELSE PROCpressenter
- :
- ENDIF : REM voice%
- :
- ELSE PROCcopysuccessively: REM copysuccessively
- :
- ENDIF : REM copysuccessively
- :
- ELSE : REM screenvoices$
- PRINT'" Which screen voice "
- CASE GET$ OF
- WHEN "1" : voice% = 1
- WHEN "2" : voice% = 2
- WHEN "3" : voice% = 3
- WHEN "x" : voice% = 1
- OTHERWISE PROCpressenter
- ENDCASE
- ENDIF : REM screenvoices$
- :
- IF copymove$ = "EC" OR copymove$ = "EM" THEN
- IF screenvoices$ = "y" THEN extractvoice% = displayvoices%(startv%+voice%-1) ELSE extractvoice% = voice%
- ENDIF : REM copymove$
- :
- IF screenvoices$ = "y" AND quickextract$ = "n" THEN voice% = displayvoices%(startv%+voice%-1)
- voice% -= 1 : samevoice% = voice%
- :
- PRINT ' " note number "
- PRINT ' " (for first type 0) "
- CASE GET$ OF
- WHEN "1" : along% = 1
- WHEN "2" : along% = 2
- WHEN "3" : along% = 3
- WHEN "4" : along% = 4
- WHEN "5" : along% = 5
- WHEN "6" : along% = 6
- WHEN "7" : along% = 7
- WHEN "8" : along% = 8
- WHEN "9" : along% = 9
- WHEN "0" : along% = 0
- ENDCASE
- :
- IF along% <> 0 THEN
- :
- another$ = INKEY$(waitafterfirst%)
- IF another$ <> "" THEN
- CASE another$ OF
- WHEN "1" : along% = (along%*10)+1
- WHEN "2" : along% = (along%*10)+2
- WHEN "3" : along% = (along%*10)+3
- WHEN "4" : along% = (along%*10)+4
- WHEN "5" : along% = (along%*10)+5
- WHEN "6" : along% = (along%*10)+6
- WHEN "7" : along% = (along%*10)+7
- WHEN "8" : along% = (along%*10)+8
- WHEN "9" : along% = (along%*10)+9
- WHEN "0" : along% = (along%*10)+0
- ENDCASE
- ENDIF : REM another$
- :
- another$ = INKEY$(waitaftersecond%)
- IF another$ <> "" THEN
- CASE another$ OF
- WHEN "1" : along% = (along%*10)+1
- WHEN "2" : along% = (along%*10)+2
- WHEN "3" : along% = (along%*10)+3
- WHEN "4" : along% = (along%*10)+4
- WHEN "5" : along% = (along%*10)+5
- WHEN "6" : along% = (along%*10)+6
- WHEN "7" : along% = (along%*10)+7
- WHEN "8" : along% = (along%*10)+8
- WHEN "9" : along% = (along%*10)+9
- WHEN "0" : along% = (along%*10)+0
- ENDCASE
- ENDIF : REM another$
- :
- COLOUR 3 : PRINT ' along% : COLOUR 0
- :
- ENDIF : REM along% <> 0
- :
- IF along% = 0 THEN along% = 1
- along%-=1
- copystartbar% = array%(holdstartcell%(voice%)+along%,0,voice%)DIV10^6
- copystartbeat% = (array%(holdstartcell%(voice%)+along%,0,voice%)MOD10^6)DIV10^3
- holdbar% = copystartbar%
- holdbeat% = copystartbeat%
- IF justone$ = "n" THEN
- :
- PRINT'" to note number "
- :
- IF firstasking$ = "y" THEN
- IF copytoend$ = "y" THEN PRINT'" (for last type 0) "
- ELSE
- :
- IF copytoend$ = "y" THEN
- PRINT'" (for last type 0) "
- ELSE
- PRINT'" (for ";prevlast%;" type 0) "
- ENDIF : REM copytoend$
- :
- ENDIF : REM firstasking$
- :
- CASE GET$ OF
- WHEN "1" : along% = 1
- WHEN "2" : along% = 2
- WHEN "3" : along% = 3
- WHEN "4" : along% = 4
- WHEN "5" : along% = 5
- WHEN "6" : along% = 6
- WHEN "7" : along% = 7
- WHEN "8" : along% = 8
- WHEN "9" : along% = 9
- WHEN "0" :
- IF copytoend$ = "y" THEN
- along% = 0
- ELSE
- along% = prevlast% : usedprev$ = "y"
- ENDIF : REM copytoend$
- OTHERWISE
- IF copytoend$ = "y" THEN
- along% = 0
- ELSE
- IF firstasking$ = "y" THEN
- CLS : COLOUR 3
- PRINT'" COPYING TO END NOT ENABLED "
- COLOUR 0
- PRINT '" (press a key to continue)"
- prevlast% = 0
- CASE GET$ OF
- ENDCASE
- ELSE
- along% = prevlast% : usedprev$ = "y"
- ENDIF : REM firstasking$
- ENDIF : REM copytoend$
- ENDCASE
- firstasking$ = "n"
- :
- IF along% <> 0 AND usedprev$ = "n" THEN
- :
- another$ = INKEY$(waitafterfirst%)
- IF another$ <> "" THEN
- CASE another$ OF
- WHEN "1" : along% = (along%*10)+1
- WHEN "2" : along% = (along%*10)+2
- WHEN "3" : along% = (along%*10)+3
- WHEN "4" : along% = (along%*10)+4
- WHEN "5" : along% = (along%*10)+5
- WHEN "6" : along% = (along%*10)+6
- WHEN "7" : along% = (along%*10)+7
- WHEN "8" : along% = (along%*10)+8
- WHEN "9" : along% = (along%*10)+9
- WHEN "0" : along% = (along%*10)+0
- ENDCASE
- ENDIF : REM another$
- :
- another$ = INKEY$(waitaftersecond%)
- IF another$ <> "" THEN
- CASE another$ OF
- WHEN "1" : along% = (along%*10)+1
- WHEN "2" : along% = (along%*10)+2
- WHEN "3" : along% = (along%*10)+3
- WHEN "4" : along% = (along%*10)+4
- WHEN "5" : along% = (along%*10)+5
- WHEN "6" : along% = (along%*10)+6
- WHEN "7" : along% = (along%*10)+7
- WHEN "8" : along% = (along%*10)+8
- WHEN "9" : along% = (along%*10)+9
- WHEN "0" : along% = (along%*10)+0
- ENDCASE
- ENDIF : REM another$
- :
- prevlast% = along%
- COLOUR 3 : PRINT ' along% : COLOUR 0
- wait$ = INKEY$(50)
- :
- ENDIF : REM along% <> 0
- :
- usedprev$ = "n"
- :
- IF along% = 0 THEN
- copyendbar% = 0
- ELSE
- along%-=1
- copyendbar% = array%(holdstartcell%(voice%)+along%,0,voice%)DIV10^6
- copyendbeat% = (array%(holdstartcell%(voice%)+along%,0,voice%)MOD10^6)DIV10^3
- ENDIF : REM along$
- ELSE
- copyendbar% = copystartbar%
- copyendbeat% = copystartbeat%
- ENDIF : REM justone$ = "n"
- :
- IF copymove$ = "EC" OR copymove$ = "EM" THEN PROCextractinfo
- :
- ENDIF : REM quickcopy$ = "n"
- :
- :
- value% = (copystartbar%*10^3)+copystartbeat%
- IF value% <= array%(0,0,voice%)DIV10^3 THEN
- startatcell% = 0
- ELSE
- PROCsearch(value%)
- startatcell% = startcell%
- ENDIF : REM value%
- :
- IF copyendbar% = 0 THEN
- endatcell% = numusedcells%(voice%) - 1
- ELSE
- value% = (copyendbar%*10^3)+copyendbeat%
- IF value% >= array%(numusedcells%(voice%)-1,0,voice%)DIV10^3 THEN
- endatcell% = numusedcells%(voice%) - 1
- ELSE
- PROCsearch(value%)
- IF shunt$ = "N" THEN endatcell% = startcell% ELSE endatcell% = startcell% - 1
- ENDIF : REM value%
- :
- ENDIF : REM copyendbar%
- :
- manyattacks% = endatcell% - startatcell% + 1
- REM create 'gap' between beat-of-bar and first actual attack
- carrybars% = (array%(startatcell%,0,voice%)DIV10^6)-copystartbar%
- carrybeats% = ((array%(startatcell%,0,voice%)DIV10^3)MOD10^3)-copystartbeat%
- attacks1%(0) = (carrybars%*960)+carrybeats%
- :
- IF copymove$ = "C" OR copymove$ = "M" THEN
- FOR count% = 0 TO (manyattacks%-1)
- IF count% > 0 THEN
- carrybars% = (array%(startatcell%+count%,0,voice%)DIV10^6)-(array%(startatcell%+count%-1,0,voice%)DIV10^6)
- carrybeats% = ((array%(startatcell%+count%,0,voice%)DIV10^3)MOD10^3)-((array%(startatcell%+count%-1,0,voice%)DIV10^3)MOD10^3)
- attacks1%(count%) = attacks1%(count%-1) + ((carrybars%*960)+carrybeats%)
- ENDIF : REM count% > 0
- :
- pitches%(count%) = array%(startatcell%+count%,0,voice%)MOD10^3
- dur% = (array%(startatcell%+count%,1,voice%)DIV10)MOD10^3
- brrr% = array%(startatcell%+count%,0,voice%)DIV10^6 : PROCreconvertdur
- durations%(count%) = dur%
- amplitudes%(count%) = (array%(startatcell%+count%,1,voice%))MOD10
- envelopes%(count%) = (array%(startatcell%+count%,2,voice%))DIV10^2
- glissandos%(count%) = array%(startatcell%+count%,1,voice%)DIV10^4
- inflections%(count%) = array%(startatcell%+count%,2,voice%)MOD10^2
- NEXT
- ELSE
- :
- PROCextract
- :
- ENDIF : REM copymove$
- :
- IF copymove$ = "M" THEN
- numnotes% = manyattacks% : startcell% = startatcell%
- FOR count% = startcell% TO (startcell%+(numnotes%-1))
- FOR counter% = 0 TO 1
- barno% = (array%(count%,0,voice%)DIV10^6)-counter%
- beatnum% = ((array%(count%,0,voice%)DIV10^3)MOD10^3)
- :
- group1start% = (disarray%(barno%,0,voice%)DIV10^7)*beatfactor%
- group1end% = group1start% + (((disarray%(barno%,0,voice%)DIV10^5)MOD10^2)*beatfactor%)-1
- IF beatnum%+(960*counter%) >= group1start% AND beatnum%+(960*counter%) <= group1end% THEN
- disarray%(barno%,0,voice%) = disarray%(barno%,0,voice%)MOD10^3
- ENDIF : REM beatnum%
- :
- group2start% = ((disarray%(barno%,0,voice%)DIV10)MOD10^2)*beatfactor%
- group2end% = group2start%+((((disarray%(barno%,0,voice%)MOD10)*10)+(disarray%(barno%,1,voice%)DIV10^8))*beatfactor%)-1
- IF beatnum%+(960*counter%) >= group2start% AND beatnum%+(960*counter%) <= group2end% THEN
- disarray%(barno%,0,voice%) = (disarray%(barno%,0,voice%)DIV10^3)*10^3
- disarray%(barno%,1,voice%) = disarray%(barno%,1,voice%)MOD10^6
- ENDIF : REM beatnum%
- group3start%=((disarray%(barno%,1,voice%)DIV10^4)MOD10^2)*beatfactor%
- group3end% = group3start% + (((disarray%(barno%,1,voice%)MOD10^4)DIV10^2)*beatfactor%)-1
- IF beatnum%+(960*counter%) >= group3start% AND beatnum%+(960*counter%) <= group3end% THEN
- disarray%(barno%,1,voice%) = (disarray%(barno%,1,voice%)DIV10^6)*10^6
- ENDIF : REM beatnum%
- group4start% = (disarray%(barno%,2,voice%)DIV10^7)*beatfactor%
- group4end% = group4start%+(((disarray%(barno%,2,voice%)DIV10^5)MOD10^2)*beatfactor%)-1
- IF beatnum%+(960*counter%) >= group4start% AND beatnum%+(960*counter%) <= group4end% THEN
- disarray%(barno%,2,voice%) = disarray%(barno%,2,voice%)MOD10^3
- ENDIF : REM beatnum%
- group5start% = ((disarray%(barno%,2,voice%)MOD10^3)DIV10)*beatfactor%
- group5end% = group5start%+((((disarray%(barno%,2,voice%)MOD10)*10)+(disarray%(barno%,3,voice%)DIV10^8))*beatfactor%)-1
- IF beatnum%+(960*counter%) >= group5start% AND beatnum%+(960*counter%) <= group5end% THEN
- disarray%(barno%,2,voice%) = (disarray%(barno%,2,voice%)DIV10^3)*10^3
- disarray%(barno%,3,voice%) = disarray%(barno%,3,voice%)MOD10^6
- ENDIF : REM beatnum%
- group6start% = ((disarray%(barno%,3,voice%)DIV10^4)MOD10^2)*beatfactor%
- group6end% = group6start% + (((disarray%(barno%,3,voice%)DIV10^2)MOD10^2)*beatfactor%)-1
- IF beatnum%+(960*counter%) >= group6start% AND beatnum%+(960*counter%) <= group6end% THEN
- disarray%(barno%,3,voice%)=(disarray%(barno%,3,voice%)DIV10^6)*10^6
- ENDIF : REM beatnum%
- :
- NEXT
- :
- NEXT : REM count%
- :
- PROCshuntleft(startcell%,numnotes%)
- ENDIF : REM copymove$
- :
- IF distort$ = "OFF" THEN
- numpitches% = manyattacks% : numdurations% = manyattacks% : numamplitudes% = manyattacks%
- numenvelopes% = manyattacks% : numinflections% = manyattacks% : method$ = "raw" : copyit$ = "ON"
- IF seeequalize$ = "y" THEN seeequalizey$ = "y"
- IF seereorder$ = "y" THEN seereordery$ = "y"
- PROCinsertattacks
- ELSE
- PROCdistort
- ENDIF : REM distort$
- :
- $ = "n" : quickextract$ = "n" : usedprev$ = "n"
- ENDPROC
- :
- REM**************************************************************
- :
- DEF PROCdistort
- :
- CLS
- CASE distortpara$ OF
- WHEN "attacks" :
- :
- INPUT'" How many bands? (0 = previous values) "answer%
- IF answer% <> 0 THEN numbands% = answer%
- :
- IF answer% > 0 THEN
- IF answer% = 1 THEN
- PRINT'" intervals to be multiplied by"
- PRINT" random percentages between..."
- PRINT '"(for ";distortparas%(1,2);
- INPUT" press 0) "number%
- IF number% = 0 THEN distortparas%(1,2) = distortparas%(1,2) ELSE distortparas%(1,2) = number%
- PRINT'" and...(for ";distortparas%(1,3);
- INPUT " press 0) "number%
- IF number% = 0 THEN distortparas%(1,3) = distortparas%(1,3) ELSE distortparas%(1,3) = number%
- distortparas%(1,0) = 0 : distortparas%(1,1) = 960000
- :
- ELSE
- :
- FOR count% = 1 TO numbands%
- CLS
- PRINT'" Band ";count%;"'s intervals are between (incl.) "
- INPUT'" bars..."bars%
- INPUT " beats..."beats%
- PROCalterbeats
- distortparas%(count%,0) = (bars%*960) + beats%
- INPUT " and bars..."bars%
- INPUT " beats..."beats%
- PROCalterbeats
- distortparas%(count%,1) = (bars%*960) + beats%
- PRINT'" which are to be multiplied by random "
- INPUT" percentages between..."distortparas%(count%,2)
- INPUT" and..."distortparas%(count%,3)
- NEXT
- :
- ENDIF
- ELSE
- COLOUR 3
- PRINT'" values as last time?"
- PRINT'distortparas%(1,0);" - ";distortparas%(1,1);" ";distortparas%(1,2);"% - ";distortparas%(1,3)"%"
- IF numbands% > 1 THEN PRINT distortparas%(2,0);" - ";distortparas%(2,1);" ";distortparas%(2,2);"% - ";distortparas%(2,3)"%"
- COLOUR 0
- CASE GET$ OF
- WHEN"y","Y":
- OTHERWISE
- ENDCASE
- ENDIF
- :
- nextinterval% = attacks1%(1) - attacks1%(0)
- FOR count% = 1 TO manyattacks% - 1
- :
- interval% = nextinterval%
- :
- band% = 0
- FOR counter% = 1 TO numbands%
- IF interval% >= distortparas%(counter%,0) AND interval% <= distortparas%(counter%,1) THEN band% = counter%
- NEXT
- :
- IF band% > 0 THEN percentage1% = distortparas%(band%,2) ELSE percentage1% = 100
- IF band% > 0 THEN percentage2% = distortparas%(band%,3) ELSE percentage2% = 100
- range% = percentage2%-percentage1%
- IF range% = 0 THEN
- percentage3 = percentage1%
- ELSE
- percentage3 = RND(range%) + percentage1% - 1
- percentage3 += (RND(99))/100
- ENDIF
- :
- nextinterval% = attacks1%(count%+1) - attacks1%(count%)
- attacks1%(count%) = attacks1%(count%-1) + ((interval%*percentage3)DIV100)
- :
- NEXT
- :
- method$ = "raw" : copyit$ = "ON" : distort$ = "OFF"
- PROCinsertattacks
- :
- WHEN "pitches" :
- :
- PROCwindow(20,69,70,54)
- PRINT'" Is the grid semi-, quarter- or eighthtone (S/Q/E)"
- PRINT'" (0 = previous) "
- CASE GET$ OF
- WHEN "S","s" : distortgrid$ = "S"
- WHEN "Q","q" : distortgrid$ = "Q"
- WHEN "E","e" : distortgrid$ = "E"
- OTHERWISE distortgrid$ = distortgrid$
- ENDCASE
- :
- INPUT'" How many bands? (0 = 1) "numbands%
- IF numbands% = 0 THEN numbands% = 1
- :
- IF numbands% = 1 THEN
- distortparas%(1,0) = 0
- distortparas%(1,1) = 1000
- PRINT'" Pitches are to be raised/lowered randomly by"
- PRINT " between how many ";
- CASE distortgrid$ OF
- WHEN "S" : PRINT"semitones (-1,1 etc) "
- INPUT" (11 = previous) "distortparas%(1,2)
- IF distortparas%(1,2) = 11 THEN
- distortparas%(1,2) = previousdistort1%
- COLOUR 3
- PRINT' previousdistort1%
- COLOUR 0
- ENDIF
- WHEN "Q" : PRINT"quartertones (-1,1 etc) "
- INPUT" (0 = previous) "distortparas%(1,2)
- IF distortparas%(1,2) = 0 THEN
- distortparas%(1,2) = previousdistort1%
- COLOUR 3
- PRINT' previousdistort1%
- COLOUR 0
- ENDIF
- WHEN "E" : INPUT"eighthtones (-1,1 etc) "distortparas%(1,2)
- ENDCASE
- PRINT '" and how many ";
- CASE distortgrid$ OF
- WHEN "S" : INPUT"semitones "distortparas%(1,3)
- IF distortparas%(1,3) = 11 THEN
- distortparas%(1,3) = previousdistort2%
- COLOUR 3
- PRINT ' previousdistort2%
- COLOUR 0
- pause$ = INKEY$(50)
- ENDIF
- WHEN "Q" : INPUT"quartertones "distortparas%(1,3)
- IF distortparas%(1,3) = 0 THEN
- distortparas%(1,3) = previousdistort2%
- COLOUR 3
- PRINT' previousdistort2%
- COLOUR 0
- pause$ = INKEY$(50)
- ENDIF
- WHEN "E" : INPUT"eighthtones "distortparas%(1,3)
- ENDCASE
- previousdistort1% = distortparas%(1,2)
- previousdistort2% = distortparas%(1,3)
- :
- ELSE
- :
- FOR count% = 1 TO numbands%
- PRINT'" Band ";count%;" is from the ";
- FOR counter% = 0 TO 1
- IF counter% = 0 THEN PRINT"lower note" ELSE PRINT'"to the upper note"
- PRINT'" pitchclass ";
- COLOUR 3
- CASE GET$ OF
- WHEN "C","c" : note% = 4 : PRINT "C"
- WHEN "D","d" : note% = 12 : PRINT "D"
- WHEN "E","e" : note% = 20 : PRINT "E"
- WHEN "F","f" : note% = 24 : PRINT "F"
- WHEN "G","g" : note% = 32 : PRINT "G"
- WHEN "A","a" : note% = 40 : PRINT "A"
- WHEN "B","b" : note% = 48 : PRINT "B"
- OTHERWISE VDU 7 : PROCdistort
- ENDCASE
- COLOUR 0
- PRINT" accidental ";
- COLOUR 3
- CASE GET$ OF
- WHEN "1" : note% -= 4 : PRINT "flat"
- WHEN "2" : note% -= 3 : PRINT "3/8 flat"
- WHEN "3" : note% -= 2 : PRINT "1/4 flat"
- WHEN "4" : note% -= 1 : PRINT "1/8 flat"
- WHEN "5" : note% -= 0 : PRINT "nat"
- WHEN "6" : note% += 1 : PRINT "1/8 shrp"
- WHEN "7" : note% += 2 : PRINT "1/4 shrp"
- WHEN "8" : note% += 3 : PRINT "3/8 shrp"
- WHEN "9" : note% += 4 : PRINT "shrp"
- ENDCASE
- COLOUR 0
- PRINT" octave ";
- COLOUR 3
- oct% = VAL(GET$) : oct%=oct%DIV1 : note% += (48*oct%) : PRINT oct%
- COLOUR 0
- distortparas%(count%,counter%) = note%
- NEXT
- :
- PRINT'" and pitches are to be raised/lowered"
- PRINT " randomly by between how many ";
- CASE distortgrid$ OF
- WHEN "S" : INPUT"semitones "distortparas%(count%,2)
- WHEN "Q" : INPUT"quartertones "distortparas%(count%,2)
- WHEN "E" : INPUT"eighthtones "distortparas%(count%,2)
- ENDCASE
- PRINT" and how many ";
- CASE distortgrid$ OF
- WHEN "S" : INPUT"semitones "distortparas%(count%,3)
- WHEN "Q" : INPUT"quartertones "distortparas%(count%,3)
- WHEN "E" : INPUT"eighthtones "distortparas%(count%,3)
- ENDCASE
- :
- NEXT
- :
- ENDIF
- :
- nextpitch% = pitches%(0)
- FOR count% = 0 TO (manyattacks%-1)
- :
- note% = nextpitch%DIV100
- accid% = (nextpitch%DIV10)MOD10
- oct% = nextpitch%MOD10
- CASE note% OF
- WHEN 0 : pitch% = 4
- WHEN 1 : pitch% = 12
- WHEN 2 : pitch% = 20
- WHEN 3 : pitch% = 24
- WHEN 4 : pitch% = 32
- WHEN 5 : pitch% = 40
- WHEN 6 : pitch% = 48
- ENDCASE
- accid% -= 5 : pitch% += accid%
- pitch% += (48*oct%)
- :
- FOR counter% = 1 TO numbands%
- IF pitch%>=distortparas%(counter%,0)ANDpitch%<=distortparas%(counter%,1) THEN band% = counter%
- NEXT
- :
- lower% = distortparas%(band%,2)
- upper% = distortparas%(band%,3)
- x% = 0 - lower%
- range% = upper% + x% + 1
- IF range% = 1 THEN inc% = 1-(x%+1) ELSE inc% = RND(range%)-(x%+1)
- IF distortgrid$ = "S" THEN inc% = inc%*4
- IF distortgrid$ = "Q" THEN inc% = inc%*2
- pitch% += inc%
- :
- FOR counter% = 0 TO 9
- IF pitch% > 2 + (48*counter%) THEN
- octave% = counter%
- ENDIF
- NEXT
- :
- pitch% -= (48*octave%)
- IF pitch% > 2 AND pitch% < 8 THEN
- pitchclass% = 0 : diff% = pitch% - 4
- ENDIF
- IF pitch% > 7 AND pitch% < 16 THEN
- pitchclass% = 1 : diff% = pitch% - 12
- ENDIF
- IF pitch% > 15 AND pitch% < 23 THEN
- pitchclass% = 2 : diff% = pitch% - 20
- ENDIF
- IF pitch% > 22 AND pitch% < 29 THEN
- pitchclass% = 3 : diff% = pitch% - 24
- ENDIF
- IF pitch% > 28 AND pitch% < 36 THEN
- pitchclass% = 4 : diff% = pitch% - 32
- ENDIF
- IF pitch% > 35 AND pitch% < 44 THEN
- pitchclass% = 5 : diff% = pitch% - 40
- ENDIF
- IF pitch% > 43 AND pitch% < 51 THEN
- pitchclass% = 6 : diff% = pitch% - 48
- ENDIF
- accid% = diff% + 5 : nextpitch% = pitches%(count%+1)
- pitches%(count%) = (pitchclass%*100)+(accid%*10)+octave%
- :
- NEXT
- :
- numpitches% = manyattacks%
- distort$ = "OFF" : PROCinsertpitches
- :
- WHEN "durations" :
- :
- PROCwindow(20,69,70,54)
- PRINT'" distort durations between"
- INPUT" what percentage "firstpercent%
- IF firstpercent% = 0 THEN
- PRINT '" that's ";prevfirstpercent%;" then?"
- CASE GET$ OF
- WHEN "Y","y" :
- firstpercent% = prevfirstpercent%
- OTHERWISE firstpercent% = prevfirstpercent%
- ENDCASE
- ENDIF
- INPUT" and what percentage "secondpercent%
- IF secondpercent% = 0 THEN
- PRINT '" that's ";prevsecondpercent%;" then?"
- CASE GET$ OF
- WHEN "Y","y","0" :
- secondpercent% = prevsecondpercent%
- OTHERWISE secondpercent% = prevsecondpercent%
- ENDCASE
- ENDIF
- :
- prevfirstpercent% = firstpercent% : prevsecondpercent% = secondpercent%
- :
- FOR count% = manyattacks% TO 1 STEP -1
- durations%(count%) = durations%(count%-1)
- NEXT
- :
- FOR count% = 1 TO manyattacks%
- multiplier = (RND(secondpercent%-firstpercent%)+firstpercent%)/100
- durations%(count%) = durations%(count%)*multiplier
- NEXT
- :
- FOR count% = 0 TO (manyattacks%-1)
- durations%(count%) = durations%(count%+1)
- NEXT
- durations%(manyattacks%) = 0
- :
- numdurations% = manyattacks%
- distort$ = "OFF" : PROCinsertdurations
- WHEN "amplitudes" :
- :
- PROCwindow(20,69,70,54)
- CLS
- PRINT'" Increase or decrease by 1 notch (I/D) "
- CASE GET$ OF
- WHEN "I","i" :
- FOR count% = 0 TO manyattacks%-1
- IF amplitudes%(count%) < 9 THEN amplitudes%(count%) += 1
- IF envelopes%(count%) <> 9 THEN
- number% = envelopes%(count%) DIV 10^3
- IF number% = 0 THEN numphases% = 1
- IF number% > 0 AND number% < 100 THEN numphases% = 2
- IF number% > 99 THEN numphases% = 3
- CASE numphases% OF
- WHEN 1 :
- IF envelopes%(count%)MOD10 < 9 THEN envelopes%(count%) += 1
- WHEN 2 :
- IF envelopes%(count%)MOD10 < 9 THEN envelopes%(count%) += 1
- IF (envelopes%(count%)DIV10)MOD10 < 9 THEN envelopes%(count%) += 10
- WHEN 3 :
- IF envelopes%(count%)MOD10 < 9 THEN envelopes%(count%) += 1
- IF (envelopes%(count%)DIV10)MOD10 < 9 THEN envelopes%(count%) += 10
- IF (envelopes%(count%)DIV100)MOD10 < 9 THEN envelopes%(count%) += 100
- ENDCASE
- ENDIF
- NEXT
- :
- OTHERWISE
- FOR count% = 0 TO manyattacks%-1
- IF amplitudes%(count%) > 0 THEN amplitudes%(count%) -= 1
- IF envelopes%(count%) <> 9 THEN
- number% = envelopes%(count%) DIV 10^3
- IF number% = 0 THEN numphases% = 1
- IF number% > 0 AND number% < 100 THEN numphases% = 2
- IF number% > 99 THEN numphases% = 3
- :
- CASE numphases% OF
- WHEN 1 :
- IF envelopes%(count%)MOD10 > 0 THEN envelopes%(count%) -= 1
- WHEN 2 :
- IF envelopes%(count%)MOD10 > 0 THEN envelopes%(count%) -= 1
- IF (envelopes%(count%)DIV10)MOD10 > 0 THEN envelopes%(count%) -= 10
- WHEN 3 :
- IF envelopes%(count%)MOD10 > 0 THEN envelopes%(count%) -= 1
- IF (envelopes%(count%)DIV10)MOD10 > 0 THEN envelopes%(count%) -= 10
- IF (envelopes%(count%)DIV100)MOD10 > 0 THEN envelopes%(count%) -= 100
- ENDCASE
- ENDIF
- NEXT
- :
- ENDCASE
- :
- numenvelopes% = manyattacks%
- distort$ = "OFF" : PROCinsertenvelopes
- :
- WHEN "envelopes" :
- PRINT'" give 1st envelope point random "
- INPUT" percentages between what percentage "firstpercent%
- INPUT" and what percentage "secondpercent%
- :
- FOR count% = manyattacks% TO 1 STEP -1
- envelopes%(count%) = envelopes%(count%-1)
- glissandos%(count%) = glissandos%(count%-1)
- NEXT
- :
- FOR count% = 1 TO manyattacks%
- newpercentage% = RND(secondpercent%-(firstpercent%-1))+(firstpercent%)
- ph2% = envelopes%(count%) DIV 10^5
- amps% = envelopes%(count%) MOD 10^3
- ph1% = newpercentage%
- envelopes%(count%) = (ph2%*10^5)+(ph1%*10^3)+amps%
- glissandos%(count%) = glissandos%(count%)
- :
- NEXT
- :
- IF numphases% = 3 THEN
- :
- PRINT'" give 2nd envelope point random "
- INPUT" percentages between what percentage "firstpercent%
- INPUT" and what percentage "secondpercent%
- :
- FOR count% = 1 TO manyattacks%
- newpercentage% = RND(secondpercent%-(firstpercent%-1))+(firstpercent%)
- ph1% = (envelopes%(count%) DIV 10^3) MOD 10^2
- amps% = envelopes%(count%) MOD 10^3
- ph2% = newpercentage%
- envelopes%(count%) = (ph2%*10^5)+(ph1%*10^3)+amps%
- glissandos%(count%) = glissandos%(count%)
- :
- NEXT
- :
- ENDIF
- :
- FOR count% = 0 TO (manyattacks%-1)
- envelopes%(count%) = envelopes%(count%+1)
- NEXT
- envelopes%(manyattacks%) = 0
- numenvelopes% = manyattacks%
- distort$ = "OFF" : PROCinsertenvelopes
- :
- WHEN "inflections" :
- :
- PROCwindow(20,69,70,55)
- PRINT'" distort inflections up or down "
- PRINT" by up to how many cents "
- INPUT" (max. 49) "cents%
- :
- FOR count% = manyattacks% TO 1 STEP -1
- inflections%(count%) = inflections%(count%-1)
- NEXT
- :
- FOR count% = 1 TO manyattacks%
- :
- REPEAT
- factor% = RND(cents%)
- upordown% = RND(2)
- :
- IF upordown% = 1 THEN
- :
- inflections%(count%) = inflections%(count%)+factor%
- ELSE
- inflections%(count%) = inflections%(count%)-factor% :
- ENDIF
- :
- UNTIL inflections%(count%) > 0 AND inflections%(count%) < 100
- :
- NEXT
- :
- FOR count% = 0 TO (manyattacks%-1)
- inflections%(count%) = inflections%(count%+1)
- NEXT
- inflections%(manyattacks%) = 0
- :
- numinflections% = manyattacks%
- distort$ = "OFF" : PROCinsertinflections
- :
- ENDCASE
- :
- ENDPROC
- :
- REM****************************************************
- :
- DEF PROCreorderattacks
- :
- r1% = 0
- :
- REM fills attacks3% with original actual durats in beats
- attacks2%() = attacks1%()
- FOR count% = 0 TO manyattacks%-2
- attacks3%(count%) = attacks2%(count%+1)-attacks2%(count%)
- NEXT
- :
- PRINT''" Random or determined order? (R/1 or D)"
- CASE GET$ OF
- WHEN "D","d" :
- CLS
- PRINT''" There are ";manyattacks%-1;" durations in the group"
- FOR count% = 1 TO manyattacks%-1
- PRINT'" New duration ";count%;
- INPUT" is now to be old duration "r%
- attacks1%(count%) = attacks1%(count%-1)+attacks3%(r%-1)
- NEXT
- OTHERWISE
- CLS
- PRINT''" There are ";manyattacks%-1;" durations in the group"
- PRINT'" How many durations do you want to re-order? "
- INPUT " (for all press 0) "howmany%
- IF howmany% = 0 THEN howmany% = manyattacks%-1
- INPUT'" Starting at duration number (0 = 1) "number%
- IF number% = 0 THEN number% = 1
- INPUT'" Chance of repeating original order(%) "chanceofnext%
- attacks2%() = 0 : count% = number%
- REPEAT
- PROCchoosenext
- IF choosenext$ = "y" AND r1% < howmany% THEN
- r1% = r1% + 1
- ELSE
- r1% = RND(howmany%)
- ENDIF
- r% = r1%+number%-1
- IF attacks2%(r%) = 0 THEN
- attacks1%(count%) = attacks1%(count%-1)+attacks3%(r%-1)
- attacks2%(r%) = 1 : count% += 1
- ENDIF
- UNTIL count% = howmany%+number%
- ENDCASE
- :
- reordered$ = "y" : seereordery$ = "n"
- PROCinsertattacks
- :
- ENDPROC
- :
- REM********************************************************
- :
- DEF PROCchoosenext
- :
- numb% = RND(100)
- IF numb% >= chanceofnext% THEN choosenext$ = "n" ELSE choosenext$ = "y"
- ENDPROC
- :
- REM********************************************************
- :
- DEF PROCsavepitchstring
- :
- *Dir SDFS::RISCOSpi.$.CAC.Files
- firstnaming$ = "n"
- CLS
- IF filenamestg$ = "" THEN
- INPUT'" filename "filenamestg$
- firstnaming$ = "y"
- ENDIF
- IF firstnaming$ = "n" THEN
- PRINT'" as '";filenamestg$;"'?"
- CASE GET$ OF
- WHEN "Y","y","+" :
- OTHERWISE INPUT'" filename "filenamestg$
- ENDCASE
- ENDIF
- :
- channel = OPENOUT filenamestg$
- PRINT#channel, numpitches%
- PRINT#channel, grid$
- PRINT#channel, samplesize%
- PRINT#channel, octavesections%
- PRINT#channel, transpositionsections%
- PRINT#channel, contoursections%
- FOR a% = 0 TO samplesize%
- PRINT#channel, sample%(a%)
- NEXT
- FOR a% = 0 TO octavesections%
- FOR b% = 0 TO 48
- FOR c% = 0 TO 11
- PRINT#channel, octavesequences%(a%,b%,c%)
- NEXT
- NEXT
- NEXT
- FOR a% = 0 TO transpositionsections%
- FOR b% = 0 TO 1
- PRINT#channel, transpositionsequences%(a%,b%)
- NEXT
- NEXT
- FOR a% = 0 TO contoursections%
- FOR b% = 0 TO 11
- PRINT#channel, contoursequences%(a%,b%)
- NEXT
- NEXT
- :
- CLOSE#channel
- *NoDir
- :
- ENDPROC
- :
- REM***************************************************
- :
- DEF PROCloadpitchstring
- :
- *Dir SDFS::RISCOSpi.$.CAC.Files
- INPUT'" filename "filenamestg$
- channel = OPENIN filenamestg$
- REPEAT
- INPUT#channel, numpitches%
- INPUT#channel, grid$
- INPUT#channel, samplesize%
- INPUT#channel, octavesections%
- INPUT#channel, transpositionsections%
- INPUT#channel, contoursections%
- FOR a% = 0 TO samplesize%
- INPUT#channel, sample%(a%)
- NEXT
- FOR a% = 0 TO octavesections%
- FOR b% = 0 TO 48
- FOR c% = 0 TO 11
- INPUT#channel, octavesequences%(a%,b%,c%)
- NEXT
- NEXT
- NEXT
- FOR a% = 0 TO transpositionsections%
- FOR b% = 0 TO 1
- INPUT#channel, transpositionsequences%(a%,b%)
- NEXT
- NEXT
- FOR a% = 0 TO contoursections%
- FOR b% = 0 TO 11
- INPUT#channel, contoursequences%(a%,b%)
- NEXT
- NEXT
- UNTIL EOF#channel
- CLOSE#channel
- *NoDir
- :
- ENDPROC
- :
- REM*****************************************************
- :
- DEF PROCeditpitchstring
- :
- IF loadstring$ = "y" THEN PROCloadpitchstring
- :
- PRINT'" Change number of notes in the"
- PRINT " pitch string? (Y/+ OR N/return)"
- PRINT'" (currently ";numpitches%;")"
- CASE GET$ OF
- WHEN "Y","y","+","=" : do$ = "y"
- OTHERWISE do$ = "n"
- ENDCASE
- IF do$ = "y" THEN
- PRINT'" Total number of notes in the"
- INPUT " pitch string (inc. sample) "numpitches%
- ENDIF
- CLS
- :
- PRINT'" Change the sample?"
- PRINT'" currently "
- FOR count% = 1 TO samplesize%
- x% = sample%(count%)
- WHILE x% > 52
- x% -= 48
- ENDWHILE
- CASE x% OF
- WHEN 5 : PRINT count%;". C nat"
- WHEN 9 : PRINT count%;". C shrp"
- WHEN 13 : PRINT count%;". D nat"
- WHEN 17 : PRINT count%;". E flat"
- WHEN 21 : PRINT count%;". E nat"
- WHEN 25 : PRINT count%;". F nat"
- WHEN 29 : PRINT count%;". F shrp"
- WHEN 33 : PRINT count%;". G nat"
- WHEN 37 : PRINT count%;". A flat"
- WHEN 41 : PRINT count%;". A nat"
- WHEN 45 : PRINT count%;". B flat"
- WHEN 49 : PRINT count%;". B nat"
- OTHERWISE
- ENDCASE
- NEXT
- REM eighthtones not yet implemented!
- CASE GET$ OF
- WHEN "Y","y","+","=" : do$ = "y"
- OTHERWISE do$ = "n"
- ENDCASE
- IF do$ = "y" THEN
- PRINT'" Change the number of notes in the sample?"
- PRINT'" Currently ";samplesize%
- CASE GET$ OF
- WHEN "Y","y","+" : do$ = "y"
- OTHERWISE do$ = "n"
- ENDCASE
- IF do$ = "y" THEN
- INPUT'" How many notes in the sample? "samplesize%
- ENDIF
- PRINT'" Change any of the sample's notes?"
- CASE GET$ OF
- WHEN "Y","y","+" : do$ = "y"
- OTHERWISE do$ = "n"
- ENDCASE
- IF do$ = "y" THEN
- INPUT'" How many "x%
- FOR count% = 1 TO x%
- IF x% < samplesize% THEN
- PRINT'" note ";count%;" is note number "
- INPUT y%
- PRINT'" this note is now pitchclass ";
- ELSE
- y% = count%
- PRINT'" note ";count%;" is now pitchclass ";
- ENDIF
- COLOUR 3
- CASE GET$ OF
- WHEN "C","c" : samplenote% = 0 : PRINT "C"
- WHEN "D","d" : samplenote% = 1 : PRINT "D"
- WHEN "E","e" : samplenote% = 2 : PRINT "E"
- WHEN "F","f" : samplenote% = 3 : PRINT "F"
- WHEN "G","g" : samplenote% = 4 : PRINT "G"
- WHEN "A","a" : samplenote% = 5 : PRINT "A"
- WHEN "B","b" : samplenote% = 6 : PRINT "B"
- ENDCASE
- samplenote% = samplenote%*100
- COLOUR 0
- PRINT " accidental ";
- COLOUR 3
- CASE GET$ OF
- WHEN "1" : samplenote% += 10 : PRINT "flat"
- WHEN "2" : samplenote% += 20 : PRINT "3/8 flat"
- WHEN "3" : samplenote% += 30 : PRINT "1/4 flat"
- WHEN "4" : samplenote% += 40 : PRINT "1/8 flat"
- WHEN "5" : samplenote% += 50 : PRINT "nat"
- WHEN "6" : samplenote% += 60 : PRINT "1/8 shrp"
- WHEN "7" : samplenote% += 70 : PRINT "1/4 shrp"
- WHEN "8" : samplenote% += 80 : PRINT "3/8 shrp"
- WHEN "9" : samplenote% += 90 : PRINT "shrp"
- ENDCASE
- COLOUR 0
- samplenote% += 5
- PROCconvertsamplenote
- sample%(y%) = samplenote%
- :
- NEXT
- ENDIF
- :
- ENDIF
- :
- CLS
- PRINT'" Make changes to the octave sequences?"
- PRINT'" Currently"
- VDU 14
- FOR a% = 1 TO octavesections%
- FOR b% = 3 TO 47 STEP 4
- FOR c% = 1 TO 11
- IF b% = 3 AND c% = 1 THEN PRINT'" C nat"
- IF b% = 7 AND c% = 1 THEN PRINT'" C shrp"
- IF b% = 11 AND c% = 1 THEN PRINT'" D nat"
- IF b% = 15 AND c% = 1 THEN PRINT'" E flat"
- IF b% = 19 AND c% = 1 THEN PRINT'" E nat"
- IF b% = 23 AND c% = 1 THEN PRINT'" F nat"
- IF b% = 27 AND c% = 1 THEN PRINT'" F shrp"
- IF b% = 31 AND c% = 1 THEN PRINT'" G nat"
- IF b% = 35 AND c% = 1 THEN PRINT'" A flat"
- IF b% = 39 AND c% = 1 THEN PRINT'" A nat"
- IF b% = 43 AND c% = 1 THEN PRINT'" B flat"
- IF b% = 47 AND c% = 1 THEN PRINT'" B nat"
- IF octavesequences%(a%,b%,c%) > 0 THEN PRINT octavesequences%(a%,b%,c%)
- NEXT
- NEXT
- NEXT
- VDU 15
- CASE GET$ OF
- WHEN "Y","y","+" : do$ = "y"
- OTHERWISE do$ = "n"
- ENDCASE
- IF do$ = "y" THEN
- PRINT'" Change the number of sections of "
- PRINT" octave sequences?"
- CASE GET$ OF
- WHEN "Y","y","+" : do$ = "y"
- OTHERWISE do$ = "n"
- ENDCASE
- IF do$ = "y" THEN
- PRINT'" How many different sections of"
- INPUT " octave sequences are there "octavesections%
- ENDIF
- IF octavesections% > 1 THEN
- PRINT'" Change the starting point of"
- PRINT" any sections?"
- CASE GET$ OF
- WHEN "Y","y","+" : do$ = "y"
- OTHERWISE do$ = "n"
- ENDCASE
- IF do$ = "y" THEN
- INPUT'" How many "z%
- FOR count% = 1 TO z%
- PRINT'" section ";count%;" is section "
- INPUT y%
- PRINT'" this section now begins at note number "
- INPUT x%
- octavesequences%(y%,0,0) = x%
- NEXT
- ENDIF
- ENDIF
- :
- PRINT'" Make changes to the actual octave"
- PRINT" sequences?"
- CASE GET$ OF
- WHEN "Y","y","+" : do$ = "y"
- OTHERWISE do$ = "n"
- ENDCASE
- IF do$ = "y" THEN
- FOR count% = 1 TO octavesections%
- PRINT'" Any changes to section ";count%
- CASE GET$ OF
- WHEN "Y","y","+" : do$ = "y"
- OTHERWISE do$ = "n"
- ENDCASE
- IF do$ = "y" THEN
- FOR pitch% = 0 TO 47
- entry$ = "n"
- IF pitch% MOD 4 = 0 AND grid$<>"s" THEN entry$ = "y"
- IF (pitch%-2)MOD4 = 0 THEN entry$ = "y"
- IF (pitch%-1)MOD2 = 0 AND grid$ = "e" THEN entry$ = "y"
- IF entry$ = "y" THEN
- PRINT'" changes in section ";count%;" to ";
- COLOUR 3 : PRINT pitchnames$(pitch%) : COLOUR 0
- CASE GET$ OF
- WHEN "Y","y","+" : do$ = "y"
- OTHERWISE do$ = "n"
- ENDCASE
- IF do$ = "y" THEN
- PRINT '"In section ";count%;" the sequence of octaves for ";
- COLOUR 3 : PRINT pitchnames$(pitch%)
- COLOUR 0 : PRINT "has how many elements "
- INPUT e%
- PRINT""
- octavesequences%(count%,pitch%+1,0) = e%
- FOR counter% = 1 TO 11
- octavesequences%(count%,pitch%+1,counter%) = 0
- NEXT
- FOR counter% = 1 TO e%
- PRINT " element ";counter%;
- INPUT " is octave "o%
- octavesequences%(count%,pitch%+1,counter%) = o%
- NEXT
- ENDIF
- ENDIF
- NEXT
- ENDIF
- NEXT
- ENDIF
- ENDIF
- :
- CLS
- PRINT'" Make changes to transposition levels?"
- PRINT'" Currently"
- FOR a% = 1 TO transpositionsections%
- PRINT'" section ";a%;". ";transpositionsequences%(a%,1)/4;" semitones starting at note number ";transpositionsequences%(a%,0)
- NEXT
- CASE GET$ OF
- WHEN "Y","y","+" : do$ = "y"
- OTHERWISE do$ = "n"
- ENDCASE
- IF do$ = "y" THEN
- PRINT'" Change the number of sections "
- PRINT" of transposition levels?"
- CASE GET$ OF
- WHEN "Y","y","+" : do$ = "y"
- OTHERWISE do$ = "n"
- ENDCASE
- IF do$ = "y" THEN
- PRINT'" How many different sections of"
- INPUT" transposition are there "transpositionsections%
- ENDIF
- IF transpositionsections% > 1 THEN
- PRINT'" Change the starting point of"
- PRINT" any sections?"
- CASE GET$ OF
- WHEN "Y","y","+" : do$ = "y"
- OTHERWISE do$ = "n"
- ENDCASE
- IF do$ = "y" THEN
- INPUT'" How many "z%
- FOR count% = 1 TO z%
- PRINT'" Section ";count%;" is section "
- INPUT y%
- PRINT'" this section now begins at "
- INPUT " note number "n%
- transpositionsequences%(y%,0) = n%
- NEXT
- ENDIF
- PRINT'" Change the degree of transposition"
- PRINT" of any sections?"
- CASE GET$ OF
- WHEN "Y","y","+" : do$ = "y"
- OTHERWISE do$ = "n"
- ENDCASE
- IF do$ = "y" THEN
- INPUT'" How many "z%
- FOR count% = 1 TO z%
- PRINT'" Section ";count%;" is section "
- INPUT y%
- PRINT'" This section now transposes"
- PRINT" up/down by how many ";
- CASE grid$ OF
- WHEN "e" : PRINT "eighthtones" : INPUT " (+/- 1 etc) "x%
- transpositionsequences%(y%,1) = x%
- WHEN "q" : PRINT "quartertones" : INPUT " (+/- 1 etc) "x%
- transpositionsequences%(y%,1) = x% * 2
- WHEN "s" : PRINT "semitones" : INPUT " (+/- 1 etc) "x%
- transpositionsequences%(y%,1) = x% * 4
- ENDCASE
- NEXT
- ENDIF
- ENDIF
- ENDIF
- :
- CLS
- PRINT'" Make changes to the contour sequences?"
- PRINT'" Currently"
- FOR a% = 1 TO contoursections%
- FOR b% = 2 TO contoursequences%(a%,1)+1
- IF b% = 2 THEN PRINT'" section ";a%
- PRINT contoursequences%(a%,b%)
- NEXT
- NEXT
- CASE GET$ OF
- WHEN "Y","y","+" : do$ = "y"
- OTHERWISE do$ = "n"
- ENDCASE
- IF do$ = "y" THEN
- PRINT'" Change the number of sections?"
- CASE GET$ OF
- WHEN "Y","y","+" : do$ = "y"
- OTHERWISE do$ = "n"
- ENDCASE
- IF do$ = "y" THEN
- PRINT'" How many different sections of "
- INPUT " contour sequences are there "contoursections%
- ENDIF
- IF contoursections%>1 THEN
- PRINT'" Change the starting point"
- PRINT" of any sections?"
- CASE GET$ OF
- WHEN "Y","y","+" : do$ = "y"
- OTHERWISE do$ = "n"
- ENDCASE
- IF do$ = "y" THEN
- INPUT'" How many "z%
- FOR count% = 1 TO z%
- PRINT'" Section ";count%;" is section "
- INPUT y%
- PRINT'" This section"
- INPUT " begins at note number "n%
- contoursequences%(y%,0) = n%
- NEXT
- ENDIF
- ENDIF
- :
- PRINT'" Make changes to any contours?"
- CASE GET$ OF
- WHEN "Y","y","+" : do$ = "y"
- OTHERWISE do$ = "n"
- ENDCASE
- IF do$ = "y" THEN
- FOR count% = 1 TO contoursections%
- PRINT'" Change section ";count%;"?"
- CASE GET$ OF
- WHEN "Y","y","+" : do$ = "y"
- OTHERWISE do$ = "n"
- ENDCASE
- IF do$ = "y" THEN
- PRINT'" In section ";count%;
- INPUT " there are how many contours "c%
- contoursequences%(count%,1) = c%
- PRINT""
- FOR counter% = 1 TO c%
- PRINT " number ";counter%;
- INPUT " is contour "contoor%
- contoursequences%(count%,counter%+1) = contoor%
- NEXT
- ENDIF
- NEXT
- ENDIF
- ENDIF
- :
- PROCdeletesections
- REM this deletes info about sections which existed in
- REM previous versions of the string
- :
- contoursize% = 0 : seriesnote% = 1 : samplenote% = 0
- contoursequence% = 1 : transpositionsequence% = 1
- octavesequence% = 1 : transpositionsequences%(1,1) = 0
- contourloop% = 0 : octaveloop%() = 0
- :
- REPEAT
- seriesnote% += contoursize%
- IF seriesnote% >= contoursequences%(contoursequence%+1,0) AND contoursequences%(contoursequence%+1,0) <> 0 THEN
- contoursequence% += 1
- contourloop% = 0
- ENDIF
- :
- contourloop% += 1
- IF contourloop% > contoursequences%(contoursequence%,1) THEN contourloop% = 1
- contour% = contoursequences%(contoursequence%,contourloop%+1)
- contoursize% = contours%(contour%,0)
- :
- IF seriesnote% >= transpositionsequences%(transpositionsequence%+1,0) AND transpositionsequences%(transpositionsequence%+1,0) <> 0 THEN
- transpositionsequence% += 1
- ENDIF
- transposition% = transpositionsequences%(transpositionsequence%,1)
- :
- FOR count% = 1 TO contoursize%
- samplenote% += 1
- IF samplenote% > samplesize% THEN samplenote% = 1
- group%(count%) = sample%(samplenote%) + transposition%
- NEXT
- :
- IF seriesnote% >= octavesequences%(octavesequence%+1,0,0) AND octavesequences%(octavesequence%+1,0,0) <> 0 THEN
- octavesequence% += 1
- octaveloop%() = 0
- ENDIF
- :
- FOR count% = 1 TO contoursize%
- pitchclass% = group%(count%)
- REPEAT
- pitchclass% -= 48
- UNTIL pitchclass% < 51
- pitchclass% -= 2
- octaveloop%(pitchclass%) += 1
- IF octaveloop%(pitchclass%) > octavesequences%(octavesequence%,pitchclass%,0) THEN octaveloop%(pitchclass%) = 1
- oxtave% = octavesequences%(octavesequence%,pitchclass%,octaveloop%(pitchclass%))
- group%(count%) = (pitchclass%+2) + (48*oxtave%)
- NEXT
- :
- IF contoursize% > 1 THEN
- REPEAT
- FOR count% = 1 TO (contoursize%-1)
- IF group%(count%) >= group%(count%+1) THEN
- save% = group%(count%)
- group%(count%) = group%(count%+1)
- group%(count%+1) = save%
- ENDIF
- NEXT
- no% = 0
- FOR count% = 1 TO (contoursize%-1)
- IF group%(count%) > group%(count%+1) THEN no% = 1
- NEXT
- UNTIL no% = 0
- ENDIF
- :
- FOR count% = 1 TO contoursize%
- simplenote% = group%(contours%(contour%,count%))
- PROCconvertsimplenote
- pitches%((seriesnote%+count%)-1) = simplenote%
- NEXT
- :
- UNTIL ((seriesnote%+contoursize%)-1) >= numpitches%
- :
- FOR count% = 0 TO numpitches%-1 : pitches%(count%) = pitches%(count%+1) : NEXT
- PRINT'" Do you want to save this pitch string?"
- CASE GET$ OF
- WHEN "Y","y","+" : PROCsavepitchstring
- OTHERWISE
- ENDCASE
- :
- PROCinsertpitches
- :
- ENDPROC
- :
- REM************************************************
- :
- :
- DEF PROCdeletesections
- :
- FOR count% = 2 TO 50
- IF count% > octavesections% THEN
- octavesequences%(count%,0,0) = 0
- ENDIF
- NEXT
- :
- FOR count% = 2 TO 199
- IF count% > transpositionsections% THEN
- transpositionsequences%(count%,0) = 0
- ENDIF
- NEXT
- :
- FOR count% = 2 TO 50
- IF count% > contoursections% THEN
- contoursequences%(count%,0) = 0
- ENDIF
- NEXT
- :
- ENDPROC
- :
- REM**************************************************
- :
- DEF PROCyesno
- :
- CASE GET$ OF
- WHEN "Y","y" : on = 1
- OTHERWISE on = 2
- ENDCASE
- :
- ENDPROC
- :
- REM**************************************************
- :
- DEF PROCeditlayers
- :
- chanceoflayer%(1) = 1
- :
- PRINT'" Alter total length? [currently ";totallength%;"]"
- PROCyesno
- IF on = 1 THEN
- INPUT'" Total duration, in BEATS "totallength%
- ENDIF
- PRINT''" LAYERS -"
- PRINT'" Alter number of layers? [currently ";numlayers%;"]"
- PROCyesno
- IF on = 1 THEN
- INPUT'" How many layers "numlayers%
- ENDIF
- :
- PRINT'" Alter contribution proportions"
- PRINT" of the layers?"
- PROCyesno
- IF on = 1 THEN
- REM 1
- :
- PRINT'" Alter number of sections of"
- PRINT" proportions?"
- PROCyesno
- IF on = 1 THEN
- PRINT'" Piece is divided into how many sections"
- PRINT " of different contribution-proportions "
- PRINT " [currently "; numlayersections%;"]"
- INPUT numlayersections%
- ENDIF
- :
- IF numlayersections% > 1 THEN
- :
- PRINT'" Alter starting points of sections?"
- PROCyesno
- IF on = 1 THEN
- FOR count% = 2 TO numlayersections%
- PRINT'" Alter start point of section ";count%;" [currently ";startoflayersection%(count%);"]"
- PROCyesno
- IF on = 1 THEN
- PRINT'" Section ";count%;" starts at beat number "
- INPUT startoflayersection%(count%)
- ENDIF
- NEXT
- ENDIF
- ENDIF
- :
- PRINT'" Alter any of the proportions?"
- PROCyesno
- IF on = 1 THEN
- REM 2
- FOR count% = 1 TO numlayersections%
- PRINT'" Alter proportions in section ";count%
- PROCyesno
- IF on = 1 THEN
- REM 3
- FOR count1% = 1 TO numlayers%
- PRINT'" Alter (section ";count%;") layer ";count1%;" proportions? [currently ";shareoflayers%(count%,count1%);"]"
- PROCyesno
- IF on = 1 THEN
- REM 4
- PRINT '"In section ";count%;", layer ";count1%;" has "
- PRINT "how many proportions?"
- INPUT shareoflayers%(count%,count1%)
- ENDIF : REM 4
- NEXT
- ENDIF : REM 3
- NEXT
- ENDIF : REM 2
- :
- ENDIF : REM 1
- :
- PRINT''" NUMBER OF ATTACKS, DURATIONS, MULTIPLIERS, RETURN AFTERS"
- FOR count% = 1 TO numlayers%
- PRINT'" Alterations to layer ";count%
- PROCyesno
- IF on = 1 THEN
- REM 5
- PRINT'" Alter number of attacks?"
- PROCyesno
- IF on = 1 THEN
- REM 6
- PRINT'" Alter whether controlled by sections/appearances?"
- PROCyesno
- IF on = 1 THEN
- REM 7
- PRINT'" In layer ";count%;" are the number of attacks controlled"
- PRINT " by sections or by appearance number (S/A)"
- PRINT " [currently ";attackscontrol$(count%);"]"
- CASE GET$ OF
- WHEN "S","s" :
- attackscontrol$(count%) = "S"
- OTHERWISE attackscontrol$(count%) = "A"
- ENDCASE
- ELSE
- IF attackscontrol$(count%) = "" THEN attackscontrol$(count%) = "S" : REM default for added layers
- ENDIF : REM 7
- :
- IF attackscontrol$(count%) = "S" THEN
- REM 8
- IF numattackssections%(count%) = 0 THEN numattackssections%(count%) = 1 : REM new layers
- PRINT'" Alter number of sections? [currently ";numattackssections%(count%);"]"
- PROCyesno
- IF on = 1 THEN
- REM 9
- INPUT'" How many sections "numattackssections%(count%)
- ENDIF : REM 9
- IF numattackssections%(count%) > 1 THEN
- PRINT'" Alter starting point of any sections?"
- PROCyesno
- IF on = 1 THEN
- REM 10
- FOR count1% = 2 TO numattackssections%(count%)
- PRINT'" Alter starting point of section ";count1%;" currently [";startofattackssection%(count%,count1%);"]"
- PROCyesno
- IF on = 1 THEN
- REM 11
- PRINT'" (layer ";count%;") section ";count1%;" starts at beat"
- INPUT startofattackssection%(count%,count1%)
- ENDIF : REM 11
- NEXT
- ENDIF : REM 10
- ENDIF
- PRINT'" Alter the number of attacks in layer ";count%
- PROCyesno
- IF on = 1 THEN
- REM 12
- :
- FOR count1% = 1 TO numattackssections%(count%)
- PRINT'" Alter attacks in section ";count1%;" [currently ";numattax%(count%,count1%,0);"-";numattax%(count%,count1%,1);"]"
- PROCyesno
- IF on = 1 THEN
- REM 13
- PRINT'" In layer ";count%;", section ";count1%;" the number"
- PRINT" of attacks varies between..."
- INPUT numattax%(count%,count1%,0)
- INPUT" and..."numattax%(count%,count1%,1)
- ENDIF : REM 13
- NEXT
- ENDIF : REM 12
- ENDIF : REM 8
- :
- IF attackscontrol$(count%) = "A" THEN
- REM 14
- PRINT'" Alter number of 'sections' of appearances? [currently ";numattackssections1%(count%);"]"
- PROCyesno
- IF on = 1 THEN
- REM 15
- INPUT'" How many 'sections' of appearances "numattackssections1%(count%)
- ENDIF : REM 15
- IF numattackssections1%(count%) > 1 THEN
- PRINT'" Alter starting point of any sections?"
- PROCyesno
- IF on = 1 THEN
- REM 16
- FOR count1% = 2 TO numattackssections1%(count%)
- PRINT'" Alter starting point of section ";count1%;" [currently appearance ";startofattackssection1%(count%,count1%);"]"
- PROCyesno
- IF on = 1 THEN
- REM 17
- PRINT'" (layer ";count%;") section ";count1%;" starts at appearance "
- INPUT startofattackssection1%(count%,count1%)
- ENDIF : REM 17
- NEXT
- ENDIF : REM 16
- ENDIF
- :
- PRINT'" Alter number of attacks in layer ";count%
- PROCyesno
- IF on = 1 THEN
- REM 18
- FOR count1% = 1 TO numattackssections1%(count%)
- PRINT'" Alter number of attacks in section ";count1%;" [currently ";numattax1%(count%,count1%,0);"-";numattax1%(count%,count1%,1);"]"
- PROCyesno
- IF on = 1 THEN
- REM 19
- PRINT'" In layer ";count%;", section ";count1%;" the number"
- PRINT" of attacks varies between..."
- INPUT numattax1%(count%,count1%,0)
- INPUT" and... "numattax1%(count%,count1%,1)
- ENDIF : REM 19
- NEXT
- ENDIF : REM 18
- ENDIF : REM 14
- ENDIF : REM 6
- :
- PRINT''" DURATIONS"
- PRINT'" Alter durations in layer ";count%
- PROCyesno
- IF on = 1 THEN
- REM 20
- :
- PRINT'" Alter whether durations in sections/appearances?"
- PROCyesno
- IF on = 1 THEN
- REM 21
- PRINT'" In layer ";count%;" are the unit durations controlled"
- PRINT" by sections or by appearance number (S/A)"
- PRINT " [currently ";durationscontrol$(count%);"]"
- CASE GET$ OF
- WHEN "S","s" :
- durationscontrol$(count%) = "S"
- OTHERWISE durationscontrol$(count%) = "A"
- ENDCASE
- ELSE
- IF durationscontrol$(count%) = "" THEN durationscontrol$(count%) = "S" : REM new layers default
- ENDIF : REM 21
- IF durationscontrol$(count%) = "S" THEN
- REM 22
- IF numdurationssections%(count%) = 0 THEN numdurationssections%(count%) = 1 : REM new layers
- PRINT'" Alter number of sections of durations? [currently ";numdurationssections%(count%);"]"
- PROCyesno
- IF on = 1 THEN
- REM 23
- INPUT'" How many sections "numdurationssections%(count%)
- ENDIF : REM 23
- IF numdurationssections%(count%) > 1 THEN
- PRINT'" Alter starting point of sections?"
- PROCyesno
- IF on = 1 THEN
- REM 24
- FOR count1% = 2 TO numdurationssections%(count%)
- PRINT'" Alter starting point of section ";count1%;" [currently ";startofdurationssection%(count%,count1%);"]"
- PROCyesno
- IF on = 1 THEN
- REM 25
- PRINT'" (layer ";count%;") section ";count1%;" starts at beat "
- INPUT startofdurationssection%(count%,count1%)
- ENDIF : REM 25
- NEXT
- ENDIF : REM 24
- ENDIF
- :
- PRINT'" Alter the unit durations?"
- PROCyesno
- IF on = 1 THEN
- REM 26
- FOR count1% = 1 TO numdurationssections%(count%)
- PRINT'" Alter the duration in section ";count1%;" [currently ";doorations%(count%,count1%);"]"
- PROCyesno
- IF on = 1 THEN
- REM 27
- PRINT'" In layer ";count%;", section ";count1%;" the unit duration is"
- INPUT beats% : PROCalterbeats
- doorations%(count%,count1%) = beats%
- ENDIF : REM 27
- NEXT
- ENDIF : REM 26
- ENDIF : REM 22
- :
- IF durationscontrol$(count%) = "A" THEN
- REM 28
- PRINT'" Alter number of 'sections'? [currently ";numdurationssections1%(count%);"]"
- PROCyesno
- IF on = 1 THEN
- REM 29
- INPUT'" How many 'sections' "numdurationssections1%(count%)
- ENDIF : REM 29
- IF numdurationssections1%(count%) > 1 THEN
- PRINT'" Alter starting point of 'sections'?"
- PROCyesno
- IF on = 1 THEN
- REM 30
- FOR count1% = 2 TO numdurationssections1%(count%)
- PRINT'" Alter section ";count1%;" [currently appearance ";startofdurationssection1%(count%,count1%);"]"
- PROCyesno
- IF on = 1 THEN
- REM 31
- PRINT'" (layer ";count%;") section ";count1%;" starts at appearance "
- INPUT startofdurationssection1%(count%,count1%)
- ENDIF : REM 31
- NEXT
- ENDIF : REM 30
- ENDIF
- PRINT'" Alter the unit durations?"
- PROCyesno
- IF on = 1 THEN
- REM 32
- FOR count1% = 1 TO numdurationssections1%(count%)
- PRINT'" Alter section ";count1%;" [currently ";doorations1%(count%,count1%);"]"
- PROCyesno
- IF on = 1 THEN
- REM 33
- PRINT'" In layer ";count%;", section ";count1%;" the unit duration is "
- INPUT doorations1%(count%,count1%)
- ENDIF : REM 33
- NEXT
- ENDIF : REM 32
- ENDIF : REM 28
- ENDIF : REM 20
- :
- PRINT'" Alter multiplication of durations?"
- PROCyesno
- IF on = 1 THEN
- REM 34
- PRINT'" Do you want the unit duration to be multiplied"
- PRINT " by a given series of values (Y/N) [currently ";multiplier$(count%);"]"
- CASE GET$ OF
- WHEN "Y","y" :
- multiplier$(count%) = "Y"
- PRINT'" starting fresh at each appearance or irrespective (F/I) "
- PRINT " [currently ";multipliermode$(count%);"]"
- CASE GET$ OF
- WHEN "F","f" :
- multipliermode$(count%) = "F"
- OTHERWISE multipliermode$(count%) = "I"
- ENDCASE
- :
- PRINT'" How many values [currently ";numvalues%(count%);"]"
- INPUT numvalues%(count%)
- FOR count1% = 1 TO numvalues%(count%)
- PRINT'" value ";count1%;" is [currently ";values(count%,count1%);"]"
- INPUT values(count%,count1%)
- NEXT
- OTHERWISE multiplier$(count%) = "N"
- ENDCASE
- ELSE
- IF multiplier$(count%) = "" THEN multiplier$(count%) = "N" : REM default for new layers
- ENDIF : REM 34
- :
- PRINT'" Alter control over reoccurence of layers?"
- PROCyesno
- IF on = 1 THEN
- REM 35
- IF numlayerOKsects%(count%) = 0 THEN word$ = "No" ELSE word$ = "Yes"
- PRINT'" Do you want this layer to reoccur according"
- PRINT " to minimum and maximum intervals (eg to"
- PRINT " control phrase-lengths)? [currently ";word$;"]"
- CASE GET$ OF
- WHEN "Y","y" :
- PRINT'" Alter number of sections? [currently ";numlayerOKsects%(count%);"]"
- PROCyesno
- IF on = 1 THEN
- REM 36
- INPUT'" How many sections of this "numlayerOKsects%(count%)
- ENDIF : REM 36
- FOR count1% = 1 TO numlayerOKsects%(count%)
- PRINT'" Any alteration to section ";count1%
- PROCyesno
- IF on = 1 THEN
- REM 37
- PRINT'" Alter the starting point? [currently ";layersOK%(count%,count1%,0);"]"
- PROCyesno
- IF on = 1 THEN
- REM 38
- IF numlayerOKsects%(count%) > 1 THEN
- PRINT'" section ";count1%;" begins at beat "
- INPUT x%
- ELSE x% = 0
- ENDIF
- layersOK%(count%,count1%,0) = x%
- ENDIF : REM 38
- PRINT'" Alter the controlling intervals?"
- PROCyesno
- IF on = 1 THEN
- REM 39
- PRINT'" in this section the layer should NOT reoccur"
- PRINT" until at least how many beats from the"
- PRINT" end of its previous occurence? [currently ";layersOK%(count%,count1%,1);"]"
- INPUT y%
- PRINT'" but SHOULD be made to reoccur after how "
- PRINT" many beats from the end of its previous"
- PRINT" occurence? [currently ";layersOK%(count%,count1%,2);"]"
- INPUT z%
- layersOK%(count%,count1%,1) = y%
- layersOK%(count%,count1%,2) = z%
- ENDIF : REM 39
- ENDIF : REM 37
- NEXT
- OTHERWISE numlayerOKsects%(count%) = 0
- ENDCASE
- ENDIF : REM 35
- :
- ENDIF : REM 5
- :
- NEXT
- :
- :
- PROClayeredattacks
- :
- ENDPROC
- :
- REM**************************************************
- :
- DEF PROCsavelayers
- :
- *Dir SDFS::RISCOSpi.$.CAC.Files
- firstnaming$ = "n"
- CLS
- IF filenamelyr$ = "" THEN
- INPUT'" filename "filenamelyr$
- firstnaming$ = "y"
- ENDIF
- IF firstnaming$ = "n" THEN
- PRINT'" as '";filenamelyr$;"'?"
- CASE GET$ OF
- WHEN "N","n" : INPUT'" filename "filenamelyr$
- OTHERWISE
- ENDCASE
- ENDIF
- :
- channel = OPENOUT filenamelyr$
- PRINT#channel, totallength%
- PRINT#channel, numlayers%
- PRINT#channel, numlayersections%
- FOR a% = 0 TO numlayersections%
- PRINT#channel, startoflayersection%(a%)
- NEXT
- FOR a% = 0 TO numlayersections%
- FOR b% = 0 TO numlayers%
- PRINT#channel, shareoflayers%(a%,b%)
- NEXT
- NEXT
- FOR a% = 0 TO numlayers%
- PRINT#channel, attackscontrol$(a%)
- NEXT
- FOR a% = 0 TO numlayers%
- PRINT#channel, numattackssections%(a%)
- NEXT
- FOR a% = 0 TO numlayers%
- FOR b% = 0 TO numattackssections%(a%)
- PRINT#channel, startofattackssection%(a%,b%)
- NEXT
- NEXT
- FOR a% = 0 TO numlayers%
- FOR b% = 0 TO numattackssections%(a%)
- FOR c% = 0 TO 1
- PRINT#channel, numattax%(a%,b%,c%)
- NEXT
- NEXT
- NEXT
- FOR a% = 0 TO numlayers%
- PRINT#channel, numattackssections1%(a%)
- NEXT
- FOR a% = 0 TO numlayers%
- FOR b% = 0 TO numattackssections1%(a%)
- PRINT#channel, startofattackssection1%(a%,b%)
- NEXT
- NEXT
- FOR a% = 0 TO numlayers%
- FOR b% = 0 TO numattackssections1%(a%)
- FOR c% = 0 TO 1
- PRINT#channel, numattax1%(a%,b%,c%)
- NEXT
- NEXT
- NEXT
- FOR a% = 0 TO numlayers%
- PRINT#channel, durationscontrol$(a%)
- NEXT
- FOR a% = 0 TO numlayers%
- PRINT#channel, numdurationssections%(a%)
- NEXT
- FOR a% = 0 TO numlayers%
- FOR b% = 0 TO numdurationssections%(a%)
- PRINT#channel, startofdurationssection%(a%,b%)
- NEXT
- NEXT
- FOR a% = 0 TO numlayers%
- FOR b% = 0 TO numdurationssections%(a%)
- PRINT#channel, doorations%(a%,b%)
- NEXT
- NEXT
- FOR a% = 0 TO numlayers%
- PRINT#channel, numdurationssections1%(a%)
- NEXT
- FOR a% = 0 TO numlayers%
- FOR b% = 0 TO numdurationssections1%(a%)
- PRINT#channel, doorations1%(a%,b%)
- NEXT
- NEXT
- FOR a% = 0 TO numlayers%
- FOR b% = 0 TO numdurationssections1%(a%)
- PRINT#channel, startofdurationssection1%(a%,b%)
- NEXT
- NEXT
- FOR a% = 0 TO numlayers%
- PRINT#channel, multiplier$(a%)
- NEXT
- FOR a% = 0 TO numlayers%
- PRINT#channel, multipliermode$(a%)
- NEXT
- FOR a% = 0 TO numlayers%
- PRINT#channel, numvalues%(a%)
- NEXT
- FOR a% = 0 TO numlayers%
- FOR b% = 0 TO numvalues%(a%)
- PRINT#channel, values(a%,b%)
- NEXT
- NEXT
- FOR a% = 0 TO numlayers%
- PRINT#channel, numlayerOKsects%(a%)
- NEXT
- FOR a% = 0 TO numlayers%
- FOR b% = 0 TO numlayerOKsects%(a%)
- FOR c% = 0 TO 2
- PRINT#channel, layersOK%(a%,b%,c%)
- NEXT
- NEXT
- NEXT
- :
- CLOSE#channel
- *NoDir
- :
- ENDPROC
- :
- REM****************************************************
- :
- DEF PROCloadlayers
- :
- *Dir SDFS::RISCOSpi.$.CAC.Files
- INPUT'" filename "filenamelyr$
- channel = OPENIN filenamelyr$
- REPEAT
- INPUT#channel, totallength%
- INPUT#channel, numlayers%
- INPUT#channel, numlayersections%
- FOR a% = 0 TO numlayersections%
- INPUT#channel, startoflayersection%(a%)
- NEXT
- FOR a% = 0 TO numlayersections%
- FOR b% = 0 TO numlayers%
- INPUT#channel, shareoflayers%(a%,b%)
- NEXT
- NEXT
- FOR a% = 0 TO numlayers%
- INPUT#channel, attackscontrol$(a%)
- NEXT
- FOR a% = 0 TO numlayers%
- INPUT#channel, numattackssections%(a%)
- NEXT
- FOR a% = 0 TO numlayers%
- FOR b% = 0 TO numattackssections%(a%)
- INPUT#channel, startofattackssection%(a%,b%)
- NEXT
- NEXT
- FOR a% = 0 TO numlayers%
- FOR b% = 0 TO numattackssections%(a%)
- FOR c% = 0 TO 1
- INPUT#channel, numattax%(a%,b%,c%)
- NEXT
- NEXT
- NEXT
- FOR a% = 0 TO numlayers%
- INPUT#channel, numattackssections1%(a%)
- NEXT
- FOR a% = 0 TO numlayers%
- FOR b% = 0 TO numattackssections1%(a%)
- INPUT#channel, startofattackssection1%(a%,b%)
- NEXT
- NEXT
- FOR a% = 0 TO numlayers%
- FOR b% = 0 TO numattackssections1%(a%)
- FOR c% = 0 TO 1
- INPUT#channel, numattax1%(a%,b%,c%)
- NEXT
- NEXT
- NEXT
- FOR a% = 0 TO numlayers%
- INPUT#channel, durationscontrol$(a%)
- NEXT
- FOR a% = 0 TO numlayers%
- INPUT#channel, numdurationssections%(a%)
- NEXT
- FOR a% = 0 TO numlayers%
- FOR b% = 0 TO numdurationssections%(a%)
- INPUT#channel, startofdurationssection%(a%,b%)
- NEXT
- NEXT
- FOR a% = 0 TO numlayers%
- FOR b% = 0 TO numdurationssections%(a%)
- INPUT#channel, doorations%(a%,b%)
- NEXT
- NEXT
- FOR a% = 0 TO numlayers%
- INPUT#channel, numdurationssections1%(a%)
- NEXT
- FOR a% = 0 TO numlayers%
- FOR b% = 0 TO numdurationssections1%(a%)
- INPUT#channel, doorations1%(a%,b%)
- NEXT
- NEXT
- FOR a% = 0 TO numlayers%
- FOR b% = 0 TO numdurationssections1%(a%)
- INPUT#channel, startofdurationssection1%(a%,b%)
- NEXT
- NEXT
- FOR a% = 0 TO numlayers%
- INPUT#channel, multiplier$(a%)
- NEXT
- FOR a% = 0 TO numlayers%
- INPUT#channel, multipliermode$(a%)
- NEXT
- FOR a% = 0 TO numlayers%
- INPUT#channel, numvalues%(a%)
- NEXT
- FOR a% = 0 TO numlayers%
- FOR b% = 0 TO numvalues%(a%)
- INPUT#channel, values(a%,b%)
- NEXT
- NEXT
- FOR a% = 0 TO numlayers%
- INPUT#channel, numlayerOKsects%(a%)
- NEXT
- FOR a% = 0 TO numlayers%
- FOR b% = 0 TO numlayerOKsects%(a%)
- FOR c% = 0 TO 2
- INPUT#channel, layersOK%(a%,b%,c%)
- NEXT
- NEXT
- NEXT
- UNTIL EOF#channel
- CLOSE#channel
- *NoDir
- :
- ENDPROC
- :
- REM************************************************
- :
- DEF PROCseriesamplitudes
- :
- IF easiermenus$ = "n" THEN PROCwindow(20,69,73,45) ELSE PROCwindow(20,69,73,42)
- :
- IF ampoptions$ = "y" THEN
- PRINT'" Create a new group, edit current group,"
- PRINT" or load a file (N/E/F)"
- CASE GET$ OF
- WHEN "N","n" :
- filenameamps$ = ""
- PRINT'" from a sample of amplitudes or"
- PRINT" according to attacks or by note"
- PRINT" numbers (S/A/N)"
- CASE GET$ OF
- WHEN "S","s" : ampmethod$ = "sample" : PROCnewamps
- WHEN "A","a" : ampmethod$ = "attacks" : PROCnewamps
- WHEN "N","n" : ampmethod$ = "notenumber" : PROCnewamps
- OTHERWISE VDU 7 : PROCseriesamplitudes
- ENDCASE
- WHEN "E","e" : PROCeditamps
- WHEN "F","f" : PROCloadamps : PROCeditamps
- OTHERWISE VDU 7 : PROCseriesamplitudes
- ENDCASE
- :
- PRINT'" Save these settings?"
- CASE GET$ OF
- WHEN "Y","y" : PROCsaveamps
- OTHERWISE
- ENDCASE
- :
- PROCrunamps
- :
- PRINT'" Re-order amplitudes randomly?"
- CASE GET$ OF
- WHEN "Y","y" : PROCreorderamps
- OTHERWISE
- ENDCASE
- :
- numamplitudes% = manyattacks% : PROCinsertamplitudes
- :
- ELSE PROCsimpleamps
- ENDIF
- :
- ENDPROC
- :
- REM***************************************
- DEF PROCsimpleamps
- :
- IF easiermenus$ = "n" THEN PROCwindow(20,69,73,45) ELSE PROCwindow(20,69,73,42)
- PRINT'" How many amplitudes "
- INPUT " (for 1 press 0) "numamplitudes%
- IF numamplitudes% = 0 THEN numamplitudes% = 1
- :
- IF numamplitudes% = 1 THEN
- INPUT'" the amplitude is: "dyn$
- PROCconvertdyn
- amplitudes%(0) = dyn%
- ELSE
- PRINT'" Are all the amplitudes the same?"
- CASE GET$ OF
- WHEN "N","n","2" :
- FOR count% = 0 TO (numamplitudes%-1)
- PRINT'" amplitude ";count%+1;" is: "
- IF count% > 0 THEN PRINT " (0 = previous) "
- INPUT dyn$
- IF dyn$ = "" THEN
- dyn$ = prevdyn$
- COLOUR 3 : PRINT dyn$
- wait$ = INKEY$(20) : COLOUR 0
- ENDIF
- prevdyn$ = dyn$
- PROCconvertdyn
- amplitudes%(count%) = dyn%
- NEXT
- OTHERWISE
- INPUT'" the amplitude is: "dyn$
- PROCconvertdyn
- FOR count% = 0 TO (numamplitudes%-1) : amplitudes%(count%) = dyn% : NEXT
- ENDCASE
- ENDIF
- :
- REM function can feed amplitudes similarly into amplitudes%()
- :
- ampmethod$ = "sample"
- PROCinsertamplitudes
- :
- ENDPROC
- :
- *************************************************************************
- :
- DEF PROCnewamps
- :
- CASE ampmethod$ OF
- WHEN "attacks" :
- PRINT'" Dynamics determined by the preceding"
- PRINT" attack intervals, the succeeding ones, "
- PRINT" or both (P/S/B)"
- CASE GET$ OF
- WHEN "P","p" : prepost$ = "P"
- WHEN "S","s" : prepost$ = "S"
- OTHERWISE prepost$ = "B"
- ENDCASE
- CLS
- PRINT'" How many different 'layers' of dynamics?"
- PRINT'" (NB layers inputted later override earlier ones;"
- PRINT" existing dynamics remain unchanged if their"
- PRINT" interval is not included, or if the interval is"
- PRINT" set at 0 - 0)"
- INPUT dynlayers%
- :
- FOR count% = 1 TO dynlayers%
- IF prepost$ = "P" OR prepost$ = "B" THEN
- PRINT'" In layer ";count%;" the preceding interval "
- PRINT " is between how many beats..."
- INPUT dynlayers%(count%,0)
- PRINT'" and how many beats..."
- INPUT dynlayers%(count%,1)
- PRINT'" and the dynamic is "
- INPUT dyn$
- PROCconvertdyn : dynlayers%(count%,2) = dyn%
- ENDIF
- :
- IF prepost$ = "S" OR prepost$ = "B" THEN
- PRINT'" In layer ";count%;" the succeeding interval "
- PRINT " is between how many beats..."
- INPUT dynlayers%(count%,3)
- PRINT'" and how many beats..."
- INPUT dynlayers%(count%,4)
- PRINT'" and the dynamic is "
- INPUT dyn$
- PROCconvertdyn : dynlayers%(count%,5) = dyn%
- ENDIF
- NEXT
- :
- WHEN "notenumber" :
- INPUT'" How many elements in the (recycling) pattern "dynnumbers%
- FOR count% = 1 TO dynnumbers%
- PRINT'" Element ";count%;" places dynamics ";count%;" and ";count%+1
- PRINT" how many notes apart?"
- INPUT dynnumbers%(count%)
- NEXT
- PRINT" and the dynamic for these notes is "
- INPUT dynnumbers$
- :
- WHEN "sample" :
- INPUT'" Total number of amplitudes "manyattacks%
- INPUT " Number of amplitudes in the sample "ampsample%
- FOR count% = 0 TO (ampsample%-1)
- PRINT'" Element ";count%+1;" in the sample is "
- INPUT dyn$
- PROCconvertdyn : ampsample%(count%) = dyn%
- NEXT
- :
- ENDCASE
- :
- ENDPROC
- :
- REM*********************************************
- :
- DEF PROCconvertdyn
- :
- CASE dyn$ OF
- WHEN "0" : dyn% = 0
- WHEN "ppp" : dyn% = 1
- WHEN "pp" : dyn% = 2
- WHEN "p" : dyn% = 3
- WHEN "mp" : dyn% = 4
- WHEN "mf" : dyn% = 5
- WHEN "f" : dyn% = 6
- WHEN "ff" : dyn% = 7
- WHEN "fff" : dyn% = 8
- ENDCASE
- ENDPROC
- :
- REM*********************************************
- :
- DEF PROCrunamps
- :
- IF ampmethod$ = "attacks" OR ampmethod$ = "notenumber" THEN
- INPUT'" The dynamics are to be read into which voice? "voice%
- voice% -= 1
- INPUT'" Starting at bar "copystartbar%
- INPUT" beat "beats%
- PROCalterbeats : copystartbeat% = beats%
- startat% = (copystartbar%*10^3)+beats%
- INPUT'" Ending at bar "copyendbar%
- INPUT " beat "beats%
- PROCalterbeats : copyendbeat% = beats%
- :
- value% = (copystartbar%*10^3)+copystartbeat%
- IF value% <= array%(0,0,voice%)DIV10^3 THEN
- startatcell% = 0
- ELSE
- PROCsearch(value%)
- startatcell% = startcell%
- ENDIF
- value% = (copyendbar%*10^3)+copyendbeat%
- IF value% >= array%(numusedcells%(voice%)-1,0,voice%)DIV10^3 THEN
- endatcell% = numusedcells%(voice%) - 1
- ELSE
- PROCsearch(value%)
- IF shunt$ = "N" THEN endatcell% = startcell% ELSE endatcell% = startcell% - 1
- ENDIF
- :
- manyattacks% = endatcell% - startatcell% + 1
- REM create 'gap' between beat-of-bar and first actual attack
- carrybars% = (array%(startatcell%,0,voice%)DIV10^6)-copystartbar%
- carrybeats% = ((array%(startatcell%,0,voice%)DIV10^3)MOD10^3)-copystartbeat%
- attacks1%(0) = (carrybars%*960)+carrybeats%
- :
- FOR count% = 0 TO (manyattacks%-1)
- IF count% > 0 THEN
- carrybars% = (array%(startatcell%+count%,0,voice%)DIV10^6)-(array%(startatcell%+count%-1,0,voice%)DIV10^6)
- carrybeats% = ((array%(startatcell%+count%,0,voice%)DIV10^3)MOD10^3)-((array%(startatcell%+count%-1,0,voice%)DIV10^3)MOD10^3)
- attacks1%(count%) = attacks1%(count%-1) + ((carrybars%*960)+carrybeats%)
- ENDIF
- :
- pitches%(count%+1) = array%(startatcell%+count%,0,voice%)MOD10^3
- durations%(count%+1) = (array%(startatcell%+count%,1,voice%)DIV10)MOD10^3
- amplitudes%(count%+1) = (array%(startatcell%+count%,1,voice%))MOD10
- envelopes%(count%+1) = (array%(startatcell%+count%,2,voice%))DIV10^2
- glissandos%(count%+1) = (array%(startatcell%+count%,1,voice%)DIV10^4)
- inflections%(count%+1) = array%(startatcell%+count%,2,voice%)MOD10^2
- NEXT
- ENDIF
- :
- CASE ampmethod$ OF
- WHEN "attacks" :
- FOR count% = 0 TO manyattacks%-1
- FOR count1% = 1 TO dynlayers%
- IF count% > 0 THEN
- IF prepost$ = "P" OR prepost$ = "B" THEN
- IF attacks1%(count%)-attacks1%(count%-1)>=dynlayers%(count1%,0) AND attacks1%(count%)-attacks1%(count%-1)<=dynlayers%(count1%,1) THEN amplitudes%(count%+1) = dynlayers%(count1%,2)
- ENDIF
- ENDIF
- IF prepost$ = "S" OR prepost$ = "B" THEN
- IF attacks1%(count%+1)-attacks1%(count%)>=dynlayers%(count1%,3)ANDattacks1%(count%+1)-attacks1%(count%)<=dynlayers%(count1%,4) THEN amplitudes%(count%+1) = dynlayers%(count1%,5)
- ENDIF
- NEXT
- NEXT
- :
- WHEN "notenumber" :
- count% = 1 : count1% = 0
- dyn$ = dynnumbers$ : PROCconvertdyn
- REPEAT
- count1% += 1
- IF count1% > dynnumbers% THEN count1% = 1
- amplitudes%(count%) = dyn%
- count% += dynnumbers%(count1%)
- UNTIL count% > manyattacks%
- :
- WHEN "sample" :
- count% = 1 : count1% = 1
- REPEAT
- amplitudes%(count%-1) = ampsample%(count1%-1)
- count% += 1 : count1% += 1
- IF count1% > ampsample% THEN count1% = 1
- UNTIL count% > manyattacks%
- :
- ENDCASE
- :
- ENDPROC
- :
- REM******************************************************
- :
- DEF PROCreorderamps
- :
- FOR count% = 0 TO manyattacks%-1
- REPEAT
- x% = RND(manyattacks%)
- x% = x%-1
- IF amplitudes%(x%) = 0 THEN thiscell$ = "done" ELSE thiscell$ = "available"
- UNTIL thiscell$ = "available"
- amplitudes1%(count%) = amplitudes%(x%)
- amplitudes%(x%) = 0
- NEXT
- amplitudes%() = amplitudes1%()
- :
- ENDPROC
- :
- REM*****************************************************
- :
- DEF PROCeditamps
- :
- CASE ampmethod$ OF
- WHEN "attacks" :
- PRINT'" Alter whether dynamics determined by"
- PRINT" preceding, succeeding intervals or both?"
- PROCyesno
- IF on = 1 THEN
- PRINT'" Dynamics determined by the preceding"
- PRINT" attack intervals, the succeeding ones, "
- PRINT" or both (P/S/B)"
- CASE GET$ OF
- WHEN "P","p" : prepost$ = "P"
- WHEN "S","s" : prepost$ = "S"
- OTHERWISE prepost$ = "B"
- ENDCASE
- ENDIF
- CLS
- PRINT'" Alter number of 'layers'?"
- PROCyesno
- IF on = 1 THEN
- PRINT'" How many different 'layers' of dynamics?"
- PRINT'" (NB layers inputted later override earlier ones;"
- PRINT" existing dynamics remain unchanged if their"
- PRINT" interval is not included, or if the interval is"
- PRINT" set at 0 - 0)"
- INPUT dynlayers%
- ENDIF
- :
- PRINT'" Alter any of the layers?"
- PROCyesno
- IF on = 1 THEN
- FOR count% = 1 TO dynlayers%
- PRINT'" Alter layer ";count%
- PROCyesno
- IF on = 1 THEN
- IF prepost$ = "P" OR prepost$ = "B" THEN
- PRINT'" In layer ";count%;" the preceding interval "
- PRINT " is between how many beats..."
- INPUT dynlayers%(count%,0)
- PRINT'" and how many beats..."
- INPUT dynlayers%(count%,1)
- PRINT'" and the dynamic is "
- INPUT dyn$
- PROCconvertdyn : dynlayers%(count%,2) = dyn%
- ENDIF
- :
- IF prepost$ = "S" OR prepost$ = "B" THEN
- PRINT'" In layer ";count%;" the succeeding interval "
- PRINT " is between how many beats..."
- INPUT dynlayers%(count%,3)
- PRINT'" and how many beats..."
- INPUT dynlayers%(count%,4)
- PRINT'" and the dynamic is "
- INPUT dyn$
- PROCconvertdyn : dynlayers%(count%,5) = dyn%
- ENDIF
- ENDIF
- NEXT
- ENDIF
- :
- WHEN "notenumber" :
- PRINT'" Alter number of elements in the pattern?"
- PROCyesno
- IF on = 1 THEN
- INPUT'" How many elements in the (recycling) pattern "dynnumbers%
- ENDIF
- FOR count% = 1 TO dynnumbers%
- PRINT'" Alter element ";count%
- PROCyesno
- IF on =1 THEN
- PRINT'" Element ";count%;" places dynamics ";count%;" and ";count%+1
- PRINT" how many notes apart?"
- INPUT dynnumbers%(count%)
- ENDIF
- NEXT
- PRINT'" Alter the dynamic?"
- PROCyesno
- IF on =1 THEN
- PRINT" and the dynamic for these notes is "
- INPUT dynnumbers$
- ENDIF
- :
- WHEN "sample" :
- PRINT'" Alter total number of amplitudes?"
- PROCyesno
- IF on =1 THEN
- INPUT'" Total number of amplitudes "manyattacks%
- ENDIF
- PRINT'" Alter number of amplitudes in the sample?"
- PROCyesno
- IF on =1 THEN
- INPUT " Number of amplitudes in the sample "ampsample%
- ENDIF
- PRINT'" Alter the sample?"
- PROCyesno
- IF on =1 THEN
- FOR count% = 0 TO ampsample%-1
- PRINT'" Alter element ";count%+1
- PROCyesno
- IF on =1 THEN
- PRINT'" Element ";count%+1;" in the sample is "
- INPUT dyn$
- PROCconvertdyn : ampsample%(count%) = dyn%
- ENDIF
- NEXT
- ENDIF
- :
- ENDCASE
- :
- ENDPROC
- :
- REM***************************************************
- :
- DEF PROCsaveamps
- :
- :
- *Dir SDFS::RISCOSpi.$.CAC.Files
- firstnaming$ = "n"
- CLS
- IF filenameamps$ = "" THEN
- INPUT'" filename "filenameamps$
- firstnaming$ = "y"
- ENDIF
- IF firstnaming$ = "n" THEN
- PRINT'" as '";filenameamps$;"'?"
- CASE GET$ OF
- WHEN "N","n" : INPUT'" filename "filenameamps$
- OTHERWISE
- ENDCASE
- ENDIF
- :
- channel = OPENOUT filenameamps$
- PRINT#channel, ampmethod$
- IF ampmethod$ = "attacks" THEN
- PRINT#channel, prepost$
- PRINT#channel, dynlayers%
- ENDIF
- IF ampmethod$ = "notenumber" THEN
- PRINT#channel, dynnumbers%
- PRINT#channel, dynnumbers$
- ENDIF
- IF ampmethod$ = "sample" THEN
- PRINT#channel, manyattacks%
- PRINT#channel, ampsample%
- ENDIF
- IF ampmethod$ = "attacks" THEN
- FOR a% = 0 TO 12
- FOR b% = 0 TO 5
- PRINT#channel, dynlayers%(a%,b%)
- NEXT
- NEXT
- ENDIF
- IF ampmethod$ = "notenumber" THEN
- FOR a% = 0 TO 99
- PRINT#channel, dynnumbers%(a%)
- NEXT
- ENDIF
- IF ampmethod$ = "sample" THEN
- FOR a% = 0 TO 49
- PRINT#channel, ampsample%(a%)
- NEXT
- ENDIF
- :
- CLOSE#channel
- *NoDir
- :
- ENDPROC
- :
- REM***********************************
- :
- DEF PROCloadamps
- :
- :
- *Dir SDFS::RISCOSpi.$.CAC.Files
- INPUT'" filename "filenameamps$
- channel = OPENIN filenameamps$
- REPEAT
- INPUT#channel, ampmethod$
- IF ampmethod$ = "attacks" THEN
- INPUT#channel, prepost$
- INPUT#channel, dynlayers%
- ENDIF
- IF ampmethod$ = "notenumber" THEN
- INPUT#channel, dynnumbers%
- INPUT#channel, dynnumbers$
- ENDIF
- IF ampmethod$ = "sample" THEN
- INPUT#channel, manyattacks%
- INPUT#channel, ampsample%
- ENDIF
- IF ampmethod$ = "attacks" THEN
- FOR a% = 0 TO 12
- FOR b% = 0 TO 5
- INPUT#channel, dynlayers%(a%,b%)
- NEXT
- NEXT
- ENDIF
- IF ampmethod$ = "notenumber" THEN
- FOR a% = 0 TO 99
- INPUT#channel, dynnumbers%(a%)
- NEXT
- ENDIF
- IF ampmethod$ = "sample" THEN
- FOR a% = 0 TO 49
- INPUT#channel, ampsample%(a%)
- NEXT
- ENDIF
- :
- UNTIL EOF#channel
- CLOSE#channel
- *NoDir
- :
- ENDPROC
- :
- REM*********************************
- :
- DEF PROCbeatnumbers
- :
- amount% = 10
- IF beatnum_diff$ = "num" THEN
- IF beatunits$ = "big" THEN
- PRINT (array%(startcell%,0,voice%)DIV10^3)MOD10^3
- ELSE beatnum = ((array%(startcell%,0,voice%)DIV10^3)MOD10^3)/beatfactor%
- IF beatnum MOD 1 > 0 THEN
- beatnum = beatnum*10
- beatnum% = beatnum DIV 1
- PRINT beatnum%/amount%
- ELSE PRINT beatnum
- ENDIF
- ENDIF
- ELSE
- beatdiff% = ((array%(startcell%+1,0,voice%)DIV10^3)MOD10^3)-((array%(startcell%,0,voice%)DIV10^3)MOD10^3)
- beatdiff%+=(((array%(startcell%+1,0,voice%)DIV10^6)-(array%(startcell%,0,voice%)DIV10^6))*960)
- :
- IF beatdiff% > 0 THEN
- IF beatunits$ = "big" THEN
- PRINT beatdiff%
- ELSE
- beatdiff = beatdiff%/beatfactor%
- IF beatdiff MOD 1 > 0 THEN
- beatdiff = beatdiff*10
- beatdiff% = beatdiff DIV 1
- PRINT beatdiff%/amount%
- ELSE PRINT beatdiff%/beatfactor%
- ENDIF
- ENDIF
- ENDIF
- :
- ENDIF
- ENDPROC
- :
- REM****************************************************
- :
- DEF PROCextract
- :
- counter% = -1 : attacks1%() = 0 : countt% = -1 : endcell% = manyattacks%
- IF extractmode$ = "random" THEN numb% = RND(higher%-lower%+1)+lower%-2
- REPEAT
- countt% += 1
- extract$ = "n"
- :
- CASE extractmode$ OF
- WHEN "pitchclass" :
- attempts% = 0
- REPEAT
- attempts% += 1
- :
- IF extractinfo%(attempts%) = array%(startatcell%+countt%,0,voice%)MOD10^3 THEN extract$ = "y"
- UNTIL extract$ = "y" OR attempts% = npitches%
- WHEN "band" :
- attempts% = 0 : top$ = "n" : bottom$ = "n"
- theoctave% = array%(startatcell%+countt%,0,voice%)MOD10
- thepitch% = (array%(startatcell%+countt%,0,voice%)DIV10^2)MOD10
- theaccid% = (array%(startatcell%+countt%,0,voice%)DIV10)MOD10
- REPEAT
- attempts% += 1
- testoctave% = extractinfo%(attempts%)MOD10
- testpitch% = extractinfo%(attempts%)DIV10^2
- testaccid% = (extractinfo%(attempts%)DIV10)MOD10
- IF ((attempts%/2)*10)MOD10 > 0 THEN
- IF theoctave% >= testoctave% THEN bottom$ = "y" ELSE bottom$ = "n"
- IF bottom$ = "y" AND theoctave% = testoctave% THEN
- IF thepitch% >= testpitch% THEN bottom$ = "y" ELSE bottom$ = "n"
- ENDIF
- IF bottom$ = "y" AND theoctave% = testoctave% AND thepitch% = testpitch% THEN
- IF theaccid% >= testaccid% THEN bottom$ = "y" ELSE bottom$ = "n"
- ENDIF
- ELSE
- IF theoctave% <= testoctave% THEN top$ = "y" ELSE top$ = "n"
- IF top$ = "y" AND theoctave% = testoctave% THEN
- IF thepitch% <= testpitch% THEN top$ = "y" ELSE top$ = "n"
- ENDIF
- IF top$ = "y" AND theoctave% = testoctave% AND thepitch% = testpitch% THEN
- IF theaccid% <= testaccid% THEN top$ = "y" ELSE top$ = "n"
- ENDIF
- ENDIF
- IF bottom$ = "y" AND top$ = "y" THEN extract$ = "y"
- UNTIL extract$ = "y" OR attempts% = npitches%
- WHEN "random" :
- extract$ = "n"
- IF numb% = countt% THEN
- extract$ = "y"
- max% = higher%-lower%+1 : a% = RND(max%) : b% = lower% -1 : c% = countt%
- IF a% = 0 THEN a% = 1
- numb% = a% + b% + c%
- IF copymove$ = "EM" THEN numb% -= 1
- ENDIF
- WHEN "attackinterval" :
- bar1% = array%(startatcell%+countt%,0,voice%)DIV10^6
- beat1% = (array%(startatcell%+countt%,0,voice%)DIV10^3)MOD10^3
- beat1% = (bar1%*960)+beat1%
- bar2% = array%(startatcell%+countt%+1,0,voice%)DIV10^6
- beat2% = (array%(startatcell%+countt%+1,0,voice%)DIV10^3)MOD10^3
- beat2% = (bar2%*960)+beat2%
- interval% = beat2% - beat1%
- IF interval% >= lower% AND interval% <= higher% THEN extract$ = "y"
- ENDCASE
- :
- IF extract$ = "y" THEN
- counter% += 1
- attacks2%(counter%) = (array%(startatcell%+countt%,0,voice%))DIV10^3
- pitches%(counter%) = array%(startatcell%+countt%,0,voice%)MOD10^3
- durations%(counter%) = (array%(startatcell%+countt%,1,voice%)DIV10)MOD10^3
- amplitudes%(counter%) = (array%(startatcell%+countt%,1,voice%))MOD10
- envelopes%(counter%) = (array%(startatcell%+countt%,2,voice%))DIV10^2
- glissandos%(counter%) = (array%(startatcell%+countt%,1,voice%)DIV10^4)
- inflections%(counter%) = array%(startatcell%+countt%,2,voice%)MOD10^2
- IF copymove$ = "EM" THEN
- REM routine to delete each note as it is extracted, if move-extract wanted
- numnotes% = 1
- bar% = array%(startatcell%+countt%,0,voice%) DIV10^6
- beats% = (array%(startatcell%+countt%,0,voice%)DIV10^3)MOD10^3
- PROCalterbeats
- start% = (bar%*(10^3))+beats%
- PROCsearch(start%)
- PROCshuntleft(startcell%,numnotes%)
- countt% -= 1 : endcell% -= 1
- REM prev line is because of deletion, ie array cells have all now shifted one to left!
- ENDIF
- REM end of delete routine
- :
- ENDIF
- UNTIL countt% = endcell% - 1
- manyattacks% = counter%+1
- attacks1%(0) = (((attacks2%(0)DIV10^3)*960)+(attacks2%(0)MOD10^3)-960)-((copystartbar%*960)+copystartbeat%-960)
- FOR count% = 1 TO manyattacks% - 1
- bars% = (attacks2%(count%)DIV10^3)-(attacks2%(count%-1)DIV10^3)
- beats% = (attacks2%(count%)MOD10^3)-(attacks2%(count%-1)MOD10^3)
- attacks1%(count%) = attacks1%(count%-1) + (bars%*960) + beats%
- NEXT
- :
- :
- ENDPROC
- :
- REM********************************************************
- :
- DEF PROCextractinfo
- :
- IF quickextract$ = "n" THEN
- :
- CLS
- aslasttime$ = "n"
- PRINT'" Extract by pitches, pitch-band,"
- PRINT'" attack interval, random number"
- PRINT'" or as last time (P/B/A/R/L) "
- CASE GET$ OF
- WHEN "P","p","0" :
- CLS
- extractmode$ = "pitchclass"
- WHEN "B","b" :
- CLS : extractmode$ = "band"
- WHEN "R","r" :
- CLS : extractmode$ = "random"
- PRINT'" Random extractions follow "
- PRINT'" each other at a distance "
- INPUT '" of between how many notes "lower%
- INPUT '" and how many notes "higher%
- WHEN "A","a" :
- CLS : extractmode$ = "attackinterval"
- PRINT'" Extract notes which precede"
- PRINT'" next note by between"
- INPUT'" how many beats "lower%
- INPUT'" and how many beats "higher%
- WHEN "L","l" :
- aslasttime$ = "y"
- OTHERWISE CLS : extractmode$ = "pitchclass"
- ENDCASE
- :
- ENDIF
- :
- IF aslasttime$ = "n" THEN
- :
- IF extractmode$ = "pitchclass" OR extractmode$ = "band" THEN
- :
- IF quickextract$ = "n" THEN
- IF extractmode$ = "pitchclass" THEN
- INPUT'" How many pitch-classes? "npitches%
- IF npitches% = 0 THEN npitches% = 1
- ELSE
- INPUT'" How many bands (0 = 1) "nbands%
- IF nbands% = 0 THEN nbands% = 1
- ENDIF
- ENDIF
- :
- IF extractmode$ = "band" THEN npitches% = nbands%*2
- FOR p% = 1 TO npitches%
- IF extractmode$ = "pitchclass" THEN
- PRINT' " Pitch-class ";p%;" has the note name ";
- ELSE PRINT'" Going up, band-point ";p%;" is note ";
- ENDIF
- COLOUR 3
- CASE GET$ OF
- WHEN "C","c" : note% = 0 : PRINT "C" : finished$ = "n"
- WHEN "D","d" : note% = 1 : PRINT "D" : finished$ = "n"
- WHEN "E","e" : note% = 2 : PRINT "E" : finished$ = "n"
- WHEN "F","f" : note% = 3 : PRINT "F" : finished$ = "n"
- WHEN "G","g" : note% = 4 : PRINT "G" : finished$ = "n"
- WHEN "A","a" : note% = 5 : PRINT "A" : finished$ = "n"
- WHEN "B","b" : note% = 6 : PRINT "B" : finished$ = "n"
- WHEN "1" : note% = 0 : accid% = 5 : octave% = 4 : finished$ = "y"
- WHEN "2" : note% = 0 : accid% = 9 : octave% = 4 : finished$ = "y"
- WHEN "3" : note% = 1 : accid% = 5 : octave% = 4 : finished$ = "y"
- WHEN "4" : note% = 2 : accid% = 1 : octave% = 4 : finished$ = "y"
- WHEN "5" : note% = 2 : accid% = 5 : octave% = 4 : finished$ = "y"
- WHEN "6" : note% = 3 : accid% = 5 : octave% = 4 : finished$ = "y"
- WHEN "7" : note% = 3 : accid% = 9 : octave% = 4 : finished$ = "y"
- WHEN "8" : note% = 4 : accid% = 5 : octave% = 4 : finished$ = "y"
- WHEN "9" : note% = 5 : accid% = 1 : octave% = 4 : finished$ = "y"
- ENDCASE
- COLOUR 0
- :
- IF finished$ = "n" THEN
- :
- PRINT " accidental ";
- COLOUR 3
- CASE GET$ OF
- WHEN "1" : accid% = 1 : PRINT "flat"
- WHEN "2" : accid% = 2 : PRINT "3/8flat"
- WHEN "3" : accid% = 3 : PRINT "1/4flat"
- WHEN "4" : accid% = 4 : PRINT "1/8flat"
- WHEN "5" : accid% = 5 : PRINT "nat"
- WHEN "6" : accid% = 6 : PRINT "1/8shrp"
- WHEN "7" : accid% = 7 : PRINT "1/4shrp"
- WHEN "8" : accid% = 8 : PRINT "3/8shrp"
- WHEN "9" : accid% = 9 : PRINT "shrp"
- ENDCASE
- COLOUR 0
- PRINT " octave ";
- COLOUR 3
- CASE GET$ OF
- WHEN "0" : octave% = 0 : PRINT "0"
- WHEN "1" : octave% = 1 : PRINT "1"
- WHEN "2" : octave% = 2 : PRINT "2"
- WHEN "3" : octave% = 3 : PRINT "3"
- WHEN "4" : octave% = 4 : PRINT "4"
- WHEN "5" : octave% = 5 : PRINT "5"
- WHEN "6" : octave% = 6 : PRINT "6"
- WHEN "7" : octave% = 7 : PRINT "7"
- WHEN "8" : octave% = 8 : PRINT "8"
- ENDCASE
- COLOUR 0
- :
- ENDIF
- :
- extractinfo%(p%) = (note%*100)+(accid%*10)+octave%
- NEXT
- :
- ENDIF
- :
- ENDIF
- :
- IF extractmode$ = "random" AND quickextract$ = "y" THEN
- PRINT '" Random extractions follow "
- PRINT ' " each other at a distance "
- INPUT '" of between how many notes "lower%
- INPUT '" and how many notes "higher%
- ENDIF
- ENDPROC
- :
- REM*************************************************
- :
- DEF PROCequalizedurats
- :
- CLS
- PRINT'" There are ";manyattacks%-1;" durations "
- PRINT'" How many do you want to equalise? "
- PRINT " (0 = ";manyattacks%-1;")"
- INPUTnumdurats%
- IF numdurats% = 0 THEN numdurats% = manyattacks%-1
- INPUT'" Starting at duration number (0 = 1) "startattack%
- IF startattack% = 0 THEN startattack% = 1
- IF (manyattacks%-startattack%)<numdurats% THEN startattack% = manyattacks%-numdurats%
- totaldurats% = 0
- FOR count% = startattack% TO (startattack%+numdurats%-1)
- totaldurats%+=(attacks1%(count%)-attacks1%(count%-1))
- NEXT
- average = totaldurats%/numdurats%
- residue% = average * 10
- residue% = residue%MOD10
- IF residue%>=5 THEN average% = ((average)DIV1)+1 ELSE average% = (average)DIV1
- FOR count% = startattack% TO (startattack%+numdurats%-1)
- attacks1%(count%) = attacks1%(count%-1)+average%
- NEXT
- adjust% = totaldurats% - (average%*numdurats%)
- attacks1%(count%-1) += adjust%
- equalized$ = "y" : seeequalizey$ = "n"
- PROCinsertattacks
- ENDPROC
- :
- REM************************************************
- :
- DEF PROCsavevoice
- :
- *Dir SDFS::RISCOSpi.$.CAC.Files
- INPUT'" filename "filenamevoice$
- channel = OPENOUT filenamevoice$
- PRINT#channel, manyattacks%
- FOR a% = 0 TO manyattacks%-1
- PRINT#channel, attacks1%(a%)
- NEXT
- FOR a% = 0 TO manyattacks%-1
- PRINT#channel, pitches%(a%)
- NEXT
- FOR a% = 0 TO manyattacks%-1
- PRINT#channel, durations%(a%)
- NEXT
- FOR a% = 0 TO manyattacks%-1
- PRINT#channel, amplitudes%(a%)
- NEXT
- FOR a% = 0 TO manyattacks%-1
- PRINT#channel, envelopes%(a%)
- NEXT
- FOR a% = 0 TO manyattacks%-1
- PRINT#channel, glissandos%(a%)
- NEXT
- FOR a% = 0 TO manyattacks%-1
- PRINT#channel, inflections%(a%)
- NEXT
- CLOSE#channel
- *NoDir
- savevoice$ = "N" : PROCdisplay
- ENDPROC
- :
- REM**********************************
- :
- DEF PROCimportvoice
- :
- *Dir SDFS::RISCOSpi.$.CAC.Files
- INPUT'" filename "filenamevoice$
- channel = OPENIN filenamevoice$
- REPEAT
- INPUT#channel, manyattacks%
- FOR a% = 0 TO manyattacks%-1
- INPUT#channel, attacks1%(a%)
- NEXT
- FOR a% = 0 TO manyattacks%-1
- INPUT#channel, pitches%(a%)
- NEXT
- FOR a% = 0 TO manyattacks%-1
- INPUT#channel, durations%(a%)
- NEXT
- FOR a% = 0 TO manyattacks%-1
- INPUT#channel, amplitudes%(a%)
- NEXT
- FOR a% = 0 TO manyattacks%-1
- INPUT#channel, envelopes%(a%)
- NEXT
- FOR a% = 0 TO manyattacks%-1
- INPUT#channel, glissandos%(a%)
- NEXT
- FOR a% = 0 TO manyattacks%-1
- INPUT#channel, inflections%(a%)
- NEXT
- UNTIL EOF#channel
- CLOSE#channel
- *NoDir
- method$ = "raw" : copyit$ = "ON" : PROCinsertattacks
- ENDPROC
- :
- REM***********************************
- :
- DEF PROCpreintervalstring
- :
- PROCwindow(20,69,80,22)
- PRINT'" Re-run current interval string,"
- PRINT" create a new string, edit the"
- PRINT " current one, or load a file (R/N/E/F)"
- CASE GET$ OF
- WHEN "R","r" : PROCintervalstring
- WHEN "E","e" : loadstring$ = "n" :PROCeditintervalstring
- WHEN "F","f" : loadstring$ = "y" :PROCeditintervalstring
- OTHERWISE
- ENDCASE
- :
- filenamestg$ = ""
- numbannedpitches% = 0 : numbannedints% = 0 : bannedpitches%() = 0
- :
- INPUT'" How many pitches "numpitches%
- INPUT'" The tessitura is how many semitones wide "tess%
- PRINT'" The bottom pitch of the tessitura is ";
- COLOUR 3
- CASE GET$ OF
- WHEN "C","c" : note% = 1 : PRINT "C" : pitch$ = "C"
- WHEN "D","d" : note% = 3 : PRINT "D" : pitch$ = "D"
- WHEN "E","e" : note% = 5 : PRINT "E" : pitch$ = "E"
- WHEN "F","f" : note% = 6 : PRINT "F" : pitch$ = "F"
- WHEN "G","g" : note% = 8 : PRINT "G" : pitch$ = "G"
- WHEN "A","a" : note% = 10 : PRINT "A" : pitch$ = "A"
- WHEN "B","b" : note% = 12 : PRINT "B" : pitch$ = "B"
- ENDCASE
- COLOUR 0
- PRINT " Accidental ";
- COLOUR 3
- CASE GET$ OF
- WHEN "1" : note% -= 1 : PRINT "flat" : accid$ = "flat"
- WHEN "5" : PRINT "nat" : accid$ = "nat"
- WHEN "9" : note% += 1 : PRINT "shrp" : accid$ = "shrp"
- OTHERWISE VDU 7
- ENDCASE
- COLOUR 0
- PRINT " Octave ";
- COLOUR 3
- octave% = EVAL(GET$) : saveoctave% = octave%
- PRINT octave%
- COLOUR 0
- transposer% = note% + (12*(octave%-1)) - 1
- PRINT'" Are any pitches to be banned? "
- CASE GET$ OF
- WHEN "Y","y" :
- REPEAT
- numbannedpitches% += 1
- PRINT '" Pitch ";numbannedpitches%;" is, going up,"
- PRINT " semitone number what, starting at 0?"
- INPUT " (type F to finish) "bannedpitch$
- IF bannedpitch$ <> "F" AND bannedpitch$ <> "f" THEN bannedpitches%(numbannedpitches%) = EVAL(bannedpitch$) + 1
- UNTIL bannedpitch$ = "F" OR bannedpitch$ = "f"
- numbannedpitches% -= 1
- OTHERWISE
- ENDCASE
- :
- PRINT'" Are any intervals to be banned?"
- CASE GET$ OF
- WHEN "Y","y" :
- REPEAT
- numbannedints% += 1
- PRINT''" Interval ";numbannedints%;" is how many semitones?"
- PRINT" (NB intervals between 12 & 23 are "
- PRINT" applied at all compounds - "
- INPUT" type F to finish) "int$
- IF int$ <> "F" AND int$ <> "f" THEN
- PRINT'" And is banned at between a"
- INPUT" minimum of how many notes from the last one "range%
- INPUT" And a maximum of how many "range1%
- bannedints%(numbannedints%,0) = EVAL(int$)
- bannedints%(numbannedints%,1) = range%
- bannedints%(numbannedints%,2) = range1%
- ENDIF
- UNTIL int$ = "F" OR int$ = "f"
- numbannedints% -= 1
- OTHERWISE
- ENDCASE
- :
- stringattempts% = 0 : PROCintervalstring
- :
- ENDPROC
- :
- REM********************************************************
- :
- DEF PROCintervalstring
- :
- notenumber% = 0 : stringattempts% += 1
- :
- REPEAT
- notenumber% += 1 : triednotes%() = 0
- :
- REPEAT
- note% = RND(tess%+1) : triednotes%(note%) = 1
- count% = 0
- test$ = "pass"
- IF numbannedpitches% > 0 THEN
- REPEAT
- count% += 1
- IF note% = bannedpitches%(count%) THEN test$ = "fail"
- UNTIL test$ = "fail" OR count% = numbannedpitches%
- ENDIF
- :
- IF notenumber% > 1 AND numbannedints% > 0 AND test$ = "pass" THEN
- count% = 0
- REPEAT
- count% += 1 : count1% = 0
- REPEAT
- count1% += 1
- testnotenumber% = bannedints%(count%,1)+count1%-1
- testnotenumber% = notenumber%-testnotenumber%
- IF testnotenumber% > 0 THEN
- IF note% >= amplitudes%(testnotenumber%) THEN
- interval% = note%-amplitudes%(testnotenumber%)
- ELSE interval% = amplitudes%(testnotenumber%)-note%
- ENDIF
- :
- REPEAT
- IF interval% > 23 THEN interval% -= 12
- UNTIL interval% < 24
- IF interval% = bannedints%(count%,0) THEN test$ = "fail"
- :
- ENDIF
- UNTIL count1% > (bannedints%(count%,2)-bannedints%(count%,1)) OR test$ = "fail"
- UNTIL count% = numbannedints% OR test$ = "fail"
- ENDIF
- :
- REM check to see if all notes tried
- check$ = "alltried"
- FOR checker% = 1 TO tess%+1
- IF triednotes%(checker%) = 0 THEN check$ = "notalltried"
- NEXT
- UNTIL test$ = "pass" OR check$ = "alltried"
- :
- amplitudes%(notenumber%) = note%
- :
- IF check$ = "alltried" AND test$ = "fail" THEN whattodo$ = "abort" ELSE whattodo$ = "continue"
- UNTIL notenumber% = numpitches% OR whattodo$ = "abort"
- :
- IF whattodo$ = "abort" THEN
- CLS : PRINT''" Attempts from fresh start - ";stringattempts%
- PROCintervalstring
- ELSE
- FOR count% = 1 TO numpitches%
- amplitudes%(count%) += transposer%
- REM which octave
- count1% = 0
- REPEAT
- count1% += 1
- UNTIL (count1%*12) >= amplitudes%(count%)
- octave% = count1%
- REM which pitch and accid
- amplitudes%(count%) -= (12*(octave%-1))
- CASE amplitudes%(count%) OF
- WHEN 1 : pitches%(count%-1) = 50 + octave%
- WHEN 2 : pitches%(count%-1) = 90 + octave%
- WHEN 3 : pitches%(count%-1) = 150 + octave%
- WHEN 4 : pitches%(count%-1) = 210 + octave%
- WHEN 5 : pitches%(count%-1) = 250 + octave%
- WHEN 6 : pitches%(count%-1) = 350 + octave%
- WHEN 7 : pitches%(count%-1) = 390 + octave%
- WHEN 8 : pitches%(count%-1) = 450 + octave%
- WHEN 9 : pitches%(count%-1) = 490 + octave%
- WHEN 10 : pitches%(count%-1) = 550 + octave%
- WHEN 11 : pitches%(count%-1) = 610 + octave%
- WHEN 12 : pitches%(count%-1) = 650 + octave%
- ENDCASE
- NEXT
- PRINT'" Do you want to save this interval string?"
- CASE GET$ OF
- WHEN "Y","y" : PROCsaveintervalstring
- OTHERWISE
- ENDCASE
- PROCinsertpitches
- ENDIF
- :
- ENDPROC
- :
- REM**********************************************
- :
- DEF PROCsaveintervalstring
- :
- *Dir SDFS::RISCOSpi.$.CAC.Files
- firstnaming$ = "n"
- CLS
- IF filenamestg$ = "" THEN
- INPUT'" filename "filenamestg$
- firstnaming$ = "y"
- ENDIF
- IF firstnaming$ = "n" THEN
- PRINT'" as '";filenamestg$;"'?"
- CASE GET$ OF
- WHEN "N","n" : INPUT'" filename "filenamestg$
- OTHERWISE
- ENDCASE
- ENDIF
- :
- channel = OPENOUT filenamestg$
- PRINT#channel, numpitches%
- PRINT#channel, tess%
- PRINT#channel, numbannedpitches%
- PRINT#channel, numbannedints%
- PRINT#channel, transposer%
- PRINT#channel, pitch$
- PRINT#channel, accid$
- PRINT#channel, saveoctave%
- FOR a% = 1 TO numbannedpitches%
- PRINT#channel, bannedpitches%(a%)
- NEXT
- FOR a% = 1 TO numbannedints%
- FOR b% = 0 TO 2
- PRINT#channel, bannedints%(a%,b%)
- NEXT
- NEXT
- :
- CLOSE#channel
- *NoDir
- :
- ENDPROC
- :
- REM******************************************
- :
- DEF PROCloadintervalstring
- :
- *Dir SDFS::RISCOSpi.$.CAC.Files
- INPUT'" filename "filenamestg$
- channel = OPENIN filenamestg$
- REPEAT
- INPUT#channel, numpitches%
- INPUT#channel, tess%
- INPUT#channel, numbannedpitches%
- INPUT#channel, numbannedints%
- INPUT#channel, transposer%
- INPUT#channel, pitch$
- INPUT#channel, accid$
- INPUT#channel, saveoctave%
- FOR a% = 1 TO numbannedpitches%
- INPUT#channel, bannedpitches%(a%)
- NEXT
- FOR a% = 1 TO numbannedints%
- FOR b% = 0 TO 2
- INPUT#channel, bannedints%(a%,b%)
- NEXT
- NEXT
- UNTIL EOF#channel
- CLOSE#channel
- *NoDir
- :
- ENDPROC
- :
- REM**************************************
- :
- DEF PROCeditintervalstring
- :
- IF loadstring$ = "y" THEN PROCloadintervalstring
- :
- CLS
- PRINT'" Alter the number of pitches?"
- PRINT" (currently ";numpitches%;")"
- CASE GET$ OF
- WHEN "Y","y" :
- INPUT'" How many pitches "numpitches%
- ENDCASE
- CLS
- PRINT'" Alter tessitura and/or location?"
- PRINT" (currently ";tess%;" semitones wide"
- PRINT" with a bottom note of ";pitch$;accid$;saveoctave%;")"
- CASE GET$ OF
- WHEN "Y","y" :
- INPUT'" The tessitura is how many semitones wide "tess%
- PRINT'" The bottom pitch of the tessitura is ";
- COLOUR 3
- CASE GET$ OF
- WHEN "C","c" : note% = 1 : PRINT "C" : pitch$ = "C"
- WHEN "D","d" : note% = 3 : PRINT "D" : pitch$ = "D"
- WHEN "E","e" : note% = 5 : PRINT "E" : pitch$ = "E"
- WHEN "F","f" : note% = 6 : PRINT "F" : pitch$ = "F"
- WHEN "G","g" : note% = 8 : PRINT "G" : pitch$ = "G"
- WHEN "A","a" : note% = 10 : PRINT "A" : pitch$ = "A"
- WHEN "B","b" : note% = 12 : PRINT "B" : pitch$ = "B"
- ENDCASE
- COLOUR 0
- PRINT " Accidental ";
- COLOUR 3
- CASE GET$ OF
- WHEN "1" : note% -= 1 : PRINT "flat" : accid$ = "flat"
- WHEN "5" : PRINT "nat" : accid$ = "nat"
- WHEN "9" : note% += 1 : PRINT "shrp" : accid$ = "shrp"
- OTHERWISE VDU 7
- ENDCASE
- COLOUR 0
- PRINT " Octave ";
- COLOUR 3
- octave% = EVAL(GET$) : saveoctave% = octave%
- PRINT octave%
- COLOUR 0
- transposer% = note% + (12*(octave%-1)) - 1
- OTHERWISE
- ENDCASE
- :
- PRINT'" Alter the banning of pitches? "
- IF numbannedpitches% = 0 THEN
- PRINT" No pitches are currently banned "
- ELSE
- PRINT" Currently banned pitches are,"
- PRINT" going up, starting at 0 -"
- PRINT" "
- VDU 14
- FOR count% = 1 TO numbannedpitches%
- PRINT " ";count%;". semitone ";bannedpitches%(count%)-1
- NEXT
- VDU 15
- ENDIF
- CASE GET$ OF
- WHEN "Y","y" :
- INPUT'" The number of banned pitches is now to be "numbannedpitches%
- FOR count% = 1 TO numbannedpitches%
- PRINT'" Alter banned pitch ";count%
- CASE GET$ OF
- WHEN "Y","y" :
- PRINT '" Pitch ";count%;" is, going up,"
- INPUT " semitone number what, starting at 0?"semitone%
- bannedpitches%(count%) = semitone%+1
- ENDCASE
- NEXT
- ENDCASE
- CLS : VDU 14
- PRINT'" Alter the banning of intervals?"
- IF numbannedints% = 0 THEN
- PRINT" No intervals are currently banned "
- ELSE
- VDU 28,20,43,70,15
- PRINT" Currently banned intervals are -"
- PRINT" "
- FOR count% = 1 TO numbannedints%
- IF bannedints%(count%,1) > 0 THEN COLOUR 131 ELSE COLOUR 191
- IF count% > 9 AND bannedints%(count%,0) > 9 THEN PRINT " ";count%;". ";bannedints%(count%,0);" semitones at between ";bannedints%(count%,1);" and ";bannedints%(count%,2);" notes"
- IF count% < 10 EOR bannedints%(count%,0) < 10 THEN PRINT " ";count%;". ";bannedints%(count%,0);" semitones at between ";bannedints%(count%,1);" and ";bannedints%(count%,2);" notes"
- IF count% < 10 AND bannedints%(count%,0) < 10 THEN PRINT " ";count%;". ";bannedints%(count%,0);" semitones at between ";bannedints%(count%,1);" and ";bannedints%(count%,2);" notes"
- NEXT
- COLOUR 191
- VDU 15
- ENDIF
- CASE GET$ OF
- WHEN "Y","y" :
- VDU 28,20,65,70,45
- PRINT'" Alter the number of banned intervals?"
- CASE GET$ OF
- WHEN "Y","y" :
- INPUT'" The number of banned intervals is now to be "numbannedints%
- ENDCASE
- FOR count% = 1 TO numbannedints%
- PRINT'" Alter interval ";count%
- CASE GET$ OF
- WHEN "Y","y" :
- PRINT'" Interval ";count%;" is how many semitones?"
- PRINT" (NB intervals between 12 & 23 are "
- INPUT" applied at all compounds) "bannedints%(count%,0)
- PRINT'" And is banned at between a minimum"
- INPUT" of how many notes from the last one "range%
- INPUT" And a maximum of how many "range1%
- bannedints%(count%,1) = range%
- bannedints%(count%,2) = range1%
- OTHERWISE
- ENDCASE
- NEXT
- ENDCASE
- :
- stringattempts% = 0 : PROCintervalstring
- :
- ENDPROC
- :
- REM********************************************************
- :
- DEF PROCconvertpitch
- :
- CASE (pitch%DIV10^2) OF
- WHEN 0 : note% = 1
- WHEN 1 : note% = 3
- WHEN 2 : note% = 5
- WHEN 3 : note% = 6
- WHEN 4 : note% = 8
- WHEN 5 : note% = 10
- WHEN 6 : note% = 12
- ENDCASE
- :
- CASE ((pitch%DIV10)MOD10) OF
- WHEN 1 : note% -= 1
- WHEN 9 : note% += 1
- OTHERWISE
- ENDCASE
- :
- octave% = pitch%MOD10
- note% = note% + (12*(octave%-1))
- chunk% = 12 : compoundint% = compoundpitch%
- ENDPROC
- :
- REM****************************************************
- :
- DEF PROCconvertquarter
- :
- CASE (pitch%DIV10^2) OF
- WHEN 0 : note% = 2
- WHEN 1 : note% = 6
- WHEN 2 : note% = 10
- WHEN 3 : note% = 12
- WHEN 4 : note% = 16
- WHEN 5 : note% = 20
- WHEN 6 : note% = 24
- ENDCASE
- :
- CASE ((pitch%DIV10)MOD10) OF
- WHEN 1 : note% -= 2
- WHEN 3 : note% -= 1
- WHEN 7 : note% += 1
- WHEN 9 : note% += 2
- OTHERWISE
- ENDCASE
- :
- octave% = pitch%MOD10
- note% = note% + (24*(octave%-1))
- chunk% = 24 : compoundint% = compoundquarter%
- ENDPROC
- ENDPROC
- :
- REM****************************************************
- :
- DEF PROCconverteighth
- :
- CASE (pitch%DIV10^2) OF
- WHEN 0 : note% = 4
- WHEN 1 : note% = 12
- WHEN 2 : note% = 20
- WHEN 3 : note% = 24
- WHEN 4 : note% = 32
- WHEN 5 : note% = 40
- WHEN 6 : note% = 48
- ENDCASE
- :
- CASE ((pitch%DIV10)MOD10) OF
- WHEN 1 : note% -= 4
- WHEN 2 : note% -= 3
- WHEN 3 : note% -= 2
- WHEN 4 : note% -= 1
- WHEN 6 : note% += 1
- WHEN 7 : note% += 2
- WHEN 8 : note% += 3
- WHEN 9 : note% += 4
- OTHERWISE
- ENDCASE
- :
- octave% = pitch%MOD10
- note% = note% + (48*(octave%-1))
- chunk% = 48 : compoundint% = compoundeighth%
- ENDPROC
- :
- REM****************************************************
- :
- DEF PROCconvertcent
- :
- CASE (pitch%DIV10^2) OF
- WHEN 0 : note% = 100
- WHEN 1 : note% = 300
- WHEN 2 : note% = 500
- WHEN 3 : note% = 600
- WHEN 4 : note% = 800
- WHEN 5 : note% = 1000
- WHEN 6 : note% = 1200
- ENDCASE
- :
- CASE ((pitch%DIV10)MOD10) OF
- WHEN 1 : note% -= 100
- WHEN 2 : note% -= 75
- WHEN 3 : note% -= 50
- WHEN 4 : note% -= 25
- WHEN 6 : note% += 25
- WHEN 7 : note% += 50
- WHEN 8 : note% += 75
- WHEN 9 : note% += 100
- OTHERWISE
- ENDCASE
- :
- octave% = pitch%MOD10
- note% = note% + (1200*(octave%-1)) + cent%
- chunk% = 1200 : compoundint% = compoundcent%
- ENDPROC
- :
- REM****************************************************
- :
- DEF PROCrandomnumber
- :
- PROCwindow(20,65,65,55)
- CLS
- :
- IF rerun$ = "n" THEN
- INPUT'" Return a random number between ? "ranx%
- INPUT " and ? "rany%
- ENDIF
- diff% = (rany%-ranx%)+1
- PRINT' RND(diff%)+(ranx%-1)
- :
- PRINT '" (press R to re-run, U for new number "
- PRINT " or any key to continue) "
- CASE GET$ OF
- WHEN "U","u" : rerun$ = "n" : PROCrandomnumber
- WHEN "R","r" : rerun$ = "y" : PROCrandomnumber
- OTHERWISE PROCdisplay
- ENDCASE
- ENDPROC
- :
- REM****************************************************
- :
- DEF PROCcheckproportiontotal
- :
- proportiontotal$ = "notOK"
- :
- it% = 0
- REPEAT
- it% += 1
- mplier = 0.5
- REPEAT
- mplier = mplier*2
- testnum% = it%*mplier
- posslownum = grouplength%/beatfactor%
- WHILE posslownum > proportiontotal%
- posslownum = posslownum/2
- ENDWHILE
- WHILE posslownum <= (proportiontotal%/2)
- posslownum = posslownum*2
- ENDWHILE
- IF proportiontotal% = testnum% AND ((it%/testnum%)*posslownum*10^3)MOD10^3=0 THEN proportiontotal$ = "OK"
- IF proportiontotal% = posslownum THEN proportiontotal$ = "OK"
- UNTIL proportiontotal$ = "OK" OR testnum% > (grouplength%/defaultmindur%)
- UNTIL proportiontotal$ = "OK" OR it% = given%
- :
- IF proportiontotal%>9999 THEN proportiontotal$ = "notOK"
- :
- ENDPROC
- :
- REM***************************************************
- :
- DEF PROCredpitches
- :
- tiss% = 0
- REPEAT
- tiss%+=1
- toss% = 0 : dored$ = "n"
- REPEAT
- toss%+=1
- IF (array%(startcell%,0,voice%)MOD10^3) = redpitches%(tiss%,toss%) THEN
- IF printing$ = "n" THEN GCOL tiss%
- dored$ = "y"
- ENDIF
- UNTIL dored$ = "y" OR toss% = numredpitches%(tiss%)
- UNTIL dored$ = "y" OR tiss% = numcols%
- ENDPROC
- :
- REM****************************************************
- :
- DEF PROCpitchstring2
- :
- IF easiermenus$ = "n" THEN PROCwindow(20,65,60,55) ELSE PROCwindow(20,65,60,42)
- PRINT'" This function returns a string"
- PRINT" of pitches drawn from a semitonal"
- PRINT" cluster based on middle C,"
- PRINT" with a controlled chance "
- PRINT" of pitch repetitions"
- INPUT'" How many semitones in the cluster "numsemis%
- INPUT'" How many pitches in the string "numpitches%
- PRINT'" Randomly occuring pitch repetitions "
- PRINT" are included or not by what "
- INPUT" percentage? "percentage%
- :
- x% = RND(numsemis%)
- CASE x% OF
- WHEN 1 : pitches%(0) = 54
- WHEN 2 : pitches%(0) = 94
- WHEN 3 : pitches%(0) = 154
- WHEN 4 : pitches%(0) = 214
- WHEN 5 : pitches%(0) = 254
- WHEN 6 : pitches%(0) = 354
- WHEN 7 : pitches%(0) = 394
- WHEN 8 : pitches%(0) = 454
- WHEN 9 : pitches%(0) = 514
- WHEN 10 : pitches%(0) = 554
- WHEN 11 : pitches%(0) = 614
- WHEN 12 : pitches%(0) = 654
- ENDCASE
- :
- FOR count% = 1 TO numpitches%-1
- REPEAT
- continue$ = "y"
- x% = RND(numsemis%)
- CASE x% OF
- WHEN 1 : pitches%(count%) = 54
- WHEN 2 : pitches%(count%) = 94
- WHEN 3 : pitches%(count%) = 154
- WHEN 4 : pitches%(count%) = 214
- WHEN 5 : pitches%(count%) = 254
- WHEN 6 : pitches%(count%) = 354
- WHEN 7 : pitches%(count%) = 394
- WHEN 8 : pitches%(count%) = 454
- WHEN 9 : pitches%(count%) = 514
- WHEN 10 : pitches%(count%) = 554
- WHEN 11 : pitches%(count%) = 614
- WHEN 12 : pitches%(count%) = 654
- ENDCASE
- :
- IF pitches%(count%) = pitches%(count%-1) THEN
- y% = RND(100)
- IF y% <= percentage% THEN continue$ = "y" ELSE continue$ = "n"
- ENDIF
- UNTIL continue$ = "y"
- NEXT
- :
- PROCinsertpitches
- ENDPROC
- :
- REM***************************************
- :
- DEF PROCrhythmdefaults
- shortirrat% = 240
- longirrat% = 240
- irratbeats% = 4
- irratbeats1% = 4
- mindur% = 60 : sieve = 960/mindur%
- buffer% = 960/(sieve*2)
- given% = 9
- defaultsieve = 2
- ENDPROC
- :
- REM******************************************
- :
- DEF PROCdisplayoptions
- :
- PROCwindow(2,72,97,1)
- OFF
- PRINT' " Do you want to (press to toggle)"
- IF copytoend$ = "y" THEN state$ = "on" ELSE state$ = "off"
- IF seegraph$ = "y" THEN state1$ = "on" ELSE state1$ = "off"
- PRINT' " See graph during accel/rit G (";state1$;") Allow copying to last note ^A (";state$;")"
- IF seeinfo$ = "y" THEN state$ = "on" ELSE state$ = "off"
- IF nodelay$ = "y" THEN state1$ = "on" ELSE state1$ = "off"
- PRINT' " See info on attacks A (";state$;") Pause for querying stave ^D (";state1$;")"
- IF printinfo$ = "y" THEN state$ = "on" ELSE state$ = "off"
- IF askprevious$ = "y" THEN state1$ = "on" ELSE state1$ = "off"
- PRINT' " get printout of info on attacks I (";state$;") Pause for previous position^F (";state1$;")"
- IF seereorder$ = "y" THEN state$ = "on" ELSE state$ = "off"
- IF errorbeforedisplay$ = "n" THEN state1$ = "off" ELSE state1$ = "on"
- PRINT' " Re-order attacks R (";state$;") Debugging mode ^G (";state1$;")"
- IF seereorderx$ = "y" THEN state$ = "on" ELSE state$ = "off"
- PRINT' " Re-order attacks during accel/rit only ^R (";state$;")"
- IF seeequalize$ = "y" THEN state$ = "on" ELSE state$ = "off"
- PRINT' " Equalize attacks E (";state$;") [press spacebar to continue] "
- IF seeequalizex$ = "y" THEN state$ = "on" ELSE state$ = "off"
- PRINT' " Equalize attacks during accel/rit only ^E (";state$;")"
- IF seerhythmicize$ = "y" THEN state$ = "on" ELSE state$ = "off"
- PRINT' " Rhythmicize attacks H (";state$;")"
- IF reorderpitches$ = "y" THEN state$ = "on" ELSE state$ = "off"
- PRINT' " Re-order pitches using M/A/P ^P (";state$;")"
- IF seequery$ = "y" THEN state$ = "on" ELSE state$ = "off"
- PRINT' " Query before adding new values to array Q (";state$;")"
- PRINT' " Define parameter values during input P (";paraset$;")"
- PRINT' " Accel/rit by total durat, endpoints or "
- PRINT " first two notes displayed T/N/F (";funcinput$;")"
- IF startfinishdurats$ = "Y" THEN state$ = "on" ELSE state$ = "off"
- PRINT' " Accel/rit by start and finish durations S (";state$;")"
- IF seeduration$ = "y" THEN state$ = "on" ELSE state$ = "off"
- PRINT' " See duration upto last displayed bar D (";state$;")"
- IF quickcopy$ = "y" THEN state$ ="on" ELSE state$ = "off"
- PRINT' " Quick copy B (";state$;")"
- CASE seedurinbts$ OF
- WHEN "y" : state$ = "on"
- WHEN "stepped" : state$ = "stepped"
- WHEN "n" : state$ = "off"
- ENDCASE
- PRINT' " See durations in micro-beats K (";state$;")"
- CASE seedurincrots$ OF
- WHEN "y" : state$ = "on"
- WHEN "stepped" : state$ = "stepped"
- WHEN "n" : state$ = "off"
- ENDCASE
- PRINT' " See durations in macro-beats C (";state$;")"
- IF screenvoices$ = "y" THEN state$ = "on" ELSE state$ = "off"
- PRINT' " Voice numbers by 1/2/3 on screen V (";state$;")"
- IF ampoptions$ = "y" THEN state$ = "on" ELSE state$ = "off"
- PRINT' " Use advanced amplitudes options O (";state$;")"
- PRINT' " Double v/^ moves down/up by 3/10 staves Z (";screenmovesby%;")"
- CASE setalong$ OF
- WHEN "y" : state$ = "A/R"
- WHEN "n" : state$ = "quick"
- WHEN "playnovoices" : state$ = "play"
- ENDCASE
- PRINT' " 1,2 = A/R start/quickdisplay/play vces J (";state$;")"
- CASE envelopedata$ OF
- WHEN "none" : stage$ = "neither"
- WHEN "percentage" : stage$ = "%'s"
- WHEN "marker" : stage$ = "indicators"
- ENDCASE
- PRINT' " See envelope %'s/indicators/neither L (";stage$;")"
- IF askaboutpitches$ = "y" THEN state$ = "on" ELSE state$ = "off"
- PRINT' " Query if pitches all the same M (";state$;")"
- IF usebottomstave$ = "y" THEN state$ = "on" ELSE state$ = "off"
- PRINT' " Group of pitches fills bottom stave U (";state$;")"
- CASE sequalssection$ OF
- WHEN "y" : state$ = "sect"
- WHEN "n" : state$ = "next"
- ENDCASE
- PRINT' " Copy from next voices/Go to section ^S (";state$;")"
- IF addpitches$ = "y" THEN state$ = "pitch" ELSE state$ = "env"
- PRINT' " ^Y = Add pitches/edit envelope Y (";state$;")"
- IF squarebracket$ = "remarks" THEN state$ = "remarks" ELSE state$ = "copy +"
- PRINT' " [] keys = move remarks/add to copydown [ (";state$;")"
- IF queryalong$ = "y" THEN state$ = "on" ELSE state$ = "off"
- PRINT' " Accel/rit asks for starting attack ] (";state$;")"
- PRINT' " Reset no.staves ^/v moves up/down by ~"
- IF singlepitch$ = "m" THEN state$ = "multiple" ELSE state$ = "single"
- PRINT' " Y = single/multiple pitch entry @ (";state$;")"
- IF namestaves$ = "nameone" THEN state$ = "rename" ELSE state$ = "delete"
- PRINT' " ^V = rename/delete batch of voice names^V (";state$;")"
- IF usebeep$ = "n" THEN state$ = "assnd" ELSE state$ = "beep"
- PRINT' " Play with beep or assigned voices ^B (";state$;")"
- IF onlycontent$ = "y" THEN state$ = "on" ELSE state$ = "off"
- PRINT' " Display only voices with content ^C (";state$;")"
- PRINT' " Show list of voices with content ^L"
- :
- CASE GET$ OF
- :
- WHEN "g" :
- IF seegraph$ = "y" THEN seegraph$ = "n" ELSE seegraph$ = "y"
- WHEN "a" :
- IF seeinfo$ = "y" THEN seeinfo$ = "n" ELSE seeinfo$ = "y"
- WHEN "A" :
- IF copytoend$ = "y" THEN copytoend$ = "n" ELSE copytoend$ = "y"
- WHEN "I","i" :
- IF printinfo$ = "y" THEN printinfo$ = "n" ELSE printinfo$ = "y"
- WHEN "r" :
- IF seereorder$ = "y" THEN
- seereorder$ = "n"
- seereordery$ = "n"
- ELSE
- seereorder$ = "y"
- seereorderx$ = "y"
- seereordery$ = "y"
- ENDIF
- WHEN "R" :
- IF seereorderx$ = "y" THEN
- seereorderx$ = "n"
- seereordery$ = "n"
- ELSE seereorderx$ = "y"
- ENDIF
- WHEN "e" :
- IF seeequalize$ = "y" THEN
- seeequalize$ = "n"
- seeequalizey$ = "n"
- ELSE
- seeequalize$ = "y"
- seeequalizex$ = "y"
- seeequalizey$ = "y"
- ENDIF
- WHEN "E" :
- IF seeequalizex$ = "y" THEN
- seeequalizex$ = "n"
- seeequalizey$ = "n"
- ELSE seereorderx$ = "y"
- ENDIF
- WHEN "P" :
- IF reorderpitches$ = "y" THEN reorderpitches$ = "n" ELSE reorderpitches$ = "y"
- WHEN "H","h" :
- IF seerhythmicize$ = "y" THEN seerhythmicize$ = "n" ELSE seerhythmicize$ = "y"
- WHEN "Q","q" :
- IF seequery$ = "y" THEN seequery$ = "n" ELSE seequery$ = "y"
- WHEN "p" :
- IF paraset$ = "on" THEN paraset$ = "off" ELSE paraset$ = "on"
- WHEN "T","t" :
- funcinput$ = "durat"
- WHEN "N","n" :
- funcinput$ = "points"
- WHEN "f" :
- funcinput$ = "displayed"
- WHEN "s" :
- IF startfinishdurats$ = "Y" THEN startfinishdurats$ = "N" ELSE startfinishdurats$ = "Y"
- WHEN "d" :
- IF seeduration$ = "y" THEN
- seeduration$ = "n" : PROCdisplay
- ELSE seeduration$ = "y" : PROCdisplay
- ENDIF
- WHEN "b" :
- IF quickcopy$ = "n" THEN quickcopy$ = "y" ELSE quickcopy$ = "n"
- WHEN "K","k" :
- IF seedurinbts$ = "n" THEN
- seedurinbts$ = "y" : seedurincrots$ = "n" : PROCdisplay
- ENDIF
- IF seedurinbts$ = "y" THEN
- seedurinbts$ = "stepped" : seedurincrots$ = "n" : PROCdisplay
- ENDIF
- IF seedurinbts$ = "stepped" THEN
- seedurinbts$ = "n": PROCdisplay
- ENDIF
- WHEN "c" :
- IF seedurincrots$ = "n" THEN
- seedurincrots$ = "y" : seedurinbts$ = "n" : PROCdisplay
- ENDIF
- IF seedurincrots$ = "y" THEN
- seedurincrots$ = "stepped" : seedurinbts$ = "n" : PROCdisplay
- ENDIF
- IF seedurincrots$ = "stepped" THEN
- seedurincrots$ = "n" : PROCdisplay
- ENDIF
- WHEN "v" :
- IF screenvoices$ = "n" THEN screenvoices$ = "y" ELSE screenvoices$ = "n" : PROCdisplay
- WHEN "V" :
- IF namestaves$ = "nameone" THEN namestaves$ = "deletemany" ELSE namestaves$ = "nameone"
- WHEN "O","o" :
- IF ampoptions$ = "n" THEN ampoptions$ = "y" ELSE ampoptions$ = "n" : PROCdisplay
- WHEN "z","Z" : IF screenmovesby% = 10 THEN screenmovesby% = 3 ELSE screenmovesby% = 10 : PROCdisplay
- WHEN "J","j" :
- CASE setalong$ OF
- WHEN "y" : setalong$ = "n"
- WHEN "n" : setalong$ = "playnovoices"
- WHEN "playnovoices" : setalong$ = "y"
- ENDCASE
- WHEN "l" :
- CASE envelopedata$ OF
- WHEN "none" : envelopedata$ = "percentage"
- WHEN "percentage" : envelopedata$ = "marker"
- WHEN "marker" : envelopedata$ = "none"
- ENDCASE
- WHEN "M","m" :
- IF askaboutpitches$ = "y" THEN askaboutpitches$ = "n" ELSE askaboutpitches$ = "y"
- WHEN "U","u" :
- IF usebottomstave$ = "y" THEN usebottomstave$ = "n" ELSE usebottomstave$ = "y"
- IF usebottomstave$ = "y" THEN askaboutpitches$ = "n" ELSE askaboutpitches$ = "y"
- WHEN "S" :
- CASE sequalssection$ OF
- WHEN "y" : sequalssection$ = "n"
- WHEN "n" : sequalssection$ = "y"
- ENDCASE
- WHEN "y","Y" :
- IF addpitches$ = "y" THEN addpitches$ = "n" ELSE addpitches$ = "y"
- WHEN "[" :
- IF squarebracket$ = "remarks" THEN squarebracket$ = "addten" ELSE squarebracket$ = "remarks"
- WHEN "]" :
- IF queryalong$ = "y" THEN queryalong$ = "n" ELSEqueryalong$ = "y"
- WHEN "~" :
- CLS
- INPUT " pressing ^ or v movesup/down by how many staves "updisplay%
- WHEN "@" :
- IF singlepitch$ = "s" THEN singlepitch$ = "m" ELSE singlepitch$ = "s"
- WHEN "B" :
- IF usebeep$ = "y" THEN usebeep$ = "n" ELSE usebeep$ = "y"
- WHEN "C" :
- IF onlycontent$ = "y" THEN onlycontent$ = "n" ELSE onlycontent$ = "y"
- PROCdisplayonlycontent
- WHEN "L" : PROCcontentonlylist
- WHEN "D" : IF nodelay$ = "y" THEN nodelay$ = "n" ELSE nodelay$ = "y"
- WHEN "F" : IF askprevious$ = "y" THEN askprevious$ = "n" ELSE askprevious$ = "y"
- WHEN "G" : IF errorbeforedisplay$ = "n" THEN errorbeforedisplay$ = "debug" ELSE errorbeforedisplay$ = "n"
- :
- OTHERWISE
- :
- ENDCASE
- ON
- :
- ENDPROC
- :
- REM******************************************************************
- :
- DEF PROCremarks
- :
- INPUT'" Which bar "baar%
- PRINT" line 1 or 2 "
- CASE GET$ OF
- WHEN "1" : line% = 0
- WHEN "2" : line% = 1
- OTHERWISE VDU7 : PROCremarks
- ENDCASE
- INPUT " What are the remarks "remarks$
- remarks$(baar%,line%) = remarks$
- :
- ENDPROC
- :
- REM********************************************************************
- :
- DEF PROCwindow(a%,b%,c%,d%)
- :
- bigger$ = "n"
- IF a% < biga% THEN
- biga% = a% : bigger$ = "y"
- ENDIF
- IF b% > bigb% THEN
- bigb% = b% : bigger$ = "y"
- ENDIF
- IF c% > bigc% THEN
- bigc% = c% : bigger$ = "y"
- ENDIF
- IF d% < bigd% THEN
- bigd% = d% : bigger$ = "y"
- ENDIF
- :
- IF box$ = "n" THEN
- box$ = "y"
- VDU 28,a%-1,b%+1,c%+1,d%-1 : COLOUR 131 : CLS
- VDU 28,a%,b%,c%,d% : COLOUR 0 : COLOUR 191 : CLS : OFF
- ELSE
- IF bigger$ = "y" THEN
- VDU 28,a%-1,b%+1,c%+1,d%-1 : COLOUR 131 : CLS
- ENDIF
- CLS : VDU 28,a%,b%,c%,d% : COLOUR 0 : COLOUR 191 : CLS : OFF
- ENDIF
- :
- ENDPROC
- :
- REM***********************************************
- :
- DEF PROCslave
- REM this program returns not simply a random
- REM percentage (tends to be too high) nor
- REM a random percentage of a random percentage
- REM (tends to be too low), but something
- REM inbetween, averaging not 50% nor 25% but 37.5%
- :
- IF quickslave$ = "n" THEN
- IF easiermenus$ = "n" THEN PROCwindow(20,69,96,55) ELSE PROCwindow(20,69,96,42)
- PRINT''" To begin, display the Mastervoice's two half-phases first on the screen."
- PRINT " This function then generates a Slavevoice's associated two half-phases,"
- PRINT " their random starting and ending points averaging 37.5% and 62.5% of the"
- PRINT " MV half-phases respectively (other averages tend to be too high or too low)"
- PRINT '" Alternatively, percentages may be determined - "
- PRINT " press D for determined or R for random now "
- CASE GET$ OF
- WHEN "D","d" : slavemethod$ = "determined"
- OTHERWISE slavemethod$ = "random"
- ENDCASE
- ENDIF
- :
- test$ = "n"
- PROCinput
- :
- ENDPROC
- :
- DEF PROCinput
- REM procedure for getting first 2 attacks displayed
- IF quickslave$ = "y" THEN
- IF easiermenus$ = "n" THEN PROCwindow(20,67,49,55) ELSE PROCwindow(20,67,49,42)
- ENDIF
- INPUT '" Mastervoice is which voice "voice%
- IF voice% = 0 THEN voice% = savevoice%
- IF voice% <> 0 THEN savevoice% = voice%
- voice% -= 1
- startingbar% = array%(holdstartcell%(voice%)+along%,0,voice%)DIV10^6
- startbeat% = (array%(holdstartcell%(voice%)+along%,0,voice%)MOD10^6)DIV10^3
- midbar% = array%(holdstartcell%(voice%)+1+along%,0,voice%)DIV10^6
- midbeat% = (array%(holdstartcell%(voice%)+1+along%,0,voice%)MOD10^6)DIV10^3
- endbar% = array%(holdstartcell%(voice%)+2+along%,0,voice%)DIV10^6
- endbeat% = (array%(holdstartcell%(voice%)+2+along%,0,voice%)MOD10^6)DIV10^3
- startpoint% = startingbar%*960
- startpoint% += startbeat%
- midpoint% = midbar%*960
- midpoint% += midbeat%
- endpoint% = endbar% * 960
- endpoint% += endbeat%
- PROCprogram
- ENDPROC
- :
- DEF PROCprogram
- IF test$ = "y" THEN number% = 1000 ELSE number% = 1
- total% = 0 : total1% = 0
- FOR count% = 1 TO number%
- firstdur% = midpoint%-startpoint%
- seconddur% = endpoint%-midpoint%
- REPEAT
- IF slavemethod$ = "determined" THEN
- INPUT'" Percentage for first half-phase is..."percentage%
- ELSE
- c% = RND(100)
- percentage% = RND(100) * (RND(101-c%)+(c%-1)) / 100
- ENDIF
- UNTIL percentage% >= lowerstart% AND percentage% <= upperstart%
- SVfirstdur% = firstdur%*percentage%/100
- REPEAT
- IF slavemethod$ = "determined" THEN
- INPUT'" Percentage for second half-phase is..."percentage1%
- ELSE
- c% = RND(100)
- percentage1% = 100 - (RND(100) * (RND(101-c%)+(c%-1)) / 100)
- ENDIF
- UNTIL percentage1% >= lowerend% AND percentage1% <= upperend%
- SVseconddur% = seconddur%*percentage1%/100
- :
- SVtotaldur% = firstdur% - SVfirstdur% + SVseconddur%
- SVthirddur% = SVtotaldur%/(firstdur%+seconddur%)*firstdur%
- :
- SVbar% = startingbar%
- SVbeat% = startbeat% + SVfirstdur%
- PROCbeats
- SVstartbar% = SVbar% : SVstartbeat% = SVbeat%
- :
- SVbar% = SVstartbar%
- SVbeat% = SVstartbeat% + SVthirddur%
- PROCbeats
- SVmidbar% = SVbar% : SVmidbeat% = SVbeat%
- :
- SVbar% = midbar%
- SVbeat% = midbeat% + SVseconddur%
- PROCbeats
- SVendbar% = SVbar% : SVendbeat% = SVbeat%
- :
- IF quickslave$ = "y" THEN
- IF easiermenus$ = "n" THEN PROCwindow(20,69,82,55) ELSE PROCwindow(20,69,82,42)
- ENDIF
- CLS
- PRINT'" The Slavevoice's first half-phase starts at ";SVstartbar%;".";SVstartbeat%;" (";percentage%;"%)"
- PRINT '" and ends at ";SVmidbar%;".";SVmidbeat%
- PRINT '" And its second half-phase ends at ";SVendbar%;".";SVendbeat%;" (";percentage1%;"%)"
- total% += percentage% : total1% += percentage1%
- NEXT
- IF test$ = "y" THEN
- PRINT''" Average 1st percent = ";total%/1000
- PRINT" Average second = ";total1%/1000
- PRINT'" to continue press C"
- CASE GET$ OF
- WHEN"C","c" : PROCdisplay
- ENDCASE
- ENDIF
- PRINT''" Do you want to add this slave voice to the array?"
- PRINT" (or, to test average percentages out of 1000 throws, press P"
- PRINT" or, to set limits for the random percentages, press L)"
- CASE GET$ OF
- WHEN"Y","y" :
- WHEN"N","n" : PROCdisplay
- WHEN "P","p" : test$ = "y" : PROCprogram
- WHEN "L","l" : PROClimits
- ENDCASE
- attacks1%(1) = ((SVmidbar%*960)+SVmidbeat%) - ((SVstartbar%*960)+SVstartbeat%)
- attacks1%(2) = ((SVendbar%*960)+SVendbeat%) - ((SVstartbar%*960)+SVstartbeat%)
- funcbar% = SVstartbar% : funcbeat% = SVstartbeat%
- method$ = "raw" : quiz$ = "no" : manyattacks% = 3
- PROCinsertattacks
- ENDPROC
- :
- DEF PROCbeats
- WHILE SVbeat% > 959
- SVbeat% -= 960 : SVbar% += 1
- ENDWHILE
- ENDPROC
- :
- DEF PROClimits
- INPUT'" Give the lower limit for SV's start-point, between 1% & 99% "lowerstart%
- INPUT " Give the upper limit for SV's start-point, between 1% & 99% "upperstart%
- INPUT'" Give the lower limit for SV's end-point, between 1% & 99% "lowerend%
- PRINT " Give the upper limit for SV's end-point, between 1% & 99% "
- INPUT " (these limits last for the session) "upperend%
- PROCdisplay
- ENDPROC
- :
- ENDPROC
- :
- REM*******************************************
- :
- DEF PROCprintattacks
- :
- durat% = 0
- MODE 16 : COLOUR 0 : COLOUR 191 : CLS
- PRINT '" The group of attacks will be at "
- PRINT" "
- PRINT TAB(8) "ATTACKS AT";
- PRINT TAB(30) "DURATIONS";
- PRINT TAB(54) "RATIOS"
- tal% = 0 : printnum% = 0
- FOR count% = 0 TO (manyattacks%-1)
- tal% += 1
- PRINT TAB(1)(attacks2%(count%))DIV10^3;" ";
- PRINT ;(attacks2%(count%))MOD10^3;
- IF count% > 0 THEN
- durat1% = durat%
- durat% = (attacks2%(count%)MOD10^3)-(attacks2%(count%-1)MOD10^3)
- addon% = ((attacks2%(count%)DIV(10^3))-(attacks2%(count%-1)DIV(10^3)))*960
- durat% = durat% + addon%
- PRINT TAB(26) durat%;
- IF count%>1 THEN
- IF direction$ = "rit" THEN ratio = durat%/durat1% ELSE ratio = durat1%/durat%
- CASE ratio OF
- WHEN 0.5 : PRINT TAB(52) "0.5"
- WHEN 1.0 : PRINT TAB(52) "1.0"
- WHEN 1.5 : PRINT TAB(52) "1.5"
- WHEN 2.0 : PRINT TAB(52) "2.0"
- WHEN 2.5 : PRINT TAB(52) "2.5"
- OTHERWISE PRINT TAB(52) ratio
- ENDCASE
- ENDIF
- ENDIF
- IF tal% > 54 AND printinfo$ = "y" THEN
- printnum% += 1
- MOVE 0,0
- MOVE 1800,1223
- *SGet mysprite
- OSCLI "SSave SDFS::RISCOSpi.$.CAC.Printing."+STR$(printnum%)
- tal% = 0
- ENDIF
- NEXT
- IF printinfo$ = "y" THEN
- MOVE 0,0
- MOVE 1800,1223
- *SGet mysprite
- OSCLI "SSave SDFS::RISCOSpi.$.CAC.Printing."+STR$(printnum%+1)
- ENDIF
- :
- PROCdisplay
- :
- ENDPROC
- :
- REM*************************************************
- :
- DEF PROCnamestaves
- :
- INPUT'" Rename which voice "thevoice%
- INPUT' " calling it what "thename$
- insts$(thevoice%,0) = thename$
- :
- ENDPROC
- :
- REM**************************************************
- :
- DEF PROCdeletenames
- :
- INPUT'" Delete names between voice "firstvoice%
- INPUT " and which voice "secondvoice%
- FOR count% = firstvoice% TO secondvoice%
- insts$(count%,0) = ""
- NEXT
- :
- ENDPROC
- :
- REM***************************************************
- :
- DEF PROCcopyrhythm
- :
- REM copies disarray data from one voice to another directly
- :
- CLS
- INPUT'" Copy rhythm from voice "fromvoice%
- INPUT'" to voice "tovoice%
- INPUT'" the passage starting at bar "frombar%
- INPUT'" and ending with bar "tobar%
- INPUT'" the copy to start at bar "copytobar%
- diff% = copytobar% - frombar%
- FOR count% = frombar% TO tobar%
- disarray%(count%+diff%,0,tovoice%-1) = disarray%(count%,0,fromvoice%-1)
- disarray%(count%+diff%,1,tovoice%-1) = disarray%(count%,1,fromvoice%-1)
- disarray%(count%+diff%,2,tovoice%-1) = disarray%(count%,2,fromvoice%-1)
- disarray%(count%+diff%,3,tovoice%-1) = disarray%(count%,3,fromvoice%-1)
- NEXT
- :
- PROCdisplay
- :
- ENDPROC
- :
- REM****************************************************
- :
- DEF PROCquantize
- :
- FOR count% = 0 TO manyattacks%-1
- :
- proceed1$ = "yes"
- proceed2$ = "yes"
- REM routine to illimunate from quantizing attacks closer than 120 bts to adjacent attacks
- IF count% > 0 THEN
- value1% = (attacks2%(count%)MOD10^3) + ((attacks2%(count%)DIV10^3)*960)
- value2% = (attacks2%(count%-1)MOD10^3) + ((attacks2%(count%-1)DIV10^3)*960)
- IF (value1% - value2%) > 120 THEN proceed1$ = "yes" ELSE proceed1$ = "no"
- ENDIF
- :
- IF count%<(manyattacks%-1) THEN
- value1% = (attacks2%(count%)MOD10^3) + ((attacks2%(count%)DIV10^3)*960)
- value2% = (attacks2%(count%+1)MOD10^3) + ((attacks2%(count%+1)DIV10^3)*960)
- IF (value2% - value1%) > 120 THEN proceed2$ = "yes" ELSE proceed2$ = "no"
- ENDIF
- :
- IF proceed1$ = "yes" AND proceed2$ = "yes" THEN
- :
- beat% = attacks2%(count%)MOD10^3
- :
- IF beat%>900 AND beat%<960 THEN
- IF beat%<930 THEN
- attacks2%(count%) = (attacks2%(count%)-beat%+900)
- ELSE
- attacks2%(count%) = (attacks2%(count%)-beat%+1000)
- attacks3%(count%)+= 1000
- ENDIF
- ENDIF
- :
- IF beat%>0 AND beat%<60 THEN
- IF beat%<31 THEN
- attacks2%(count%)-=beat%
- ELSE
- attacks2%(count%) = (attacks2%(count%)-beat%+60)
- ENDIF
- ENDIF
- :
- IF beat%>420 AND beat%<480 THEN
- IF beat%<430 THEN
- attacks2%(count%)= (attacks2%(count%)-beat%+420)
- ELSE
- attacks2%(count%) = (attacks2%(count%)-beat%+480)
- ENDIF
- ENDIF
- :
- IF beat%>480 AND beat%<540 THEN
- IF beat%<511 THEN
- attacks2%(count%)= (attacks2%(count%)-beat%+480)
- ELSE
- attacks2%(count%) = (attacks2%(count%)-beat%+540)
- ENDIF
- ENDIF
- :
- ENDIF
- :
- NEXT
- :
- ENDPROC
- :
- REM**************************************************************
- :
- DEF PROCreleases
- :
- IF easiermenus$ = "n" THEN PROCwindow(20,69,64,55) ELSE PROCwindow(20,69,64,42)
- CLS
- copymove$ = "C"
- :
- IF quickcopy$ = "n" THEN
- PRINT'" Create envelope points for which voice? "
- INPUT'" (0 = top) "voice%
- IF voice% = 0 THEN PROCpressenter
- voice% -= 1
- INPUT'" Starting at bar "copystartbar%
- holdbar% = copystartbar%
- INPUT'" beat "beats%
- PROCalterbeats : copystartbeat% = beats%
- holdbeat% = copystartbeat%
- IF justone$ = "n" THEN
- PRINT'" Ending at bar "
- INPUT'" (for last type 0) "copyendbar%
- IF copyendbar% > 0 THEN
- INPUT '" beat "beats%
- PROCalterbeats : copyendbeat% = beats%
- ENDIF
- ELSE
- copyendbar% = copystartbar%
- copyendbeat% = copystartbeat%
- ENDIF
- :
- ELSE
- :
- PRINT'" Create envelope points for which voice? "
- INPUT '" (0 = top) "voice%
- IF voice% = 0 THEN PROCpressenter
- voice% -= 1
- INPUT '" note number (for 1 press 0) "along%
- IF along% = 0 THEN along% = 1
- along%-=1
- copystartbar% = array%(holdstartcell%(voice%)+along%,0,voice%)DIV10^6
- copystartbeat% = (array%(holdstartcell%(voice%)+along%,0,voice%)MOD10^6)DIV10^3
- holdbar% = copystartbar%
- holdbeat% = copystartbeat%
- IF justone$ = "n" THEN
- PRINT'" to note number "
- INPUT'" (for last type 0) "along%
- IF along% = 0 THEN
- copyendbar% = 0
- ELSE
- along%-=1
- copyendbar% = array%(holdstartcell%(voice%)+along%,0,voice%)DIV10^6
- copyendbeat% = (array%(holdstartcell%(voice%)+along%,0,voice%)MOD10^6)DIV10^3
- ENDIF
- ELSE
- copyendbar% = copystartbar%
- copyendbeat% = copystartbeat%
- ENDIF
- ENDIF
- :
- :
- value% = (copystartbar%*10^3)+copystartbeat%
- IF value% <= array%(0,0,voice%)DIV10^3 THEN
- startatcell% = 0
- ELSE
- PROCsearch(value%)
- startatcell% = startcell%
- ENDIF
- IF copyendbar% = 0 THEN
- endatcell% = numusedcells%(voice%) - 1
- ELSE
- value% = (copyendbar%*10^3)+copyendbeat%
- IF value% >= array%(numusedcells%(voice%)-1,0,voice%)DIV10^3 THEN
- endatcell% = numusedcells%(voice%) - 1
- ELSE
- PROCsearch(value%)
- IF shunt$ = "N" THEN endatcell% = startcell% ELSE endatcell% = startcell% - 1
- ENDIF
- ENDIF
- :
- manyattacks% = endatcell% - startatcell% + 1
- REM create 'gap' between beat-of-bar and first actual attack
- carrybars% = (array%(startatcell%,0,voice%)DIV10^6)-copystartbar%
- carrybeats% = ((array%(startatcell%,0,voice%)DIV10^3)MOD10^3)-copystartbeat%
- attacks1%(0) = (carrybars%*960)+carrybeats%
- :
- FOR count% = 0 TO (manyattacks%-1)
- IF count% > 0 THEN
- carrybars% = (array%(startatcell%+count%,0,voice%)DIV10^6)-(array%(startatcell%+count%-1,0,voice%)DIV10^6)
- carrybeats% = ((array%(startatcell%+count%,0,voice%)DIV10^3)MOD10^3)-((array%(startatcell%+count%-1,0,voice%)DIV10^3)MOD10^3)
- attacks1%(count%) = attacks1%(count%-1) + ((carrybars%*960)+carrybeats%)
- ENDIF
- :
- pitches%(count%) = array%(startatcell%+count%,0,voice%)MOD10^3
- dur% = (array%(startatcell%+count%,1,voice%)DIV10)MOD10^3
- brrr% = array%(startatcell%+count%,0,voice%)DIV10^6 : PROCreconvertdur
- durations%(count%) = dur%
- NEXT
- :
- counter% = -1
- FOR count% = 0 TO (manyattacks%-1)
- :
- counter% += 1
- gliss1% = (array%(startatcell%+count%,1,voice%)DIV10^4)MOD10^2 : gliss1% = 50-gliss1%
- gliss2% = (array%(startatcell%+count%,1,voice%)DIV10^6)MOD10^2 : gliss2% = 50 - gliss2%
- gliss3% = array%(startatcell%+count%,1,voice%)DIV10^8 : gliss3% = 10 - gliss3%
- note% = pitches%(count%)DIV10^2
- accid% = (pitches%(count%)DIV10)MOD10
- oct% = pitches%(count%)MOD10
- :
- ph1% = ((array%(startatcell%+count%,2,voice%))DIV10^5)MOD10^2
- IF ph1% <> 0 THEN
- envattacks%(counter%) = attacks1%(count%)+(durations%(count%)*ph1%/100)
- gliss% = gliss1%
- IF gliss% <> 0 THEN
- PROCglisspitches
- envpitches%(counter%) = (note1%*100)+(accid1%*10)+oct1%
- ELSE
- envpitches%(counter%) = (note%*100)+(accid%*10)+oct%
- ENDIF
- :
- ENDIF
- :
- ph2% = (array%(startatcell%+count%,2,voice%))DIV10^7
- IF ph2% <> 0 THEN
- counter% += 1
- envattacks%(counter%) = attacks1%(count%)+(durations%(count%)*ph2%/100)
- gliss% = gliss1% + gliss2%
- IF gliss% <> 0 THEN
- PROCglisspitches
- envpitches%(counter%) = (note1%*100)+(accid1%*10)+oct1%
- ELSE
- envpitches%(counter%) = (note%*100)+(accid%*10)+oct%
- ENDIF
- :
- ENDIF
- :
- IF ph1% <> 0 THEN counter% += 1
- envattacks%(counter%) = attacks1%(count%)+durations%(count%)
- IF ph1% = 0 THEN gliss% = gliss1%
- IF ph1% <> 0 AND ph2% = 0 THEN gliss% = gliss1% + gliss2%
- IF ph2% <> 0 THEN gliss% = gliss1% + gliss2% + gliss3%
- IF gliss% <> 0 THEN
- PROCglisspitches
- envpitches%(counter%) = (note1%*100)+(accid1%*10)+oct1%
- ELSE
- envpitches%(counter%) = (note%*100)+(accid%*10)+oct%
- ENDIF
- :
- NEXT
- :
- FOR count% = 0 TO counter%
- :
- attacks1%(count%) = envattacks%(count%)
- pitches%(count%) = envpitches%(count%)
- durations%(count%) = 0
- amplitudes%(count%) = 0
- envelopes%(count%) = 9
- glissandos%(count%) = 105050
- inflections%(count%) = 50
- NEXT
- :
- numpitches% = counter% + 1
- manyattacks% = counter% + 1
- method$ = "raw"
- copyit$ = "ON"
- PROCinsertattacks
- :
- justone$ = "n"
- :
- ENDPROC
- :
- REM**********************************************
- :
- DEF PROCglisspitches
- :
- note1% = note% : accid1% = accid% : oct1% = oct%
- :
- IF gliss% < 0 THEN step% = -1 ELSE step% = 1
- IF gliss% > 0 THEN startloop% = 1 ELSE startloop% = -1
- :
- FOR country% = startloop% TO gliss% STEP step%
- :
- CASE step% OF
- WHEN -1 :
- CASE accid1% OF
- WHEN 1 :
- CASE note1% OF
- WHEN 0 :
- note1% = 6 : accid1% = 4 : oct1% -=1
- WHEN 1, 2, 4, 5, 6 :
- note1% -= 1 : accid1% = 8
- WHEN 3 :
- note1% -= 1 : accid1% = 4
- ENDCASE
- OTHERWISE accid1% -= 1
- ENDCASE
- WHEN 1 :
- CASE accid1% OF
- WHEN 9 :
- CASE note1% OF
- WHEN 0, 1, 3, 4, 5 :
- note1% += 1 : accid1% = 2
- WHEN 2 :
- note1% += 1 : accid1% = 6
- WHEN 6 :
- note1% = 0 : accid1% = 6 : oct1% += 1
- ENDCASE
- OTHERWISE accid1% += 1
- ENDCASE
- ENDCASE
- NEXT
- :
- ENDPROC
- :
- REM*********************************************
- :
- DEF PROCdoublestop
- :
- IF easiermenus$ = "n" THEN PROCwindow(20,69,96,54) ELSE PROCwindow(20,69,96,42)
- repeatposit$ = "n"
- distort$ = "OFF"
- dothis$ = "YES"
- :
- copymove$ = "DS"
- savevoice$ = "N"
- justone$ = "n"
- :
- PRINT'" Violin, viola, cello or bass (N,A,O,S)? "
- PRINT'" (or press E for an explanation of the function) "
- CASE GET$ OF
- WHEN "N","n" : member$ = "violin"
- WHEN "A","a" : member$ = "viola"
- WHEN "O","o" : member$ = "cello"
- WHEN "S","s" : member$ = "bass"
- WHEN "E","e" :
- IF easiermenus$ = "n" THEN PROCwindow(8,71,96,54) ELSE PROCwindow(11,69,96,42)
- VDU 14
- CLS
- PRINT'" The typical situation in which the double-stop function would play a part"
- PRINT" is imagined to be this: up to four voices are employed to schedule attack-points "
- PRINT" on each of the strings (at this stage make a single-voice reduction with the attacks "
- PRINT" pitched on the open strings, because this will be needed in the function). "
- PRINT'" Pitches are allocated to the attacks, including open strings and harmonics, with "
- PRINT" the condition that all are within a single lh position at any one time. "
- PRINT'" Now reduce these separate-string voices to a single voice - this is treated by "
- PRINT" the function to produce a version inserting practical double-stops according to "
- PRINT" user-defined probabilities; this is copied into two further voices to enable faithful "
- PRINT" play-back; durations are correctly clipped, so a further reduction of these two "
- PRINT" voices will give a clear indication of notation on a single stave. "
- PRINT'" (press C to continue) "
- CASE GET$ OF
- ENDCASE
- VDU 15
- PROCdisplay
- OTHERWISE PROCdoublestop
- ENDCASE
- INPUT'" Which single voice is to be treated? "treatvoice%
- treatvoice% -= 1
- INPUT'" Which other 2 voices is it divided into? - voice... "firstvoice%
- firstvoice% -= 1
- INPUT'" and voice... "secondvoice%
- secondvoice% -= 1
- INPUT'" And which single voice carries the open strings? - voice... "stringvoice%
- stringvoice% -= 1
- CLS
- PRINT''" These 4 voices are assumed to correspond vertically; "
- INPUT'" the passage is to start at bar "copystartbar%
- IF copystartbar% = 0 THEN
- copystartbar% = holdbar% : copystartbeat% = holdbeat% : repeatposit$ = "y"
- ENDIF
- holdbar% = copystartbar%
- IF repeatposit$ = "y" THEN
- PRINT'" bar ";copystartbar%;" beat ";copystartbeat%;"?"
- PRINT" (for OK press 0, if not OK press X)"
- CASE GET$ OF
- WHEN"X","x" : PROCdoublestop
- OTHERWISE
- ENDCASE
- ELSE
- INPUT" beat "beats%
- ENDIF
- PROCalterbeats : copystartbeat% = beats%
- holdbeat% = copystartbeat%
- IF justone$ = "n" THEN
- PRINT'" Ending at bar "
- INPUT" (for last type 0) "copyendbar%
- IF copyendbar% > 0 THEN
- INPUT " beat "beats%
- PROCalterbeats : copyendbeat% = beats%
- ENDIF
- ELSE
- copyendbar% = copystartbar%
- copyendbeat% = copystartbeat%
- ENDIF
- :
- CLS
- PRINT'" On what percentage of occasions do you want a potential "
- PRINT" double-stop to be allowed? "
- INPUT'" (a) following a single-stop... "singlechance%
- INPUT'" (b) following a double-stop... "doublechance%
- :
- FOR run% = 0 TO 1
- IF run% = 0 THEN voice% = stringvoice% ELSE voice% = treatvoice%
- value% = (copystartbar%*10^3)+copystartbeat%
- IF value% <= array%(0,0,voice%)DIV10^3 THEN
- startatcell% = 0
- ELSE
- PROCsearch(value%)
- startatcell% = startcell%
- ENDIF
- IF copyendbar% = 0 THEN
- endatcell% = numusedcells%(voice%) - 1
- ELSE
- value% = (copyendbar%*10^3)+copyendbeat%
- IF value% >= array%(numusedcells%(voice%)-1,0,voice%)DIV10^3 THEN
- endatcell% = numusedcells%(voice%) - 1
- ELSE
- PROCsearch(value%)
- IF shunt$ = "N" THEN endatcell% = startcell% ELSE endatcell% = startcell% - 1
- ENDIF
- ENDIF
- :
- manyattacks% = endatcell% - startatcell% + 1
- REM create 'gap' between beat-of-bar and first actual attack
- carrybars% = (array%(startatcell%,0,voice%)DIV10^6)-copystartbar%
- carrybeats% = ((array%(startatcell%,0,voice%)DIV10^3)MOD10^3)-copystartbeat%
- attacks1%(0) = (carrybars%*960)+carrybeats%
- :
- IF copymove$ = "DS" THEN
- FOR count% = 0 TO (manyattacks%-1)
- IF count% > 0 THEN
- carrybars% = (array%(startatcell%+count%,0,voice%)DIV10^6)-(array%(startatcell%+count%-1,0,voice%)DIV10^6)
- carrybeats% = ((array%(startatcell%+count%,0,voice%)DIV10^3)MOD10^3)-((array%(startatcell%+count%-1,0,voice%)DIV10^3)MOD10^3)
- attacks1%(count%) = attacks1%(count%-1) + ((carrybars%*960)+carrybeats%)
- ENDIF
- :
- pitches%(count%) = array%(startatcell%+count%,0,voice%)MOD10^3
- IF run% = 0 THEN
- pitch% = pitches%(count%)
- PROCopenstgs
- ENDIF
- dur% = (array%(startatcell%+count%,1,voice%)DIV10)MOD10^3
- brrr% = array%(startatcell%+count%,0,voice%)DIV10^6 : PROCreconvertdur
- durations%(count%) = dur%
- amplitudes%(count%) = (array%(startatcell%+count%,1,voice%))MOD10
- envelopes%(count%) = (array%(startatcell%+count%,2,voice%))DIV10^2
- glissandos%(count%) = (array%(startatcell%+count%,1,voice%)DIV10^4)
- inflections%(count%) = array%(startatcell%+count%,2,voice%)MOD10^2
- NEXT
- ENDIF
- NEXT run%
- :
- :
- firstcutoff% = 0
- secondcutoff% = 0
- :
- FOR count% = 0 TO (manyattacks%-1)
- :
- REM determine state before making decision
- state$ = "tacet"
- IF firstcutoff% > attacks1%(count%) THEN state$ = "single1"
- IF secondcutoff% > attacks1%(count%) AND state$ = "tacet" THEN state$ = "single2"
- IF secondcutoff% > attacks1%(count%) AND state$ = "single1" THEN state$ = "double"
- :
- CASE state$ OF
- WHEN "tacet" :
- dsvoice%(count%) = firstvoice%
- firstcutoff% = attacks1%(count%) + durations%(count%)
- firstcount% = count%
- firststg% = openstgs%(count%)
- :
- WHEN "single1" :
- newstg$ = "nonadj"
- IF firststg% = openstgs%(count%) THEN newstg$ = "same"
- IF firststg% = (openstgs%(count%)-1) OR firststg% = (openstgs%(count%)+1) THEN newstg$ = "adj"
- :
- CASE newstg$ OF
- WHEN "same" :
- dsvoice%(count%) = firstvoice%
- firstcutoff% = attacks1%(count%) + durations%(count%)
- firststg% = openstgs%(count%)
- REM clip duration of interrupted note
- durations%(firstcount%) = attacks1%(count%) - attacks1%(firstcount%)
- firstcount% = count%
- WHEN "adj" :
- PROCsingleprob
- IF ds$ = "n" THEN
- dsvoice%(count%) = firstvoice%
- firstcutoff% = attacks1%(count%) + durations%(count%)
- firststg% = openstgs%(count%)
- REM clip duration of interrupted note
- durations%(firstcount%) = attacks1%(count%) - attacks1%(firstcount%)
- firstcount% = count%
- ELSE
- dsvoice%(count%) = secondvoice%
- secondcutoff% = attacks1%(count%) + durations%(count%)
- secondcount% = count%
- secondstg% = openstgs%(count%)
- ENDIF
- WHEN "nonadj" :
- dsvoice%(count%) = firstvoice%
- firstcutoff% = attacks1%(count%) + durations%(count%)
- firststg% = openstgs%(count%)
- REM clip duration of interrupted note and add slight 'rest'
- durations%(firstcount%) = attacks1%(count%) - (attacks1%(firstcount%)+60)
- IF durations%(firstcount%) <0 THEN durations%(firstcount%) = 1
- firstcount% = count%
- ENDCASE
- :
- WHEN "single2" :
- newstg$ = "nonadj"
- IF secondstg% = openstgs%(count%) THEN newstg$ = "same"
- IF secondstg% = (openstgs%(count%)-1) OR secondstg% = (openstgs%(count%)+1) THEN newstg$ = "adj"
- :
- CASE newstg$ OF
- WHEN "same" :
- dsvoice%(count%) = secondvoice%
- secondcutoff% = attacks1%(count%) + durations%(count%)
- secondstg% = openstgs%(count%)
- REM clip duration of interrupted note
- durations%(secondcount%) = attacks1%(count%) - attacks1%(secondcount%)
- secondcount% = count%
- WHEN "adj" :
- PROCsingleprob
- IF ds$ = "n" THEN
- dsvoice%(count%) = secondvoice%
- secondcutoff% = attacks1%(count%) + durations%(count%)
- secondstg% = openstgs%(count%)
- REM clip duration of interrupted note
- durations%(secondcount%) = attacks1%(count%) - attacks1%(secondcount%)
- secondcount% = count%
- ELSE
- dsvoice%(count%) = firstvoice%
- firstcutoff% = attacks1%(count%) + durations%(count%)
- firstcount% = count%
- firststg% = openstgs%(count%)
- ENDIF
- WHEN "nonadj" :
- dsvoice%(count%) = secondvoice%
- secondcutoff% = attacks1%(count%) + durations%(count%)
- secondstg% = openstgs%(count%)
- REM clip duration of interrupted note and add slight 'rest'
- durations%(secondcount%) = attacks1%(count%) - (attacks1%(secondcount%)+60)
- IF durations%(secondcount%) <0 THEN durations%(secondcount%) = 1
- secondcount% = count%
- ENDCASE
- :
- WHEN "double" :
- newstg$ = "nonadj"
- IF openstgs%(count%) = firststg% THEN newstg$ = "sameasfirst"
- IF openstgs%(count%) = secondstg% THEN newstg$ = "sameassecond"
- IF (openstgs%(count%) = (firststg%-1) OR openstgs%(count%) = (firststg%+1)) AND openstgs%(count%) <> secondstg% THEN newstg$ = "adjtofirst"
- IF (openstgs%(count%) = (secondstg%-1) OR openstgs%(count%) = (secondstg%+1)) AND openstgs%(count%) <> firststg% THEN newstg$ = "adjtosecond"
- :
- CASE newstg$ OF
- WHEN "sameasfirst" :
- PROCdoubleprob
- IF ds$ = "n" THEN
- dsvoice%(count%) = firstvoice%
- firstcutoff% = attacks1%(count%) + durations%(count%)
- firststg% = openstgs%(count%)
- REM clip durations of both interrupted notes
- durations%(firstcount%) = attacks1%(count%) - attacks1%(firstcount%)
- firstcount% = count%
- durations%(secondcount%) = attacks1%(count%) - attacks1%(secondcount%)
- secondcutoff% = attacks1%(secondcount%) + durations%(secondcount%)
- ELSE
- dsvoice%(count%) = firstvoice%
- firstcutoff% = attacks1%(count%) + durations%(count%)
- firststg% = openstgs%(count%)
- REM clip duration of interrupted note
- durations%(firstcount%) = attacks1%(count%) - attacks1%(firstcount%)
- firstcount% = count%
- ENDIF
- WHEN "sameassecond" :
- PROCdoubleprob
- IF ds$ = "n" THEN
- dsvoice%(count%) = secondvoice%
- secondcutoff% = attacks1%(count%) + durations%(count%)
- secondstg% = openstgs%(count%)
- REM clip durations of both interrupted notes
- durations%(secondcount%) = attacks1%(count%) - attacks1%(secondcount%)
- secondcount% = count%
- durations%(firstcount%) = attacks1%(count%) - attacks1%(firstcount%)
- firstcutoff% = attacks1%(firstcount%) + durations%(firstcount%)
- ELSE
- dsvoice%(count%) = secondvoice%
- secondcutoff% = attacks1%(count%) + durations%(count%)
- secondstg% = openstgs%(count%)
- REM clip duration of interrupted note
- durations%(secondcount%) = attacks1%(count%) - attacks1%(secondcount%)
- secondcount% = count%
- ENDIF
- WHEN "adjtofirst" :
- PROCdoubleprob
- IF ds$ = "n" THEN
- dsvoice%(count%) = firstvoice%
- firstcutoff% = attacks1%(count%) + durations%(count%)
- firststg% = openstgs%(count%)
- REM clip durations of both interrupted notes
- durations%(firstcount%) = attacks1%(count%) - attacks1%(firstcount%)
- firstcount% = count%
- durations%(secondcount%) = attacks1%(count%) - attacks1%(secondcount%)
- secondcutoff% = attacks1%(secondcount%) + durations%(secondcount%)
- ELSE
- dsvoice%(count%) = secondvoice%
- secondcutoff% = attacks1%(count%) + durations%(count%)
- secondstg% = openstgs%(count%)
- REM clip duration of interrupted note
- durations%(secondcount%) = attacks1%(count%) - attacks1%(secondcount%)
- secondcount% = count%
- ENDIF
- WHEN "adjtosecond" :
- PROCdoubleprob
- IF ds$ = "n" THEN
- dsvoice%(count%) = secondvoice%
- secondcutoff% = attacks1%(count%) + durations%(count%)
- secondstg% = openstgs%(count%)
- REM clip durations of both interrupted notes
- durations%(secondcount%) = attacks1%(count%) - attacks1%(secondcount%)
- secondcount% = count%
- durations%(firstcount%) = attacks1%(count%) - attacks1%(firstcount%)
- firstcutoff% = attacks1%(firstcount%) + durations%(firstcount%)
- ELSE
- dsvoice%(count%) = firstvoice%
- firstcutoff% = attacks1%(count%) + durations%(count%)
- firststg% = openstgs%(count%)
- REM clip duration of interrupted note
- durations%(firstcount%) = attacks1%(count%) - attacks1%(firstcount%)
- firstcount% = count%
- ENDIF
- WHEN "nonadj" :
- dsvoice%(count%) = firstvoice%
- firstcutoff% = attacks1%(count%) + durations%(count%)
- firststg% = openstgs%(count%)
- REM clip durations of both interrupted notes and add 'rests'
- durations%(firstcount%) = attacks1%(count%) - (attacks1%(firstcount%)+60)
- IF durations%(firstcount%) <0 THEN durations%(firstcount%) = 1
- firstcount% = count%
- durations%(secondcount%) = attacks1%(count%) - (attacks1%(secondcount%)+60)
- IF durations%(secondcount%) <0 THEN durations%(secondcount%) = 1
- secondcutoff% = attacks1%(secondcount%) + durations%(secondcount%)
- ENDCASE
- :
- ENDCASE
- :
- NEXT
- :
- :
- numpitches% = manyattacks% : method$ = "raw" : copyit$ = "ON" : justone$ = "n"
- : repeatposit$ = "n" : reordered$ = "n" : equalized$ = "n" : rhythmicized$ = "n"
- :
- : startat% = (copystartbar%*(10^3))+copystartbeat%
- attacks2%() = attacks1%()
- :
- attacks2%() = attacks2%() + (startat% MOD 10^3) : REM moves attacks further up bar, if necc
- :
- attacks3%() = attacks2%()
- FOR count% = 0 TO (manyattacks%-1)
- attacks3%(count%) = attacks3%(count%) DIV 960
- NEXT
- REM gives list of bar mos starting at 0
- :
- attacks3%() = attacks3%() * 960
- attacks2%() = attacks2%() - attacks3%()
- attacks3%() = attacks3%() / 960
- REM list of actual beat numbers
- :
- attacks3%() = attacks3%() + (startat% DIV 10^3) : REM list of actual bar nos
- :
- attacks3%() = attacks3%()*(10^3)
- attacks2%() = attacks2%() + attacks3%()
- REM list of actual bar/beat numbers
- :
- :
- addingnotes$ = "y"
- :
- FOR counter% = 0 TO (manyattacks%-1)
- voice% = dsvoice%(counter%)
- PROCnewnotereception(voice%, (attacks2%(counter%)DIV10^3), (attacks2%(counter%)MOD10^3), pitches%(counter%), amplitudes%(counter%), envelopes%(counter%), durations%(counter%), glissandos%(counter%), inflections%(counter%))
- NEXT
- :
- copyit$ = "OFF" : displayedfunc$ = "n" : PROCdisplay
- :
- ENDPROC
- :
- REM******************************************************************
- :
- DEF PROCopenstgs
- :
- CASE member$ OF
- WHEN "violin" :
- CASE pitch% OF
- WHEN 255 : openstgs%(count%) = 1
- WHEN 554 : openstgs%(count%) = 2
- WHEN 154 : openstgs%(count%) = 3
- WHEN 453 : openstgs%(count%) = 4
- OTHERWISE
- VDU 7 : PRINT "NOT AN OPEN STRING"
- PRINT "press C to continue"
- CASE GET$ OF
- ENDCASE
- PROCdoublestop
- ENDCASE
- :
- WHEN "viola" :
- CASE pitch% OF
- WHEN 554 : openstgs%(count%) = 1
- WHEN 154 : openstgs%(count%) = 2
- WHEN 453 : openstgs%(count%) = 3
- WHEN 53 : openstgs%(count%) = 4
- OTHERWISE
- VDU 7 : PRINT "NOT AN OPEN STRING"
- PRINT "press C to continue"
- CASE GET$ OF
- ENDCASE
- PROCdoublestop
- ENDCASE
- :
- WHEN "cello" :
- CASE pitch% OF
- WHEN 553 : openstgs%(count%) = 1
- WHEN 153 : openstgs%(count%) = 2
- WHEN 452 : openstgs%(count%) = 3
- WHEN 52 : openstgs%(count%) = 4
- OTHERWISE
- VDU 7 : PRINT "NOT AN OPEN STRING"
- PRINT "press C to continue"
- CASE GET$ OF
- ENDCASE
- PROCdoublestop
- ENDCASE
- :
- WHEN "bass" :
- CASE pitch% OF
- WHEN 452 : openstgs%(count%) = 1
- WHEN 152 : openstgs%(count%) = 2
- WHEN 551 : openstgs%(count%) = 3
- WHEN 251 : openstgs%(count%) = 4
- OTHERWISE
- VDU 7 : PRINT "NOT AN OPEN STRING"
- PRINT "press C to continue"
- CASE GET$ OF
- ENDCASE
- PROCdoublestop
- ENDCASE
- :
- ENDCASE
- :
- ENDPROC
- :
- REM****************************************************
- :
- DEF PROCsingleprob
- :
- number% = RND(100)
- IF number% > 0 AND number% <= singlechance% THEN
- ds$ = "y"
- ELSE
- ds$ = "n"
- ENDIF
- ENDPROC
- :
- REM***************************************************
- :
- DEF PROCdoubleprob
- :
- number% = RND(100)
- IF number% > 0 AND number% <= doublechance% THEN
- ds$ = "y"
- ELSE
- ds$ = "n"
- ENDIF
- ENDPROC
- :
- REM***************************************************
- :
- DEF PROCsamepitches
- :
- PRINT' " Note name for pitch is ";
- COLOUR 3
- CASE GET$ OF
- WHEN "C","c" : note% = 0 : PRINT "C"
- WHEN "D","d" : note% = 1 : PRINT "D"
- WHEN "E","e" : note% = 2 : PRINT "E"
- WHEN "F","f" : note% = 3 : PRINT "F"
- WHEN "G","g" : note% = 4 : PRINT "G"
- WHEN "A","a" : note% = 5 : PRINT "A"
- WHEN "B","b" : note% = 6 : PRINT "B"
- ENDCASE
- COLOUR 0
- PRINT " accidental ";
- COLOUR 3
- CASE GET$ OF
- WHEN "1" : accid% = 1 : PRINT "flat"
- WHEN "2" : accid% = 2 : PRINT "3/8flat"
- WHEN "3" : accid% = 3 : PRINT "1/4flat"
- WHEN "4" : accid% = 4 : PRINT "1/8flat"
- WHEN "5" : accid% = 5 : PRINT "nat"
- WHEN "6" : accid% = 6 : PRINT "1/8shrp"
- WHEN "7" : accid% = 7 : PRINT "1/4shrp"
- WHEN "8" : accid% = 8 : PRINT "3/8shrp"
- WHEN "9" : accid% = 9 : PRINT "shrp"
- ENDCASE
- COLOUR 0
- PRINT " octave ";
- COLOUR 3
- CASE GET$ OF
- WHEN "0" : octave% = 0 : PRINT "0"
- WHEN "1" : octave% = 1 : PRINT "1"
- WHEN "2" : octave% = 2 : PRINT "2"
- WHEN "3" : octave% = 3 : PRINT "3"
- WHEN "4" : octave% = 4 : PRINT "4"
- WHEN "5" : octave% = 5 : PRINT "5"
- WHEN "6" : octave% = 6 : PRINT "6"
- WHEN "7" : octave% = 7 : PRINT "7"
- WHEN "8" : octave% = 8 : PRINT "8"
- ENDCASE
- COLOUR 0
- FOR count% = 0 TO numpitches% - 1
- pitches%(count%) = (note%*100)+(accid%*10)+octave%
- NEXT
- :
- firstpitch$ = "n" : prevnumpitches% = numpitches%
- REM function can feed pitches similarly into pitches%
- :
- PROCinsertpitches
- :
- ENDPROC
- :
- REM*************************************************
- :
- DEF PROCedit
- :
- PROCwindow(20,60,58,39)
- PRINT ' " move 1st envelope point E"
- PRINT ' " move 2nd envelope point R"
- PRINT ' " change 1st amplitude A"
- PRINT ' " change 2nd amplitude S"
- PRINT ' " change 3rd amplitude D"
- PRINT ' " change 4th amplitude F"
- PRINT ' " move note+following note N"
- PRINT ' " move note+drag previous duration M"
- PRINT ' " change duration C"
- PRINT ' " then Shift + < OR >"
- CASE GET$ OF
- WHEN "E", "e" : editwhat$ = "1stenvelope"
- WHEN "R", "r" : editwhat$ = "2ndenvelope"
- WHEN "A", "a" : editwhat$ = "1stamplitude"
- WHEN "S", "s" : editwhat$ = "2ndamplitude"
- WHEN "D", "d" : editwhat$ = "3rdamplitude"
- WHEN "F", "f" : editwhat$ = "4thamplitude"
- WHEN "N", "n" : editwhat$ = "movetwo"
- WHEN "M", "m" : editwhat$ = "move&drag"
- WHEN "C", "c" : editwhat$ = "duration"
- ENDCASE
- PROCdisplay
- ENDPROC
- :
- REM*************************************************
- :
- DEF PROCconvertoldenvelopes
- :
- REM When a/dal niente was introduced, notes with amp2%=0 had to display an envelope
- REM whereas previously amp2%=0 meant "no envelope"
- REM Consequently files predating this change now undesirably display "no envelope" notes as single-phase "dim a niente" notes
- REM To update the old files, use this proc to give a value amp2%=9 to all notes
- PROCwindow(20,60,68,45)
- PRINT' " Do you want to convert all the envelopes"
- PRINT" in the file back to 0 phase envelopes?"
- CASE GET$ OF
- WHEN "Y", "y" :
- FOR voice% = 0 TO (numparts%-1)
- :
- FOR count% = 0 TO numusedcells%(voice%)-1
- number% = array%(count%,2,voice%) DIV 10^2
- array%(count%,2,voice%) = array%(count%,2,voice%) - (number%*100)
- array%(count%,2,voice%) = array%(count%,2,voice%) + 900
- NEXT
- :
- NEXT
- PROCdisplay
- OTHERWISE PROCdisplay
- ENDCASE
- ENDPROC
- :
- REM************************************************
- :
- DEF PROCkeyboardshortcuts
- :
- PROCwindow(2,68,97,2)
- :
- PRINT ' " Menu M Accel/rit by total duration T"
- PRINT ' " Display menu O Accel/rit by start/end points E"
- PRINT ' " Move down 1, 3/10, x many, 50 v/vv/vx/v0 Accel/rit between adjacent notes F"
- PRINT ' " Move up 1, 3/10, x many, 50 ^/^^/^x/^0 Starting note for F above 1,2,3..."
- PRINT ' " Move left </<</<9 Random number/with same values n/N"
- PRINT ' " Move right >/>>/>9 Group of durations U"
- PRINT ' " Go to bar B Quickplay top x voices (see M-V-Q) P"
- PRINT ' " Go to SECTION S Quickplay 2nd voice only ;"
- PRINT ' " Display x number of bars D Quickplay 3rd voice only /"
- PRINT ' " Double number of bars + Quickplay top x voices, screen only ^P"
- PRINT ' " Halve number of bars - Quickplay 2nd voice, screen only :"
- PRINT ' " Quick display Q Quickplay 3rd voice, screem only ?"
- PRINT ' " Prev Quick/Quick/Ord Display W Replay R"
- PRINT ' " Top remarks left/right [/] Slavevoice function ^L"
- PRINT ' " Bottom remarks left/right '/# Edit envelope voice 1, note 1,2,3... ^QWER..."
- PRINT ' " [free keystroke] ~ Edit envelope voice 2, note 1,2,3... ^ASDF..."
- PRINT ' " Menus easier to read @ Edit envelope voice 3, note 1,2,3... ^ZXCV..."
- PRINT ' " Hard copy H Enter last value again Return"
- PRINT ' " Name staves ^V Import ^I"
- PRINT ' " Accel/rit A Group of attacks 0"
- PRINT ' " Group of amplitudes L Group of envelopes J"
- PRINT ' " Show keyboard shortcuts K Move a passage \"
- PRINT ' " Distort attacks/pitches `/`` Move one note ^\"
- PRINT ' " Increment calculator C Copy one note Z"
- PRINT ' " Group of pitches Y Copy a passage X"
- PRINT ' " Copy note x down 1/x stave(s)^x/^xx Quickdisplay x voices 1,2,3..."
- PRINT ' " Delete note 1/x top stave ^O/^Ox Delete sim middle/bottom staves ^K/^M"
- PRINT ' " [free keystroke] # Extract I"
- PRINT ' " Fill gaps with durations G Copy successive voices to same voice S"
- PRINT ' " Add 0/10/20 to copying down [/]/' Input screen voice Return 1/2/3 times"
- PRINT ' " Display all voices ^= Display from which voice down ¬"
- PRINT ' " Quick copy on { Quick copy off }"
- PRINT ' " (press a key to continue)"
- CASE GET$ OF
- WHEN "c", "C" :
- PROCdisplay
- OTHERWISE
- PROCdisplay
- ENDCASE
- :
- ENDPROC
- :
- REM***************************************************************************************
- :
- DEF PROCmoveback
- :
- INPUT " Move back by how many bars "backbybars%
- INPUT " and how many beats "backby%
- backby% = backby%+(backbybars%*960)
- :
- IF backby% = 0 THEN
- COLOUR 3 : PRINT' holdbackby%;"?"
- CASE GET$ OF
- WHEN "N","n" : COLOUR 0 : PROCmoveback
- OTHERWISE backby% = holdbackby%
- ENDCASE
- COLOUR 0
- ENDIF
- :
- holdbackby% = backby%
- beats% = beats% - backby%
- REPEAT
- IF beats% < 0 THEN
- REPEAT
- beats% = 960 + beats%
- bars% -= 1
- UNTIL beats% >= 0
- ENDIF
- :
- ENDPROC
- :
- REM******************************************************************************************
- :
- DEF PROCmoveforward
- :
- INPUT " Move forward by how many bars "backbybars%
- INPUT " and how many beats "backby%
- backby% = backby%+(backbybars%*960)
- :
- IF backby% = 0 THEN
- COLOUR 3 : PRINT' holdbackby%;"?"
- CASE GET$ OF
- WHEN "N","n" : COLOUR 0 : PROCmoveforward
- OTHERWISE backby% = holdbackby%
- ENDCASE
- COLOUR 0
- ENDIF
- :
- holdbackby% = backby%
- beats% = beats% + backby%
- REPEAT
- IF beats% > 960 THEN
- REPEAT
- beats% = beats% - 960
- bars% += 1
- UNTIL beats% <= 960
- ENDIF
- :
- ENDPROC
- :
- REM******************************************************************************************
- :
- DEF PROCpitchstring3
- :
- IF easiermenus$ = "n" THEN PROCwindow(20,69,60,55) ELSE PROCwindow(20,69,60,42)
- PRINT'" Return a random pitch-class having"
- PRINT" pre-defined its probability "
- PRINT'" Use previous shares or re-define (P/R)? "
- CASE GET$ OF
- WHEN "r","R" :
- :
- totalshares% = 0
- INPUT '" C nat has how many shares "many%
- cnat% = 0 + many% : totalshares% += many%
- INPUT '" C sharp has how many shares "many%
- cshrp% = cnat% + many% : totalshares% += many%
- INPUT '" D nat has how many shares "many%
- dnat% = cshrp% + many% : totalshares% += many%
- INPUT '" D sharp has how many shares "many%
- dshrp% = dnat% + many% : totalshares% += many%
- INPUT '" E nat has how many shares "many%
- enat% = dshrp% + many% : totalshares% += many%
- INPUT '" F nat has how many shares "many%
- fnat% = enat% + many% : totalshares% += many%
- INPUT '" F sharp has how many shares "many%
- fshrp% = fnat% + many% : totalshares% += many%
- INPUT '" G nat has how many shares "many%
- gnat% = fshrp% + many% : totalshares% += many%
- INPUT '" G sharp has how many shares "many%
- gshrp% = gnat% + many% : totalshares% += many%
- INPUT '" A nat has how many shares "many%
- anat% = gshrp% + many% : totalshares% += many%
- INPUT '" A sharp has how many shares "many%
- ashrp% = anat% + many% : totalshares% += many%
- INPUT '" B nat has how many shares "many%
- bnat% = ashrp% + many% : totalshares% += many%
- OTHERWISE
- ENDCASE
- throw% = RND(totalshares%)
- IF throw% > 0 AND throw% <= cnat% THEN note$ = "C nat"
- IF throw% > cnat% AND throw% <= cshrp% THEN note$ = "C sharp"
- IF throw% > cshrp% AND throw% <= dnat% THEN note$ = "D nat"
- IF throw% > dnat% AND throw% <= dshrp% THEN note$ = "D sharp"
- IF throw% > dshrp% AND throw% <= enat% THEN note$ = "E nat"
- IF throw% > enat% AND throw% <= fnat% THEN note$ = "F nat"
- IF throw% > fnat% AND throw% <= fshrp% THEN note$ = "F sharp"
- IF throw% > fshrp% AND throw% <= gnat% THEN note$ = "G nat"
- IF throw% > gnat% AND throw% <= gshrp% THEN note$ = "G sharp"
- IF throw% > gshrp% AND throw% <= anat% THEN note$ = "A nat"
- IF throw% > anat% AND throw% <= ashrp% THEN note$ = "A sharp"
- IF throw% > ashrp% AND throw% <= bnat% THEN note$ = "B nat"
- PRINT ''" note = ";note$
- PRINT '" use this? "
- CASE GET$ OF
- WHEN "n","N" :
- PROCpitchstring3
- OTHERWISE
- ENDCASE
- INPUT'" which octave "octave%
- IF octave% > 0 THEN sameoctave% = octave%
- IF octave% = 0 THEN octave% = sameoctave%
- CASE note$ OF
- WHEN "C nat" : note% = 0 : accid% = 5 : octave% = octave%
- WHEN "C sharp" : note% = 0 : accid% = 9 : octave% = octave%
- WHEN "D nat" : note% = 1 : accid% = 5 : octave% = octave%
- WHEN "D sharp" : note% = 1 : accid% = 9 : octave% = octave%
- WHEN "E nat" : note% = 2 : accid% = 5 : octave% = octave%
- WHEN "F nat" : note% = 3 : accid% = 5 : octave% = octave%
- WHEN "F sharp" : note% = 3 : accid% = 9 : octave% = octave%
- WHEN "G nat" : note% = 4 : accid% = 5 : octave% = octave%
- WHEN "G sharp" : note% = 4 : accid% = 9 : octave% = octave%
- WHEN "A nat" : note% = 5 : accid% = 5 : octave% = octave%
- WHEN "A sharp" : note% = 5 : accid% = 9 : octave% = octave%
- WHEN "B nat" : note% = 6 : accid% = 5 : octave% = octave%
- ENDCASE
- numpitches% = 1 : pitches%(0) = (note%*100)+(accid%*10)+octave%
- PROCinsertpitches
- :
- ENDPROC
- :
- REM******************************************************************
- :
- DEF PROCincrementcalc
- :
- PROCwindow(15,71,89,45)
- CLS
- :
- PRINT'" As it is written, Accel/Rit allows no.attacks and rate"
- PRINT" to be defined in one mode, or start/finish durs in the other"
- PRINT" but not start dur AND a defined rate together (and just to"
- PRINT" complicate things, the resultant rate in fact varies in different"
- PRINT" contexts). If you want, say, a closely defined quickend and"
- PRINT" also a closely defined rate of rit, to get this in accel/Rit"
- PRINT" you will also need to know IN ADVANCE what the end dur will be"
- PRINT" so as to input this when using Accel/Rit in its second mode."
- PRINT" The proceedure below is for finding precisely this."
- :
- count% = 1
- INPUT'" First type the start duration "value
- PRINT'" then the arithmetic rate of increment (not the Accel/Rit rate)"
- INPUT" as a decimal number "factor
- total% = value
- INPUT'" and finally the total duration "reqtotal%
- PRINT'" (then press a key for successive increments)"
- PRINT'count%;". duration = ";value;" total = ";total%
- REPEAT
- CASE GET$ OF
- OTHERWISE
- count% += 1
- value = value * factor
- total% = total% + value
- gap% = reqtotal% - total%
- value% = value DIV 1
- PRINT'count%;". duration = ";value%;" total = ";total%;" (";gap%;" short of required total)"
- ENDCASE
- UNTIL gap% <0
- :
- PRINT'" (to return to display press F)"
- REPEAT
- key$ = GET$
- IF key$ = "f" THEN PROCdisplay ELSE VDU 7
- UNTIL key$ = "f"
- ENDPROC
- :
- REM*********************************************************************************
- :
- DEF PROCchangeclef
- :
- PROCwindow(20,69,65,55)
- INPUT'" Change clef for which voice "itsvoice%
- INPUT'" How many staves does this voice have "numstaves$
- PRINT'" And what is/are its clefs (P/T/B/D or"
- INPUT" PP/PT etc.) "clef$
- :
- insts$(itsvoice%,2) = numstaves$
- insts$(itsvoice%,1) = clef$
- :
- ENDPROC
- :
- REM**********************************************************************************
- :
- DEF PROCrandomassign
- :
- CLS
- INPUT'" between voice (for 1 press 0) "first%
- IF first% = 0 THEN firs% = 1
- INPUT'" and voice (for last press 0) "last%
- IF last% = 0 THEN last% = numparts%
- :
- INPUT '" using how many of the 19 voices "no%
- taken%() = 0
- :
- FOR count% = 1 TO no%
- result$ = "failure"
- REPEAT
- voice% = RND(19)
- IF taken%(voice%) = 0 THEN
- taken%(voice%) = 1
- result$ = "success"
- ENDIF
- UNTIL result$ = "success"
- NEXT
- :
- FOR count% = first% TO last%
- REPEAT
- x% = RND(19)
- UNTIL taken%(x%) = 1
- :
- CASE x% OF
- WHEN 1 : IF type$ = "drums" THEN waveforms$(count%) = "Timpani" ELSE waveforms$(count%) = "RecorderGb"
- WHEN 2 : IF type$ = "drums" THEN waveforms$(count%) = "TimpCresBb" ELSE waveforms$(count%) = "PiccoloE"
- WHEN 3 : IF type$ = "drums" THEN waveforms$(count%) = "TimpRollEb" ELSE waveforms$(count%) = "SaxSoprnoE"
- WHEN 4 : IF type$ = "drums" THEN waveforms$(count%) = "TimpLowBb" ELSE waveforms$(count%) = "SaxEbBarC"
- WHEN 5 : IF type$ = "drums" THEN waveforms$(count%) = "BassDrum" ELSE waveforms$(count%) = "SaxBbTenrE"
- WHEN 7 : IF type$ = "drums" THEN waveforms$(count%) = "BDGatedRev" ELSE waveforms$(count%) = "BugleC"
- WHEN 8 : IF type$ = "drums" THEN waveforms$(count%) = "BDMarching" ELSE waveforms$(count%) = "Trombone1"
- WHEN 9 : IF type$ = "drums" THEN waveforms$(count%) = "BDPiloMute" ELSE waveforms$(count%) = "Trumpet"
- WHEN 10 : IF type$ = "drums" THEN waveforms$(count%) = "CongaHi" ELSE waveforms$(count%) = "EngHornGb"
- WHEN 11 : IF type$ = "drums" THEN waveforms$(count%) = "CongaMid" ELSE waveforms$(count%) = "ClarinetBb"
- WHEN 12 : IF type$ = "drums" THEN waveforms$(count%) = "CongaSmCl" ELSE waveforms$(count%) = "ClarVibEb"
- WHEN 14 : IF type$ = "drums" THEN waveforms$(count%) = "ElecTom1" ELSE waveforms$(count%) = "BassoonEb"
- WHEN 16 : IF type$ = "drums" THEN waveforms$(count%) = "RotoTomRev" ELSE waveforms$(count%) = "FlugelHnEb"
- WHEN 15 : IF type$ = "drums" THEN waveforms$(count%) = "SimmonsBD1" ELSE waveforms$(count%) = "CornetEb"
- WHEN 13 : IF type$ = "drums" THEN waveforms$(count%) = "Snare" ELSE waveforms$(count%) = "TubaGb"
- WHEN 6 : IF type$ = "drums" THEN waveforms$(count%) = "SnareEcho" ELSE waveforms$(count%) = "BassBowAb"
- WHEN 17 : IF type$ = "drums" THEN waveforms$(count%) = "SynTom" ELSE waveforms$(count%) = "JapFlute"
- WHEN 18 : IF type$ = "drums" THEN waveforms$(count%) = "TablaHi" ELSE waveforms$(count%) = "EnsWodAb45"
- WHEN 19 : IF type$ = "drums" THEN waveforms$(count%) = "Tomtom1" ELSE waveforms$(count%) = "Bass"
- ENDCASE
- NEXT
- :
- PROCwindow(20,72,83,25)
- VDU 14
- PRINT'" Current assignations are now "
- PRINT " (press Ctrl-Shift to scroll down) "
- FOR count% = 1 TO numparts%
- IF waveforms$(count%) <> "" THEN
- PRINT'" voice ";count%;
- IF insts$(count%,0)<> "" THEN PRINT " (";insts$(count%,0);")";
- PRINT " - ";waveforms$(count%)
- ENDIF
- NEXT
- VDU 15
- PRINT'" Do you want to keep these, reassign,"
- PRINT " use WaveSynth-Beep defaults, "
- PRINT " randomly assign sustaining/dry instruments/drums "
- PRINT " to all staves, or assign in groups "
- PRINT " (K/R/W/S/D/M/G) "
- CASE GET$ OF
- WHEN "R","r" : defaultvoices$ = "n" : PROCassignvoices : PROCdisplay
- WHEN "W","w" : defaultvoices$ = "y" : PROCassignvoices : PROCdisplay
- WHEN "K","k" : defaultvoices$ = "n" : PROCdisplay
- WHEN "S","s" : defaultvoices$ = "n" : type$ = "sustaining" : PROCrandomassign : PROCdisplay
- WHEN "M","m" : defaultvoices$ = "n" : type$ = "drums" : PROCrandomassign : PROCdisplay
- WHEN "D","d" : defaultvoices$ = "n" : PROCrandomdry : PROCdisplay
- WHEN "G","g" : defaultvoices$ = "n" : PROCgroupassign : PROCdisplay
- ENDCASE
- :
- ENDPROC
- :
- REM************************************************************************8
- :
- DEF PROCrandomdry
- :
- CLS
- PRINT'" Group A = 'ch' sounds "
- PRINT " Group B = 'donk' sounds "
- PRINT " Group C = pizz sounds "
- PRINT'" Select a group or to mix A+B press D, to mix A+C press E "
- PRINT " to mix B+C press F, or to mix all three press G "
- CASE GET$ OF
- WHEN "A","a" : choice$ = "A"
- WHEN "B","b" : choice$ = "B"
- WHEN "C","c" : choice$ = "C"
- WHEN "D","d" : choice$ = "D"
- WHEN "E","e" : choice$ = "E"
- WHEN "F","f" : choice$ = "F"
- OTHERWISE choice$ = "G"
- ENDCASE
- :
- INPUT'" between voice (for first press 0) "first%
- IF first% = 0 THEN first% = 1
- INPUT'" and voice (for last press 0) "last%
- IF last% = 0 THEN last% = numparts%
- :
- FOR count% = first% TO last%
- waveforms$(count%) = "empty"
- NEXT
- :
- FOR count% = first% TO last%
- :
- REPEAT
- x% = RND(19)
- :
- CASE x% OF
- WHEN 1 : IF choice$ = "A" OR choice$ = "D" OR choice$ = "E" OR choice$ = "G" THEN waveforms$(count%) = "GuiroFast"
- WHEN 2 : IF choice$ = "A" OR choice$ = "D" OR choice$ = "E" OR choice$ = "G" THEN waveforms$(count%) = "Cachichi1"
- WHEN 3 : IF choice$ = "A" OR choice$ = "D" OR choice$ = "E" OR choice$ = "G" THEN waveforms$(count%) = "Cabasa"
- WHEN 4 : IF choice$ = "A" OR choice$ = "D" OR choice$ = "E" OR choice$ = "G" THEN waveforms$(count%) = "HiHat"
- WHEN 5 : IF choice$ = "A" OR choice$ = "D" OR choice$ = "E" OR choice$ = "G" THEN waveforms$(count%) = "HiHatFoot"
- WHEN 7 : IF choice$ = "B" OR choice$ = "D" OR choice$ = "F" OR choice$ = "G" THEN waveforms$(count%) = "TablaHi"
- WHEN 8 : IF choice$ = "B" OR choice$ = "D" OR choice$ = "F" OR choice$ = "G" THEN waveforms$(count%) = "Clave"
- WHEN 9 : IF choice$ = "B" OR choice$ = "D" OR choice$ = "F" OR choice$ = "G" THEN waveforms$(count%) = "AgogoWood"
- WHEN 10 : IF choice$ = "B" OR choice$ = "D" OR choice$ = "F" OR choice$ = "G" THEN waveforms$(count%) = "CongaHi"
- WHEN 11 : IF choice$ = "B" OR choice$ = "D" OR choice$ = "F" OR choice$ = "G" THEN waveforms$(count%) = "CowBell"
- WHEN 12 : IF choice$ = "B" OR choice$ = "D" OR choice$ = "F" OR choice$ = "G" waveforms$(count%) = "AgogoAfric"
- WHEN 14 : IF choice$ = "B" OR choice$ = "D" OR choice$ = "F" OR choice$ = "G" THEN waveforms$(count%) = "Vibe"
- WHEN 16 : IF choice$ = "B" OR choice$ = "D" OR choice$ = "F" OR choice$ = "G" THEN waveforms$(count%) = "Xylophone"
- WHEN 15 : IF choice$ = "C" OR choice$ = "E" OR choice$ = "F" OR choice$ = "G" THEN waveforms$(count%) = "AcouBass"
- WHEN 13 : IF choice$ = "C" OR choice$ = "E" OR choice$ = "F" OR choice$ = "G" THEN waveforms$(count%) = "AcuBassAb1"
- WHEN 6 : IF choice$ = "C" OR choice$ = "E" OR choice$ = "F" OR choice$ = "G" THEN waveforms$(count%) = "AcGuitar1"
- WHEN 17 : IF choice$ = "C" OR choice$ = "E" OR choice$ = "F" OR choice$ = "G" THEN waveforms$(count%) = "Bass"
- WHEN 18 : IF choice$ = "C" OR choice$ = "E" OR choice$ = "F" OR choice$ = "G" THEN waveforms$(count%) = "AcouGtr2B"
- WHEN 19 : IF choice$ = "C" OR choice$ = "E" OR choice$ = "F" OR choice$ = "G" THEN waveforms$(count%) = "GtrDobroB"
- REM another possibility is Harp1
- ENDCASE
- :
- UNTIL waveforms$(count%) <> "empty"
- :
- NEXT
- :
- PROCwindow(20,72,83,25)
- VDU 14
- PRINT'" Current assignations are now "
- PRINT " (press Ctrl-Shift to scroll down) "
- FOR count% = 1 TO numparts%
- IF waveforms$(count%) <> "" THEN
- PRINT'" voice ";count%;
- IF insts$(count%,0)<> "" THEN PRINT " (";insts$(count%,0);")";
- PRINT " - ";waveforms$(count%)
- ENDIF
- NEXT
- VDU 15
- PRINT'" Do you want to keep these, reassign,"
- PRINT " use WaveSynth-Beep defaults, "
- PRINT " randomly assign sustaining/dry instruments/drums "
- PRINT " to all staves, or assign in groups "
- PRINT " (K/R/W/S/D/M/G) "
- CASE GET$ OF
- WHEN "R","r" : defaultvoices$ = "n" : PROCassignvoices : PROCdisplay
- WHEN "W","w" : defaultvoices$ = "y" : PROCassignvoices : PROCdisplay
- WHEN "K","k" : defaultvoices$ = "n" : PROCdisplay
- WHEN "S","s" : defaultvoices$ = "n" : type$ = "sustaining" : PROCrandomassign : PROCdisplay
- WHEN "M","m" : defaultvoices$ = "n" : type$ = "drums" : PROCrandomassign : PROCdisplay
- WHEN "D","d" : defaultvoices$ = "n" : PROCrandomdry : PROCdisplay
- WHEN "G","g" : defaultvoices$ = "n" : PROCgroupassign : PROCdisplay
- ENDCASE
- :
- ENDPROC
- :
- REM***********************************************************************************
- :
- DEF PROCgroupassign
- :
- CLS
- PRINT'" Groups of voices ranging downwards are to "
- PRINT " take the waveform of the first in the group "
- INPUT " in batches of how many voices "gap%
- INPUT'" To apply between voice "low%
- INPUT " and voice "high%
- :
- FOR count% = 1 TO numparts%
- :
- IF count% >= low% AND count% <= high% THEN
- :
- x% = 0
- REPEAT
- :
- IF count% > (low%+(gap%*x%)) AND count% < (low%+(gap%*(x%+1))) THEN
- number% = low%+(gap%*x%)
- waveforms$(count%) = waveforms$(number%)
- ENDIF
- :
- x% = x%+1
- UNTIL (low%+(gap%*x%)) > high%
- :
- ENDIF
- :
- NEXT
- :
- PROCwindow(20,72,83,25)
- VDU 14
- PRINT'" Current assignations are now "
- PRINT " (press Ctrl-Shift to scroll down) "
- FOR count% = 1 TO numparts%
- IF waveforms$(count%) <> "" THEN
- PRINT'" voice ";count%;
- IF insts$(count%,0)<> "" THEN PRINT " (";insts$(count%,0);")";
- PRINT " - ";waveforms$(count%)
- ENDIF
- NEXT
- VDU 15
- PRINT'" Do you want to keep these, reassign,"
- PRINT " use WaveSynth-Beep defaults, "
- PRINT " randomly assign sustaining/dry instruments "
- PRINT " to all staves, or assign in groups "
- PRINT " (K/R/W/S/D/G) "
- CASE GET$ OF
- WHEN "R","r" : defaultvoices$ = "n" : PROCassignvoices : PROCdisplay
- WHEN "W","w" : defaultvoices$ = "y" : PROCassignvoices : PROCdisplay
- WHEN "K","k" : defaultvoices$ = "n" : PROCdisplay
- WHEN "S","s" : defaultvoices$ = "n" : PROCrandomassign : PROCdisplay
- WHEN "D","d" : defaultvoices$ = "n" : PROCrandomdry : PROCdisplay
- WHEN "G","g" : defaultvoices$ = "n" : PROCgroupassign : PROCdisplay
- ENDCASE
- :
- ENDPROC
- :
- REM***********************************************************************************
- :
- DEF PROCpitchstring4
- :
- CLS
- INPUT'" How many attacks "many%
- PRINT'" the first note is ";
- COLOUR 3
- CASE GET$ OF
- WHEN "c" : note1% = 0 : PRINT "C"
- WHEN "d" : note1% = 1 : PRINT "D"
- WHEN "e" : note1% = 2 : PRINT "E"
- WHEN "f" : note1% = 3 : PRINT "F"
- WHEN "g" : note1% = 4 : PRINT "G"
- WHEN "a" : note1% = 5 : PRINT "A"
- WHEN "b" : note1% = 6 : PRINT "B"
- ENDCASE
- COLOUR 0
- PRINT " accidental ";
- COLOUR 3
- CASE GET$ OF
- WHEN "1" : accid1% = 1 : PRINT " flat"
- WHEN "2" : accid1% = 2 : PRINT " 3/8 flat"
- WHEN "3" : accid1% = 3 : PRINT " 1/4 flat"
- WHEN "4" : accid1% = 4 : PRINT " 1/8 flat"
- WHEN "5" : accid1% = 5 : PRINT " natural"
- WHEN "6" : accid1% = 6 : PRINT " 1/8 sharp"
- WHEN "7" : accid1% = 7 : PRINT " 1/4 sharp"
- WHEN "8" : accid1% = 8 : PRINT " 3/8 sharp"
- WHEN "9" : accid1% = 9 : PRINT " sharp"
- ENDCASE
- COLOUR 0
- PRINT " octave ";
- COLOUR 3
- CASE GET$ OF
- WHEN "1" : octave1% = 1 : PRINT " octave 1"
- WHEN "2" : octave1% = 2 : PRINT " octave 2"
- WHEN "3" : octave1% = 3 : PRINT " octave 3"
- WHEN "4" : octave1% = 4 : PRINT " octave 4"
- WHEN "5" : octave1% = 5 : PRINT " octave 5"
- WHEN "6" : octave1% = 6 : PRINT " octave 6"
- WHEN "7" : octave1% = 7 : PRINT " octave 7"
- WHEN "8" : octave1% = 8 : PRINT " octave 8"
- ENDCASE
- COLOUR 0
- PRINT'" and the second note is ";
- COLOUR 3
- CASE GET$ OF
- WHEN "c" : note2% = 0 : PRINT "C"
- WHEN "d" : note2% = 1 : PRINT "D"
- WHEN "e" : note2% = 2 : PRINT "E"
- WHEN "f" : note2% = 3 : PRINT "F"
- WHEN "g" : note2% = 4 : PRINT "G"
- WHEN "a" : note2% = 5 : PRINT "A"
- WHEN "b" : note2% = 6 : PRINT "B"
- ENDCASE
- COLOUR 0
- PRINT " accidental ";
- COLOUR 3
- CASE GET$ OF
- WHEN "1" : accid2% = 1 : PRINT " flat"
- WHEN "2" : accid2% = 2 : PRINT " 3/8 flat"
- WHEN "3" : accid2% = 3 : PRINT " 1/4 flat"
- WHEN "4" : accid2% = 4 : PRINT " 1/8 flat"
- WHEN "5" : accid2% = 5 : PRINT " natural"
- WHEN "6" : accid2% = 6 : PRINT " 1/8 sharp"
- WHEN "7" : accid2% = 7 : PRINT " 1/4 sharp"
- WHEN "8" : accid2% = 8 : PRINT " 3/8 sharp"
- WHEN "9" : accid2% = 9 : PRINT " sharp"
- ENDCASE
- COLOUR 0
- PRINT " octave ";
- COLOUR 3
- CASE GET$ OF
- WHEN "1" : octave2% = 1 : PRINT " octave 1"
- WHEN "2" : octave2% = 2 : PRINT " octave 2"
- WHEN "3" : octave2% = 3 : PRINT " octave 3"
- WHEN "4" : octave2% = 4 : PRINT " octave 4"
- WHEN "5" : octave2% = 5 : PRINT " octave 5"
- WHEN "6" : octave2% = 6 : PRINT " octave 6"
- WHEN "7" : octave2% = 7 : PRINT " octave 7"
- WHEN "8" : octave2% = 8 : PRINT " octave 8"
- ENDCASE
- COLOUR 0
- tick% = 1
- FOR count% = 1 TO many%
- IF tick% = 1 THEN
- pitches%(count%-1) = (note1%*100)+(accid1%*10)+octave1%
- ELSE
- pitches%(count%-1) = (note2%*100)+(accid2%*10)+octave2%
- ENDIF
- IF tick% = 1 THEN tick% = 2 ELSE tick% = 1
- NEXT
- :
- numpitches% = many%
- PROCinsertpitches
- :
- ENDPROC
- :
- REM*********************************************************************************
- :
- DEF PROCcopyonenote
- :
- repeatposit$ = "n"
- IF distort$ = "OFF" THEN dothis$ = "YES"
- IF distort$ = "ON" THEN
- IF distortpara$ = "attacks" THEN dothis$ = "YES" ELSE dothis$ = "NO"
- ENDIF
- copymove$ = "C" : savevoice$ = "N" : justone$ = "y"
- :
- PROCcopy2
- :
- justone$ = "n"
- :
- ENDPROC
- :
- REM***********************************************************************************
- :
- DEF PROCcopygroupofnotes
- :
- repeatposit$ = "n"
- IF distort$ = "OFF" THEN dothis$ = "YES"
- IF distort$ = "ON" THEN
- IF distortpara$ = "attacks" THEN dothis$ = "YES" ELSE dothis$ = "NO"
- ENDIF
- :
- copymove$ = "C" : savevoice$ = "N" : justone$ = "n"
- :
- PROCcopy2
- :
- ENDPROC
- :
- REM*************************************************************************************
- :
- DEF PROCcopydownwards
- :
- repeatposit$ = "n"
- IF distort$ = "OFF" THEN dothis$ = "YES"
- IF distort$ = "ON" THEN
- IF distortpara$ = "attacks" THEN dothis$ = "YES" ELSE dothis$ = "NO"
- ENDIF
- copymove$ = "C" : savevoice$ = "N" : justone$ = "y"
- :
- voice% = displayvoices%(startv%)
- voice% = voice%-1
- :
- along% = copydownwards%
- :
- along%-=1
- copystartbar% = array%(holdstartcell%(voice%)+along%,0,voice%)DIV10^6
- copystartbeat% = (array%(holdstartcell%(voice%)+along%,0,voice%)MOD10^6)DIV10^3
- holdbar% = copystartbar%
- holdbeat% = copystartbeat%
- :
- copyendbar% = copystartbar%
- copyendbeat% = copystartbeat%
- :
- value% = (copystartbar%*10^3)+copystartbeat%
- IF value% <= array%(0,0,voice%)DIV10^3 THEN
- startatcell% = 0
- ELSE
- PROCsearch(value%)
- startatcell% = startcell%
- ENDIF
- IF copyendbar% = 0 THEN
- endatcell% = numusedcells%(voice%) - 1
- ELSE
- value% = (copyendbar%*10^3)+copyendbeat%
- IF value% >= array%(numusedcells%(voice%)-1,0,voice%)DIV10^3 THEN
- endatcell% = numusedcells%(voice%) - 1
- ELSE
- PROCsearch(value%)
- IF shunt$ = "N" THEN endatcell% = startcell% ELSE endatcell% = startcell% - 1
- ENDIF
- ENDIF
- :
- manyattacks% = endatcell% - startatcell% + 1
- REM create 'gap' between beat-of-bar and first actual attack
- carrybars% = (array%(startatcell%,0,voice%)DIV10^6)-copystartbar%
- carrybeats% = ((array%(startatcell%,0,voice%)DIV10^3)MOD10^3)-copystartbeat%
- attacks1%(0) = (carrybars%*960)+carrybeats%
- :
- IF copymove$ = "C" OR copymove$ = "M" THEN
- FOR count% = 0 TO (manyattacks%-1)
- IF count% > 0 THEN
- carrybars% = (array%(startatcell%+count%,0,voice%)DIV10^6)-(array%(startatcell%+count%-1,0,voice%)DIV10^6)
- carrybeats% = ((array%(startatcell%+count%,0,voice%)DIV10^3)MOD10^3)-((array%(startatcell%+count%-1,0,voice%)DIV10^3)MOD10^3)
- attacks1%(count%) = attacks1%(count%-1) + ((carrybars%*960)+carrybeats%)
- ENDIF
- :
- pitches%(count%) = array%(startatcell%+count%,0,voice%)MOD10^3
- dur% = (array%(startatcell%+count%,1,voice%)DIV10)MOD10^3
- brrr% = array%(startatcell%+count%,0,voice%)DIV10^6 : PROCreconvertdur
- durations%(count%) = dur%
- amplitudes%(count%) = (array%(startatcell%+count%,1,voice%))MOD10
- envelopes%(count%) = (array%(startatcell%+count%,2,voice%))DIV10^2
- glissandos%(count%) = array%(startatcell%+count%,1,voice%)DIV10^4
- inflections%(count%) = array%(startatcell%+count%,2,voice%)MOD10^2
- NEXT
- ELSE PROCextract
- ENDIF
- :
- IF copymove$ = "M" THEN
- numnotes% = manyattacks% : startcell% = startatcell%
- FOR count% = startcell% TO (startcell%+(numnotes%-1))
- FOR counter% = 0 TO 1
- barno% = (array%(count%,0,voice%)DIV10^6)-counter%
- beatnum% = ((array%(count%,0,voice%)DIV10^3)MOD10^3)
- :
- group1start% = (disarray%(barno%,0,voice%)DIV10^7)*beatfactor%
- group1end% = group1start% + (((disarray%(barno%,0,voice%)DIV10^5)MOD10^2)*beatfactor%)-1
- IF beatnum%+(960*counter%) >= group1start% AND beatnum%+(960*counter%) <= group1end% THEN
- disarray%(barno%,0,voice%) = disarray%(barno%,0,voice%)MOD10^3
- ENDIF
- :
- group2start% = ((disarray%(barno%,0,voice%)DIV10)MOD10^2)*beatfactor%
- group2end% = group2start%+((((disarray%(barno%,0,voice%)MOD10)*10)+(disarray%(barno%,1,voice%)DIV10^8))*beatfactor%)-1
- IF beatnum%+(960*counter%) >= group2start% AND beatnum%+(960*counter%) <= group2end% THEN
- disarray%(barno%,0,voice%) = (disarray%(barno%,0,voice%)DIV10^3)*10^3
- disarray%(barno%,1,voice%) = disarray%(barno%,1,voice%)MOD10^6
- ENDIF
- group3start%=((disarray%(barno%,1,voice%)DIV10^4)MOD10^2)*beatfactor%
- group3end% = group3start% + (((disarray%(barno%,1,voice%)MOD10^4)DIV10^2)*beatfactor%)-1
- IF beatnum%+(960*counter%) >= group3start% AND beatnum%+(960*counter%) <= group3end% THEN
- disarray%(barno%,1,voice%) = (disarray%(barno%,1,voice%)DIV10^6)*10^6
- ENDIF
- group4start% = (disarray%(barno%,2,voice%)DIV10^7)*beatfactor%
- group4end% = group4start%+(((disarray%(barno%,2,voice%)DIV10^5)MOD10^2)*beatfactor%)-1
- IF beatnum%+(960*counter%) >= group4start% AND beatnum%+(960*counter%) <= group4end% THEN
- disarray%(barno%,2,voice%) = disarray%(barno%,2,voice%)MOD10^3
- ENDIF
- group5start% = ((disarray%(barno%,2,voice%)MOD10^3)DIV10)*beatfactor%
- group5end% = group5start%+((((disarray%(barno%,2,voice%)MOD10)*10)+(disarray%(barno%,3,voice%)DIV10^8))*beatfactor%)-1
- IF beatnum%+(960*counter%) >= group5start% AND beatnum%+(960*counter%) <= group5end% THEN
- disarray%(barno%,2,voice%) = (disarray%(barno%,2,voice%)DIV10^3)*10^3
- disarray%(barno%,3,voice%) = disarray%(barno%,3,voice%)MOD10^6
- ENDIF
- group6start% = ((disarray%(barno%,3,voice%)DIV10^4)MOD10^2)*beatfactor%
- group6end% = group6start% + (((disarray%(barno%,3,voice%)DIV10^2)MOD10^2)*beatfactor%)-1
- IF beatnum%+(960*counter%) >= group6start% AND beatnum%+(960*counter%) <= group6end% THEN
- disarray%(barno%,3,voice%)=(disarray%(barno%,3,voice%)DIV10^6)*10^6
- ENDIF
- NEXT
- :
- NEXT
- PROCshuntleft(startcell%,numnotes%)
- ENDIF
- :
- numpitches% = manyattacks% : method$ = "raw" : copyit$ = "ON" : copydownwards$ = "y"
- :
- PROCinsertattacks
- :
- justone$ = "n" : copydownwards$ = "n"
- ENDPROC
- :
- REM****************************************************************
- :
- DEF PROCdeleteone
- :
- CASE deleteone$ OF
- WHEN "top" :
- voice% = 1
- voice% = displayvoices%(startv%+voice%-1)
- voice% -= 1
- WHEN "middle" :
- voice% = 2
- voice% = displayvoices%(startv%+voice%-1)
- voice% -= 1
- WHEN "bottom" :
- voice% = 3
- voice% = displayvoices%(startv%+voice%-1)
- voice% -= 1
- ENDCASE
- :
- numnotes% = 1
- :
- incre$ = INKEY$(100)
- IF incre$ <> "" THEN
- CASE incre$ OF
- WHEN "!" : along% = 1
- WHEN """" : along% = 2
- WHEN "£" : along% = 3
- WHEN "$" : along% = 4
- WHEN "%" : along% = 5
- WHEN "^" : along% = 6
- WHEN "&" : along% = 7
- WHEN "*" : along% = 8
- WHEN "(" : along% = 9
- WHEN ")" : along% = 10
- ENDCASE
- ELSE along% = 1
- ENDIF
- :
- IF addten$ = "y" THEN along% +=10
- IF addten$ = "twenty" THEN along% +=20
- :
- along%-=1
- copystartbar% = array%(holdstartcell%(voice%)+along%,0,voice%)DIV10^6
- copystartbeat% = (array%(holdstartcell%(voice%)+along%,0,voice%)MOD10^6)DIV10^3
- beats% = copystartbeat%
- PROCalterbeats
- start% = (copystartbar%*(10^3))+beats%
- PROCsearch(start%)
- PROCshuntleft(startcell%,numnotes%)
- :
- deleteone$ = "none"
- ENDPROC
- :
- REM**********************************************************************
- :
- DEF PROCpitchstring5
- :
- IF easiermenus$ = "n" THEN PROCwindow(20,65,60,55) ELSE PROCwindow(20,65,60,42)
- PRINT'" This function returns a string"
- PRINT" of pitches which recycles an"
- PRINT" ascending chromatic scale,"
- PRINT" useful for subsequently"
- PRINT" extracting certain pitches"
- INPUT'" How many semitones in the scale "numsemis%
- INPUT'" How many pitches in the string "numpitches%
- counter% = 0
- :
- FOR count% = 0 TO numpitches%-1
- counter% += 1
- CASE counter% OF
- WHEN 1 : pitches%(count%) = 54
- WHEN 2 : pitches%(count%) = 94
- WHEN 3 : pitches%(count%) = 154
- WHEN 4 : pitches%(count%) = 214
- WHEN 5 : pitches%(count%) = 254
- WHEN 6 : pitches%(count%) = 354
- WHEN 7 : pitches%(count%) = 394
- WHEN 8 : pitches%(count%) = 454
- WHEN 9 : pitches%(count%) = 514
- WHEN 10 : pitches%(count%) = 554
- WHEN 11 : pitches%(count%) = 614
- WHEN 12 : pitches%(count%) = 654
- ENDCASE
- :
- IF counter% = numsemis% THEN counter% = 0
- :
- NEXT
- :
- PROCinsertpitches
- ENDPROC
- :
- ******************************************
- :
- DEF PROCdurationsbetween
- :
- IF numdurations% = 111 THEN mode$ = "legato"
- IF numdurations% = 222 THEN mode$ = "mezzostacc"
- PROCwindow(20,69,60,55)
- CLS
- :
- IF screenvoices$ = "n" THEN
- INPUT' " Which voice (0 = top) "voice%
- IF voice% = 0 THEN PROCpressenter
- ELSE
- PRINT'" Which screen voice "
- CASE GET$ OF
- WHEN "1" : voice% = 1
- WHEN "2" : voice% = 2
- WHEN "3" : voice% = 3
- OTHERWISE PROCpressenter
- ENDCASE
- ENDIF
- IF screenvoices$ = "y" AND voice% > 0 THEN voice% = displayvoices%(startv%+voice%-1)
- voice% -= 1
- IF voice% >= 0 THEN samevoice% = voice%
- IF voice% = -1 THEN voice% = samevoice%
- :
- PRINT'" How many gaps to be filled "
- INPUT " (for 1 press 0) "numdurations%
- PRINT'" starting at note number "
- INPUT " (for 1 press 0) "note%
- IF note% = 0 THEN note% = 1
- :
- PROCnewnotereception(voice%,startbar%,0,0,0,0,0,0,0)
- CASE option% OF
- WHEN 1 : startcell% = 0
- WHEN 2 : startcell% = numusedcells%(voice%)
- WHEN 3 : startcell% = 0
- WHEN 4 : start% = firstbar%*10^3 : PROCsearch(start%)
- ENDCASE
- silly% = startcell%+note%-1
- :
- FOR count% = 0 TO numdurations%-1
- beatdiff% = ((array%(silly%+1+count%,0,voice%)DIV10^3)MOD10^3)-((array%(silly%+count%,0,voice%)DIV10^3)MOD10^3)
- beatdiff%+=(((array%(silly%+1+count%,0,voice%)DIV10^6)-(array%(silly%+count%,0,voice%)DIV10^6))*960)
- CASE mode$ OF
- WHEN "legato" :
- durations%(count%+1) = beatdiff%
- OTHERWISE
- durations%(count%+1) = beatdiff%/2
- ENDCASE
- :
- NEXT
- :
- along% = note%-1
- copystartbar% = array%(holdstartcell%(voice%)+along%,0,voice%)DIV10^6
- copystartbeat% = (array%(holdstartcell%(voice%)+along%,0,voice%)MOD10^6)DIV10^3
- beats% = copystartbeat%
- PROCalterbeats
- startat% = (copystartbar%*(10^3))+beats%
- :
- PROCsearch(startat%)
- shunt$ = "N"
- :
- FOR count% = startcell% TO (startcell%+(numdurations%-1))
- PROCcellfill(count%,voice%,999,999,999,9,999,durations%(count%-startcell%+1),99,99)
- NEXT
- :
- PROCdisplay
- :
- ENDPROC
- :
- REM************************************************************************88
- :
- DEF PROCshortmove
- :
- ON : PROCwindow(20,69,60,55)
- CLS
- repeatposit$ = "n"
- IF distort$ = "OFF" THEN dothis$ = "YES"
- IF distort$ = "ON" THEN
- IF distortpara$ = "attacks" THEN dothis$ = "YES" ELSE dothis$ = "NO"
- ENDIF
- :
- IF dothis$ = "YES" THEN
- copymove$ = "M" : savevoice$ = "N" : justone$ = "n"
- ELSE copymove$ = "C"
- ENDIF
- :
- PROCcopy2
- IF quickextract$ = "y" THEN quickextract$ = "n"
- :
- ENDPROC
- :
- REM***********************************************************************8
- :
- DEF PROCshortmoveone
- :
- ON : PROCwindow(20,69,60,55)
- CLS
- repeatposit$ = "n"
- IF distort$ = "OFF" THEN dothis$ = "YES"
- IF distort$ = "ON" THEN
- IF distortpara$ = "attacks" THEN dothis$ = "YES" ELSE dothis$ = "NO"
- ENDIF
- :
- IF dothis$ = "YES" THEN
- copymove$ = "M" : savevoice$ = "N" : justone$ = "y"
- ELSE copymove$ = "C"
- ENDIF
- :
- PROCcopy2
- IF quickextract$ = "y" THEN quickextract$ = "n"
- :
- ENDPROC
- :
- REM************************************************************************
- :
- DEF PROCcopysuccessively
- :
- IF succfirsttime$ = "y" THEN
- INPUT'" Which voice? (0 = top) "voice%
- IF voice% = 0 THEN PROCpressenter
- fromvoice% = voice%
- succfirsttime$ = "n"
- succcounter% = 0
- ELSE succcounter% += 1
- ENDIF
- :
- IF succcounter% > 0 THEN
- :
- fromvoice% += 1 : voice% = fromvoice%
- PRINT' " That's voice ";voice%;"?"
- PRINT' " (0 = yes/C = cancel successive copying) "
- CASE GET$ OF
- WHEN "C","c" :
- copysuccessively$ = "n" : succfirsttime$ = "y" : PROCdisplay
- OTHERWISE
- ENDCASE
- :
- ENDIF
- :
- ENDPROC
- :
- REM***************************************************************************
- :
- DEF PROCpressenter
- :
- COLOUR 3
- incre$ = INKEY$(50)
- IF incre$ = "" THEN
- IF screenvoices$ = "y" THEN
- voice% = 1 : PRINT ' voice%
- ELSE
- voice% = displayvoices%(startv%) : PRINT ' voice%
- ENDIF
- ELSE
- incre$ = INKEY$(50)
- IF screenvoices$ = "y" THEN
- IF incre$ = "" THEN voice% = 2 ELSE voice% = 3
- PRINT ' voice%
- ELSE
- IF incre$ = "" THEN voice% = displayvoices%(startv%+1) ELSE voice% = displayvoices%(startv%+2)
- PRINT ' voice%
- ENDIF
- ENDIF
- COLOUR 0
- :
- ENDPROC
- :
- REM***************************************************************************
- :
- DEF PROCfornexttime
- :
- IF housekeepingdimmed$ = "n" THEN
- DIM lastfilename$(9)
- ENDIF
- *Dir SDFS::RISCOSpi.$.CAC.Files
- thisfilename$ = "housekeeping2"
- channel = OPENOUT thisfilename$
- FOR count% = 1 TO 9
- PRINT#channel, lastfilename$(count%)
- NEXT
- CLOSE#channel
- *NoDir
- :
- ENDPROC
- :
- REM****************************************************************************
- :
- DEF PROChousekeeping
- :
- IF housekeepingdimmed$ = "n" THEN
- DIM lastfilename$(9) : housekeepingdimmed$ = "y"
- ENDIF
- *Dir SDFS::RISCOSpi.$.CAC.Files
- thisfilename$ = "housekeeping2"
- channel = OPENIN thisfilename$
- REPEAT
- FOR count% = 1 TO 9
- INPUT#channel, lastfilename$(count%)
- NEXT
- UNTIL EOF#channel
- CLOSE#channel
- *NoDir
- :
- ENDPROC
- :
- REM*****************************************************************************
- :
- DEF PROCshuntlastfilename
- :
- FOR count% = 9 TO 2 STEP -1
- lastfilename$(count%) = lastfilename$(count%-1)
- NEXT
- lastfilename$(1) = filename$
- :
- ENDPROC
- :
- REM*****************************************************************************
- :
- DEF PROCspecialshunt
- :
- FOR count% = theone% TO 2 STEP -1
- lastfilename$(count%) = lastfilename$(count%-1)
- NEXT
- lastfilename$(1) = filename$
- :
- ENDPROC
- :
- REM******************************************************************************
- :
- DEF PROCroguenotes
- :
- FOR count% = 0 TO numparts%-1
- array%(numusedcells%(count%),0,count%) = 0
- NEXT
- :
- PROCdisplay
- :
- ENDPROC
- :
- REM*******************************************************************
- :
- DEF PROCnotenumberfreq
- :
- CASE nosevery% OF
- WHEN 1 :
- IF howmany% >= startnos% THEN printnumber$ = "y" ELSE printnumber$ = "n"
- WHEN 2 :
- howmany = howmany%/2
- howmany = (howmany * 10) MOD 10
- IF howmany = 5 THEN printnumber$ = "n" ELSE printnumber$ = "y"
- IF howmany% < startnos% THEN printnumber$ = "n"
- WHEN 4 :
- howmany = howmany%/4
- howmany = (howmany * 10) MOD 10
- IF howmany = 2 OR howmany = 5 OR howmany = 7 THEN printnumber$ = "n" ELSE printnumber$ = "y"
- IF howmany% < startnos% THEN printnumber$ = "n"
- WHEN 10 :
- IF howmany% MOD 10 = 0 THEN printnumber$ = "y" ELSE printnumber$ = "n"
- IF howmany% < startnos% THEN printnumber$ = "n"
- ENDCASE
- :
- ENDPROC
- :
- REM**************************************************************************
- :
- DEF PROCnotenumbersep
- old% = current%
- current% = hposn%-100
- gap% = current%-old%
- IF old% <> 0 AND howmany% > 1 THEN
- IF gap% < 50 THEN lowernumber% += 20 ELSE lowernumber% = 0
- IF (hposn%-100) - firsttrack% > 50 THEN
- lowernumber% = 0
- firsttrack% = hposn%-100
- ENDIF
- ENDIF
- ENDPROC
- :
- REM****************************************************************************
- :
- DEF PROCpitchstring6
- :
- CLS
- PRINT'" How many semitones high is the "
- INPUT " vertical space (0 = previous) "height
- IF height = 0 THEN
- height = previousheight
- COLOUR 3
- PRINT' previousheight
- COLOUR 0
- ENDIF
- PRINT'" and this is to be divided into "
- INPUT " how many steps "steps
- IF steps = 0 THEN
- steps = previoussteps
- COLOUR 3
- PRINT' previoussteps
- COLOUR 0
- ENDIF
- :
- each = height/(steps-1)
- result = 0
- FOR count% = 1 TO (steps-1)
- result += each
- IF ((result*10)MOD10) <= 5 add$ = "n" ELSE add$ = "y"
- result% = result DIV 1
- IF add$ = "y" result% += 1
- :
- oct% = 1
- IF result% > 11 THEN
- REPEAT
- result% -= 12
- oct% += 1
- UNTIL result% < 12
- ENDIF
- :
- CASE result% OF
- WHEN 0 : pitch% = 050
- WHEN 1 : pitch% = 090
- WHEN 2 : pitch% = 150
- WHEN 3 : pitch% = 210
- WHEN 4 : pitch% = 250
- WHEN 5 : pitch% = 350
- WHEN 6 : pitch% = 390
- WHEN 7 : pitch% = 450
- WHEN 8 : pitch% = 490
- WHEN 9 : pitch% = 550
- WHEN 10 : pitch% = 610
- WHEN 11 : pitch% = 650
- ENDCASE
- :
- pitch% += oct%
- pitches%(count%) = pitch%
- pitches%(0) = 051
- NEXT
- numpitches% = steps
- :
- PRINT'" Contour upwards, downwards,"
- PRINT " up-down, down-up (1/2/3/4) "
- CASE GET$ OF
- WHEN "1" : previouscontour$ = "1"
- WHEN "2" : previouscontour$ = "2" : PROCcontourdown
- WHEN "3" : previouscontour$ = "3" : PROCcontourupdown
- WHEN "4" : previouscontour$ = "4" : PROCcontourdownup
- OTHERWISE
- CASE previouscontour$ OF
- WHEN "1" : COLOUR 3 : PRINT'" upwards " : COLOUR 0
- wait$ = INKEY$(50)
- WHEN "2" : PROCcontourdown : COLOUR 3 : PRINT' "downwards " : COLOUR 0
- wait$ = INKEY$(50)
- WHEN "3" : PROCcontourupdown : COLOUR 3 : PRINT'" up-down " : COLOUR 0
- wait$ = INKEY$(50)
- WHEN "4" : PROCcontourdownup : COLOUR 3 : PRINT' " down-up " : COLOUR 0
- wait$ = INKEY$(50)
- ENDCASE
- ENDCASE
- :
- previousheight = height
- previoussteps = steps
- :
- PROCinsertpitches
- :
- ENDPROC
- :
- REM************************************************************************8
- :
- DEF PROCcontourdown
- :
- FOR count% = 0 TO (numpitches%-1)
- pitches1%(count%) = pitches%((numpitches%-1)-count%)
- NEXT
- FOR count% = 0 TO (numpitches%-1)
- pitches%(count%) = pitches1%(count%)
- NEXT
- :
- ENDPROC
- :
- REM***************************************************************************
- :
- DEF PROCcontourupdown
- :
- middle% = ((numpitches%+1)/2)-1
- addnumber% = 1
- minusnumber% = 0
- swing$ = "add"
- FOR count% = 0 TO (numpitches%-1)
- IF swing$ = "subtract" THEN swing$ = "add" ELSE swing$ = "subtract"
- :
- IF swing$ = "add" THEN
- pitches1%(middle%+addnumber%) = pitches%((numpitches%-1)-count%)
- addnumber% += 1
- ELSE
- pitches1%(middle%-minusnumber%) = pitches%((numpitches%-1)-count%)
- minusnumber% += 1
- ENDIF
- NEXT
- :
- FOR count% = 0 TO (numpitches%-1)
- pitches%(count%) = pitches1%(count%)
- NEXT
- :
- ENDPROC
- :
- REM******************************************************************************
- :
- DEF PROCcontourdownup
- :
- middle% = ((numpitches%+1)/2)-1
- addnumber% = 1
- minusnumber% = 0
- swing$ = "add"
- FOR count% = 0 TO (numpitches%-1)
- IF swing$ = "subtract" THEN swing$ = "add" ELSE swing$ = "subtract"
- :
- IF swing$ = "add" THEN
- pitches1%(middle%+addnumber%) = pitches%(count%)
- addnumber% += 1
- ELSE
- pitches1%(middle%-minusnumber%) = pitches%(count%)
- minusnumber% += 1
- ENDIF
- NEXT
- :
- FOR count% = 0 TO (numpitches%-1)
- pitches%(count%) = pitches1%(count%)
- NEXT
- :
- ENDPROC
- :
- REM**********************************************************************************
- :
- DEF PROCdisplayonlycontent
- :
- IF onlycontent$ = "n" THEN
- displayvoices%() = displayvoices1%() : numvoices% = numvoices1%
- ELSE
- voicedone% = -1 : voicesdone% = 0 : displayvoices1%() = displayvoices%()
- numvoices1% = numvoices%
- FOR count% = 1 TO numvoices%
- FOR counter% = startbar% TO (startbar%+numbars%-1)
- voice% = displayvoices%(count%)-1
- addingnotes$ = "n"
- PROCnewnotereception(voice%,counter%,0,0,0,0,0,0,0)
- CASE option% OF
- WHEN 1 : startcell% = 0
- WHEN 2 : startcell% = numusedcells%(voice%)
- WHEN 3 : startcell% = 0
- WHEN 4 : PROCsearch(counter%*10^3)
- ENDCASE
- IF array%(startcell%,0,voice%) DIV10^6 > 0 THEN
- IF (array%(startcell%,0,voice%) DIV10^6) < (startbar%+numbars%) THEN
- IF voice% <> voicedone% THEN
- voicesdone% += 1 : displayvoices%(voicesdone%) = (voice%+1) : holddisplay%(voicesdone%) = (voice%+1)
- voicedone% = voice%
- ENDIF
- ENDIF
- ENDIF
- NEXT
- NEXT
- :
- numvoices% = voicesdone% : startv% = 1 : holdstart% = 1
- :
- ENDIF
- :
- PROCdisplay
- :
- ENDPROC
- :
- REM**********************************************************8
- :
- DEF PROCcontentonlylist
- :
- CLS
- PRINT ""
- voicedone% = -1
- FOR count% = 1 TO numvoices%
- FOR counter% = startbar% TO (startbar%+numbars%-1)
- voice% = displayvoices%(count%)-1
- addingnotes$ = "n"
- PROCnewnotereception(voice%,counter%,0,0,0,0,0,0,0)
- CASE option% OF
- WHEN 1 : startcell% = 0
- WHEN 2 : startcell% = numusedcells%(voice%)
- WHEN 3 : startcell% = 0
- WHEN 4 : PROCsearch(counter%*10^3)
- ENDCASE
- IF array%(startcell%,0,voice%) DIV 10^6 > 0 THEN
- IF (array%(startcell%,0,voice%)) DIV 10^6 < (startbar%+numbars%) THEN
- IF voice% <> voicedone% THEN
- IF compress$ = "n" THEN
- PRINT ' voice%+1;". ";insts$(voice%+1,0)
- ELSE
- PRINT voice%+1;". ";insts$(voice%+1,0)
- ENDIF
- voicedone% = voice%
- ENDIF
- ENDIF
- ENDIF
- NEXT
- NEXT
- :
- PRINT'" (press R to remove the list, press C to"
- PRINT'" compress/uncompress the list or press Q to"
- PRINT'" go to Quickdisplay without removing the list"
- CASE GET$ OF
- WHEN "C","c" :
- IF compress$ = "y" THEN compress$ = "n" ELSE compress$ = "y"
- PROCcontentonlylist
- WHEN "Q","q" : quickdisplaywindow$ = "n" : PROCquickdisplay
- OTHERWISE PROCdisplay
- ENDCASE
- :
- ENDPROC
- :
- REM*************************************************************
- :
- DEF PROCundoprepare
- :
- manynotesX%=manynotes%
- numpartsX%=numparts%
- nobarsX% =nobars%
- startvX% =startv%
- startv1X% =startv1%
- numbarsX% =numbars%
- startbarX% =startbar%
- numvoicesX%=numvoices%
- factorX% =factor%
- beatfactorX%=beatfactor%
- beamsX% =beams%
- longbeatsupperX%= longbeatsupper%
- longbeatslowerX%=longbeatslower%
- tempoX% =tempo%
- MMX% =MM%
- noteheadX$=notehead$
- longscoreX$= longscore$
- barlinesX$ =barlines$
- stavesX$ =staves$
- beatsX$ =beats$
- amplitudesX$= amplitudes$
- namesX$ =names$
- accidentalsX$=accidentals$
- stemsX$=stems$
- xoptionX$= xoption$
- durationsX$=durations$
- envelopesX$ =envelopes$
- glissandosX$ =glissandos$
- numwavesX% =numwaves%
- manywavesX% =manywaves%
- barnosoftenX%= barnosoften%
- FOR c% = 0 TO (numparts%-1)
- numusedcellsX%(c%)=numusedcells%(c%)
- NEXT
- FOR e% = 0 TO (numparts%-1)
- FOR d% = 0 TO 2
- FOR c% = 0 TO manynotes%
- arrayX%(c%,d%,e%)=array%(c%,d%,e%)
- NEXT
- NEXT
- NEXT
- FOR c% = 0 TO numparts%
- FOR d% = 0 TO 2
- instsX$(c%,d%)=insts$(c%,d%)
- NEXT
- NEXT
- FOR c% = 0 TO nobars%
- FOR d% = 0 TO 3
- FOR e% = 0 TO (numparts%-1)
- disarrayX%(c%,d%,e%)= disarray%(c%,d%,e%)
- NEXT
- NEXT
- NEXT
- FOR c% = 0 TO numparts%
- longbeamposnX%(c%) =longbeamposn%(c%)
- NEXT
- FOR c% = 0 TO numparts%
- shortbeamposnX%(c%) =shortbeamposn%(c%)
- NEXT
- FOR c% = 0 TO numparts%
- shortampposX%(c%)=shortamppos%(c%)
- NEXT
- FOR c% = 0 TO numparts%
- longampposX%(c%) =longamppos%(c%)
- NEXT
- FOR c% = 0 TO (numparts%-1)
- longstemdirX$(c%)=longstemdir$(c%)
- NEXT
- FOR c% = 0 TO (numparts%-1)
- shortstemdirX$(c%)=shortstemdir$(c%)
- NEXT
- FOR c% = 0 TO numparts%
- waveformsX$(c%)=waveforms$(c%)
- NEXT
- FOR c% = 0 TO numvoices%
- displayvoicesX%(c%)=displayvoices%(c%)
- NEXT
- FOR c% = 0 TO 19
- wformsX$(c%)=wforms$(c%)
- NEXT
- FOR c% = 0 TO 8
- FOR d% = 0 TO 9
- lvdataX%(c%,d%)= lvdata%(c%,d%)
- NEXT
- NEXT
- FOR a% = 0 TO 47
- pitchsetX%(a%)=pitchset%(a%)
- NEXT
- FOR a% = 0 TO 47
- dursetX%(a%)=durset%(a%)
- NEXT
- FOR a% = 0 TO 47
- ampsetX%(a%) =ampset%(a%)
- NEXT
- FOR a% = 0 TO 47
- glisssetX%(a%)=glissset%(a%)
- NEXT
- FOR a% = 0 TO 47
- envsetX%(a%) =envset%(a%)
- NEXT
- FOR a% = 0 TO nobars%
- tempiX%(a%) =tempi%(a%)
- NEXT
- FOR a% = 0 TO nobars%
- FOR b% = 0 TO 1
- remarksX$(a%,b%)= remarks$(a%,b%)
- NEXT
- NEXT
- :
- ENDPROC
- :
- REM****************************************
- :
- DEF PROCundo
- :
- manynotes%=manynotes%
- numparts%=numpartsX%
- nobars% =nobarsX%
- startv% =startvX%
- startv1% =startv1X%
- numbars% =numbarsX%
- startbar% =startbarX%
- numvoices%=numvoicesX%
- factor% =factorX%
- beatfactor%=beatfactorX%
- beams% =beamsX%
- longbeatsupper%= longbeatsupperX%
- longbeatslower%=longbeatslowerX%
- tempo% =tempoX%
- MM% =MMX%
- notehead$=noteheadX$
- longscore$= longscoreX$
- barlines$ =barlinesX$
- staves$ =stavesX$
- beats$ =beatsX$
- amplitudes$= amplitudesX$
- names$ =namesX$
- accidentals$=accidentalsX$
- stems$=stemsX$
- xoption$= xoptionX$
- durations$=durationsX$
- envelopes$ =envelopesX$
- glissandos$ =glissandosX$
- numwaves% =numwavesX%
- manywaves% =manywavesX%
- barnosoften%= barnosoftenX%
- FOR c% = 0 TO (numparts%-1)
- numusedcells%(c%)=numusedcellsX%(c%)
- NEXT
- FOR e% = 0 TO (numparts%-1)
- FOR d% = 0 TO 2
- FOR c% = 0 TO manynotes%
- array%(c%,d%,e%)=arrayX%(c%,d%,e%)
- NEXT
- NEXT
- NEXT
- FOR c% = 0 TO numparts%
- FOR d% = 0 TO 2
- insts$(c%,d%)=instsX$(c%,d%)
- NEXT
- NEXT
- FOR c% = 0 TO nobars%
- FOR d% = 0 TO 3
- FOR e% = 0 TO (numparts%-1)
- disarray%(c%,d%,e%)= disarrayX%(c%,d%,e%)
- NEXT
- NEXT
- NEXT
- FOR c% = 0 TO numparts%
- longbeamposn%(c%) =longbeamposnX%(c%)
- NEXT
- FOR c% = 0 TO numparts%
- shortbeamposn%(c%) =shortbeamposnX%(c%)
- NEXT
- FOR c% = 0 TO numparts%
- shortamppos%(c%)=shortampposX%(c%)
- NEXT
- FOR c% = 0 TO numparts%
- longamppos%(c%) =longampposX%(c%)
- NEXT
- FOR c% = 0 TO (numparts%-1)
- longstemdir$(c%)=longstemdirX$(c%)
- NEXT
- FOR c% = 0 TO (numparts%-1)
- shortstemdir$(c%)=shortstemdirX$(c%)
- NEXT
- FOR c% = 0 TO numparts%
- waveforms$(c%)=waveformsX$(c%)
- NEXT
- FOR c% = 0 TO numvoices%
- displayvoices%(c%)=displayvoicesX%(c%)
- NEXT
- FOR c% = 0 TO 19
- wforms$(c%)=wformsX$(c%)
- NEXT
- FOR c% = 0 TO 8
- FOR d% = 0 TO 9
- lvdata%(c%,d%)= lvdataX%(c%,d%)
- NEXT
- NEXT
- FOR a% = 0 TO 47
- pitchset%(a%)=pitchsetX%(a%)
- NEXT
- FOR a% = 0 TO 47
- durset%(a%)=dursetX%(a%)
- NEXT
- FOR a% = 0 TO 47
- ampset%(a%) =ampsetX%(a%)
- NEXT
- FOR a% = 0 TO 47
- glissset%(a%)=glisssetX%(a%)
- NEXT
- FOR a% = 0 TO 47
- envset%(a%) =envsetX%(a%)
- NEXT
- FOR a% = 0 TO nobars%
- tempi%(a%) =tempiX%(a%)
- NEXT
- FOR a% = 0 TO nobars%
- FOR b% = 0 TO 1
- remarks$(a%,b%)= remarksX$(a%,b%)
- NEXT
- NEXT
- :
- PROCdisplay
- :
- ENDPROC
- :
- REM*********************************
- :
- DEF PROCtutorial
- :
- CLS
- :
- PRINT ' " Bars and beats B"
- PRINT ' " Handling of durations D"
- PRINT ' " Only voices with content O"
- PRINT ' " Exiting dialogue windows E"
- PRINT ' " What does '0 = top' mean? W"
- PRINT ' " Accel/rit A"
- CASE GET$ OF
- WHEN "D","d" : PROCwindow(10,71,72,20) : CLS
- PRINT '" When a duration is input in bars/beats it is converted "
- PRINT '" into 1/20ths of a second at the current tempo "
- PRINT '" before being saved in the array. "
- PRINT '" (This is because when sounds are played, their durations "
- PRINT '" are given by BASIC to the OS as so many 1/20ths of a second). "
- PRINT' '" The Display procedure then reconverts back to bars/beats. "
- PRINT' '" Unavoidable floating point discrepencies occur during "
- PRINT '" this conversion/reconversion process, which often lead to "
- PRINT '" durations being displayed with different values to those "
- PRINT '" initially input, especially in the case of very small values. "
- PRINT ''" (to return to program press any key)"
- CASE GET$ OF
- WHEN "R","r" : PROCdisplay
- OTHERWISE PROCdisplay
- ENDCASE
- :
- WHEN "E","e" : PROCwindow(10,71,72,20) : CLS
- PRINT '" When no obvious key-presses are indicated, e.g. when you "
- PRINT '" want to exit a dialogue window at any point etc., simply "
- PRINT '" press <Esc> to return to the display. "
- CASE GET$ OF
- WHEN "R","r" : PROCdisplay
- OTHERWISE PROCdisplay
- ENDCASE
- :
- WHEN "W","w" : PROCwindow(10,71,72,20) : CLS
- PRINT '" This is a keyboard shortcut to select a voice which "
- PRINT '" is already displayed on the screen. "
- PRINT '" Press <Enter> once to select the top voice displayed. "
- PRINT '" Press <Enter> twice quickly to select the second voice "
- PRINT '" selected. Press <Enter> three times quickly to select "
- PRINT '" the bottom voice displayed. "
- CASE GET$ OF
- WHEN "R","r" : PROCdisplay
- OTHERWISE PROCdisplay
- ENDCASE
- :
- WHEN "A","a": PROCwindow(10,71,72,20) : CLS
- CASE GET$ OF
- WHEN "R","r" : PROCdisplay
- OTHERWISE PROCdisplay
- ENDCASE
- :
- WHEN "B","b": PROCwindow(10,71,82,10) : CLS
- PRINT '" CAC invariably understands that a bar consists of 960 beats, "
- PRINT '" regardless of which file you create. This fine gradation allows "
- PRINT '" you to position sounds effectively in continuous time, just as "
- PRINT '" CAC allows you also to position sounds effectively in continuous "
- PRINT '" pitch. "
- PRINT ''" When you initially create a new file, you can decide how the bar "
- PRINT '" is to be subdivided into a particular 'time signature'. For example, "
- PRINT '" in 4/4 each crotchet is a quarter of the bar, and thus 240 beats each."
- PRINT '" Each crotchet contains 4 semiquavers, making 16 semiquavers in the bar."
- PRINT '" So in this case you would initially ask CAC to create a new file with "
- PRINT '" 16 beats (in another sense of 'beats') each, being semiquavers, notated"
- PRINT '" rhythmically as having two beams."
- PRINT ''" When a passage will later be 'rhythmicized' to become musical notation "
- PRINT '" each bar will consist of rhythms adding up to a 4/4 time signature."
- PRINT ''" The position of the semiquavers can be displayed by pressing Display "
- PRINT '" Menu/Add Beats (O/T). And you can choose whether your sounds are "
- PRINT '" positioned in terms of semiquaver 'beats' or in terms of the fine grid "
- PRINT '" of 960 'beats' by pressing Menu/Various/Beats Input (M/V/B)."
- CASE GET$ OF
- WHEN "R","r" : PROCdisplay
- OTHERWISE PROCdisplay
- ENDCASE
- :
- OTHERWISE
- CASE GET$ OF
- WHEN "R","r" : PROCdisplay
- OTHERWISE PROCdisplay
- ENDCASE
- :
- ENDCASE
- :
- ENDPROC
|