Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Messages - loganmcbroom

Pages: 1 [2] 3 4 5
16
Showcase / Quick track for a party
« on: November 21, 2017, 11:53:36 PM »
I played a quick set for a Toyota themed party recently and put this track together for that

https://loganmcbroom.bandcamp.com/track/toyota-abstract

17
Composition / Re: MIDI tuplet generator?
« on: July 12, 2017, 09:23:53 PM »
I've definitely done this in live, I'll boot it up in a bit and remember how it's done.

Edit: Okay so when you select the notes there is an indicator at both ends of the selection at the top of the piano roll, dragging this has the desired effect.

18
Composition / Re: MIDI tuplet generator?
« on: July 11, 2017, 09:29:16 PM »
I'm not familiar with any tools that accomplish this but in DAWs I've used you can lay out n+1 notes on the regular grid lines and shrink the sequence so the final note is sitting at the start of a bar. Deleting the final note yields n notes at regular intervals across the bar. That being said, there are libraries that make midi programs very simple to write. I've used the JUCE midi stuff before and I'm sure you could add some neat functionality in a custom program. Imo doing things a little awkwardly in the daw is worth not having to break workflow to switch programs.

19
Showcase / Re: Some Tracks
« on: June 29, 2017, 06:12:16 AM »
Here is the current version. It's in a kind of incomplete but completed stage where I lost some progress in a hard drive failure and it's done enough that I don't really mind the missing details. The NoteData.lua script is something I just started rebuilding today that I lost. TVPairs.lua is finished and is the important one anyway. The readme has a decent description of the c++ side features.

https://drive.google.com/file/d/0BxzJlrC6KHmxUEpoX0NrczZpRUE/view?usp=sharing

The really worth checking out features are the LTMP (readme explains), and the TVPairs script. I am particularly fond of TVPairs sample/unsample methods. Unsample is extra neat if you like math.

20
Showcase / Re: Some Tracks
« on: June 28, 2017, 07:43:35 PM »
Thanks! I used my own lua frontend. If you're interested in faster batch processing and generating time-value files programatically I'll post a link (only works on windows).

21
Showcase / Some Tracks
« on: June 07, 2017, 05:42:40 AM »
Finished up an album I've been working on for a while last week and several of the tracks use a good bit of CDP content.

https://loganmcbroom.bandcamp.com/album/precision-vibration

Specifically the tracks "Precision, Vibration" and "Emulation".

22
General Board / Re: Mailing List Poll
« on: February 09, 2017, 06:56:01 PM »
I think a mailing list would serve the same purpose as a forum for me considering I check in here daily, it would be a convenience though. If any new form of communication were added I would prefer something instant in nature, e.g. an IRC channel.

23
General Board / Re: IRC
« on: February 08, 2017, 09:43:51 PM »
I don't know of one personally, seconding the IRC.

24
General Board / Re: Community Projects
« on: December 22, 2016, 06:44:21 PM »
Here's a utility for converting midi files into notelists. The output isn't a complete notedata file, just a single notelist block per track in the input file.

https://drive.google.com/drive/folders/0BxzJlrC6KHmxald1R25JUmotU1E?usp=sharing

25
Announce / Re: CDP 7.1 sources now on github
« on: December 21, 2016, 05:32:40 PM »
!!! Yes !!!
 This is great news!

26
Showcase / Re: My first piece made with CDP
« on: December 20, 2016, 07:01:21 PM »
Cool stuff! Hope to see more from you.

27
General Board / Re: Community Projects
« on: December 20, 2016, 04:19:35 AM »
Here's a lua script for manipulating time-value pairs. For the sake of operations the object is considered a function, lerping for values between defined points (this is what the cdp does for most things). + - * / are overloaded for operating on two TVPairs or one TVPairs and a scalar. % is overloaded as time shift and ^ is overloaded as convolution. There is also a function to generate TVPairs from a function, as well as a function for generating a polynomial from a TVPairs (sample and unsample). I'm using a pure lua matrix solver so unsample gets pretty unusable beyond ten or so data points. The compile function won't work outside of my frontend due to it using the file generating function altar_text.

Code: [Select]
local TVPairs = {}
function TVPairs:new( o )
o = o or {}
setmetatable( o, self )
self.__index = self
return o:sort()
end
function TVPairs:__tostring()
local out = ""
for i = 1, #self do
out = out .. self[i][1] .. " " .. self[i][2] .. "\n"
end
return out
end
function TVPairs:__call( t )
if #self == 0 or self[1][1] > t or self[#self][1] < t then return 0 end

for i = 2, #self do
if self[i][1] >= t then --lerp it
local x1, x2, y1, y2 = self[i-1][1], self[i][1], self[i-1][2], self[i][2]
local m = (y1-y2)/(x1-x2)
return m*(t-x1) + y1
end
end
print "Error in TVPairs:_call"
end

--Math
local function tvp_operate( lhs, rhs, operation )
if type(lhs) == "number" then
local data = {}
for i = 1, #rhs do data[i] = {rhs[i][1], operation( rhs[i][2], lhs )} end
return TVPairs:new( data )
elseif type(rhs) == "number" then
local data = {}
for i = 1, #lhs do data[i] = {lhs[i][1], operation( lhs[i][2], rhs )} end
return TVPairs:new( data )
else
local times = {}
for i = 1, #lhs do times[i] = lhs[i][1] end
for i = 1, #rhs do times[i+#lhs] = rhs[i][1] end
table.sort( times )
for i = 1, #times - 1 do
if times[i] == times[i+1] then table.remove( times, i ) end
end

local data = {}
for i = 1, #times do
data[i] = { times[i], operation( lhs(times[i]), rhs(times[i]) ) }
end

return TVPairs:new( data )
end
end
function TVPairs:__unm()
local tvp = {}
for i = 1, #self do
tvp[i] = {self[i][1], -self[i][2]}
end
return TVPairs:new( tvp )
end
function TVPairs.__add( lhs, rhs ) return tvp_operate( lhs, rhs, function( a, b ) return a + b end ) end
function TVPairs.__sub( lhs, rhs ) return tvp_operate( lhs, rhs, function( a, b ) return a - b end ) end
function TVPairs.__mul( lhs, rhs ) return tvp_operate( lhs, rhs, function( a, b ) return a * b end ) end
function TVPairs.__div( lhs, rhs )
return tvp_operate( lhs, rhs, function( a, b )
if b == 0 then return 0
else return a / b
end
end )
end
function TVPairs.__mod( lhs, rhs ) --time shift
local data = {}
if type( lhs ) == "number" then
for i,v in ipairs(rhs) do data[i] = { rhs[i][1] + lhs, rhs[i][2] } end
else
for i,v in ipairs(lhs) do data[i] = { lhs[i][1] + rhs, lhs[i][2] } end
end
return TVPairs:new( data )
end
function TVPairs.__pow( lhs, rhs ) --convolution
local data = TVPairs:new()
for _,v in ipairs(lhs) do
data = data + ( ( rhs * v[2] ) % v[1] )
end
return TVPairs:new( data )
end
function TVPairs.__concat( lhs, rhs )
if getmetatable( lhs ) == TVPairs and getmetatable( rhs ) == TVPairs then --combining two TVPairs
local data = {}
for i = 1, #lhs do data[i     ] = lhs[i] end
for i = 1, #rhs do data[i+#lhs] = rhs[i] end
table.sort( data, function( a, b ) return a[1] < b[1] end )
for i = 1, #data - 1 do
if data[i][1] == data[i+1][1] then table.remove( data, i+1 ) end
end
return TVPairs:new( data )
else -- Only one of the two was a TVPairs, assume the other can be converted to TVPairs
if getmetatable( lhs ) == TVPairs then return lhs .. TVPairs:new( rhs )
else return TVPairs:new( lhs ) .. rhs --It must be the case that rhs was TVPairs so don't bother checking
end
end
end

--Other
function TVPairs:sort() --Sort... appropriately
table.sort( self, function( a, b ) return a[1] < b[1] end )
return self
end
function TVPairs:compile() return compile( self ) end
function TVPairs:sample( length, rate, func ) return sample( length, rate, func ) end
function TVPairs:unsample() --returns a polynomial passing through all points in self
local function ToReducedRowEchelonForm ( M ) --From rosettacode
local lead = 1
local n_rows, n_cols = #M, #M[1]

for r = 1, n_rows do
if n_cols <= lead then break end

local i = r
while M[i][lead] == 0 do
i = i + 1
if n_rows == i then
i = r
lead = lead + 1
if n_cols == lead then break end               
end
end
M[i], M[r] = M[r], M[i]

local m = M[r][lead]
for k = 1, n_cols do
M[r][k] = M[r][k] / m
end
for i = 1, n_rows do
if i ~= r then
local m = M[i][lead]
for k = 1, n_cols do
M[i][k] = M[i][k] - m * M[r][k]
end
end
end 
lead = lead + 1     
end
end
--determine coefficients by matrix reduction
local M = {}
for i = 1, #self do
M[i] = {}
for j = 1, #self do
M[i][j] = self[i][1]^(j-1)
end
M[i][#self + 1] = self[i][2]
end
ToReducedRowEchelonForm( M )
local coeff = {} --store in increasing degree order
for i = 1, #M do
coeff[i] = M[i][#M[i]]
end

return function( t )
local out = 0
for i = 1, #coeff do
out = out + coeff[i]*(t^(i-1))
end
return out
end
end
----------------------------------------------------------------------------------
function compile( ... )
local arg = {...}
local files = {}
for i = 1, #arg do
files[i] = altar_text( tostring( arg[i] ) )
end
return unpack( files )
end
function sample( length, rate, func )
local data = {}
local samples = math.floor( length / rate )
for i = 1, samples + 1 do
local t = rate * (i-1)
data[i] =  {t, func(t)}
end
return TVPairs:new( data )
end
----------------------------------------------------------------------------------

local M = {}
M.TVPairs = TVPairs
M.compile = compile
M.sample = sample
return M

Here are some examples:

Code: [Select]
local tvp = require( "TVPairs" )

--Resample data at *10 resolution as a polynomial
local tr1 = tvp.TVPairs:new{ {0, 0}, {1, 1}, {2, 8}, {3, 6}, {4, 5}, {5, 4} }
local tr2 = tvp.sample( 5, .1, tr1:unsample() )
print( tostring( tr2 ) )

--Generate sinusoid TVPairs
function sample_sin( length, low, high, period, offset )
offset = offset or 0
local base = (low+high)/2.0
return tvp.sample( length, .1,
function( t )
return base + (high - base) * math.sin( (2.0*math.pi)*(t/period) + offset )
end
)
end

28
General Board / Community Projects
« on: December 18, 2016, 04:16:16 AM »
It seems like there are a good deal of people here willing to put a good deal of effort into software derived from the CDP. Maybe we could get some kind of community project going? What kinds of tools would be good to have? What things seem to be missing?

I think some in depth tools for generating all the various text files needed to automate parameters would be a good thing to have. It's one aspect of soundloom that seems the most dated to me.

29
Showcase / Re: Another go at a CDP frontend
« on: December 18, 2016, 04:06:41 AM »
Looking very usable. As always, looking forward to checking it out. Especially the vst support... I'll have to start adding that to my own project when I have the chance.

30
General Board / Re: Creating Compound Textures?
« on: November 28, 2016, 08:38:01 PM »
Kind of, I have a readme that I think is reasonable in here along with the newest version. And yes it is Lua, it's a fantastic language for this application.

https://drive.google.com/file/d/0BxzJlrC6KHmxaEJDcFNKZ0N0RVU/view?usp=sharing

Pages: 1 [2] 3 4 5