Permalink
Browse files

version change, many changes not fully implemented but working. give …

…it a try, any doubts contact me
  • Loading branch information...
Macario
Macario committed Aug 7, 2009
1 parent 54ff5c1 commit 1ee081838c2274e483b5f81d992945f5b89f6bad
Showing with 134 additions and 7,574 deletions.
  1. +2 −1 .gitignore
  2. +26 −83 Manifest.txt
  3. +21 −3 README.rdoc
  4. +20 −20 Rakefile
  5. +1 −12 TODO.markdown
  6. +1 −6 lib/scruby.rb
  7. BIN lib/scruby/.DS_Store
  8. BIN lib/scruby/audio/.DS_Store
  9. +0 −153 lib/scruby/audio/buffer.rb
  10. +0 −67 lib/scruby/audio/bus.rb
  11. +0 −31 lib/scruby/audio/control_name.rb
  12. +0 −93 lib/scruby/audio/env.rb
  13. +0 −20 lib/scruby/audio/group.rb
  14. +0 −106 lib/scruby/audio/node.rb
  15. +0 −208 lib/scruby/audio/server.rb
  16. +0 −62 lib/scruby/audio/synth.rb
  17. +0 −111 lib/scruby/audio/synthdef.rb
  18. +0 −40 lib/scruby/audio/ugens/env_gen.rb
  19. +0 −66 lib/scruby/audio/ugens/in_out.rb
  20. +0 −48 lib/scruby/audio/ugens/multi_out_ugens.rb
  21. +0 −92 lib/scruby/audio/ugens/operation_indices.yaml
  22. +0 −65 lib/scruby/audio/ugens/operation_ugens.rb
  23. +0 −181 lib/scruby/audio/ugens/ugen.rb
  24. +0 −3,389 lib/scruby/audio/ugens/ugen_defs.yaml
  25. +0 −59 lib/scruby/audio/ugens/ugen_operations.rb
  26. +0 −90 lib/scruby/audio/ugens/ugens.rb
  27. +1 −1 lib/scruby/env.rb
  28. +2 −1 lib/scruby/ugens/ugen_defs.yaml
  29. +1 −0 lib/scruby/ugens/ugens.rb
  30. +1 −1 script/console
  31. +42 −0 scruby.gemspec
  32. +0 −21 sesion 1.rb
  33. BIN spec/.DS_Store
  34. +0 −198 spec/audio/buffer_spec.rb
  35. +0 −186 spec/audio/bus_spec.rb
  36. +0 −24 spec/audio/env_gen_spec.rb
  37. +0 −72 spec/audio/group_spec.rb
  38. +0 −122 spec/audio/in_out_spec.rb
  39. +0 −89 spec/audio/integration_spec.rb
  40. +0 −110 spec/audio/multiout_ugen_spec.rb
  41. +0 −109 spec/audio/node_spec.rb
  42. +0 −193 spec/audio/operation_ugens_spec.rb
  43. +0 −12 spec/audio/server.rb
  44. +0 −186 spec/audio/server_spec.rb
  45. +0 −67 spec/audio/synth_spec.rb
  46. +0 −263 spec/audio/synthdef_spec.rb
  47. +0 −97 spec/audio/ugen_operations_spec.rb
  48. +0 −367 spec/audio/ugen_spec.rb
  49. +0 −73 spec/audio/ugens_spec.rb
  50. +0 −119 spec/core_ext_spec.rb
  51. +0 −143 spec/delegator_array_spec.rb
  52. +3 −3 spec/server_spec.rb
  53. +0 −95 spec/typed_array_spec.rb
  54. +1 −1 spec/ugens_spec.rb
  55. +12 −15 test.live.rb
View
@@ -1,4 +1,5 @@
.DS_Store
pkg
doc
-Manifest
+Manifest
+notas.markdown
View
@@ -1,78 +1,9 @@
History.txt
Manifest.txt
-PostInstall.txt
README.rdoc
Rakefile
+TODO.markdown
bin/livecode.rb
-doc/classes/Array.html
-doc/classes/Fixnum.html
-doc/classes/Float.html
-doc/classes/Kernel.html
-doc/classes/Live.html
-doc/classes/Live/Pipe.html
-doc/classes/Live/Session.html
-doc/classes/Notice.html
-doc/classes/Numeric.html
-doc/classes/Object.html
-doc/classes/Proc.html
-doc/classes/Scruby.html
-doc/classes/Scruby/Audio.html
-doc/classes/Scruby/Audio/ControlName.html
-doc/classes/Scruby/Audio/SCError.html
-doc/classes/Scruby/Audio/Server.html
-doc/classes/Scruby/Audio/SynthDef.html
-doc/classes/Scruby/Audio/Ugens.html
-doc/classes/Scruby/Audio/Ugens/EnvGen.html
-doc/classes/Scruby/Audio/Ugens/In.html
-doc/classes/Scruby/Audio/Ugens/MultiOutUgen.html
-doc/classes/Scruby/Audio/Ugens/OperationUgens.html
-doc/classes/Scruby/Audio/Ugens/OperationUgens/BasicOpUgen.html
-doc/classes/Scruby/Audio/Ugens/OperationUgens/BinaryOpUGen.html
-doc/classes/Scruby/Audio/Ugens/OperationUgens/MulAdd.html
-doc/classes/Scruby/Audio/Ugens/OperationUgens/UnaryOpUGen.html
-doc/classes/Scruby/Audio/Ugens/Out.html
-doc/classes/Scruby/Audio/Ugens/OutputProxy.html
-doc/classes/Scruby/Audio/Ugens/Ugen.html
-doc/classes/Scruby/Audio/Ugens/UgenOperations.html
-doc/classes/Scruby/Audio/Ugens/UgenOperations/BinaryOperations.html
-doc/classes/Scruby/Audio/Ugens/UgenOperations/UnaryOperators.html
-doc/classes/Scruby/Control.html
-doc/classes/Scruby/Control/Metro.html
-doc/classes/Scruby/Env.html
-doc/classes/Scruby/Node.html
-doc/classes/Scruby/Synth.html
-doc/classes/Special.html
-doc/classes/String.html
-doc/classes/TypedArray.html
-doc/classes/Warning.html
-doc/created.rid
-doc/files/README_rdoc.html
-doc/files/bin/live_session_rb.html
-doc/files/lib/live/session_rb.html
-doc/files/lib/scruby/control_name_rb.html
-doc/files/lib/scruby/env_rb.html
-doc/files/lib/scruby/node_rb.html
-doc/files/lib/scruby/server_rb.html
-doc/files/lib/scruby/synth_rb.html
-doc/files/lib/scruby/synthdef_rb.html
-doc/files/lib/scruby/ugens/env_gen_rb.html
-doc/files/lib/scruby/ugens/in_out_rb.html
-doc/files/lib/scruby/ugens/multi_out_ugens_rb.html
-doc/files/lib/scruby/ugens/operation_indices_yaml.html
-doc/files/lib/scruby/ugens/operation_ugens_rb.html
-doc/files/lib/scruby/ugens/ugen_defs_yaml.html
-doc/files/lib/scruby/ugens/ugen_operations_rb.html
-doc/files/lib/scruby/ugens/ugen_rb.html
-doc/files/lib/scruby/ugens/ugens_rb.html
-doc/files/lib/scruby/control/metro_rb.html
-doc/files/lib/scruby/extensions_rb.html
-doc/files/lib/scruby/typed_array_rb.html
-doc/files/lib/scruby_rb.html
-doc/fr_class_index.html
-doc/fr_file_index.html
-doc/fr_method_index.html
-doc/index.html
-doc/rdoc-style.css
examples/example.live.rb
extras/Ruby Live.tmbundle/Commands/Run selection:line in session.tmCommand
extras/Ruby Live.tmbundle/Commands/Run selection:scope in session.tmCommand
@@ -84,8 +15,20 @@ extras/Ruby Live.tmbundle/Syntaxes/Ruby Live.tmLanguage
extras/Ruby Live.tmbundle/info.plist
lib/live/session.rb
lib/scruby.rb
+lib/scruby/buffer.rb
+lib/scruby/bus.rb
lib/scruby/control_name.rb
+lib/scruby/core_ext/array.rb
+lib/scruby/core_ext/delegator_array.rb
+lib/scruby/core_ext/fixnum.rb
+lib/scruby/core_ext/numeric.rb
+lib/scruby/core_ext/object.rb
+lib/scruby/core_ext/proc.rb
+lib/scruby/core_ext/string.rb
+lib/scruby/core_ext/symbol.rb
+lib/scruby/core_ext/typed_array.rb
lib/scruby/env.rb
+lib/scruby/group.rb
lib/scruby/node.rb
lib/scruby/server.rb
lib/scruby/synth.rb
@@ -96,31 +39,31 @@ lib/scruby/ugens/multi_out_ugens.rb
lib/scruby/ugens/operation_indices.yaml
lib/scruby/ugens/operation_ugens.rb
lib/scruby/ugens/ugen.rb
+lib/scruby/ugens/ugen_defs 2.yaml
lib/scruby/ugens/ugen_defs.yaml
lib/scruby/ugens/ugen_operations.rb
lib/scruby/ugens/ugens.rb
-lib/scruby/extensions.rb
-lib/scruby/typed_array.rb
-script/console
-script/destroy
-script/generate
-spec/env_gen_specs.rb
+spec/buffer_spec.rb
+spec/bus_spec.rb
+spec/core_ext/core_ext_spec.rb
+spec/core_ext/delegator_array_spec.rb
+spec/core_ext/typed_array_spec.rb
+spec/env_gen_spec.rb
+spec/env_spec.rb
+spec/group_spec.rb
+spec/helper.rb
spec/in_out_spec.rb
spec/integration_spec.rb
-spec/lib_spec.rb
spec/multiout_ugen_spec.rb
spec/node_spec.rb
spec/operation_ugens_spec.rb
+spec/server.rb
spec/server_spec.rb
spec/synth_spec.rb
spec/synthdef_spec.rb
spec/ugen_operations_spec.rb
spec/ugen_spec.rb
spec/ugens_spec.rb
-spec/control/timer_spec.rb
-spec/env_spec.rb
-spec/extensions_spec.rb
-spec/helper.rb
-spec/typed_array_spec.rb
-test/test_Scruby.rb
+test.live.rb
test/test_helper.rb
+test/test_scruby.rb
View
@@ -1,15 +1,33 @@
-
-
== Scruby
Is a bare-bones SuperCollider livecoding library for Ruby, it provides comunication with a remote or local scsynth server and SynthDef creation with a
-very similar syntax as Sclang.
+in a similar way to Sclang.
SynthDef creation and sending is robust but some features are not implemented such as SynthDef variations and others I may not be aware of.
livecode.rb executable is located in the bin directory and a TextMate bundle included in extras permits livecoding from TextMate, comunication is
thrugh *nix pipes. Similar functionality shouldn't be too dificult to implement from Emacs or Vim.
+== USAGE
+
+ require 'scruby'
+
+ s = Server.new
+ s.boot
+
+
+ SynthDef.new :fm do |freq, amp, dur|
+ gate = EnvGen.kr Env.perc(0, 0.2)
+ mod_env = EnvGen.kr Env.new([600, 200, 100], d(0.7,0.3) * dur), gate
+ mod = SinOsc.ar freq * 1.4, :mul => mod_env
+ sig = SinOsc.ar freq + mod
+ env = EnvGen.kr Env.new( [0, 1, 0.6, 0.2, 0.1, 0 ], d(0.001, 0.005, 0.3, 0.5, 0.7) * dur ), gate, :doneAction => 2
+ sig = sig * amp * env
+ Out.ar [sig, sig]
+ end.send
+
+ Synth.new :fm, :freq => 200, :amp => 0.8, :dur => 5
+
== TODO
Receive OSC messages from SuperCollider
View
@@ -1,28 +1,28 @@
-require 'rubygems' unless ENV['NO_RUBYGEMS']
-%w[rake rake/clean fileutils newgem rubigen].each { |f| require f }
-require File.dirname(__FILE__) + '/lib/scruby'
+require 'rubygems'
+gem 'hoe', '>= 2.1.0'
+require 'hoe'
+require 'fileutils'
+require './lib/scruby'
+
+Hoe.plugin :newgem
+# Hoe.plugin :website
+# Hoe.plugin :cucumberfeatures
# Generate all the Rake tasks
# Run 'rake -T' to see list of generated tasks (from gem root directory)
-$hoe = Hoe.new('Scruby', Scruby::VERSION) do |p|
- p.developer('FIXME full name', 'FIXME email')
- p.changes = p.paragraphs_of("History.txt", 0..1).join("\n\n")
- p.rubyforge_name = p.name # TODO this is default value
- p.extra_deps = [
- ['maca-arguments','>= 0.4.2'],
- ['maca-rosc','>= 0.4.2']
- ]
- p.extra_dev_deps = [
- ['newgem', ">= #{::Newgem::VERSION}"]
+$hoe = Hoe.spec 'scruby' do
+ self.developer 'Macario Ortega', 'macarui@gmail.com'
+ self.rubyforge_name = self.name
+ self.extra_deps = [
+ ['maca-arguments','>= 0.6'],
+ ['maca-rosc', '>= 0.4.2']
]
- p.clean_globs |= %w[**/.DS_Store tmp *.log]
- path = (p.rubyforge_name == p.name) ? p.rubyforge_name : "\#{p.rubyforge_name}/\#{p.name}"
- p.remote_rdoc_dir = File.join(path.gsub(/^#{p.rubyforge_name}\/?/,''), 'rdoc')
- p.rsync_args = '-av --delete --ignore-errors'
+
end
-require 'newgem/tasks' # load /tasks/*.rake
+require 'newgem/tasks'
Dir['tasks/**/*.rake'].each { |t| load t }
-# # TODO - want other tests/tasks run by default? Add them to the list
-task :default => :spec
+# TODO - want other tests/tasks run by default? Add them to the list
+# remove_task :default
+# task :default => [:spec, :features]
View
@@ -2,15 +2,4 @@
**Array workarrounds**
-* If Synth is passed an array makes an array of synths that behave like one, freeing it frees all. DelegatorArray
-
-* Somehow let all elements of an array be multiplied by a number, maybe if the Numeric multiplies the Array, eg:
-
- 2 * [1,2] == [2,4] and 2 * [1,2] == c[2,4] and ChannelArray.new(2,4) # => true (DONE)
-
-* Maybe the result of a multichannel Ugen could be an instance of Array with binary operators overriden, eg:
-
- mc = SinOsc.ar [400,402]
- mc * 0.5 == c(SinOsc.ar(400) * 0.5, SinOsc.ar(402) * 0.5) # => true
-
-* "Literal" for ChannelArray c[] or c()
+* Buffer as Ugen input
View
@@ -21,13 +21,10 @@
require 'rosc'
require 'yaml'
-# require 'methopara' if RUBY_VERSION.to_f >= 1.9
-
-
$:.unshift(File.dirname(__FILE__)) unless $:.include?(File.dirname(__FILE__)) || $:.include?(File.expand_path(File.dirname(__FILE__)))
module Scruby
- VERSION = '0.1'
+ VERSION = '0.2'
end
require "scruby/core_ext/object"
@@ -60,7 +57,5 @@ module Scruby
require "scruby/bus"
require "scruby/buffer"
-
include Scruby
include Ugens
-
View
Binary file not shown.
View
Binary file not shown.
Oops, something went wrong.

0 comments on commit 1ee0818

Please sign in to comment.