pc

package
v0.3.4 Latest Latest
Warning

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

Go to latest
Published: Aug 10, 2021 License: Apache-2.0 Imports: 24 Imported by: 0

Documentation

Index

Constants

View Source
const SleepTimeS = 1.0 / 60.0

Variables

View Source
var CommonFragmentShaderStr string
View Source
var CommonVertexShaderStr string
View Source
var DefaultFragShaderStr string
View Source
var DefaultVertexShaderStr string
View Source
var EllipseFragShaderStr string
View Source
var EllipseVertexShaderStr string
View Source
var ImageFragShaderStr string
View Source
var ImageVertexShaderStr string
View Source
var RectFragShaderStr string
View Source
var ShapeFragShaderStr string
View Source
var ShapeVertexShaderStr string
View Source
var TextFragShaderStr string
View Source
var TextVertexShaderStr string

Functions

This section is empty.

Types

type EllipseRenderer added in v0.2.0

type EllipseRenderer struct {
	// contains filtered or unexported fields
}

func (EllipseRenderer) OnRemovePrimitive added in v0.2.0

func (r EllipseRenderer) OnRemovePrimitive(ctx *rendering.PrimitiveRenderingContext)

func (*EllipseRenderer) OnRender added in v0.2.0

func (EllipseRenderer) OnSetPrimitive added in v0.2.0

func (r EllipseRenderer) OnSetPrimitive(ctx *rendering.PrimitiveRenderingContext)

func (*EllipseRenderer) OnStart added in v0.2.0

func (r *EllipseRenderer) OnStart()

func (EllipseRenderer) OnStop added in v0.2.0

func (r EllipseRenderer) OnStop()

type Frontend

type Frontend struct {
	// contains filtered or unexported fields
}

func NewFrontend

func NewFrontend() *Frontend

func (*Frontend) CommencePanic

func (f *Frontend) CommencePanic(reason, msg string)

func (*Frontend) Execute added in v0.2.1

func (f *Frontend) Execute(item dispatch.WorkItem)

func (*Frontend) GetApp

func (f *Frontend) GetApp() *frontend.App

func (*Frontend) GetContext

func (f *Frontend) GetContext() frontend.Context

func (*Frontend) GetLaunchArgs added in v0.1.7

func (f *Frontend) GetLaunchArgs() a.SiMap

func (*Frontend) GetMessageDispatcher added in v0.2.1

func (f *Frontend) GetMessageDispatcher() dispatch.MessageDispatcher

func (*Frontend) GetPlatform

func (f *Frontend) GetPlatform() common.Platform

func (*Frontend) GetRenderer

func (f *Frontend) GetRenderer() *rendering.ARenderer

func (*Frontend) GetResourceManager

func (f *Frontend) GetResourceManager() frontend.ResourceManager

func (*Frontend) GetWorkDispatcher added in v0.2.1

func (f *Frontend) GetWorkDispatcher() dispatch.WorkDispatcher

func (*Frontend) Init

func (f *Frontend) Init()

func (*Frontend) Run

func (f *Frontend) Run()

func (*Frontend) SendMessage added in v0.2.1

func (f *Frontend) SendMessage(message *dispatch.Message)

func (*Frontend) SetEngineDispatcher added in v0.2.1

func (f *Frontend) SetEngineDispatcher(disp dispatch.MessageDispatcher)

func (*Frontend) Stop

func (f *Frontend) Stop()

type GlProgram added in v0.3.4

type GlProgram struct {
	// contains filtered or unexported fields
}

func NewGlProgram added in v0.3.4

func NewGlProgram(vertexShader, fragmentShader, tag string) *GlProgram
func (p *GlProgram) CompileAndLink()

func (*GlProgram) Delete added in v0.3.4

func (p *GlProgram) Delete()

func (*GlProgram) GetUniformLocation added in v0.3.4

func (p *GlProgram) GetUniformLocation(uName string) int32

func (*GlProgram) IsUsable added in v0.3.4

func (p *GlProgram) IsUsable() bool

func (*GlProgram) SetClipArea2DUniforms added in v0.3.4

func (p *GlProgram) SetClipArea2DUniforms(area *rendering.ClipArea2D)

func (*GlProgram) Use added in v0.3.4

func (p *GlProgram) Use()

type ImageRenderer added in v0.2.0

type ImageRenderer struct {
	// contains filtered or unexported fields
}

func (ImageRenderer) OnRemovePrimitive added in v0.2.0

func (r ImageRenderer) OnRemovePrimitive(ctx *rendering.PrimitiveRenderingContext)

func (*ImageRenderer) OnRender added in v0.2.0

func (ImageRenderer) OnSetPrimitive added in v0.2.0

func (r ImageRenderer) OnSetPrimitive(ctx *rendering.PrimitiveRenderingContext)

func (*ImageRenderer) OnStart added in v0.2.0

func (r *ImageRenderer) OnStart()

func (ImageRenderer) OnStop added in v0.2.0

func (r ImageRenderer) OnStop()

type LineRenderer added in v0.2.0

type LineRenderer struct {
	// contains filtered or unexported fields
}

func (LineRenderer) OnRemovePrimitive added in v0.2.0

func (r LineRenderer) OnRemovePrimitive(ctx *rendering.PrimitiveRenderingContext)

func (*LineRenderer) OnRender added in v0.2.0

func (LineRenderer) OnSetPrimitive added in v0.2.0

func (r LineRenderer) OnSetPrimitive(ctx *rendering.PrimitiveRenderingContext)

func (*LineRenderer) OnStart added in v0.2.0

func (r *LineRenderer) OnStart()

func (LineRenderer) OnStop added in v0.2.0

func (r LineRenderer) OnStop()

type OpenGLRenderer

type OpenGLRenderer struct {
	// contains filtered or unexported fields
}

OpenGLRenderer implements the RendererDelegate interface for pc

func (*OpenGLRenderer) OnClear added in v0.2.0

func (r *OpenGLRenderer) OnClear()

func (*OpenGLRenderer) OnPerformRenderingEnd added in v0.2.0

func (r *OpenGLRenderer) OnPerformRenderingEnd()

func (*OpenGLRenderer) OnPerformRenderingStart added in v0.2.0

func (r *OpenGLRenderer) OnPerformRenderingStart()

func (*OpenGLRenderer) OnPrepare added in v0.2.0

func (r *OpenGLRenderer) OnPrepare()

func (*OpenGLRenderer) OnStop added in v0.2.0

func (r *OpenGLRenderer) OnStop()

type RectangleRenderer added in v0.2.0

type RectangleRenderer struct {
	// contains filtered or unexported fields
}

func (RectangleRenderer) OnRemovePrimitive added in v0.2.0

func (r RectangleRenderer) OnRemovePrimitive(ctx *rendering.PrimitiveRenderingContext)

func (*RectangleRenderer) OnRender added in v0.2.0

func (RectangleRenderer) OnSetPrimitive added in v0.2.0

func (r RectangleRenderer) OnSetPrimitive(ctx *rendering.PrimitiveRenderingContext)

func (*RectangleRenderer) OnStart added in v0.2.0

func (r *RectangleRenderer) OnStart()

func (RectangleRenderer) OnStop added in v0.2.0

func (r RectangleRenderer) OnStop()

type ResourceManager

type ResourceManager struct {
	// contains filtered or unexported fields
}

func (*ResourceManager) FullPathOf added in v0.1.1

func (r *ResourceManager) FullPathOf(id a.ResId) string

func (*ResourceManager) IdOf

func (r *ResourceManager) IdOf(path string) a.ResId

func (*ResourceManager) PathOf

func (r *ResourceManager) PathOf(id a.ResId) string

func (*ResourceManager) ReadFile

func (r *ResourceManager) ReadFile(id a.ResId) ([]byte, error)

func (*ResourceManager) RegisterResource

func (r *ResourceManager) RegisterResource(path string)

type TextRenderer added in v0.2.0

type TextRenderer struct {
	// contains filtered or unexported fields
}

func (TextRenderer) OnRemovePrimitive added in v0.2.0

func (r TextRenderer) OnRemovePrimitive(ctx *rendering.PrimitiveRenderingContext)

func (*TextRenderer) OnRender added in v0.2.0

func (TextRenderer) OnSetPrimitive added in v0.2.0

func (r TextRenderer) OnSetPrimitive(ctx *rendering.PrimitiveRenderingContext)

func (*TextRenderer) OnStart added in v0.2.0

func (r *TextRenderer) OnStart()

func (TextRenderer) OnStop added in v0.2.0

func (r TextRenderer) OnStop()

type TriangleRenderer added in v0.2.0

type TriangleRenderer struct {
	// contains filtered or unexported fields
}

func (TriangleRenderer) OnRemovePrimitive added in v0.2.0

func (r TriangleRenderer) OnRemovePrimitive(ctx *rendering.PrimitiveRenderingContext)

func (*TriangleRenderer) OnRender added in v0.2.0

func (TriangleRenderer) OnSetPrimitive added in v0.2.0

func (r TriangleRenderer) OnSetPrimitive(ctx *rendering.PrimitiveRenderingContext)

func (*TriangleRenderer) OnStart added in v0.2.0

func (r *TriangleRenderer) OnStart()

func (TriangleRenderer) OnStop added in v0.2.0

func (r TriangleRenderer) OnStop()

Jump to

Keyboard shortcuts

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