samples/07_advanced_rendering/04_render_primitive_hierarchies/app/main.rb
# Holds and outputs a collection of borders and a collection of solids
# Collections are created by using arrays to hold parameters of each individual object
Holds and outputs a collection of borders and a collection of solids
Collections are created by using arrays to hold parameters of each individual object
Holds and outputs a collection of borders and a collection of solids Collections are created by using arrays to hold parameters of each individual object
def collection_of_borders_and_solids args
  collection_borders = [
    [
      [200,  0, 50, 50],                    
      [200,  100, 50, 50, 255, 0, 0],       
      [200,  200, 50, 50, [0, 255, 0]],     
    ],
    [[200, 300, 50, 50], 0, 0, 255],        
    [[200, 400, 50, 50], [255, 0, 255]]      and nested color
  ]
  args.outputs.borders << collection_borders
  collection_solids = [
    [
      [[300, 300, 50, 50], 0, 0, 255],      
      [[300, 400, 50, 50], [255, 0, 255]]    and nested color
    ],
    [300,  0, 50, 50],
    [300,  100, 50, 50, 255, 0, 0],
    [300,  200, 50, 50, [0, 255, 0]],       
  ]
  args.outputs.solids << collection_solids
end
def collection_of_borders_and_solids args collection_borders = [ [ [ 200 , 0 , 50 , 50 ] , [ 200 , 100 , 50 , 50 , 255 , 0 , 0 ] , [ 200 , 200 , 50 , 50 , [ 0 , 255 , 0 ] ] , ] , [ [ 200 , 300 , 50 , 50 ] , 0 , 0 , 255 ] , [ [ 200 , 400 , 50 , 50 ] , [ 255 , 0 , 255 ] ] ] args . outputs . borders << collection_borders collection_solids = [ [ [ [ 300 , 300 , 50 , 50 ] , 0 , 0 , 255 ] , [ [ 300 , 400 , 50 , 50 ] , [ 255 , 0 , 255 ] ] ] , [ 300 , 0 , 50 , 50 ] , [ 300 , 100 , 50 , 50 , 255 , 0 , 0 ] , [ 300 , 200 , 50 , 50 , [ 0 , 255 , 0 ] ] , ] args . outputs . solids << collection_solids end
Holds and outputs a collection of borders and a collection of solids
Collections are created by using arrays to hold parameters of each individual object
Holds and outputs a collection of borders and a collection of solids Collections are created by using arrays to hold parameters of each individual object
# black border # red border # nested color # nested rect # nested rect and nested color # nested rect # nested rect and nested color # nested color
args