Exemple #1
0
 public ZertzCupRenderer(RenderContainer rc, int id)
 {
     this.ws = new WaterSimulator(GRID_POINTS, GRID_POINTS, 2.0f*HALF_WIDTH/(GRID_POINTS-0x01), 0.3f, 0.05f, 1.0f);//dz=0.12f
     float c = HALF_WIDTH+0.5f*THICKNESS;
     this.ztra = new ZertzTileRenderer(c, BORDER_HEIGHT+CORNER_HEIGHT, c);
     this.ztrb = new ZertzTileRenderer(-c, BORDER_HEIGHT+CORNER_HEIGHT, -c);
     float alt = (float)(0.5f*Math.Sqrt(5.0f)-0.5f)*ZertzTileRenderer.TILE_HEIGHT;
     float wid = (ZertzTileRenderer.TILE_HEIGHT-alt);
     LinuxFlag lfa = new LinuxFlag(8, 8, wid, 250.0f, 0.98f, alt, ZertzTileRenderer.TILE_RADIUS);
     lfa.Location = new Vector3(c, BORDER_HEIGHT+CORNER_HEIGHT, -c);
     rc.Add(id, lfa);
     LinuxFlag lfb = new LinuxFlag(8, 8, wid, 250.0f, 0.98f, alt, ZertzTileRenderer.TILE_RADIUS);
     lfb.Location = new Vector3(-c, BORDER_HEIGHT+CORNER_HEIGHT, c);
     rc.Add(id+0x01, lfb);
 }
Exemple #2
0
        public ZertzCupRenderer(RenderContainer rc, int id)
        {
            this.ws = new WaterSimulator(GRID_POINTS, GRID_POINTS, 2.0f * HALF_WIDTH / (GRID_POINTS - 0x01), 0.3f, 0.05f, 1.0f);      //dz=0.12f
            float c = HALF_WIDTH + 0.5f * THICKNESS;

            this.ztra = new ZertzTileRenderer(c, BORDER_HEIGHT + CORNER_HEIGHT, c);
            this.ztrb = new ZertzTileRenderer(-c, BORDER_HEIGHT + CORNER_HEIGHT, -c);
            float     alt = (float)(0.5f * Math.Sqrt(5.0f) - 0.5f) * ZertzTileRenderer.TILE_HEIGHT;
            float     wid = (ZertzTileRenderer.TILE_HEIGHT - alt);
            LinuxFlag lfa = new LinuxFlag(8, 8, wid, 250.0f, 0.98f, alt, ZertzTileRenderer.TILE_RADIUS);

            lfa.Location = new Vector3(c, BORDER_HEIGHT + CORNER_HEIGHT, -c);
            rc.Add(id, lfa);
            LinuxFlag lfb = new LinuxFlag(8, 8, wid, 250.0f, 0.98f, alt, ZertzTileRenderer.TILE_RADIUS);

            lfb.Location = new Vector3(-c, BORDER_HEIGHT + CORNER_HEIGHT, c);
            rc.Add(id + 0x01, lfb);
        }