Merge branch 'develop' into rap

This commit is contained in:
Gary Kertopermono committed 2021-06-28 10:44:22 +02:00
commit 612c18326d
46 files changed
+1632 -319

No files matched your search

+13 -2
View File
@@ -101,7 +101,7 @@ namespace VocaluxeLib.Songs
public readonly List<string> BackgroundFileNames = new List<string>();
public string VideoFileName = String.Empty;
public EAspect VideoAspect = EAspect.Crop;
public EAspect VideoAspect = EAspect.Automatic;
public bool NotesLoaded { get; private set; }
@@ -289,6 +289,17 @@ namespace VocaluxeLib.Songs
return loader.ReadNotes();
}
public bool ReloadSong(bool reloadNotes)
{
var loader = new CSongLoader(this);
bool retValue = loader.ReadHeader();
if (!retValue)
return false;
retValue = loader.ReadNotes(reloadNotes);
return retValue;
}
public bool Save()
{
return Save(Path.Combine(Folder, FileName));
@@ -519,4 +530,4 @@ namespace VocaluxeLib.Songs
ShortEnd.Source = EDataSource.Calculated;
}
}
}
}
+8 -2
View File
@@ -82,12 +82,16 @@ namespace VocaluxeLib.Songs
_Song.Languages.Clear();
_Song.Genres.Clear();
_Song.UnknownTags.Clear();
_Song.BackgroundFileNames.Clear();
_Song._Comment = "";
_Song.ManualEncoding = false;
_Song.Medley.Source = EDataSource.None;
_Song._CalculateMedley = true;
_Song.Preview.Source = EDataSource.None;
_Song.ShortEnd.Source = EDataSource.None;
_Song.Start = 0;
_Song.VideoGap = 0;
_Song.Preview.StartTime = 0;
var headerFlags = new EHeaderFlags();
StreamReader sr = null;
@@ -569,6 +573,8 @@ namespace VocaluxeLib.Songs
case 'R':
case 'G':
case 'F':
case 'R': // Read R (RAP) and G (Golden RAP) notes as Freestyle notes currently. Final implementation needed!
case 'G': // Read R (RAP) and G (Golden RAP) notes as Freestyle notes currently. Final implementation needed!
string[] noteData = line.Split(splitChars, 4);
if (noteData.Length < 4)
{
@@ -616,7 +622,7 @@ namespace VocaluxeLib.Songs
if (tag.Equals('*'))
noteType = ENoteType.Golden;
else if (tag.Equals('F'))
else if (tag.Equals('F') || tag.Equals('R') || tag.Equals('G')) // Read R (RAP) and G (Golden RAP) notes as Freestyle notes currently. Final implementation needed!
noteType = ENoteType.Freestyle;
else if (tag.Equals('R'))
{
@@ -773,4 +779,4 @@ namespace VocaluxeLib.Songs
}
}
}
}
}