I=(S=Uno.Graphics.IndexBuffer = function(){
}).prototype;

I.SetData = function(data)
{
    gl.bindBuffer(34963, this.buf);
    gl.bufferSubData(34963, 0, data);
    gl.bindBuffer(34963, null);
};

I.GLHandle = function()
{
    return this.buf;
};

S.$0 = function(sizeInBytes, dynamic, $this) {
    if (!$this) $this = new Uno.Graphics.IndexBuffer;
    $this.sizeInBytes = sizeInBytes;
    $this.dynamic = dynamic;
    $this.buf = gl.createBuffer();
    var usage = 35044;

    if (dynamic)
    {
        usage = 35048;
    }

    gl.bindBuffer(34963, $this.buf);
    gl.bufferData(34963, sizeInBytes, usage);
    gl.bindBuffer(34963, null);
    return $this;
};
