decoder/dsdiff: use PackedBE64 instead of DffDsdUint64
This commit is contained in:
parent
02296adbba
commit
c472046cbb
@ -31,17 +31,6 @@ public:
|
|||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
class DffDsdUint64 {
|
|
||||||
uint32_t hi;
|
|
||||||
uint32_t lo;
|
|
||||||
|
|
||||||
public:
|
|
||||||
constexpr uint64_t Read() const {
|
|
||||||
return (uint64_t(FromBE32(hi)) << 32) |
|
|
||||||
uint64_t(FromBE32(lo));
|
|
||||||
}
|
|
||||||
};
|
|
||||||
|
|
||||||
bool
|
bool
|
||||||
dsdlib_skip_to(DecoderClient *client, InputStream &is,
|
dsdlib_skip_to(DecoderClient *client, InputStream &is,
|
||||||
offset_type offset);
|
offset_type offset);
|
||||||
|
@ -22,13 +22,13 @@
|
|||||||
|
|
||||||
struct DsdiffHeader {
|
struct DsdiffHeader {
|
||||||
DsdId id;
|
DsdId id;
|
||||||
DffDsdUint64 size;
|
PackedBE64 size;
|
||||||
DsdId format;
|
DsdId format;
|
||||||
};
|
};
|
||||||
|
|
||||||
struct DsdiffChunkHeader {
|
struct DsdiffChunkHeader {
|
||||||
DsdId id;
|
DsdId id;
|
||||||
DffDsdUint64 size;
|
PackedBE64 size;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Read the "size" attribute from the specified header, converting it
|
* Read the "size" attribute from the specified header, converting it
|
||||||
@ -36,7 +36,7 @@ struct DsdiffChunkHeader {
|
|||||||
*/
|
*/
|
||||||
[[nodiscard]] constexpr
|
[[nodiscard]] constexpr
|
||||||
uint64_t GetSize() const {
|
uint64_t GetSize() const {
|
||||||
return size.Read();
|
return size;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
Loading…
Reference in New Issue
Block a user