Ejemplo n.º 1
0
        private void button1_Click(object sender, EventArgs e)
        {
            evtchr = new EVTCHR(File.ReadAllBytes(@"Resources\EVENT\EVTCHR.BIN"));
            Bitmap b = new Bitmap(evtchr[0].Width, evtchr[0].Height);

            pictureBox1.Image      = b;
            numericUpDown1.Enabled = true;
            numericUpDown2.Enabled = true;
            BackgroundWorker bw = new BackgroundWorker();

            bw.WorkerReportsProgress      = true;
            bw.WorkerSupportsCancellation = true;
            set = FullSpriteSet.FromPsxISO(@"N:\dev\fft\images\fft-usa.bin", bw);
            numericUpDown2_ValueChanged(numericUpDown1, EventArgs.Empty);
        }
Ejemplo n.º 2
0
        void importPsxMenuItem_Click(object sender, EventArgs e)
        {
            openFileDialog.FileName    = string.Empty;
            openFileDialog.Filter      = "PSX ISO files (*.iso, *.img, *.bin)|*.iso;*.img;*.bin";
            openFileDialog.FilterIndex = 0;

            if (openFileDialog.ShowDialog(this) == DialogResult.OK)
            {
                DoBackgroundTask(
                    delegate(object o, DoWorkEventArgs args)
                {
                    FullSpriteSet set = FullSpriteSet.FromPsxISO(openFileDialog.FileName, o as BackgroundWorker);
                    if (fullSpriteSetEditor1.InvokeRequired)
                    {
                        fullSpriteSetEditor1.Invoke(new MethodInvoker(delegate() { fullSpriteSetEditor1.LoadFullSpriteSet(set); }));
                    }
                    else
                    {
                        fullSpriteSetEditor1.LoadFullSpriteSet(set);
                    }
                });
            }
        }