*/
  public int [] gen_textures (int n) {
    RequestOutputStream o = display.out;
    int [] textures;
    synchronized (o) {
      o.begin_request (glx.major_opcode, 145, 3);
      o.write_int32 (tag);
      o.write_int32 (n);
      ResponseInputStream in = display.in;
      synchronized (in) {
        in.skip (32);
        textures = new int [n];
        for (int i = 0; i < n; i++)
          textures [i] = in.read_int32 ();
      }
    }
    return textures;
  }