+void Commands::begin_query(const QueryPool &pool, unsigned index)
+{
+ if(index>=pool.queries.size())
+ throw out_of_range("OpenGLCommands::begin_query");
+ glBeginQuery(pool.gl_type, pool.queries[index]);
+}
+
+void Commands::end_query(const QueryPool &pool, unsigned)
+{
+ glEndQuery(pool.gl_type);
+}
+