예제 #1
0
 public static void Draw(VertexBuffer vertices, VertexFormat format, IndexBuffer indices)
 {
     if (!Toolkit.utDraw(vertices.Handle, format.Handle, indices.Handle, 0, indices.Length))
         throw new FrameworkException();
 }
        public override void Setup()
        {
            _window = new GraphicsWindow(T.Get("Framework Sample"), 640, 480);

            _vfmt = new VertexFormat(format);

            _vbuf = new VertexBuffer(vertices.Length);
            _vbuf.CopyData(vertices);

            _ibuf = new IndexBuffer(indices.Length);
            _ibuf.CopyData(indices);

            _tex = new Texture(4, 4, TextureFormat.RGBA8);
            _tex.CopyData(texture);

            _startTick = Platform.TickCount;
        }