summaryrefslogtreecommitdiff
path: root/emfio/source
diff options
context:
space:
mode:
authorMichael Stahl <mstahl@redhat.com>2017-10-27 11:51:28 +0200
committerMichael Stahl <mstahl@redhat.com>2017-10-27 12:37:45 +0200
commita3cb93b3917608f5b329321caea8d699b80b1ddf (patch)
tree6f46725c4e90dfb2e09f9b6e993fa071fd1ff76e /emfio/source
parent39a2401807e67f41e96f51f747cb10c54700d793 (diff)
remove GetSwapFloat nonsense from all 3 EMF readers
SvStream::ReadFloat already does that, and SvStream is initialised to SvStreamEndian::LITTLE by default. Change-Id: I5859e43014533bcebef9d4b8f0678c516193b92e
Diffstat (limited to 'emfio/source')
-rw-r--r--emfio/source/reader/emfreader.cxx14
-rw-r--r--emfio/source/reader/mtftools.cxx9
2 files changed, 0 insertions, 23 deletions
diff --git a/emfio/source/reader/emfreader.cxx b/emfio/source/reader/emfreader.cxx
index 8ff413b79033..f865487e00d1 100644
--- a/emfio/source/reader/emfreader.cxx
+++ b/emfio/source/reader/emfreader.cxx
@@ -305,20 +305,6 @@ record_type_name(sal_uInt32 nRecType)
#endif
}
-#ifdef OSL_BIGENDIAN
-// little endian <-> big endian switch
-static float GetSwapFloat(SvStream& rStream)
-{
- float fTmp;
- sal_Int8* pPtr = (sal_Int8*)&fTmp;
- rStream.ReadSChar(pPtr[3]);
- rStream.ReadSChar(pPtr[2]);
- rStream.ReadSChar(pPtr[1]);
- rStream.ReadSChar(pPtr[0]);
- return fTmp;
-}
-#endif
-
struct BLENDFUNCTION
{
unsigned char aBlendOperation;
diff --git a/emfio/source/reader/mtftools.cxx b/emfio/source/reader/mtftools.cxx
index b6de61d1f6bc..038000e9a185 100644
--- a/emfio/source/reader/mtftools.cxx
+++ b/emfio/source/reader/mtftools.cxx
@@ -56,21 +56,12 @@ namespace emfio
}
else
{
-#ifdef OSL_BIGENDIAN
- rXForm.eM11 = GetSwapFloat(rInStream);
- rXForm.eM12 = GetSwapFloat(rInStream);
- rXForm.eM21 = GetSwapFloat(rInStream);
- rXForm.eM22 = GetSwapFloat(rInStream);
- rXForm.eDx = GetSwapFloat(rInStream);
- rXForm.eDy = GetSwapFloat(rInStream);
-#else
rInStream.ReadFloat(rXForm.eM11);
rInStream.ReadFloat(rXForm.eM12);
rInStream.ReadFloat(rXForm.eM21);
rInStream.ReadFloat(rXForm.eM22);
rInStream.ReadFloat(rXForm.eDx);
rInStream.ReadFloat(rXForm.eDy);
-#endif
}
return rInStream;
}