 
 class BlenderInternalMaterial
     constructor: (@material) ->
-        {data, _input_list, inputs, _texture_list, context} = @material
+        {data, _input_list, inputs, _texture_list, @context} = @material
         for u in data.uniforms
             switch u.type
                 when -1

        return "projection_matrix"

    get_code: ->
        fragment = @material.data.fragment
        fragment = @material.context.SHADER_LIB + fragment
        return {fragment}

    get_uniform_assign: (gl, program) ->
        # TODO: reassign lamps when cloning etc

                    _input_list.push inputs[path] = {value, type: u.count, path}
                when 13, GPU_DYNAMIC_SAMPLER_2DIMAGE, GPU_DYNAMIC_SAMPLER_2DBUFFER, \
                    14, GPU_DYNAMIC_SAMPLER_2DSHADOW
                        _texture_list.push {value: @context.render_manager.blank_texture}
        return

    assign_textures: ->
