grid

package
v1.1.3 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Aug 30, 2022 License: LGPL-2.1 Imports: 4 Imported by: 0

Documentation

Overview

Package grid is used to generate grid data. include square and hexagon.

Index

Constants

View Source
const (
	// Angle of sin 60 = 0.866025403785
	Sin60 = 0.866025403785
	Cos60 = 0.5
)

const ...

Variables

This section is empty.

Functions

func HexagonGrid

func HexagonGrid(bound space.Bound, cellSize float64) (gridGeoms [][]Grid)

HexagonGrid Draw a grid according to the distance, including the given area

func SquareGrid

func SquareGrid(bound space.Bound, cellSize float64) (gridGeoms [][]Grid)

SquareGrid ,Draw a grid according to the distance, including the given area.

Types

type Grid

type Grid struct {
	Geometry space.Geometry
}

Grid ...

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL