- GL::translate(16, 1, 0);
- GL::scale_uniform(10);
- GL::Immediate imm((GL::COLOR4_UBYTE, GL::TEXCOORD2, GL::VERTEX2));
- netvis.get_font().draw_string(name, imm);
+ {
+ GL::Immediate imm((GL::COLOR4_UBYTE, GL::VERTEX2));
+ imm.begin(GL::QUADS);
+ imm.color(color.r, color.g, color.b, color.a);
+ unsigned x = static_cast<unsigned>(activity.get_average()/4096);
+ imm.vertex(14, 0);
+ imm.vertex(14+x, 0);
+ imm.vertex(14+x, 10);
+ imm.vertex(14, 10);
+ imm.end();
+ }
+ GL::MatrixStack::modelview() *= GL::Matrix::translation(16, 1, 0);
+ GL::MatrixStack::modelview() *= GL::Matrix::scaling(10);
+ netvis.get_font().draw_string(name);