mirror of
https://github.com/aaru-dps/Aaru.git
synced 2025-12-16 19:24:25 +00:00
Added support for AmigaDOS filesystems.
This commit is contained in:
@@ -47,6 +47,7 @@ namespace DiscImageChef
|
||||
static readonly DateTime UNIXEpoch = new DateTime(1970, 1, 1, 0, 0, 0);
|
||||
// Day 0 of Julian Date system
|
||||
static readonly DateTime JulianEpoch = new DateTime(1858, 11, 17, 0, 0, 0);
|
||||
static readonly DateTime AmigaEpoch = new DateTime(1978, 1, 1, 0, 0, 0);
|
||||
|
||||
public static DateTime MacToDateTime(ulong MacTimeStamp)
|
||||
{
|
||||
@@ -145,6 +146,13 @@ namespace DiscImageChef
|
||||
double delta = vmsDate * 0.0001; // Tenths of microseconds to milliseconds, will lose some detail
|
||||
return JulianEpoch.AddMilliseconds(delta);
|
||||
}
|
||||
|
||||
public static DateTime AmigaToDateTime(UInt32 days, UInt32 minutes, UInt32 ticks)
|
||||
{
|
||||
DateTime temp = AmigaEpoch.AddDays(days);
|
||||
temp = temp.AddMinutes(minutes);
|
||||
return temp.AddMilliseconds(ticks * 20);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user