Quantcast
Channel: beginners - openFrameworks
Viewing all articles
Browse latest Browse all 4929

I do not know how to use setVertexBuffer

$
0
0

@UmiKOMPnMI4QrmG wrote:

header

	ofBufferObject PosBuff;
	ofVbo ObjsVbo;
    float vert[3*4];//This contains vertex information of a rectangle

setup

	PosBuff.allocate();
	PosBuff.setData(sizeof(float)*3*4,vert,GL_DYNAMIC_DRAW);

	ObjsVbo.setVertexBuffer(PosBuff,3,sizeof(float)*3,0);

draw

	ObjsVbo.draw(GL_POINTS,0,4);

This will not work properly.Please Help Me!!

Posts: 1

Participants: 1

Read full topic


Viewing all articles
Browse latest Browse all 4929

Trending Articles