#ifndef __MMNCPU_BI__
#define __MMNCPU_BI__

'  #############
' # mmncpu.bi #
'#############
' Copyright 2005-2013 by D.J.Peters (Joshy)
' d.j.peters@web.de

#include once "fbstypes.bi"
#inclib "fbscpu"


#define _AAP as any ptr
#define _AAPP as any ptr ptr

declare function IsFPU              () as FBSBOOLEAN
declare function IsTSC              () as FBSBOOLEAN
declare function IsCMOV             () as FBSBOOLEAN
declare function IsMMX              () as FBSBOOLEAN
declare function IsMMX2             () as FBSBOOLEAN
declare function IsSSE              () as FBSBOOLEAN
declare function IsSSE2             () as FBSBOOLEAN
declare function IsNOW3D            () as FBSBOOLEAN
declare function IsNOW3D2           () as FBSBOOLEAN
declare function Mhz                () as integer
declare function CPUCounter         () as longint

declare sub      Zero               (d _AAP,                                            n as integer)
declare sub      ZeroBuffer         (s _AAP,p _AAPP,e _AAP ,                            n as integer)
declare sub      Copy               (d _AAP,s _AAP ,                                    n as integer)
declare sub      Mix16              (d _AAP,a _AAP ,b _AAP ,                            n as integer)
declare sub      Scale16            (d _AAP,s _AAP ,v  as single,                       n as integer)
declare sub      Pan16              (d _AAP,s _AAP ,l  as single,r as single,           n as integer)
declare sub      CopyRight16        (d _AAP,s _AAP ,p _AAPP,e _AAP ,l _AAPP,            n as integer)
declare sub      CopyRight32        (d _AAP,s _AAP ,p _AAPP,e _AAP ,l _AAPP,            n as integer)
declare sub      MoveRight16        (s _AAP,p _AAPP,e _AAP ,l _AAPP,                    n as integer)
declare sub      MoveRight32        (s _AAP,p _AAPP,e _AAP ,l _AAPP,                    n as integer)
declare sub      CopySliceRight16   (d _AAP,s _AAP ,p _AAPP,e _AAP ,l _AAPP,v as single,n as integer)
declare sub      CopySliceRight32   (d _AAP,s _AAP ,p _AAPP,e _AAP ,l _AAPP,v as single,n as integer)
declare sub      MoveSliceRight16   (s _AAP,p _AAPP,e _AAP ,l _AAPP,v as single,        n as integer)
declare sub      MoveSliceRight32   (s _AAP,p _AAPP,e _AAP ,l _AAPP,v as single,        n as integer)
declare sub      CopySliceLeft16    (d _AAP,s _AAP ,p _AAPP,e _AAP ,l _AAPP,v as single,n as integer)
declare sub      CopySliceLeft32    (d _AAP,s _AAP ,p _AAPP,e _AAP ,l _AAPP,v as single,n as integer)
declare sub      MoveSliceLeft16    (s _AAP,p _AAPP,e _AAP ,l _AAPP,v as single,        n as integer)
declare sub      MoveSliceLeft32    (s _AAP,p _AAPP,e _AAP ,l _AAPP,v as single,        n as integer)

#ifndef NOMP3
declare sub      CopyMP3Frame       (s _AAP,p _AAPP,e _AAP ,f _AAP ,                    n as integer)
declare sub      CopySliceMP3Frame32(s _AAP,p _AAPP,e _AAP ,f _AAP ,v as single,        n as integer)
declare sub      CopySliceMP3Frame16(s _AAP,p _AAPP,e _AAP ,f _AAP ,v as single,        n as integer)
declare sub      ScaleMP3Frame_22_16(d _AAP,a _AAP ,b _AAP ,                            n as integer)
declare sub      ScaleMP3Frame_21_16(d _AAP,a _AAP ,b _AAP ,                            n as integer)
declare sub      ScaleMP3Frame_12_16(d _AAP,s _AAP ,                                    n as integer)
declare sub      ScaleMP3Frame_11_16(d _AAP,s _AAP ,                                    n as integer)
#endif

#endif ' __MMNCPU_BI__
