ImageFX script location

If you're working on this assignment and you can't find the ImageFX script that's mentioned around 4:45, you can do the following:

  • Open your night vision Unity project.
  • Download "project-course-files.zip" from the list of files under the video.
  • Unzip that file.
  • In the newly unzipped folder "project-course-files", find "Unity Files" -> "ShaderSchool_UnityProject_Complete.unitypackage".
  • Drag "ShaderSchool_UnityProject_Complete.unitypackage" onto your open Unity project's "Project" view (often in the lower left corner of the Unity interface).
  • A modal window should appear, asking you to select which files you want to import. First, click "None" at the bottom to deselect all imports. Then tick the box on "Shader School" -> "Scripts".
  • Click "Import".
  • The ImageFX script should now be accessible in the Project tab under "Assets" -> "Shader School" -> "Scripts".
  • Peter Moldovia(petermoldovia) replied

    Alternatively, you can simply paste the following into a new script:


    using System.Collections;
    using System.Collections.Generic;
    using UnityEngine;
    
    public class ImageFX : MonoBehaviour {
    
    	public Material mat;
    
    	void OnRenderImage(RenderTexture source, RenderTexture destination)
    	{
    	
    		Graphics.Blit (source, destination, mat);
    	}
    }