             @_input_list.push @inputs[path] = {value, type: u.count}
         @animation_strips = @data?.animation_strips
         return
+
+    clone_to_scene: (scene) ->
+        n = new Material(@context, @name, @data, null)
+        n.scene = @scene
+        n.render_scene = scene
+        # TODO: Handle lights of new scene
+        return n
 
 
 id = 0

        return prog

    reupload: ->
        @constructor(@context, @data, @scene)

    destroy: ->
        @context.render_manager.gl.deleteProgram @_program

    #   }
    #   Data type of each uniform is inferred from the type or the custom value.
    # * varyings: list of varyings, TODO. See loader.coffee:93
    constructor: (@context, @data, @material, @layout, @vertex_modifiers) ->
        @id = id++
        if @context.all_materials.indexOf(@) == -1
            @context.all_materials.push @
