why this error??

hi everybody, I have a problem. now i’m using RagePixel to do a game but when i done this script:

private IRagepixel rpix;
void Update () {
        if (Input.GetMouseButtonDown(0))

and i launch game when i click debugger says me 

NullReferenceException:Object reference not set to an instance of an object

what's my error??
thanks in advance :-)

You’re getting a null ref since rpix is never instantiated anywhere.

You declare the variable on the first line, and next try to access in the update. However, declaring a class variable only reserves the variable name, it does not create a new object.

Depending on the method of the initialization for IRagepixel, you would need to create a new object by using rpix = new IRagepixel.

Also, from the name, it seems IRagepixel is an interface, and cannot be instantiated directly. You would need to instantiate a class implementing this interface and assign it to rpix.