Compare commits
2 Commits
2107d68e71
...
v0.1.3
| Author | SHA1 | Date | |
|---|---|---|---|
| faf4a2f4d5 | |||
| 29a467b694 |
Vendored
+6
@@ -1,3 +1,9 @@
|
||||
libxisf (0.1.3-ubuntu1) focal; urgency=medium
|
||||
|
||||
* Write missing pixelStorage attribute
|
||||
|
||||
-- Dušan Poizl <nou@nouspiro.space> Fri, 17 Feb 2023 16:57:30 +0100
|
||||
|
||||
libxisf (0.1.2-ubuntu1) focal; urgency=medium
|
||||
|
||||
* Add qtbase5-dev as dependency to libxisf-dev
|
||||
|
||||
+13
@@ -952,6 +952,7 @@ void XISFWriter::writeImageElement(const Image &image)
|
||||
_xml->writeAttribute("sampleFormat", Image::sampleFormatString(image._sampleFormat));
|
||||
_xml->writeAttribute("colorSpace", Image::colorSpaceString(image._colorSpace));
|
||||
_xml->writeAttribute("imageType", Image::imageTypeString(image._imageType));
|
||||
_xml->writeAttribute("pixelStorage", Image::pixelStorageString(image._pixelStorage));
|
||||
if((image._sampleFormat == Image::Float32 || image._sampleFormat == Image::Float64) ||
|
||||
image._bounds.first != 0.0 || image._bounds.second != 1.0)
|
||||
{
|
||||
@@ -966,6 +967,7 @@ void XISFWriter::writeImageElement(const Image &image)
|
||||
writeFITSKeyword(fitsKeyword);
|
||||
|
||||
writeCFA(image);
|
||||
writeICC(image._iccProfile);
|
||||
|
||||
_xml->writeEndElement();
|
||||
}
|
||||
@@ -1083,6 +1085,17 @@ void XISFWriter::writeCFA(const Image &image)
|
||||
}
|
||||
}
|
||||
|
||||
void XISFWriter::writeICC(const QByteArray &icc)
|
||||
{
|
||||
if(!icc.isEmpty())
|
||||
{
|
||||
QByteArray base64 = icc.toBase64();
|
||||
_xml->writeStartElement("ICCProfile");
|
||||
_xml->writeAttribute("location", "inline:base64");
|
||||
_xml->writeCharacters(base64);
|
||||
}
|
||||
}
|
||||
|
||||
#define REGISTER_METATYPE(type) { int id = qMetaTypeId<type>(); \
|
||||
typeToId.insert({#type, id}); idToType.insert({id, #type}); }
|
||||
|
||||
|
||||
Reference in New Issue
Block a user