IsVisibleFrom

Author: Michael Garforth

Overview
This C# class gives simple extension access to checking if an Renderer is rendered by a specific Camera.

Due to the way UnityScript/javascript compiles extension methods, it's not accessible in the same way, so another javascript specific class is added below it

Use
For the c# extension method: renderer.IsVisibleFrom(cam)

For the UnityScript static function: RendererHelper.IsVisibleFrom(renderer, cam)

C# - RendererExtensions.cs
The script should be named RendererExtensions.cs

UnityScript - RendererHelpers.js
The script should be named RendererHelpers.js Use this only if you won't be using c#