Class: PresentationLoader::MyVideo
- Inherits:
-
Object
- Object
- PresentationLoader::MyVideo
- Defined in:
- lib/soby/loader.rb
Instance Attribute Summary collapse
-
#height ⇒ Object
readonly
Returns the value of attribute height.
-
#matrix ⇒ Object
readonly
Returns the value of attribute matrix.
-
#slide ⇒ Object
readonly
Returns the value of attribute slide.
-
#video ⇒ Object
Returns the value of attribute video.
-
#width ⇒ Object
readonly
Returns the value of attribute width.
Instance Method Summary collapse
-
#initialize(path, slide, matrix, width, height) ⇒ MyVideo
constructor
A new instance of MyVideo.
- #play ⇒ Object
Constructor Details
#initialize(path, slide, matrix, width, height) ⇒ MyVideo
Returns a new instance of MyVideo.
290 291 292 293 294 295 296 |
# File 'lib/soby/loader.rb', line 290 def initialize(path, , matrix, width, height) @path = path @width = width @height = height @matrix = matrix @slide = end |
Instance Attribute Details
#height ⇒ Object (readonly)
Returns the value of attribute height.
287 288 289 |
# File 'lib/soby/loader.rb', line 287 def height @height end |
#matrix ⇒ Object (readonly)
Returns the value of attribute matrix.
287 288 289 |
# File 'lib/soby/loader.rb', line 287 def matrix @matrix end |
#slide ⇒ Object (readonly)
Returns the value of attribute slide.
287 288 289 |
# File 'lib/soby/loader.rb', line 287 def @slide end |
#video ⇒ Object
Returns the value of attribute video.
288 289 290 |
# File 'lib/soby/loader.rb', line 288 def video @video end |
#width ⇒ Object (readonly)
Returns the value of attribute width.
287 288 289 |
# File 'lib/soby/loader.rb', line 287 def width @width end |
Instance Method Details
#play ⇒ Object
298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 |
# File 'lib/soby/loader.rb', line 298 def play if @video == nil absolute_path = $app.sketchPath "" << @path puts ("loading the video : " + absolute_path) vid = Movie.new($app, absolute_path) vid.play # vid = Movie.new($app, @path) puts "Loaded " puts vid, vid.width, vid.height @video = vid true else false end end |