C# Класс Gravitation.CameraControls.Camera

Показать файл Открыть проект

Защищенные свойства (Protected)

Свойство Тип Описание
_cameraPosition Vector2
_cameraZoom Vector3
_screenCenter Vector2
_view Matrix
mapHeightInPixels float
mapWidthInPixels float
prizemBase Microsoft.Xna.Framework.Rectangle
prizemTip Vector3
screenHeight int
screenWidth int
xLeftC float
xLeftM float
xRightC float
xRightM float
yBottomC float
yBottomM float
yTopC float
yTopM float

Открытые методы

Метод Описание
Camera ( ) : System
initCamera ( GraphicsDeviceManager graphics, float leftWallPos, float rightWallPos, float topWallPos, float bottomWallPos, float mapWidth, float mapHeight ) : void
updateCamera ( Vector2 shipPos ) : void

Защищенные методы

Метод Описание
correctCameraPositionX ( float &cameraXPos, float cameraZoom ) : void
correctCameraPositionY ( float &cameraYPos, float cameraZoom ) : void

Приватные методы

Метод Описание
calculateGradient ( Vector2 point1, Vector2 point2 ) : float
calculateXIntercept ( Vector3 PointOnline, float gradient ) : float
calculateYIntercept ( Vector3 PointOnline, float gradient ) : float
getXForZoomLeft ( float zoom ) : float
getXForZoomRight ( float zoom ) : float
getYForZoomBottom ( float zoom ) : float
getYForZoomTop ( float zoom ) : float
initPrisemEdgeGradients ( ) : void
initYIntercepts ( ) : void
isXOutofBounds ( float &posX, float zoom ) : bool
isYOutofBounds ( float &posY, float zoom ) : bool

Описание методов

Camera() публичный Метод

public Camera ( ) : System
Результат System

correctCameraPositionX() защищенный Метод

protected correctCameraPositionX ( float &cameraXPos, float cameraZoom ) : void
cameraXPos float
cameraZoom float
Результат void

correctCameraPositionY() защищенный Метод

protected correctCameraPositionY ( float &cameraYPos, float cameraZoom ) : void
cameraYPos float
cameraZoom float
Результат void

initCamera() публичный Метод

public initCamera ( GraphicsDeviceManager graphics, float leftWallPos, float rightWallPos, float topWallPos, float bottomWallPos, float mapWidth, float mapHeight ) : void
graphics GraphicsDeviceManager
leftWallPos float
rightWallPos float
topWallPos float
bottomWallPos float
mapWidth float
mapHeight float
Результат void

updateCamera() публичный Метод

public updateCamera ( Vector2 shipPos ) : void
shipPos Vector2
Результат void

Описание свойств

_cameraPosition защищенное свойство

protected Vector2 _cameraPosition
Результат Vector2

_cameraZoom защищенное свойство

protected Vector3 _cameraZoom
Результат Vector3

_screenCenter защищенное свойство

protected Vector2 _screenCenter
Результат Vector2

_view защищенное свойство

protected Matrix _view
Результат Matrix

mapHeightInPixels защищенное свойство

protected float mapHeightInPixels
Результат float

mapWidthInPixels защищенное свойство

protected float mapWidthInPixels
Результат float

prizemBase защищенное свойство

protected Rectangle,Microsoft.Xna.Framework prizemBase
Результат Microsoft.Xna.Framework.Rectangle

prizemTip защищенное свойство

protected Vector3 prizemTip
Результат Vector3

screenHeight защищенное свойство

protected int screenHeight
Результат int

screenWidth защищенное свойство

protected int screenWidth
Результат int

xLeftC защищенное свойство

protected float xLeftC
Результат float

xLeftM защищенное свойство

protected float xLeftM
Результат float

xRightC защищенное свойство

protected float xRightC
Результат float

xRightM защищенное свойство

protected float xRightM
Результат float

yBottomC защищенное свойство

protected float yBottomC
Результат float

yBottomM защищенное свойство

protected float yBottomM
Результат float

yTopC защищенное свойство

protected float yTopC
Результат float

yTopM защищенное свойство

protected float yTopM
Результат float