openexr: Fix some warnings
authorNirbheek Chauhan <nirbheek@centricular.com>
Fri, 18 Mar 2022 08:07:30 +0000 (13:37 +0530)
committerGStreamer Marge Bot <gitlab-merge-bot@gstreamer-foundation.org>
Fri, 18 Mar 2022 22:49:16 +0000 (22:49 +0000)
```
../subprojects/gst-plugins-bad/ext/openexr/gstopenexrdec.cpp:46:24: warning: ‘Imf_3_1::Int64’ is deprecated: use uint64_t [-Wdeprecated-declarations]
   46 |   virtual Int64 tellg ();
      |                        ^
In file included from ../subprojects/gst-plugins-bad/ext/openexr/gstopenexrdec.cpp:32:
/usr/include/OpenEXR/ImfInt64.h:23:32: note: declared here
   23 | typedef IMATH_NAMESPACE::Int64 Int64;
      |                                ^~~~~
../subprojects/gst-plugins-bad/ext/openexr/gstopenexrdec.cpp:47:32: warning: ‘Imf_3_1::Int64’ is deprecated: use uint64_t [-Wdeprecated-declarations]
   47 |   virtual void seekg (Int64 pos);
      |                                ^
In file included from ../subprojects/gst-plugins-bad/ext/openexr/gstopenexrdec.cpp:32:
/usr/include/OpenEXR/ImfInt64.h:23:32: note: declared here
   23 | typedef IMATH_NAMESPACE::Int64 Int64;
      |                                ^~~~~
../subprojects/gst-plugins-bad/ext/openexr/gstopenexrdec.cpp:67:26: warning: ‘Imf_3_1::Int64’ is deprecated: use uint64_t [-Wdeprecated-declarations]
   67 | Int64 MemIStream::tellg ()
      |                          ^
In file included from ../subprojects/gst-plugins-bad/ext/openexr/gstopenexrdec.cpp:32:
/usr/include/OpenEXR/ImfInt64.h:23:32: note: declared here
   23 | typedef IMATH_NAMESPACE::Int64 Int64;
      |                                ^~~~~
../subprojects/gst-plugins-bad/ext/openexr/gstopenexrdec.cpp:73:29: warning: ‘Imf_3_1::Int64’ is deprecated: use uint64_t [-Wdeprecated-declarations]
   73 | MemIStream::seekg (Int64 pos)
      |                             ^
In file included from ../subprojects/gst-plugins-bad/ext/openexr/gstopenexrdec.cpp:32:
/usr/include/OpenEXR/ImfInt64.h:23:32: note: declared here
   23 | typedef IMATH_NAMESPACE::Int64 Int64;
      |                                ^~~~~
```

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/1977>

subprojects/gst-plugins-bad/ext/openexr/gstopenexrdec.cpp

index 32b1d03c388a441cb1293fc261a1eec634c3e5f0..d54b308319a23d3a61f5180a7fa6de46b37dd769 100644 (file)
 
 #include <gst/base/base.h>
 #include <string.h>
+#include <stdint.h>
 
 #include <ImfRgbaFile.h>
 #include <ImfIO.h>
-#include <ImfInt64.h>
 using namespace Imf;
 using namespace Imath;
 
@@ -43,8 +43,8 @@ public:
   }
 
   virtual bool read (char c[], int n);
-  virtual Int64 tellg ();
-  virtual void seekg (Int64 pos);
+  virtual uint64_t tellg ();
+  virtual void seekg (uint64_t pos);
   virtual void clear ();
 
 private:
@@ -64,13 +64,13 @@ bool MemIStream::read (char c[], int n)
   return (offset == size);
 }
 
-Int64 MemIStream::tellg ()
+uint64_t MemIStream::tellg ()
 {
   return offset;
 }
 
 void
-MemIStream::seekg (Int64 pos)
+MemIStream::seekg (uint64_t pos)
 {
   offset = pos;
   if (offset > size)