fixed: github.com/ReconfigureIO/fixed Index | Files | Directories

package fixed

import "github.com/ReconfigureIO/fixed"

Package fixed implements fixed-point integer types for FPGAs

Index

Package Files

fixed.go

type Int26_6 Uses

type Int26_6 int32

func I26 Uses

func I26(i int32) Int26_6

func I26F Uses

func I26F(i int32, f int32) Int26_6

func (Int26_6) Add Uses

func (x Int26_6) Add(y Int26_6) Int26_6

An alias for the builtin addition operation. It is recommended that you use the primitive + to avoid the overhead of a function call.

func (Int26_6) Ceil Uses

func (x Int26_6) Ceil() int32

The least integer greater than x.

func (Int26_6) Floor Uses

func (x Int26_6) Floor() int32

The greatest integer value ≤ x.

func (Int26_6) Mul Uses

func (x Int26_6) Mul(y Int26_6) Int26_6

The product of x * y. Please note there is no overflow detection at this point.

func (Int26_6) Round Uses

func (x Int26_6) Round() int32

The nearest integer to x.

type Int52_12 Uses

type Int52_12 int64

func I52 Uses

func I52(x int64) Int52_12

func I52F Uses

func I52F(x int64, f int64) Int52_12

func (Int52_12) Ceil Uses

func (x Int52_12) Ceil() int64

The least integer greater than x.

func (Int52_12) Floor Uses

func (x Int52_12) Floor() int64

The greatest integer value ≤ x.

func (Int52_12) Mul Uses

func (x Int52_12) Mul(y Int52_12) Int52_12

Mul returns x*y in 52.12 fixed-point arithmetic.

func (Int52_12) Round Uses

func (x Int52_12) Round() int64

The nearest integer to x.

Directories

PathSynopsis
host

Package fixed is imported by 2 packages. Updated 2017-12-28. Refresh now. Tools for package owners.