X-Git-Url: http://git.tdb.fi/?a=blobdiff_plain;ds=inline;f=source%2Fselect.cpp;h=e905729d84229877e09ce0fb7b1ad69a0c3d0939;hb=f17794d55923d4fb4f63e9d082d8d84a735a04e8;hp=e7037cbfb6e59137c36418da552106acbce7f496;hpb=a4ec5410595ddf37bfbc0e85ad87d31a9cbf94f1;p=libs%2Fgl.git diff --git a/source/select.cpp b/source/select.cpp index e7037cbf..e905729d 100644 --- a/source/select.cpp +++ b/source/select.cpp @@ -14,7 +14,7 @@ using namespace std; namespace { vector *select_buf=0; -vector select_buf_int; +vector select_buf_int; } @@ -28,14 +28,34 @@ void select_buffer(vector &buf) select_buf=&buf; } -void parse_select_records(const uint *buf, uint count, vector &tbuf) +void init_names() { - uint i=0; + glInitNames(); +} + +void push_name(unsigned n) +{ + glPushName(n); +} + +void pop_name() +{ + glPopName(); +} + +void load_name(unsigned n) +{ + glLoadName(n); +} + +void parse_select_records(const unsigned *buf, unsigned count, vector &tbuf) +{ + unsigned i=0; while(count--) { SelectRecord record; - uint n_names=buf[i++]; + unsigned n_names=buf[i++]; record.min_depth=buf[i++]; record.max_depth=buf[i++]; @@ -47,7 +67,7 @@ void parse_select_records(const uint *buf, uint count, vector &tbu } } -void _parse_internal_select_records(uint count) +void _parse_internal_select_records(unsigned count) { if(!select_buf) throw InvalidState("No select buffer specified");