zahirtezcan's picture

Gen/Delete helpers for single object generation

Project:The Open Toolkit library
Version:1.1.0-stable
Component:Code
Category:feature request
Priority:minor
Assigned:Unassigned
Status:closed
Description

Is it possible to have gen/delete pairs like:

int GenX();
void DeleteX(int);

for X being Buffer/VertexArray/Framebuffer/Renderbuffer etc. We have such overload for texture objects and it would be nice if we had for other object types


Comments

Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.
the Fiddler's picture

#1

The only reason I have not added those overloads is that I'm working on a higher-level abstraction which could become much more useful in the end. On the other hand, these helpers are so simple that there's no good reason why these couldn't be added too.

Patches welcome! (Just edit GLHelper.cs and add the necessary overloads. I will make sure they stay consistent between OpenGL and OpenGL ES.)

the Fiddler's picture

#2

Version:1.x-dev» 1.1.0-stable
Status:open» closed

This has been implemented in opentk-1.1.0 through the binding generator. Perfect for F# immutable types!