Adrian Schröter
8ba574cff5
Submit gmic package to openSUSE:Factory via the graphics Devel package. Sidenote: While I will continue to build the full gmic binary in my home:garloff:Photography project (and use MMX,SSE on i386) for continuity reasons, I follow upstream to only build gmic the float type for openSUSE submission, covering probably 99% of the use cases ... This is controlled by a %define in the specfile, so I can keep the packages in sync otherwise at least for the time being. OBS-URL: https://build.opensuse.org/request/show/225522 OBS-URL: https://build.opensuse.org/package/show/graphics/gmic?expand=0&rev=1
16 lines
942 B
Diff
16 lines
942 B
Diff
Index: gmic-1.5.8.4/src/CImg.h
|
|
===================================================================
|
|
--- gmic-1.5.8.4.orig/src/CImg.h
|
|
+++ gmic-1.5.8.4/src/CImg.h
|
|
@@ -45929,9 +45929,9 @@ namespace cimg_library_suffixed {
|
|
filename?filename:"(FILE*)");
|
|
#endif
|
|
std::FILE *const nfile = file?file:cimg::fopen(filename,"wb");
|
|
const char *const ptype = pixel_type(), *const etype = cimg::endianness()?"big":"little";
|
|
- if (std::strstr(ptype,"unsigned")==ptype) std::fprintf(nfile,"%u unsigned_%s %s_endian\n",_width,ptype+9,etype);
|
|
+ if (std::strlen(ptype)>9 && std::strstr(ptype,"unsigned")==ptype) std::fprintf(nfile,"%u unsigned_%s %s_endian\n",_width,ptype+9,etype);
|
|
else std::fprintf(nfile,"%u %s %s_endian\n",_width,ptype,etype);
|
|
cimglist_for(*this,l) {
|
|
const CImg<T>& img = _data[l];
|
|
std::fprintf(nfile,"%u %u %u %u",img._width,img._height,img._depth,img._spectrum);
|