qtractor icon indicating copy to clipboard operation
qtractor copied to clipboard

Please increas the atom Port buffer size

Open brummer10 opened this issue 3 years ago • 5 comments

Hi I run into a issue with the atom Port buffer sizes. So, I want to send a sequence like this one:

## Plugin => UI (7512 bytes) ##
<http://lv2plug.in/ns/ext/atom#Blank>
	a <https://github.com/brummer10/Fluida.lv2#soundfont> ;
	<http://lv2plug.in/ns/ext/atom#String> "000 000 Yamaha Grand Piano" ,
		"000 001 Bright Yamaha Grand" ,
		"000 002 Electric Piano" ,
		"000 003 Honky Tonk" ,
		"000 004 Rhodes EP" ,
		"000 005 Legend EP 2" ,
		"000 006 Harpsichord" ,
		"000 007 Clavinet" ,
		"000 008 Celesta" ,
		"000 009 Glockenspiel" ,
		"000 010 Music Box" ,
		"000 011 Vibraphone" ,
		"000 012 Marimba" ,
		"000 013 Xylophone" ,
		"000 014 Tubular Bells" ,
		"000 015 Dulcimer" ,
		"000 016 DrawbarOrgan" ,
		"000 017 Percussive Organ" ,
		"000 018 Rock Organ" ,
		"000 019 Church Organ" ,
		"000 020 Reed Organ" ,
		"000 021 Accordian" ,
		"000 022 Harmonica" ,
		"000 023 Bandoneon" ,
		"000 024 Nylon String Guitar" ,
		"000 025 Steel String Guitar" ,
		"000 026 Jazz Guitar" ,
		"000 027 Clean Guitar" ,
		"000 028 Palm Muted Guitar" ,
		"000 029 Overdrive Guitar" ,
		"000 030 Distortion Guitar" ,
		"000 031 Guitar Harmonics" ,
		"000 032 Acoustic Bass" ,
		"000 033 Fingered Bass" ,
		"000 034 Picked Bass" ,
		"000 035 Fretless Bass" ,
		"000 036 Slap Bass" ,
		"000 037 Pop Bass" ,
		"000 038 Synth Bass 1" ,
		"000 039 Synth Bass 2" ,
		"000 040 Violin" ,
		"000 041 Viola" ,
		"000 042 Cello" ,
		"000 043 Contrabass" ,
		"000 044 Tremolo" ,
		"000 045 Pizzicato Section" ,
		"000 046 Harp" ,
		"000 047 Timpani" ,
		"000 048 Strings" ,
		"000 049 Slow Strings" ,
		"000 050 Synth Strings 1" ,
		"000 051 Synth Strings 2" ,
		"000 052 Ahh Choir" ,
		"000 053 Ohh Voices" ,
		"000 054 Synth Voice" ,
		"000 055 Orchestra Hit" ,
		"000 056 Trumpet" ,
		"000 057 Trombone" ,
		"000 058 Tuba" ,
		"000 059 Muted Trumpet" ,
		"000 060 French Horns" ,
		"000 061 Brass Section" ,
		"000 062 Synth Brass 1" ,
		"000 063 Synth Brass 2" ,
		"000 064 Soprano Sax" ,
		"000 065 Alto Sax" ,
		"000 066 Tenor Sax" ,
		"000 067 Baritone Sax" ,
		"000 068 Oboe" ,
		"000 069 English Horn" ,
		"000 070 Bassoon" ,
		"000 071 Clarinet" ,
		"000 072 Piccolo" ,
		"000 073 Flute" ,
		"000 074 Recorder" ,
		"000 075 Pan Flute" ,
		"000 076 Bottle Chiff" ,
		"000 077 Shakuhachi" ,
		"000 078 Whistle" ,
		"000 079 Ocarina" ,
		"000 080 Square Lead" ,
		"000 081 Saw Wave" ,
		"000 082 Calliope Lead" ,
		"000 083 Chiffer Lead" ,
		"000 084 Charang" ,
		"000 085 Solo Vox" ,
		"000 086 Fifth Sawtooth Wave" ,
		"000 087 Bass & Lead" ,
		"000 088 Fantasia" ,
		"000 089 Warm Pad" ,
		"000 090 Polysynth" ,
		"000 091 Space Voice" ,
		"000 092 Bowed Glass" ,
		"000 093 Metal Pad" ,
		"000 094 Halo Pad" ,
		"000 095 Sweep Pad" ,
		"000 096 Ice Rain" ,
		"000 097 Soundtrack" ,
		"000 098 Crystal" ,
		"000 099 Atmosphere" ,
		"000 100 Brightness" ,
		"000 101 Goblin" ,
		"000 102 Echo Drops" ,
		"000 103 Star Theme" ,
		"000 104 Sitar" ,
		"000 105 Banjo" ,
		"000 106 Shamisen" ,
		"000 107 Koto" ,
		"000 108 Kalimba" ,
		"000 109 BagPipe" ,
		"000 110 Fiddle" ,
		"000 111 Shenai" ,
		"000 112 Tinker Bell" ,
		"000 113 Agogo" ,
		"000 114 Steel Drums" ,
		"000 115 Woodblock" ,
		"000 116 Taiko Drum" ,
		"000 117 Melodic Tom" ,
		"000 118 Synth Drum" ,
		"000 119 Reverse Cymbal" ,
		"000 120 Fret Noise" ,
		"000 121 Breath Noise" ,
		"000 122 Sea Shore" ,
		"000 123 Bird Tweet" ,
		"000 124 Telephone" ,
		"000 125 Helicopter" ,
		"000 126 Applause" ,
		"000 127 Gun Shot" ,
		"008 004 Detuned EP 1" ,
		"008 005 Detuned EP 2" ,
		"008 006 Coupled Harpsichord" ,
		"008 014 Church Bell" ,
		"008 016 Detuned Organ 1" ,
		"008 017 Detuned Organ 2" ,
		"008 019 Church Organ 2" ,
		"008 021 Italian Accordion" ,
		"008 024 Ukulele" ,
		"008 025 12 String Guitar" ,
		"008 026 Hawaiian Guitar" ,
		"008 028 Funk Guitar" ,
		"008 030 Feedback Guitar" ,
		"008 031 Guitar Feedback" ,
		"008 038 Synth Bass 3" ,
		"008 039 Synth Bass 4" ,
		"008 040 Slow Violin" ,
		"008 048 Orchestral Pad" ,
		"008 050 Synth Strings 3" ,
		"008 061 Brass 2" ,
		"008 062 Synth Brass 3" ,
		"008 063 Synth Brass 4" ,
		"008 080 Sine Wave" ,
		"008 107 Taisho Koto" ,
		"008 115 Castanets" ,
		"008 116 Concert Bass Drum" ,
		"008 117 Melo Tom 2" ,
		"008 118 808 Tom" ,
		"009 125 Burst Noise" ,
		"016 025 Mandolin" ,
		"128 000 Standard" ,
		"128 001 Standard 1" ,
		"128 002 Standard 2" ,
		"128 003 Standard 3" ,
		"128 004 Standard 4" ,
		"128 005 Standard 5" ,
		"128 006 Standard 6" ,
		"128 007 Standard 7" ,
		"128 008 Room" ,
		"128 009 Room 1" ,
		"128 010 Room 2" ,
		"128 011 Room 3" ,
		"128 012 Room 4" ,
		"128 013 Room 5" ,
		"128 014 Room 6" ,
		"128 015 Room 7" ,
		"128 016 Power" ,
		"128 017 Power 1" ,
		"128 018 Power 2" ,
		"128 019 Power 3" ,
		"128 024 Electronic" ,
		"128 025 TR-808" ,
		"128 032 Jazz" ,
		"128 033 Jazz 1" ,
		"128 034 Jazz 2" ,
		"128 035 Jazz 3" ,
		"128 036 Jazz 4" ,
		"128 040 Brush" ,
		"128 041 Brush 1" ,
		"128 042 Brush 2" ,
		"128 048 Orchestra Kit" .

I noticed that tit didn't makes it true. The most strings I could send at once been 20. I only noticed this limitation in Qtractor, and would ask you, if you could increase the buffersize for Atom messages, before I start to implement a sequencer for it.

regards hermann

brummer10 avatar Nov 21 '20 17:11 brummer10

you're probably better to set LV2_RESIZE_PORT__minimumSize property on the plugin manifest (.ttl): make it as big or bigger than the largest sequence you wish to send to the host.

qtractor will comply with that minimumSize as soon the lv2 plugin in question is inserted (instantiated).

rncbc avatar Nov 21 '20 17:11 rncbc

mm, I've @prefix rsz: <http://lv2plug.in/ns/ext/resize-port/#> . and

        a lv2:OutputPort ,
            atom:AtomPort ;
        atom:bufferType atom:Sequence ;
        atom:supports patch:Message ;
        lv2:designation lv2:control ;
        lv2:index 3 ;
        lv2:symbol "NOTIFY" ;
        lv2:name "NOTIFY";
        rsz:minimumSize 65664 ;

which doesn't do the trick.

brummer10 avatar Nov 21 '20 18:11 brummer10

are you sure it's taking effect? asking it because here https://github.com/brummer10/Fluida.lv2/blob/main/Fluida/Fluida.ttl it still see no entry to rsz:minimumSize 65664 ; whatsoever

rncbc avatar Nov 21 '20 20:11 rncbc

Yes, I haven't commit it to the repository right now as I just realize the issue and looking for a solution. So testing locally here. Anyway, when I check the buffer size it tells me 20480 regardless if I set minimumSize or not. Still this seems to be big enough to hold the frame, but it didn't reach the GUI. I'll check now how it works when I split the message over some circles.

brummer10 avatar Nov 22 '20 03:11 brummer10

So, I've implement a push/pull sequencer for those atom messages between dsp and UI, and that worked. I found the limit in push a atom sequence by ~700 bytes per UI frame. Bigger messages didn't makes it true. However, feel free to close this issue as for me it is solved.

this is how it looks now: https://pastebin.com/FUxV9G9m

brummer10 avatar Nov 22 '20 04:11 brummer10