
calcfl		macro
		ifnd	_MathffpOpnc
		func	_MathffpBase,=,openlibrary,"mathffp.library",0
		beq	_nomathffplib
_MathffpOpnc	set	1
		endc
		ifnc	'\2,''
		varin 	\3,d0
		ifnd	\3sw
		move.l	_MathffpBase(a4),a6
		jsr	-36(a6)		;_LVOSPFlt(a6)
		endc
		ifnc	'\4',''
		varin	\5,d1
		ifnd	\5sw
		move.l	d0,-(sp)
		move.l	d1,d0
		move.l	_MathffpBase(a4),a6
		jsr	-36(a6)		;_LVOSPFlt(a6)
		move.l	d0,d1
		move.l	(sp)+,d0
		endc
		move.l	_MathffpBase(a4),a6
		ifc	'\4','+'
		jsr	-66(a6)		;_LVOSPAdd(a6)
		endc
		ifc	'\4','-'
		jsr	-72(a6)		;_LVOSPSub(a6)
		endc
		ifc	'\4','*'
		jsr	-78(a6)		;_LVOSPMul(a6)
		endc
		ifc	'\4','/'
		jsr	-84(a6)		;_LVOSPDiv(a6)
		endc
		endc
		varinout	d0,\1
		endc

		endm

inttofl		macro
		ifnd	_MathffpOpnc
		func	_MathffpBase,=,openlibrary,"mathffp.library",0
		beq	_nomathffplib
_MathffpOpnc	set	1
		endc
		varin	\2,d0
		move.l	_MathffpBase(a4),a6
		jsr	-36(a6)		;_LVOSPFlt(a6)
		varinout	d0,\1
		endm

fltoint		macro
		ifnd	_MathffpOpnc
		func	_MathffpBase,=,openlibrary,"mathffp.library",0
		beq	_nomathfplib
		endc
		varin	\2,d0
		move.l	_MathffpBase(a4),a6)
		jsr	-30(a6)		;_LVOSPFix(a6)
		varinout	d0,\1
		endm