インターフェイス IGraphicsEx
Namespace: GameCanvas
public interface IGraphicsEx : IGraphics継承元
プロパティ
BackgroundColor
継承元: IGraphics
Color BackgroundColor { get; set; }背景色
BorderColor
継承元: IGraphics
Color BorderColor { get; }キャンバス外に表示される帯の色
備考
ChangeBorderColor を呼び出すことで変更できます
CanvasAABB
GcAABB CanvasAABB { get; }キャンバスのAABB
CanvasCenter
float2 CanvasCenter { get; }キャンバスの中心座標
CanvasHeight
int CanvasHeight { get; }キャンバスの縦幅
CanvasResolution
GcResolution CanvasResolution { get; }キャンバスの解像度とリフレッシュレート
CanvasSize
継承元: IGraphics
int2 CanvasSize { get; }キャンバス解像度
備考
ChangeCanvasSize を呼び出すことで変更できます
CanvasWidth
int CanvasWidth { get; }キャンバスの横幅
CircleResolution
継承元: IGraphics
int CircleResolution { get; set; }円の解像度
Color
継承元: IGraphics
Color Color { get; set; }描画色
ColorAqua
Color ColorAqua { get; }水色
ColorBlack
Color ColorBlack { get; }黒色
ColorBlue
Color ColorBlue { get; }青色
ColorCyan
Color ColorCyan { get; }シアン
ColorGray
Color ColorGray { get; }灰色
ColorGreen
Color ColorGreen { get; }緑色
ColorPurple
Color ColorPurple { get; }紫色
ColorRed
Color ColorRed { get; }赤色
ColorWhite
Color ColorWhite { get; }白色
ColorYellow
Color ColorYellow { get; }黄色
CoordinateScope
継承元: IGraphics
CoordinateScope CoordinateScope { get; }PushCoordinate と PopCoordinate が自動的に呼び出されるスコープ
CornerRadius
継承元: IGraphics
float CornerRadius { get; set; }角丸の半径
CurrentCoordinate
継承元: IGraphics
float2x3 CurrentCoordinate { get; set; }現在の座標系(変換行列)
CurrentStyle
継承元: IGraphics
GcStyle CurrentStyle { get; set; }現在のスタイル
DeviceScreenHeight
int DeviceScreenHeight { get; }端末スクリーンの縦幅
DeviceScreenSize
継承元: IGraphics
int2 DeviceScreenSize { get; }端末スクリーン解像度
DeviceScreenWidth
int DeviceScreenWidth { get; }端末スクリーンの横幅
Font
継承元: IGraphics
GcFont Font { get; set; }フォント種別
FontSize
継承元: IGraphics
int FontSize { get; set; }フォントサイズ
LineCap
継承元: IGraphics
GcLineCap LineCap { get; set; }描線の端点の形状
LineWidth
継承元: IGraphics
float LineWidth { get; set; }描線の太さ
RectAnchor
継承元: IGraphics
GcAnchor RectAnchor { get; set; }矩形のアンカー位置
StringAnchor
継承元: IGraphics
GcAnchor StringAnchor { get; set; }文字列のアンカー位置
StyleScope
継承元: IGraphics
StyleScope StyleScope { get; }PushStyle と PopStyle が自動的に呼び出されるスコープ
メソッド
CalcStringHeight(string)
継承元: IGraphics
float CalcStringHeight(in string str)文字列の縦幅を計算します
パラメーター
str— 文字列
戻り値
縦幅
CalcStringSize(string)
継承元: IGraphics
float2 CalcStringSize(in string str)文字列のサイズを計算します
パラメーター
str— 文字列
戻り値
サイズ
CalcStringWidth(string)
継承元: IGraphics
float CalcStringWidth(in string str)文字列の横幅を計算します
パラメーター
str— 文字列
戻り値
横幅
CanvasToScreenPoint(float2, float2)
継承元: IGraphics
void CanvasToScreenPoint(in float2 canvas, out float2 screen)キャンバス座標を端末スクリーン座標に変換します
パラメーター
canvas— 変換元 キャンバス座標screen— 変換後 端末スクリーン座標
CanvasToScreenPoint(float2, int2)
継承元: IGraphics
void CanvasToScreenPoint(in float2 canvas, out int2 screen)キャンバス座標を端末スクリーン座標に変換します
パラメーター
canvas— 変換元 キャンバス座標screen— 変換後 端末スクリーン座標
ChangeBorderColor(Color)
継承元: IGraphics
void ChangeBorderColor(in Color color)キャンバス外の帯の色を変更します
備考
既存キャンバスの描画内容は全て破棄されます
パラメーター
color— 新しい帯の色
ChangeBorderColor(float, float, float)
void ChangeBorderColor(in float r, in float g, in float b)帯の色を変更します
パラメーター
r— 帯の色の赤成分g— 帯の色の緑成分b— 帯の色の青成分
ChangeCanvasSize(int, int)
void ChangeCanvasSize(in int width, in int height)キャンバス解像度を指定します
備考
- 初期値は 720x1280 です
- ディスプレイ解像度と縦横比が異なる場合は、上下もしくは左右に帯がつきます
パラメーター
width— 横幅height— 縦幅
ChangeCanvasSize(int2)
継承元: IGraphics
void ChangeCanvasSize(in int2 size)キャンバス解像度を変更します
備考
- 初期値は 720x1280 です
- ディスプレイ解像度と縦横比が異なる場合は、上下もしくは左右に帯がつきます
- 既存キャンバスの描画内容は全て破棄されます
パラメーター
size— 新しいキャンバス解像度
ClearCoordinate()
継承元: IGraphics
void ClearCoordinate()CurrentCoordinate をリセットします
ClearScreen()
継承元: IGraphics
void ClearScreen()キャンバスを BackgroundColor で塗りつぶします
ClearStyle()
継承元: IGraphics
void ClearStyle()CurrentStyle をリセットします
DrawCircle()
継承元: IGraphics
void DrawCircle()中抜きの円を描画します
DrawCircle(float, float, float)
void DrawCircle(in float x, in float y, in float radius)円を線で描画します
パラメーター
x— 中心のX座標y— 中心のY座標radius— 半径
DrawCircle(float2, float)
void DrawCircle(in float2 position, in float radius)円を線で描画します
パラメーター
position— 中心の座標radius— 半径
DrawCircle(GcCircle)
継承元: IGraphics
void DrawCircle(in GcCircle circle)中抜きの円を描画します
パラメーター
circle— 円
DrawImage(GcImage, float, float, float, float, float)
void DrawImage(in GcImage image, in float x, in float y, in float width, in float height, float degree = 0f)画像を拡縮して描画します
パラメーター
image— 描画する画像x— X座標y— Y座標width— 横幅。画像の横幅がこれになるように拡縮されるheight— 縦幅。画像の縦幅がこれになるように拡縮されるdegree— 回転(度数法)
DrawImage(GcImage, float, float, float)
void DrawImage(in GcImage image, in float x, in float y, float degree = 0f)画像を描画します
パラメーター
image— 描画する画像x— X座標y— Y座標degree— 回転(度数法)
DrawImage(GcImage, float2, float)
継承元: IGraphics
void DrawImage(in GcImage image, in float2 position, float degree = 0f)画像を描画します
パラメーター
image— 描画する画像position— 位置degree— 回転(度数法)
DrawImage(GcImage, GcRect)
継承元: IGraphics
void DrawImage(in GcImage image, in GcRect rect)画像を拡縮して描画します
パラメーター
image— 描画する画像rect— 画像をフィッティングする矩形領域
DrawImage(GcImage)
継承元: IGraphics
void DrawImage(in GcImage image)画像を描画します
パラメーター
image— 描画する画像
DrawLine()
継承元: IGraphics
void DrawLine()線を描画します
DrawLine(float, float, float, float)
void DrawLine(in float x0, in float y0, in float x1, in float y1)線を描画します
パラメーター
x0— 始点のX座標y0— 始点のY座標x1— 終点のX座標y1— 終点のY座標
DrawLine(float2, float2)
void DrawLine(in float2 begin, in float2 end)線を描画します
パラメーター
begin— 始点end— 終点
DrawLine(GcLine)
継承元: IGraphics
void DrawLine(in GcLine line)線を描画します
パラメーター
line— 線
DrawRect()
継承元: IGraphics
void DrawRect()矩形を線で描画します
DrawRect(float, float, float, float, float)
void DrawRect(in float x, in float y, in float width, in float height, float degree = 0f)矩形を線で描画します
パラメーター
x— X座標y— Y座標width— 横幅height— 縦幅degree— 回転(度数法)
DrawRect(float2, float2, float)
void DrawRect(in float2 position, in float2 size, float degree = 0f)矩形を線で描画します
パラメーター
position— 位置size— 大きさdegree— 回転(度数法)
DrawRect(GcRect)
継承元: IGraphics
void DrawRect(in GcRect rect)矩形を線で描画します
パラメーター
rect— 矩形
DrawRoundedRect()
継承元: IGraphics
void DrawRoundedRect()角丸矩形を線で描画します
DrawRoundedRect(float, float, float, float, float, float)
void DrawRoundedRect(in float x, in float y, in float width, in float height, float cornerRadius, float degree = 0f)角丸矩形を線で描画します
パラメーター
x— X座標y— Y座標width— 横幅height— 縦幅cornerRadius— 角丸の半径degree— 回転(度数法)
DrawRoundedRect(float, float, float, float, float)
void DrawRoundedRect(in float x, in float y, in float width, in float height, float degree = 0f)角丸矩形を線で描画します
パラメーター
x— X座標y— Y座標width— 横幅height— 縦幅degree— 回転(度数法)
DrawRoundedRect(float2, float2, float, float)
void DrawRoundedRect(in float2 position, in float2 size, float cornerRadius, float degree = 0f)角丸矩形を線で描画します
パラメーター
position— 位置size— 大きさcornerRadius— 角丸の半径degree— 回転(度数法)
DrawRoundedRect(float2, float2, float)
void DrawRoundedRect(in float2 position, in float2 size, float degree = 0f)角丸矩形を線で描画します
パラメーター
position— 位置size— 大きさdegree— 回転(度数法)
DrawRoundedRect(GcRect, float)
継承元: IGraphics
void DrawRoundedRect(in GcRect rect, float cornerRadius)角丸矩形を線で描画します
パラメーター
rect— 二等辺三角形が収まる矩形cornerRadius— 角丸の半径
DrawRoundedRect(GcRect)
継承元: IGraphics
void DrawRoundedRect(in GcRect rect)角丸矩形を線で描画します
パラメーター
rect— 二等辺三角形が収まる矩形
DrawString(string, float, float, float, float, float)
void DrawString(in string str, in float x, in float y, in float width, in float height, float degree = 0f)文字列を拡縮して描画します
パラメーター
str— 描画する文字列x— X座標y— Y座標width— 横幅。文字列の横幅がこれになるように拡縮されるheight— 縦幅。文字列の縦幅がこれになるように拡縮されるdegree— 回転(度数法)
DrawString(string, float, float, float)
void DrawString(in string str, in float x, in float y, float degree = 0f)文字列を描画します
パラメーター
str— 描画する文字列x— X座標y— Y座標degree— 回転(度数法)
DrawString(string, float2, float)
継承元: IGraphics
void DrawString(in string str, in float2 position, float degree = 0f)文字列を描画します
パラメーター
str— 描画する文字列position— 位置degree— 回転(度数法)
DrawString(string, GcRect)
継承元: IGraphics
void DrawString(in string str, in GcRect rect)文字列を拡縮して描画します
パラメーター
str— 描画する文字列rect— 文字列をフィッティングする矩形領域
DrawString(string)
継承元: IGraphics
void DrawString(in string str)文字列を描画します
パラメーター
str— 描画する文字列
DrawTexture(Texture, float, float, float, float, float)
void DrawTexture(in Texture texture, in float x, in float y, in float width, in float height, float degree = 0f)テクスチャーを拡縮して描画します
パラメーター
texture— 描画するテクスチャーx— X座標y— Y座標width— 横幅。画像の横幅がこれになるように拡縮されるheight— 縦幅。画像の縦幅がこれになるように拡縮されるdegree— 回転(度数法)
DrawTexture(Texture, float2, float)
継承元: IGraphics
void DrawTexture(in Texture texture, in float2 position, float degree = 0f)テクスチャーを描画します
パラメーター
texture— 描画するテクスチャーposition— 位置degree— 回転(度数法)
DrawTexture(Texture, float2x3)
継承元: IGraphics
void DrawTexture(in Texture texture, in float2x3 matrix)テクスチャーを変形して描画します
パラメーター
texture— 描画するテクスチャーmatrix— アフィン変換行列
DrawTexture(Texture, GcRect)
継承元: IGraphics
void DrawTexture(in Texture texture, in GcRect rect)テクスチャーを拡縮して描画します
パラメーター
texture— 描画するテクスチャーrect— テクスチャーをフィッティングする矩形領域
DrawTexture(Texture)
継承元: IGraphics
void DrawTexture(in Texture texture)テクスチャーを描画します
パラメーター
texture— 描画するテクスチャー
FillCircle()
継承元: IGraphics
void FillCircle()円を塗りで描画します
FillCircle(float, float, float)
void FillCircle(in float x, in float y, in float radius)円を塗りで描画します
パラメーター
x— 中心のX座標y— 中心のY座標radius— 半径
FillCircle(float2, float)
void FillCircle(in float2 position, in float radius)円を塗りで描画します
パラメーター
position— 中心の座標radius— 半径
FillCircle(GcCircle)
継承元: IGraphics
void FillCircle(in GcCircle circle)円を塗りで描画します
パラメーター
circle— 円
FillRect()
継承元: IGraphics
void FillRect()矩形を塗りで描画します
FillRect(float, float, float, float, float)
void FillRect(in float x, in float y, in float width, in float height, float degree = 0f)矩形を塗りで描画します
パラメーター
x— X座標y— Y座標width— 横幅height— 縦幅degree— 回転(度数法)
FillRect(float2, float2, float)
void FillRect(in float2 position, in float2 size, float degree = 0f)矩形を塗りで描画します
パラメーター
position— 位置size— 大きさdegree— 回転(度数法)
FillRect(GcRect)
継承元: IGraphics
void FillRect(in GcRect rect)矩形を塗りで描画します
パラメーター
rect— 矩形
FillRoundedRect()
継承元: IGraphics
void FillRoundedRect()角丸矩形を塗りで描画します
FillRoundedRect(float, float, float, float, float, float)
void FillRoundedRect(in float x, in float y, in float width, in float height, float cornerRadius, float degree = 0f)角丸矩形を塗りで描画します
パラメーター
x— X座標y— Y座標width— 横幅height— 縦幅cornerRadius— 角丸の半径degree— 回転(度数法)
FillRoundedRect(float, float, float, float, float)
void FillRoundedRect(in float x, in float y, in float width, in float height, float degree = 0f)角丸矩形を塗りで描画します
パラメーター
x— X座標y— Y座標width— 横幅height— 縦幅degree— 回転(度数法)
FillRoundedRect(float2, float2, float, float)
void FillRoundedRect(in float2 position, in float2 size, float cornerRadius, float degree = 0f)角丸矩形を塗りで描画します
パラメーター
position— 位置size— 大きさcornerRadius— 角丸の半径degree— 回転(度数法)
FillRoundedRect(float2, float2, float)
void FillRoundedRect(in float2 position, in float2 size, float degree = 0f)角丸矩形を塗りで描画します
パラメーター
position— 位置size— 大きさdegree— 回転(度数法)
FillRoundedRect(GcRect, float)
継承元: IGraphics
void FillRoundedRect(in GcRect rect, float cornerRadius)角丸矩形を塗りで描画します
パラメーター
rect— 二等辺三角形が収まる矩形cornerRadius— 角丸の半径
FillRoundedRect(GcRect)
継承元: IGraphics
void FillRoundedRect(in GcRect rect)角丸矩形を塗りで描画します
パラメーター
rect— 二等辺三角形が収まる矩形
GetImageHeight(GcImage)
int GetImageHeight(in GcImage image)画像の縦幅を取得します
パラメーター
image— 画像
戻り値
縦幅
GetImageSize(GcImage)
int2 GetImageSize(in GcImage image)画像のサイズを取得します
パラメーター
image— 画像
戻り値
サイズ
GetImageWidth(GcImage)
int GetImageWidth(in GcImage image)画像の横幅を取得します
パラメーター
image— 画像
戻り値
横幅
PopCoordinate()
継承元: IGraphics
void PopCoordinate()スタックから座標系(変換行列)を取り出し CurrentCoordinate に上書きします
PopStyle()
継承元: IGraphics
void PopStyle()スタックから描画スタイルを取り出し CurrentStyle に上書きします
PushCoordinate()
継承元: IGraphics
void PushCoordinate()CurrentCoordinate をスタックに保存します
PushStyle()
継承元: IGraphics
void PushStyle()CurrentStyle をスタックに保存します
RebuildFontTexture()
継承元: IGraphics
void RebuildFontTexture()フォントテクスチャ―を再生成します
備考
- テキスト描画が乱れた場合にのみ呼び出すことを想定しています
- 実際に再生成が行われるのは、この関数を呼び出した次のフレームの冒頭です
RotateCoordinate(float, float, float)
void RotateCoordinate(in float degree, in float originX, in float originY)座標系(変換行列)を回転させます
パラメーター
degree— 回転量(度数法)originX— 回転中心のX座標originY— 回転中心のY座標
RotateCoordinate(float, float2)
継承元: IGraphics
void RotateCoordinate(in float degree, in float2 origin)座標系(変換行列)を指定した座標を中心に回転させます
パラメーター
degree— 回転量(度数法)origin— 回転中心
RotateCoordinate(float)
継承元: IGraphics
void RotateCoordinate(in float degree)座標系(変換行列)を回転させます
パラメーター
degree— 回転量(度数法)
ScaleCoordinate(float, float)
void ScaleCoordinate(in float sx, in float sy)座標系(変換行列)を拡縮させます
パラメーター
sx— X軸方向の拡縮率sy— Y軸方向の拡縮率
ScaleCoordinate(float2)
継承元: IGraphics
void ScaleCoordinate(in float2 scaling)座標系(変換行列)を拡縮させます
パラメーター
scaling— 拡縮率
ScreenToCanvasPoint(float2, float2)
継承元: IGraphics
void ScreenToCanvasPoint(in float2 screen, out float2 canvas)端末スクリーン座標をキャンバス座標に変換します
パラメーター
screen— 変換元 端末スクリーン座標canvas— 変換後 キャンバス座標
ScreenToCanvasPoint(float2, int2)
継承元: IGraphics
void ScreenToCanvasPoint(in float2 screen, out int2 canvas)端末スクリーン座標をキャンバス座標に変換します
パラメーター
screen— 変換元 端末スクリーン座標canvas— 変換後 キャンバス座標
SetBackgroundColor(Color)
void SetBackgroundColor(in Color color)背景色を指定します
パラメーター
color— 背景色
SetBackgroundColor(float, float, float)
void SetBackgroundColor(in float r, in float g, in float b)背景色を指定します
パラメーター
r— 背景色の赤成分g— 背景色の緑成分b— 背景色の青成分
SetColor(byte, byte, byte, byte)
void SetColor(in byte r, in byte g, in byte b, byte a = 255)描画色を指定します
パラメーター
r— 描画色の赤成分g— 描画色の緑成分b— 描画色の青成分a— 描画色の不透明度
SetColor(Color, float)
void SetColor(in Color color, in float alpha)描画色を指定します
パラメーター
color— 描画色alpha— 描画色の不透明度
SetColor(Color)
void SetColor(in Color color)描画色を指定します
パラメーター
color— 描画色
SetColor(float, float, float, float)
void SetColor(in float r, in float g, in float b, float a = 1f)描画色を指定します
パラメーター
r— 描画色の赤成分g— 描画色の緑成分b— 描画色の青成分a— 描画色の不透明度
SetCoordinate(float2x3)
void SetCoordinate(in float2x3 matrix)座標系(変換行列)を指定します
パラメーター
matrix— 座標系(変換行列)
SetFont(GcFont)
void SetFont(in GcFont font)フォントを指定します
パラメーター
font— フォント
SetFontSize(int)
void SetFontSize(in int fontSize)フォントサイズを指定します
パラメーター
fontSize— フォントサイズ
SetLineCap(GcLineCap)
void SetLineCap(in GcLineCap lineCap)描線の端点の形状を指定します
パラメーター
lineCap— 描線の端点の形状
SetLineWidth(float)
void SetLineWidth(in float lineWidth)描線の太さを指定します
パラメーター
lineWidth— 描線の太さ
SetRectAnchor(GcAnchor)
void SetRectAnchor(in GcAnchor anchor)矩形や画像のアンカー位置を指定します
パラメーター
anchor— アンカー位置
SetStringAnchor(GcAnchor)
void SetStringAnchor(in GcAnchor anchor)文字列のアンカー位置を指定します
パラメーター
anchor— アンカー位置
SetStyle(GcStyle)
void SetStyle(in GcStyle style)スタイルを指定します
パラメーター
style—
TranslateCoordinate(float, float)
void TranslateCoordinate(in float tx, in float ty)座標系(変換行列)を平行移動させます
パラメーター
tx— X軸方向の移動量ty— Y軸方向の移動量
TranslateCoordinate(float2)
継承元: IGraphics
void TranslateCoordinate(in float2 translation)座標系(変換行列)を平行移動させます
パラメーター
translation— 移動量
