Ejemplo n.º 1
0
		private void btnMake_Click(object sender, EventArgs e)
		{
			ImBusy(true);
			
			seq = new Sequence4();
			if (File.Exists(lastFile))
			{
				seq.ReadSequenceFile(lastFile);
			}

			if (chkDoFence.Checked)
			{
				BuildFence();
			}

			if (chkDoAirship.Checked)
			{
				BuildShip();
			}

			if (chkDoTree.Checked)
			{
				BuildTreeNew();
			}

			FileInfo oFilenfo = new FileInfo(lastFile);
			string newFile = oFilenfo.Directory + "\\" + JustName(lastFile) + " + NEW" + oFilenfo.Extension;

			seq.WriteSequenceFile(newFile);
			//seq.WriteFileInDisplayOrder(newFile);

			ImBusy(false);
			SystemSounds.Exclamation.Play();

		}
Ejemplo n.º 2
0
		private void SaveFile()
		{ 
			string newName = Path.GetDirectoryName(lastFile) + "\\";
			newName += Path.GetFileNameWithoutExtension(lastFile);
			newName += " + Tree Pixels 6th Try";
			newName += Path.GetExtension(lastFile);
			seq.WriteSequenceFile(newName);
		}
Ejemplo n.º 3
0
        }         // end Save As...

        private int SaveSequence(string newName)
        {
            int err = seq.WriteSequenceFile(newName);

            if (err == 0)
            {
                if (chkAutoLaunch.Checked)
                {
                    System.Diagnostics.Process.Start(newName);
                }
            }
            return(err);
        }         // end SaveSequence
Ejemplo n.º 4
0
		private void btnSave_Click(object sender, EventArgs e)
		{
			int newCS = utils.UNDEFINED;
			int.TryParse(txtNewCS.Text, out newCS);
			if ((newCS > 100) && (newCS < 360000))
			{
				string ext = Path.GetExtension(fileSequence).ToLower();
				string pth = Path.GetDirectoryName(fileSequence);
				string fn = Path.GetFileNameWithoutExtension(fileSequence) + " CentiFixed";
				dlgSaveFile.DefaultExt = ext;
				dlgSaveFile.InitialDirectory = pth;
				dlgSaveFile.FileName = fn;
				if (ext == "lms")
				{
					dlgSaveFile.Filter = "Musical Sequence *.lms|*.lms";
				}
				else
				{
					dlgSaveFile.Filter = "Animated Sequence *.las|*.las";
				}
				dlgSaveFile.FilterIndex = 1;
				dlgSaveFile.OverwritePrompt = true;
				dlgSaveFile.SupportMultiDottedExtensions = true;
				dlgSaveFile.ValidateNames = true;
				dlgSaveFile.Title = "Save Fixed Sequence As...";
				DialogResult dr = dlgSaveFile.ShowDialog(this);
				if (dr == DialogResult.OK)
				{
					string newFile = dlgSaveFile.FileName;

					ImBusy(true);
					CentiFixx(newCS);
					seq.WriteSequenceFile(newFile);
					SystemSounds.Exclamation.Play();
					ImBusy(false);
				}
			}
			
		}
Ejemplo n.º 5
0
 private void button1_Click(object sender, EventArgs e)
 {
     seqOne.WriteSequenceFile("D:\\Light-O-Rama\\2017 Betty\\rewritten_norm.las");
     seqOne.WriteSequenceFile_DisplayOrder("D:\\Light-O-Rama\\2017 Betty\\rewritten_disp.las");
 }
Ejemplo n.º 6
0
		private void btnMake_Click(object sender, EventArgs e)
		{
			EnableAll(false);
			pixelNum = 1;
			groupCount = 0;
			groupNumber = 1;

			seq = new Sequence4();
			if (File.Exists(lastFile))
			{
				seq.ReadSequenceFile(lastFile);
			}





			// Strip 1
			if (chkMake1.Checked)
			{
				stripName = txtStripName1.Text;
				universeNum = Convert.ToInt16(numUniverse1.Value);
				stripCount = Int16.Parse(txtKeywdelCt1.Text);
				stripNum = 1;
				pixelNum = 1;
				reversed = optReverse1.Checked;
				if (reversed)
				{
					stripStart = Int16.Parse(txtKeywdelCt1.Text);
					stripEnd = Int16.Parse(txtStartCh1.Text);
					chIncr = -1;
				}
				else
				{
					stripStart = Int16.Parse(txtStartCh1.Text);
					stripEnd = Int16.Parse(txtKeywdelCt1.Text);
					chIncr = 1;
				}
				if (optRGB1.Checked) chOrder = 1;
				if (optGRB1.Checked) chOrder = 2;
				groupSize = Int16.Parse(cboGroupSize1.Text);

				pixNumFirst = 1;
				pixNumLast = groupSize;
				stripNumFirst = stripStart;
				stripNumLast = stripStart + (groupSize * chIncr);
				dmxChFirst = Math.Min(stripNumFirst, stripNumLast) * 3 + 1;
				dmxChLast = Math.Max(stripNumFirst, stripNumLast) * 3;

				AddStrip();
			}
			
			// Strip 2
			if (chkMake2.Checked)
			{
				stripName = txtStripName2.Text;
				universeNum = Convert.ToInt16(numUniverse2.Value);
				stripCount = Int16.Parse(txtKeywdelCt2.Text);
				stripNum = 2;
				reversed = optReverse2.Checked;
				if (reversed)
				{
					stripStart = Int16.Parse(txtKeywdelCt2.Text);
					stripEnd = Int16.Parse(txtStartCh2.Text);
					chIncr = -1;
				}
				else
				{
					stripStart = Int16.Parse(txtStartCh2.Text);
					stripEnd = Int16.Parse(txtKeywdelCt2.Text);
					chIncr = 1;
				}
				if (optRGB2.Checked) chOrder = 1;
				if (optGRB2.Checked) chOrder = 2;
				groupSize = Int16.Parse(cboGroupSize2.Text);

				pixNumFirst = Int16.Parse(txtKeywdelCt1.Text) + 1;
				int gc = ((pixelNum / Int16.Parse(cboGroupSize1.Text)) + 1) * groupSize;
				pixNumLast = 180; // gc; // Int16.Parse(txtKeywdelCt1.Text) + Int16.Parse(txtKeywdelCt2.Text);
				stripNumFirst = 1;
				stripNumLast = 10;
				dmxChFirst = Int16.Parse(txtStartCh2.Text);
				dmxChLast = 30; // groupSize * 3;

				AddStrip();
			}

			// Strip 3
			if (chkMake3.Checked)
			{
				stripName = txtStripName3.Text;
				universeNum = Convert.ToInt16(numUniverse3.Value);
				stripCount = Int16.Parse(txtKeywdelCt3.Text);
				stripNum = 3;
				reversed = optReverse3.Checked;
				if (reversed)
				{
					stripStart = Int16.Parse(txtKeywdelCt3.Text);
					stripEnd = Int16.Parse(txtStartCh3.Text);
					chIncr = -1;
				}
				else
				{
					stripStart = Int16.Parse(txtStartCh3.Text);
					stripEnd = Int16.Parse(txtKeywdelCt3.Text);
					chIncr = 1;
				}
				if (optRGB3.Checked) chOrder = 1;
				if (optGRB3.Checked) chOrder = 2;
				groupSize = Int16.Parse(cboGroupSize3.Text);

				pixNumFirst = Int16.Parse(txtKeywdelCt1.Text) + Int16.Parse(txtKeywdelCt2.Text) + 1;
				pixNumLast = 360; // Int16.Parse(txtKeywdelCt1.Text) + Int16.Parse(txtKeywdelCt2.Text) + Int16.Parse(txtKeywdelCt3.Text);
				stripNumFirst = 170; // Int16.Parse(txtKeywdelCt1.Text) + Int16.Parse(txtKeywdelCt2.Text) + stripStart;
				stripNumLast = 151; // stripNumFirst + (groupSize * chIncr);
				dmxChFirst = 451; // Int16.Parse(txtStartCh3.Text);
				dmxChLast = 510; //  (Int16.Parse(txtKeywdelCt3.Text) * 3) - 1;

				AddStrip();
			}

			// Strip 4
			if (chkMake4.Checked)
			{
				stripName = txtStripName4.Text;
				universeNum = Convert.ToInt16(numUniverse4.Value);
				stripCount = Int16.Parse(txtKeywdelCt4.Text);
				stripNum = 4;
				reversed = optReverse4.Checked;
				if (reversed)
				{
					stripStart = Int16.Parse(txtKeywdelCt4.Text);
					stripEnd = Int16.Parse(txtStartCh4.Text);
					chIncr = -1;
				}
				else
				{
					stripStart = Int16.Parse(txtStartCh4.Text);
					stripEnd = Int16.Parse(txtKeywdelCt4.Text);
					chIncr = 1;
				}
				if (optRGB4.Checked) chOrder = 1;
				if (optGRB4.Checked) chOrder = 2;
				groupSize = Int16.Parse(cboGroupSize4.Text);

				pixNumFirst = Int16.Parse(txtKeywdelCt1.Text) + Int16.Parse(txtKeywdelCt2.Text) + Int16.Parse(txtKeywdelCt3.Text) + 1;
				pixNumLast = 520; // Int16.Parse(txtKeywdelCt1.Text) + Int16.Parse(txtKeywdelCt2.Text) + Int16.Parse(txtKeywdelCt3.Text) + Int16.Parse(txtKeywdelCt4.Text);
				stripNumFirst = 1; // Int16.Parse(txtKeywdelCt1.Text) + Int16.Parse(txtKeywdelCt2.Text) + Int16.Parse(txtKeywdelCt3.Text) + stripStart;
				stripNumLast = 10; // stripNumFirst + (groupSize * chIncr);
				dmxChFirst = 1; // Int16.Parse(txtStartCh4.Text);
				dmxChLast = 30; // (Int16.Parse(txtKeywdelCt4.Text) * 3) - 1;

				AddStrip();
			}

			FileInfo oFilenfo = new FileInfo(lastFile);
			//string newFile = oFilenfo.Directory + "\\" + JustName(lastFile) + " + Strips" + oFilenfo.Extension;
			string newFile = oFilenfo.Directory + "\\" + Path.GetFileNameWithoutExtension(lastFile) + " + Strips" + oFilenfo.Extension;

			seq.WriteSequenceFile(newFile);
			//seq.WriteFileInDisplayOrder(newFile);

			EnableAll(true);
			SystemSounds.Exclamation.Play();

		} // end btnMake_Click()