Re: [fpc-pascal] x86 asm bswap

2013-02-06 Thread Mark Morgan Lloyd
Juha Manninen wrote: On Wed, Feb 6, 2013 at 10:40 AM, Jeppe Græsdal Johansen wrote: function TPNGProcessor.SwapLong( const aValue: Cardinal ): Cardinal; begin result := BeToN(aValue); end; Thanks, it works! There are so many functions in FPC libraries which I don't know anything about. Thi

Re: [fpc-pascal] x86 asm bswap

2013-02-06 Thread Sven Barth
Am 06.02.2013 11:01, schrieb Juha Manninen: On Wed, Feb 6, 2013 at 10:40 AM, Jeppe Græsdal Johansen wrote: function TPNGProcessor.SwapLong( const aValue: Cardinal ): Cardinal; begin result := BeToN(aValue); end; Thanks, it works! There are so many functions in FPC libraries which I don't k

Re: [fpc-pascal] x86 asm bswap

2013-02-06 Thread Juha Manninen
On Wed, Feb 6, 2013 at 10:40 AM, Jeppe Græsdal Johansen wrote: > function TPNGProcessor.SwapLong( const aValue: Cardinal ): Cardinal; > begin >result := BeToN(aValue); > end; Thanks, it works! There are so many functions in FPC libraries which I don't know anything about. This was one of them

Re: [fpc-pascal] x86 asm bswap

2013-02-06 Thread Juha Manninen
On Wed, Feb 6, 2013 at 10:40 AM, Vincent Snijders wrote: > 2013/2/6 Juha Manninen : >> I read that bswap is used for converting big-endian (Intel) format to >> little-endian (Motorolla etc.) format. >> However this a an old Delphi app, Win32 only. > > I am confused. Intel i386 is little endian. Mo

Re: [fpc-pascal] x86 asm bswap

2013-02-06 Thread Jeppe Græsdal Johansen
function TPNGProcessor.SwapLong( const aValue: Cardinal ): Cardinal; begin result := BeToN(aValue); end; Den 06-02-2013 09:25, Juha Manninen skrev: A Delphi project "DeleD 3-D" which I try to convert, has unit_PNGSupport with method: function TPNGProcessor.SwapLong( const aValue: Cardinal )

Re: [fpc-pascal] x86 asm bswap

2013-02-06 Thread Vincent Snijders
2013/2/6 Juha Manninen : > I read that bswap is used for converting big-endian (Intel) format to > little-endian (Motorolla etc.) format. > However this a an old Delphi app, Win32 only. I am confused. Intel i386 is little endian. Motorola Powerpc is big endian. Vincent ___