Skip to content

クラス GcProxy

Namespace: GameCanvas

csharp
public sealed class GcProxy : IGameCanvas

ユーザー定義クラスからGameCanvasの機能を呼び出すためのクラス

継承元

プロパティ

AccelerationEventCount

csharp
public int AccelerationEventCount { get; }

前回のフレーム処理以降に検出した 加速度イベントの数

AccelerationEvents

csharp
public System.ReadOnlySpan<GcAccelerationEvent> AccelerationEvents { get; }

前回のフレーム処理以降に検出した 加速度イベントの列挙子

AccelerometerSamplingRate

csharp
public float AccelerometerSamplingRate { get; set; }

加速度計の動作周波数

BackgroundColor

csharp
public Color BackgroundColor { get; set; }

背景色

BorderColor

csharp
public Color BorderColor { get; }

キャンバス外に表示される帯の色

備考

ChangeBorderColor を呼び出すことで変更できます

CameraDeviceCount

csharp
public int CameraDeviceCount { get; }

認識可能なカメラ(外部入力映像)の数

CameraDevices

csharp
public System.ReadOnlySpan<GcCameraDevice> CameraDevices { get; }

全ての認識可能なカメラ(外部入力映像)の一覧

CanvasAABB

csharp
public GcAABB CanvasAABB { get; }

キャンバスのAABB

CanvasCenter

csharp
public float2 CanvasCenter { get; }

キャンバスの中心座標

CanvasHeight

csharp
public int CanvasHeight { get; }

キャンバスの縦幅

CanvasResolution

csharp
public GcResolution CanvasResolution { get; }

キャンバスの解像度とリフレッシュレート

CanvasSize

csharp
public int2 CanvasSize { get; }

キャンバス解像度

備考

ChangeCanvasSize を呼び出すことで変更できます

CanvasWidth

csharp
public int CanvasWidth { get; }

キャンバスの横幅

CircleResolution

csharp
public int CircleResolution { get; set; }

円の解像度

Color

csharp
public Color Color { get; set; }

描画色

ColorAqua

csharp
public Color ColorAqua { get; }

水色

ColorBlack

csharp
public Color ColorBlack { get; }

黒色

ColorBlue

csharp
public Color ColorBlue { get; }

青色

ColorCyan

csharp
public Color ColorCyan { get; }

シアン

ColorGray

csharp
public Color ColorGray { get; }

灰色

ColorGreen

csharp
public Color ColorGreen { get; }

緑色

ColorPurple

csharp
public Color ColorPurple { get; }

紫色

ColorRed

csharp
public Color ColorRed { get; }

赤色

ColorWhite

csharp
public Color ColorWhite { get; }

白色

ColorYellow

csharp
public Color ColorYellow { get; }

黄色

CoordinateScope

csharp
public CoordinateScope CoordinateScope { get; }

PushCoordinatePopCoordinate が自動的に呼び出されるスコープ

CornerRadius

csharp
public float CornerRadius { get; set; }

角丸の半径

CurrentCoordinate

csharp
public float2x3 CurrentCoordinate { get; set; }

現在の座標系(変換行列)

CurrentFrame

csharp
public int CurrentFrame { get; }

アプリ起動からの累計フレーム数

CurrentStyle

csharp
public GcStyle CurrentStyle { get; set; }

現在のスタイル

CurrentTime

csharp
public System.DateTimeOffset CurrentTime { get; }

現在フレームの日時

CurrentTimeDay

csharp
public int CurrentTimeDay { get; }

現在フレームの日付(1~31)

CurrentTimeDayOfWeek

csharp
public System.DayOfWeek CurrentTimeDayOfWeek { get; }

現在フレームの曜日(0~6)

CurrentTimeHour

csharp
public int CurrentTimeHour { get; }

現在フレームの時刻の時間部分(0~23)

CurrentTimeMillisecond

csharp
public int CurrentTimeMillisecond { get; }

現在フレームの時刻のミリ秒部分(0~999)

CurrentTimeMinute

csharp
public int CurrentTimeMinute { get; }

現在フレームの時刻の分部分(0~59)

CurrentTimeMonth

csharp
public int CurrentTimeMonth { get; }

現在フレームの日付の月部分(1~12)

CurrentTimeSecond

csharp
public int CurrentTimeSecond { get; }

現在フレームの時刻の秒部分(0~59)

CurrentTimestamp

csharp
public long CurrentTimestamp { get; }

現在フレームのUnixタイムスタンプ

CurrentTimeYear

csharp
public int CurrentTimeYear { get; }

現在フレームの日付の西暦部分

DeviceScreenHeight

csharp
public int DeviceScreenHeight { get; }

端末スクリーンの縦幅

DeviceScreenSize

csharp
public int2 DeviceScreenSize { get; }

端末スクリーン解像度

DeviceScreenWidth

csharp
public int DeviceScreenWidth { get; }

端末スクリーンの横幅

DidUpdateAccelerationThisFrame

csharp
public bool DidUpdateAccelerationThisFrame { get; }

前回のフレーム処理以降に 加速度イベントの更新があったかどうか

DidUpdateGeolocationThisFrame

csharp
public bool DidUpdateGeolocationThisFrame { get; }

前回のフレーム処理以降に 位置情報イベントの更新があったかどうか

Font

csharp
public GcFont Font { get; set; }

フォント種別

FontSize

csharp
public int FontSize { get; set; }

フォントサイズ

GeolocationStatus

継承元: IInputGeolocation

csharp
LocationServiceStatus GeolocationStatus { get; }

位置情報サービスの状態

HasUserAuthorizedPermissionCamera

csharp
public bool HasUserAuthorizedPermissionCamera { get; }

カメラデバイスへのアクセス権限を取得済みかどうか

HasUserAuthorizedPermissionGeolocation

csharp
public bool HasUserAuthorizedPermissionGeolocation { get; }

位置情報へのアクセス権限を取得済みかどうか

IsAccelerometerEnabled

csharp
public bool IsAccelerometerEnabled { get; set; }

加速度計が現在有効かどうか

IsAccelerometerSupported

csharp
public bool IsAccelerometerSupported { get; }

端末が加速度計を搭載しているかどうか

IsAnyKey

csharp
public bool IsAnyKey { get; }

なんらかのキーイベントがあるかどうか

IsAnyKeyDown

csharp
public bool IsAnyKeyDown { get; }

いずれかのキーが押されたかどうか

IsAnyKeyHold

csharp
public bool IsAnyKeyHold { get; }

いずれかのキーが押されているかどうか(押された瞬間を除く)

IsAnyKeyPress

csharp
public bool IsAnyKeyPress { get; }

いずれかのキーが押されているかどうか(押された瞬間を含む)

IsAnyKeyUp

csharp
public bool IsAnyKeyUp { get; }

いずれかのキーが離されたかどうか

IsGeolocationRunning

csharp
public bool IsGeolocationRunning { get; }

位置情報サービスが起動しているかどうか(起動中を含む)

IsScreenKeyboardSupported

csharp
public bool IsScreenKeyboardSupported { get; }

スクリーンキーボードがサポートされているかどうか

IsScreenKeyboardVisible

csharp
public bool IsScreenKeyboardVisible { get; }

スクリーンキーボードが表示されているかどうか

IsTouchPressureSupported

csharp
public bool IsTouchPressureSupported { get; }

実行端末でタッチ圧力がサポートされているかどうか

IsTouchSupported

csharp
public bool IsTouchSupported { get; }

実行端末でタッチ操作がサポートされているかどうか

備考

Windowsエディタ環境では、タッチ対応デバイスであっても常に偽を返します

KeyDownCount

csharp
public int KeyDownCount { get; }

前回のフレーム処理以降に 押されたキーの数

KeyEscape

csharp
public Key KeyEscape { get; }

戻るボタン(Androidのみ)

KeyHoldCount

csharp
public int KeyHoldCount { get; }

前回のフレームに引き続き 押されているキーの数(押された瞬間を除く)

KeyPressCount

csharp
public int KeyPressCount { get; }

前回のフレームに引き続き 押されているキーの数(押された瞬間を含む)

KeyUpCount

csharp
public int KeyUpCount { get; }

前回のフレーム処理以降に 離されたキーの数

LastAccelerationEvent

csharp
public GcAccelerationEvent LastAccelerationEvent { get; }

最後に検出した加速度イベント

LastGeolocationEvent

csharp
public GcGeolocationEvent LastGeolocationEvent { get; }

最後に取得した位置情報イベント

LastPointerEvent

csharp
public GcPointerEvent LastPointerEvent { get; }

最後に検出したポインターイベント。過去のフレームも含める

LastPointerFrame

csharp
public int LastPointerFrame { get; }

最後に検出したポインターイベントの 検出フレーム番号

LastPointerPoint

csharp
public float2 LastPointerPoint { get; }

最後に検出したポインターイベントの位置

LastPointerTime

csharp
public float LastPointerTime { get; }

最後に検出したポインターイベントの 検出時間(起動からの経過秒数)

LastPointerX

csharp
public float LastPointerX { get; }

最後に検出したポインターイベントの X座標

LastPointerY

csharp
public float LastPointerY { get; }

最後に検出したポインターイベントの Y座標

LineCap

csharp
public GcLineCap LineCap { get; set; }

描線の端点の形状

LineWidth

csharp
public float LineWidth { get; set; }

描線の太さ

NowTime

csharp
public System.DateTimeOffset NowTime { get; }

現在(関数呼び出し時点)の日時

PointerBeginCount

csharp
public int PointerBeginCount { get; }

前回のフレーム処理以降に検出した ポインター開始イベントの数

PointerCount

csharp
public int PointerCount { get; }

前回のフレーム処理以降に検出した ポインターイベントの数

PointerEndCount

csharp
public int PointerEndCount { get; }

前回のフレーム処理以降に検出した ポインター終了イベントの数

PointerTapCount

csharp
public int PointerTapCount { get; }

前回のフレーム処理以降に検出した タップポイントの数

RectAnchor

csharp
public GcAnchor RectAnchor { get; set; }

矩形のアンカー位置

StringAnchor

csharp
public GcAnchor StringAnchor { get; set; }

文字列のアンカー位置

StyleScope

csharp
public StyleScope StyleScope { get; }

PushStylePopStyle が自動的に呼び出されるスコープ

TapSettings

csharp
public GcTapSettings TapSettings { get; set; }

タップ感度の設定

TargetFrameInterval

csharp
public double TargetFrameInterval { get; }

フレーム更新間隔の目標値(秒)

TargetFrameRate

csharp
public int TargetFrameRate { get; }

フレームレート(1秒あたりのフレーム数)の目標値

TimeSincePrevFrame

csharp
public float TimeSincePrevFrame { get; }

ひとつ前のフレームからの経過時間(秒)

TimeSinceStartup

csharp
public float TimeSinceStartup { get; }

現在フレームのアプリ起動からの経過時間(秒)

VSyncEnabled

csharp
public bool VSyncEnabled { get; }

垂直同期の有無

備考

この設定は、SetFrameIntervalSetFrameRate の第二引数から変更できます。

メソッド

Abs(float)

csharp
public float Abs(in float value)

絶対値を計算します

パラメーター

  • value — 入力値

戻り値

絶対値

Abs(int)

csharp
public int Abs(in int value)

絶対値を計算します

パラメーター

  • value — 入力値

戻り値

絶対値

AddActor(GcActor)

csharp
public void AddActor(in GcActor actor)

指定したアクターをシーンに登録します

パラメーター

  • actor — 登録するアクター

AlmostSame(float, float)

csharp
public bool AlmostSame(in float a, in float b)

計算誤差を考慮して同値かどうか判定します

戻り値

同値かどうか

AlmostZero(float)

csharp
public bool AlmostZero(in float value)

計算誤差を考慮してゼロかどうか判定します

パラメーター

  • value — 入力値

戻り値

ゼロかどうか

Atan2(float, float)

csharp
public float Atan2(in float x, in float y)

ベクトルとX+軸平面のなす角度を計算します

パラメーター

  • x — ベクトルのX軸の大きさ
  • y — ベクトルのY軸の大きさ

戻り値

角度(度数法)

Atan2(float2)

csharp
public float Atan2(in float2 v)

ベクトルとX+軸平面のなす角度を計算します

パラメーター

  • v — ベクトル

戻り値

角度(度数法)

CalcStringHeight(string)

csharp
public float CalcStringHeight(in string str)

文字列の縦幅を計算します

パラメーター

  • str — 文字列

戻り値

縦幅

CalcStringSize(string)

csharp
public float2 CalcStringSize(in string str)

文字列のサイズを計算します

パラメーター

  • str — 文字列

戻り値

サイズ

CalcStringWidth(string)

csharp
public float CalcStringWidth(in string str)

文字列の横幅を計算します

パラメーター

  • str — 文字列

戻り値

横幅

CanvasToScreenPoint(float2, float2)

csharp
public void CanvasToScreenPoint(in float2 canvas, out float2 screen)

キャンバス座標を端末スクリーン座標に変換します

パラメーター

  • canvas — 変換元 キャンバス座標
  • screen — 変換後 端末スクリーン座標

CanvasToScreenPoint(float2, int2)

csharp
public void CanvasToScreenPoint(in float2 canvas, out int2 screen)

キャンバス座標を端末スクリーン座標に変換します

パラメーター

  • canvas — 変換元 キャンバス座標
  • screen — 変換後 端末スクリーン座標

ChangeBorderColor(Color)

csharp
public void ChangeBorderColor(in Color color)

キャンバス外の帯の色を変更します

備考

既存キャンバスの描画内容は全て破棄されます

パラメーター

  • color — 新しい帯の色

ChangeBorderColor(float, float, float)

csharp
public void ChangeBorderColor(in float r, in float g, in float b)

帯の色を変更します

パラメーター

  • r — 帯の色の赤成分
  • g — 帯の色の緑成分
  • b — 帯の色の青成分

ChangeCanvasSize(int, int)

csharp
public void ChangeCanvasSize(in int width, in int height)

キャンバス解像度を指定します

備考

  • 初期値は 720x1280 です
  • ディスプレイ解像度と縦横比が異なる場合は、上下もしくは左右に帯がつきます

パラメーター

  • width — 横幅
  • height — 縦幅

ChangeCanvasSize(int2)

csharp
public void ChangeCanvasSize(in int2 size)

キャンバス解像度を変更します

備考

  • 初期値は 720x1280 です
  • ディスプレイ解像度と縦横比が異なる場合は、上下もしくは左右に帯がつきます
  • 既存キャンバスの描画内容は全て破棄されます

パラメーター

  • size — 新しいキャンバス解像度

ChangeScene<T>(object?)

csharp
public void ChangeScene<T>(object? state = null) where T : GcScene

シーンを切り替えます

備考

  • これまで有効だったシーンは、現在のフレームの最後に終了処理が実行されます
  • これから有効になるシーンは、次のフレームの最初に開始処理が実行されます

型パラメーター

  • T — 開始するシーンの型

パラメーター

  • state — シーンの開始処理 (IScene.EnterScene) に引数として渡す任意の値

Clamp(float, float, float)

csharp
public float Clamp(in float value, in float min, in float max)

値を丸めます

パラメーター

  • value — 入力値
  • min — 最小値
  • max — 最大値

ClearCoordinate()

csharp
public void ClearCoordinate()

CurrentCoordinate をリセットします

ClearDownloadCache(string)

csharp
public void ClearDownloadCache(in string url)

指定されたオンラインリソースのダウンロードキャッシュを削除します

パラメーター

  • url — リソースURL

ClearDownloadCacheAll()

csharp
public void ClearDownloadCacheAll()

全てのオンラインリソースのダウンロードキャッシュを削除します

ClearScreen()

csharp
public void ClearScreen()

ClearSound()

csharp
public void ClearSound()

すべてのサウンド再生を停止し、トラック音量を初期値に戻します

ClearStyle()

csharp
public void ClearStyle()

CurrentStyle をリセットします

Cos(float)

csharp
public float Cos(in float degree)

コサインを計算します

パラメーター

  • degree — 角度(度数法)

戻り値

コサイン

CreateActor<T>()

csharp
public T CreateActor<T>() where T : GcActor, new()

指定したアクターを生成し、シーンに登録します

型パラメーター

  • T — 生成・登録するアクターの型

戻り値

登録したアクター

Cross(float2, float2)

csharp
public float Cross(in float2 a, in float2 b)

ベクトルの外積を計算します

戻り値

外積

CrossTest(GcLine, GcLine, float2)

csharp
public bool CrossTest(in GcLine a, in GcLine b, out float2 intersection)

GcLineGcLine の交差判定

CrossTest(GcLine, GcLine)

csharp
public bool CrossTest(in GcLine a, in GcLine b)

GcLineGcLine の交差判定

DidUpdateCameraImageThisFrame(GcCameraDevice)

csharp
public bool DidUpdateCameraImageThisFrame(in GcCameraDevice camera)

前回のフレーム処理以降に 指定されたカメラ(外部入力映像)テクスチャーに更新があったかどうか

パラメーター

  • camera — カメラ(外部入力映像)

戻り値

テクスチャーに更新があったかどうか

Dot(float2, float2)

csharp
public float Dot(in float2 a, in float2 b)

ベクトルの内積を計算します

戻り値

内積

DrawCameraImage(GcCameraDevice, bool)

csharp
public void DrawCameraImage(in GcCameraDevice camera, bool autoPlay = true)

カメラ(外部入力映像)を描画します

パラメーター

  • camera — カメラ(外部入力映像)
  • autoPlay — カメラ(外部入力映像)が停止していた場合、内部でPlayCameraImageを呼び出すかどうか

DrawCameraImage(GcCameraDevice, float, float, float, bool)

csharp
public void DrawCameraImage(in GcCameraDevice camera, in float x, in float y, float degree = 0, bool autoPlay = true)

カメラ(外部入力映像)を描画します

パラメーター

  • camera — カメラ(外部入力映像)
  • x — X座標
  • y — Y座標
  • degree — 回転(度数法)
  • autoPlay — カメラ(外部入力映像)が停止していた場合、内部でPlayCameraImageを呼び出すかどうか

DrawCameraImage(GcCameraDevice, float, float, float, float, float, bool)

csharp
public void DrawCameraImage(in GcCameraDevice camera, in float x, in float y, in float width, in float height, float degree = 0f, bool autoPlay = true)

カメラ(外部入力映像)を拡縮して描画します

パラメーター

  • camera — カメラ(外部入力映像)
  • x — X座標
  • y — Y座標
  • width — 横幅。映像の横幅がこれになるように拡縮される
  • height — 縦幅。映像の縦幅がこれになるように拡縮される
  • degree — 回転(度数法)
  • autoPlay — カメラ(外部入力映像)が停止していた場合、内部でPlayCameraImageを呼び出すかどうか

DrawCameraImage(GcCameraDevice, float2, float, bool)

csharp
public void DrawCameraImage(in GcCameraDevice camera, in float2 position, float degree = 0, bool autoPlay = true)

カメラ(外部入力映像)を描画します

パラメーター

  • camera — カメラ(外部入力映像)
  • position — 位置
  • degree — 回転(度数法)
  • autoPlay — カメラ(外部入力映像)が停止していた場合、内部でPlayCameraImageを呼び出すかどうか

DrawCameraImage(GcCameraDevice, GcRect, bool)

csharp
public void DrawCameraImage(in GcCameraDevice camera, in GcRect rect, bool autoPlay = true)

カメラ(外部入力映像)を拡縮して描画します

パラメーター

  • camera — カメラ(外部入力映像)
  • rect — 映像をフィッティングする矩形領域
  • autoPlay — カメラ(外部入力映像)が停止していた場合、内部でPlayCameraImageを呼び出すかどうか

DrawCircle()

csharp
public void DrawCircle()

中抜きの円を描画します

DrawCircle(float, float, float)

csharp
public void DrawCircle(in float x, in float y, in float radius)

円を線で描画します

パラメーター

  • x — 中心のX座標
  • y — 中心のY座標
  • radius — 半径

DrawCircle(float2, float)

csharp
public void DrawCircle(in float2 position, in float radius)

円を線で描画します

パラメーター

  • position — 中心の座標
  • radius — 半径

DrawCircle(GcCircle)

csharp
public void DrawCircle(in GcCircle circle)

中抜きの円を描画します

パラメーター

  • circle — 円

DrawImage(GcImage, float, float, float, float, float)

csharp
public 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)

csharp
public void DrawImage(in GcImage image, in float x, in float y, float degree = 0f)

画像を描画します

パラメーター

  • image — 描画する画像
  • x — X座標
  • y — Y座標
  • degree — 回転(度数法)

DrawImage(GcImage, float2, float)

csharp
public void DrawImage(in GcImage image, in float2 position, float degree = 0f)

画像を描画します

パラメーター

  • image — 描画する画像
  • position — 位置
  • degree — 回転(度数法)

DrawImage(GcImage, GcRect)

csharp
public void DrawImage(in GcImage image, in GcRect rect)

画像を拡縮して描画します

パラメーター

  • image — 描画する画像
  • rect — 画像をフィッティングする矩形領域

DrawImage(GcImage)

csharp
public void DrawImage(in GcImage image)

画像を描画します

パラメーター

  • image — 描画する画像

DrawLine()

csharp
public void DrawLine()

線を描画します

DrawLine(float, float, float, float)

csharp
public 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)

csharp
public void DrawLine(in float2 begin, in float2 end)

線を描画します

パラメーター

  • begin — 始点
  • end — 終点

DrawLine(GcLine)

csharp
public void DrawLine(in GcLine line)

線を描画します

パラメーター

  • line — 線

DrawOnlineImage(string, float, float, float, float, float)

csharp
public GcAvailability DrawOnlineImage(in string url, in float x, in float y, in float width, in float height, float degree = 0f)

オンライン画像リソースを拡縮して描画します

パラメーター

  • url — リソースURL
  • x — X座標
  • y — Y座標
  • width — 横幅。画像の横幅がこれになるように拡縮される
  • height — 縦幅。画像の縦幅がこれになるように拡縮される
  • degree — 回転(度数法)

DrawOnlineImage(string, float, float, float)

csharp
public GcAvailability DrawOnlineImage(in string url, in float x, in float y, float degree = 0f)

オンライン画像リソースを描画します

パラメーター

  • url — リソースURL
  • x — X座標
  • y — Y座標
  • degree — 回転(度数法)

戻り値

オンラインリソースの可用性

DrawOnlineImage(string, float2, float)

csharp
public GcAvailability DrawOnlineImage(in string url, in float2 position, float degree = 0f)

オンライン画像リソースを描画します

パラメーター

  • url — リソースURL
  • position — 位置
  • degree — 回転(度数法)

戻り値

オンラインリソースの可用性

DrawOnlineImage(string, GcRect)

csharp
public GcAvailability DrawOnlineImage(in string url, in GcRect rect)

オンライン画像リソースを拡縮して描画します

パラメーター

  • url — リソースURL
  • rect — 画像をフィッティングする矩形領域

DrawOnlineImage(string)

csharp
public GcAvailability DrawOnlineImage(in string url)

オンライン画像リソースを描画します

パラメーター

  • url — リソースURL

戻り値

オンラインリソースの可用性

DrawRect()

csharp
public void DrawRect()

矩形を線で描画します

DrawRect(float, float, float, float, float)

csharp
public 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)

csharp
public void DrawRect(in float2 position, in float2 size, float degree = 0f)

矩形を線で描画します

パラメーター

  • position — 位置
  • size — 大きさ
  • degree — 回転(度数法)

DrawRect(GcRect)

csharp
public void DrawRect(in GcRect rect)

矩形を線で描画します

パラメーター

  • rect — 矩形

DrawRoundedRect()

csharp
public void DrawRoundedRect()

角丸矩形を線で描画します

DrawRoundedRect(float, float, float, float, float, float)

csharp
public 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)

csharp
public 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)

csharp
public void DrawRoundedRect(in float2 position, in float2 size, float cornerRadius, float degree = 0f)

角丸矩形を線で描画します

パラメーター

  • position — 位置
  • size — 大きさ
  • cornerRadius — 角丸の半径
  • degree — 回転(度数法)

DrawRoundedRect(float2, float2, float)

csharp
public void DrawRoundedRect(in float2 position, in float2 size, float degree = 0f)

角丸矩形を線で描画します

パラメーター

  • position — 位置
  • size — 大きさ
  • degree — 回転(度数法)

DrawRoundedRect(GcRect, float)

csharp
public void DrawRoundedRect(in GcRect rect, float cornerRect)

角丸矩形を線で描画します

パラメーター

  • rect — 二等辺三角形が収まる矩形
  • cornerRadius — 角丸の半径

DrawRoundedRect(GcRect)

csharp
public void DrawRoundedRect(in GcRect rect)

角丸矩形を線で描画します

パラメーター

  • rect — 二等辺三角形が収まる矩形

DrawString(string, float, float, float, float, float)

csharp
public 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)

csharp
public void DrawString(in string str, in float x, in float y, float degree = 0f)

文字列を描画します

パラメーター

  • str — 描画する文字列
  • x — X座標
  • y — Y座標
  • degree — 回転(度数法)

DrawString(string, float2, float)

csharp
public void DrawString(in string str, in float2 position, float degree = 0f)

文字列を描画します

パラメーター

  • str — 描画する文字列
  • position — 位置
  • degree — 回転(度数法)

DrawString(string, GcRect)

csharp
public void DrawString(in string str, in GcRect rect)

文字列を拡縮して描画します

パラメーター

  • str — 描画する文字列
  • rect — 文字列をフィッティングする矩形領域

DrawString(string)

csharp
public void DrawString(in string str)

文字列を描画します

パラメーター

  • str — 描画する文字列

DrawTexture(Texture, float, float, float, float, float)

csharp
public 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)

csharp
public void DrawTexture(in Texture texture, in float2 position, float degree = 0f)

テクスチャーを描画します

パラメーター

  • texture — 描画するテクスチャー
  • position — 位置
  • degree — 回転(度数法)

DrawTexture(Texture, float2x3)

csharp
public void DrawTexture(in Texture texture, in float2x3 matrix)

テクスチャーを変形して描画します

パラメーター

  • texture — 描画するテクスチャー
  • matrix — アフィン変換行列

DrawTexture(Texture, GcRect)

csharp
public void DrawTexture(in Texture texture, in GcRect rect)

テクスチャーを拡縮して描画します

パラメーター

  • texture — 描画するテクスチャー
  • rect — テクスチャーをフィッティングする矩形領域

DrawTexture(Texture)

csharp
public void DrawTexture(in Texture texture)

テクスチャーを描画します

パラメーター

  • texture — 描画するテクスチャー

EraseSavedDataAll()

csharp
public void EraseSavedDataAll()

ローカルストレージに保存された全ての値を削除します

FillCircle()

csharp
public void FillCircle()

円を塗りで描画します

FillCircle(float, float, float)

csharp
public void FillCircle(in float x, in float y, in float radius)

円を塗りで描画します

パラメーター

  • x — 中心のX座標
  • y — 中心のY座標
  • radius — 半径

FillCircle(float2, float)

csharp
public void FillCircle(in float2 position, in float radius)

円を塗りで描画します

パラメーター

  • position — 中心の座標
  • radius — 半径

FillCircle(GcCircle)

csharp
public void FillCircle(in GcCircle circle)

円を塗りで描画します

パラメーター

  • circle — 円

FillRect()

csharp
public void FillRect()

矩形を塗りで描画します

FillRect(float, float, float, float, float)

csharp
public 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)

csharp
public void FillRect(in float2 position, in float2 size, float degree = 0f)

矩形を塗りで描画します

パラメーター

  • position — 位置
  • size — 大きさ
  • degree — 回転(度数法)

FillRect(GcRect)

csharp
public void FillRect(in GcRect rect)

矩形を塗りで描画します

パラメーター

  • rect — 矩形

FillRoundedRect()

csharp
public void FillRoundedRect()

角丸矩形を塗りで描画します

FillRoundedRect(float, float, float, float, float, float)

csharp
public 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)

csharp
public 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)

csharp
public void FillRoundedRect(in float2 position, in float2 size, float cornerRadius, float degree = 0f)

角丸矩形を塗りで描画します

パラメーター

  • position — 位置
  • size — 大きさ
  • cornerRadius — 角丸の半径
  • degree — 回転(度数法)

FillRoundedRect(float2, float2, float)

csharp
public void FillRoundedRect(in float2 position, in float2 size, float degree = 0f)

角丸矩形を塗りで描画します

パラメーター

  • position — 位置
  • size — 大きさ
  • degree — 回転(度数法)

FillRoundedRect(GcRect, float)

csharp
public void FillRoundedRect(in GcRect rect, float cornerRadius)

角丸矩形を塗りで描画します

パラメーター

  • rect — 二等辺三角形が収まる矩形
  • cornerRadius — 角丸の半径

FillRoundedRect(GcRect)

csharp
public void FillRoundedRect(in GcRect rect)

角丸矩形を塗りで描画します

パラメーター

  • rect — 二等辺三角形が収まる矩形

FocusCameraImage(GcCameraDevice, float2?)

csharp
public void FocusCameraImage(in GcCameraDevice camera, in float2? uv)

カメラ(外部入力映像)の任意の点に焦点をあわせるように要求します

備考

  • このAPIは、対応するカメラデバイスに対して、実機上での実行したときのみ動作します
  • uv引数は、キャンバス座標系ではなく、左下を原点とする 0.0~1.0 のUV座標系を指定します
  • 焦点あわせを解除するには、uv引数に null を渡します

パラメーター

  • camera — カメラ(外部入力映像)
  • uv — 焦点をあわせる位置(左下を原点とする 0.0~1.0 のUV座標系)

GetActor()

csharp
public GcActor? GetActor()

シーンに登録されているアクターのうち、1つだけ取得します

戻り値

取得できたアクター

GetActor<T>()

csharp
public T? GetActor<T>() where T : GcActor

シーンに登録されているアクターのうち、指定した型のものを1つだけ取得します

型パラメーター

  • T — 取得するアクターの型

戻り値

取得できたアクター

GetActorCount()

csharp
public int GetActorCount()

シーンに登録されているアクターの総数を取得します

戻り値

アクターの数

GetActorCount<T>()

csharp
public int GetActorCount<T>() where T : GcActor

シーンに登録されているアクターのうち、指定した型のものが幾つあるか取得します

型パラメーター

  • T — 取得するアクターの型

戻り値

アクターの数

GetActorList<T>()

継承元: ISceneManagementEx

csharp
ReadOnlyActorList<T> GetActorList<T>() where T : GcActor

シーンに登録されているアクターのうち、指定した型のものを取得します

型パラメーター

  • T — 取得するアクターの型

戻り値

取得したアクターのリスト

GetImageHeight(GcImage)

csharp
public int GetImageHeight(in GcImage image)

画像の縦幅を取得します

パラメーター

  • image — 画像

戻り値

縦幅

GetImageSize(GcImage)

csharp
public int2 GetImageSize(in GcImage image)

画像のサイズを取得します

パラメーター

  • image — 画像

戻り値

サイズ

GetImageWidth(GcImage)

csharp
public int GetImageWidth(in GcImage image)

画像の横幅を取得します

パラメーター

  • image — 画像

戻り値

横幅

GetKeyPressDuration(Key)

csharp
public float GetKeyPressDuration(in Key key)

指定されたキーが押されている時間(秒)

パラメーター

  • key — キー

戻り値

時間(秒)

GetKeyPressFrameCount(Key)

csharp
public int GetKeyPressFrameCount(in Key key)

指定されたキーが押されているフレーム数

パラメーター

  • key — キー

戻り値

フレーム数

GetOnlineImageHeight(string)

csharp
public int GetOnlineImageHeight(in string url)

オンライン画像リソースの縦幅を取得します

パラメーター

  • url — リソースURL

戻り値

オンライン画像リソースの縦幅。取得できなかった場合は0を返します

GetOnlineImageWidth(string)

csharp
public int GetOnlineImageWidth(in string url)

オンライン画像リソースの横幅を取得します

パラメーター

  • url — リソースURL

戻り値

オンライン画像リソースの横幅。取得できなかった場合は0を返します

GetOrCreateCameraTexture(GcCameraDevice, GcResolution)

csharp
public WebCamTexture? GetOrCreateCameraTexture(in GcCameraDevice camera, in GcResolution request)

指定されたカメラ(外部入力映像)のテクスチャーを生成もしくは取得します

備考

  • 既にテクスチャーが生成済みの場合は、request引数の値は無視されます
  • 生成後に解像度を変更する場合は TryChangeCameraImageResolution 関数を呼び出してください

パラメーター

  • camera — カメラ(外部入力映像)
  • request — テクスチャーが未生成だった場合に、希望する解像度とリフレッシュレート

戻り値

テクスチャー

GetPrimaryCameraResolution(GcCameraDevice)

csharp
public GcResolution GetPrimaryCameraResolution(in GcCameraDevice camera)

指定されたカメラ(外部入力映像)の推奨解像度を取得します

備考

  • 推奨解像度を取得できない場合、現在のキャンバス解像度とフレームレートに基づいた適当な値を返します
  • エディタでは常に推奨解像度を取得できません

パラメーター

  • camera — カメラ(外部入力映像)

戻り値

解像度とリフレッシュレート

GetRandomState()

csharp
public uint GetRandomState()

乱数計算の現在の状態(≒シード値)を取得します

戻り値

シード値

GetSoundLevel(GcSoundTrack)

csharp
public float GetSoundLevel(GcSoundTrack track = GcSoundTrack.Master)

トラック音量を取得します

パラメーター

  • track — 対象の音声トラック

戻り値

音量(-96db~20db)

GetSoundVolume(GcSoundTrack)

csharp
public float GetSoundVolume(GcSoundTrack track = GcSoundTrack.Master)

トラック音量を取得します

パラメーター

  • track — 対象の音声トラック

戻り値

音量(0f~1f)

HideScreenKeyboard()

csharp
public void HideScreenKeyboard()

スクリーンキーボードを閉じます

HitTest(GcAABB, float2)

csharp
public bool HitTest(in GcAABB aabb, in float2 point)

GcAABB と 点の接触判定

HitTest(GcAABB, GcAABB)

csharp
public bool HitTest(in GcAABB a, in GcAABB b)

GcAABBGcAABB の接触判定

HitTest(GcCircle, float2)

csharp
public bool HitTest(in GcCircle circle, in float2 point)

GcCircle と 点の接触判定

HitTest(GcCircle, GcCircle)

csharp
public bool HitTest(in GcCircle circle1, in GcCircle circle2)

GcCircleGcCircle の接触判定

IsFlippedCameraImage(GcCameraDevice)

csharp
public bool IsFlippedCameraImage(in GcCameraDevice camera)

指定されたカメラ(外部入力映像)は上下が反転しているかどうか

パラメーター

  • camera — カメラ(外部入力映像)

戻り値

上下が反転しているかどうか

IsKeyDown(Key)

csharp
public bool IsKeyDown(in Key key)

指定されたキーが押されたかどうか

パラメーター

  • key — キー

戻り値

押されたかどうか

IsKeyHold(Key, GcKeyTrace)

csharp
public bool IsKeyHold(in Key key, out GcKeyTrace trace)

指定されたキーが押されているかどうか(押された瞬間を除く)

パラメーター

  • key — キー
  • trace — キーの軌跡

戻り値

押されているかどうか(押された瞬間を除く)

IsKeyHold(Key)

csharp
public bool IsKeyHold(in Key key)

指定されたキーが押されているかどうか(押された瞬間を除く)

パラメーター

  • key — キー

戻り値

押されているかどうか(押された瞬間を除く)

IsKeyPress(Key)

csharp
public bool IsKeyPress(in Key key)

指定されたキーが押されているかどうか(押された瞬間を含む)

パラメーター

  • key — キー

戻り値

押されているかどうか(押された瞬間を含む)

IsKeyUp(Key, GcKeyTrace)

csharp
public bool IsKeyUp(in Key key, out GcKeyTrace trace)

指定されたキーが離されたかどうか

パラメーター

  • key — キー
  • trace — キーの軌跡

戻り値

離されたかどうか

IsKeyUp(Key)

csharp
public bool IsKeyUp(in Key key)

指定されたキーが離されたかどうか

パラメーター

  • key — キー

戻り値

離されたかどうか

IsPlayingCameraImage(GcCameraDevice)

csharp
public bool IsPlayingCameraImage(in GcCameraDevice camera)

指定されたカメラ(外部入力映像)の更新が行われているかどうか

パラメーター

  • camera — カメラ(外部入力映像)

戻り値

更新が行われているかどうか

IsPlayingSound(GcSoundTrack)

csharp
public bool IsPlayingSound(GcSoundTrack track = GcSoundTrack.BGM1)

指定された音声トラックが再生中かどうか

パラメーター

  • track — 対象の音声トラック

戻り値

再生中かどうか

IsTapped()

csharp
public bool IsTapped()

前回のフレーム処理以降に タップされたかどうか

戻り値

タップされたかどうか

IsTapped(float, float, float, float, float, float)

csharp
public bool IsTapped(in float x, in float y, in float width, in float height, out float px, out float py)

前回のフレーム処理以降に 指定した領域がタップされたかどうか

パラメーター

  • x — 領域 左上X座標
  • y — 領域 左上Y座標
  • width — 領域 横幅
  • height — 領域 縦幅
  • px — タップ位置 X座標
  • py — タップ位置 Y座標

戻り値

指定した領域がタップされたかどうか

IsTapped(float, float)

csharp
public bool IsTapped(out float x, out float y)

前回のフレーム処理以降に タップされたかどうか

パラメーター

  • x — タップ位置 X座標
  • y — タップ位置 Y座標

戻り値

タップされたかどうか

IsTapped(float2)

csharp
public bool IsTapped(out float2 point)

前回のフレーム処理以降に タップされたかどうか

パラメーター

  • point — タップ位置

戻り値

タップされたかどうか

IsTapped(GcAABB, float2)

csharp
public bool IsTapped(in GcAABB aabb, out float2 point)

前回のフレーム処理以降に 指定した領域がタップされたかどうか

パラメーター

  • aabb — 領域
  • point — タップ位置

戻り値

指定した領域がタップされたかどうか

IsTouchBegan()

csharp
public bool IsTouchBegan()

前回のフレーム処理以降に タッチされ始めたかどうか

戻り値

タッチされ始めたかどうか

IsTouchBegan(float, float, float, float, float, float)

csharp
public bool IsTouchBegan(in float x, in float y, in float width, in float height, out float px, out float py)

前回のフレーム処理以降に 指定した領域がタッチされ始めたかどうか

パラメーター

  • x — 領域 左上X座標
  • y — 領域 左上Y座標
  • width — 領域 横幅
  • height — 領域 縦幅
  • px — タッチ位置 X座標
  • py — タッチ位置 Y座標

戻り値

指定した領域がタッチされ始めたかどうか

IsTouchBegan(float, float)

csharp
public bool IsTouchBegan(out float x, out float y)

前回のフレーム処理以降に タッチされ始めたかどうか

パラメーター

  • x — タッチ位置 X座標
  • y — タッチ位置 Y座標

戻り値

タッチされ始めたかどうか

IsTouchBegan(float2)

csharp
public bool IsTouchBegan(out float2 point)

前回のフレーム処理以降に タッチされ始めたかどうか

パラメーター

  • point — タッチ位置

戻り値

タッチされ始めたかどうか

IsTouchBegan(GcAABB, float2)

csharp
public bool IsTouchBegan(in GcAABB aabb, out float2 point)

前回のフレーム処理以降に 指定した領域がタッチされ始めたかどうか

パラメーター

  • aabb — 領域
  • point — タッチ位置

戻り値

指定した領域がタッチされ始めたかどうか

IsTouchBegan(GcPointerEvent)

csharp
public bool IsTouchBegan(out GcPointerEvent pointer)

前回のフレーム処理以降に タッチされ始めたかどうか

パラメーター

  • pointer — ポインターイベント

戻り値

タッチされ始めたかどうか

IsTouched()

csharp
public bool IsTouched()

前回のフレーム処理以降 タッチされていたか(開始と終了を含む)

戻り値

タッチされていたか(開始と終了を含む)

IsTouched(float, float, float, float, float, float)

csharp
public bool IsTouched(in float x, in float y, in float width, in float height, out float px, out float py)

前回のフレーム処理以降 指定した領域がタッチされていたか(開始と終了を含む)

パラメーター

  • x — 領域 左上X座標
  • y — 領域 左上Y座標
  • width — 領域 横幅
  • height — 領域 縦幅
  • px — タッチ位置 X座標
  • py — タッチ位置 Y座標

戻り値

指定した領域がタッチされていたか(開始と終了を含む)

IsTouched(float, float)

csharp
public bool IsTouched(out float x, out float y)

前回のフレーム処理以降 タッチされていたか(開始と終了を含む)

パラメーター

  • x — タッチ位置 X座標
  • y — タッチ位置 Y座標

戻り値

タッチされていたか(開始と終了を含む)

IsTouched(float2)

csharp
public bool IsTouched(out float2 point)

前回のフレーム処理以降 タッチされていたか(開始と終了を含む)

パラメーター

  • point — タッチ位置

戻り値

タッチされていたか(開始と終了を含む)

IsTouched(GcAABB, float2)

csharp
public bool IsTouched(in GcAABB aabb, out float2 point)

前回のフレーム処理以降 指定した領域がタッチされていたか(開始と終了を含む)

パラメーター

  • aabb — 領域
  • point — タッチ位置

戻り値

指定した領域がタッチされていたか(開始と終了を含む)

IsTouched(GcPointerEvent)

csharp
public bool IsTouched(out GcPointerEvent pointer)

前回のフレーム処理以降 タッチされていたか(開始と終了を含む)

パラメーター

  • e — ポインターイベント

戻り値

タッチされていたか(開始と終了を含む)

IsTouched(GcPointerTrace)

csharp
public bool IsTouched(out GcPointerTrace pointer)

前回のフレーム処理以降 タッチされていたか(開始と終了を含む)

パラメーター

  • trace — タッチの軌跡

戻り値

タッチされていたか(開始と終了を含む)

IsTouchEnded()

csharp
public bool IsTouchEnded()

前回のフレーム処理以降 タッチされ終えたかどうか

戻り値

タッチされ終えたかどうか

IsTouchEnded(float, float, float, float, float, float)

csharp
public bool IsTouchEnded(in float x, in float y, in float width, in float height, out float px, out float py)

前回のフレーム処理以降 指定した領域がタッチされ終えたかどうか

パラメーター

  • x — 領域 左上X座標
  • y — 領域 左上Y座標
  • width — 領域 横幅
  • height — 領域 縦幅
  • px — タッチ位置 X座標
  • py — タッチ位置 Y座標

戻り値

指定した領域がタッチされ終えたかどうか

IsTouchEnded(float, float)

csharp
public bool IsTouchEnded(out float x, out float y)

前回のフレーム処理以降 タッチされ終えたかどうか

パラメーター

  • x — タッチ位置 X座標
  • y — タッチ位置 Y座標

戻り値

タッチされ終えたかどうか

IsTouchEnded(float2)

csharp
public bool IsTouchEnded(out float2 point)

前回のフレーム処理以降 タッチされ終えたかどうか

パラメーター

  • point — タッチ位置

戻り値

タッチされ終えたかどうか

IsTouchEnded(GcAABB, float2)

csharp
public bool IsTouchEnded(in GcAABB aabb, out float2 point)

前回のフレーム処理以降 指定した領域がタッチされ終えたかどうか

パラメーター

  • aabb — 領域
  • point — タッチ位置

戻り値

指定した領域がタッチされ終えたかどうか

IsTouchEnded(GcPointerEvent)

csharp
public bool IsTouchEnded(out GcPointerEvent pointer)

前回のフレーム処理以降 タッチされ終えたかどうか

パラメーター

  • pointer — ポインターイベント

戻り値

タッチされ終えたかどうか

IsTouchEnded(GcPointerTrace)

csharp
public bool IsTouchEnded(out GcPointerTrace pointer)

前回のフレーム処理以降 タッチされ終えたかどうか

パラメーター

  • pointer — タッチの軌跡

戻り値

タッチされ終えたかどうか

Max(float, float)

csharp
public float Max(in float a, in float b)

2つの値を比較して、より大きい方を返します

戻り値

大きい方の値

Min(float, float)

csharp
public float Min(in float a, in float b)

2つの値を比較して、より小さい方を返します

戻り値

小さい方の値

PauseCameraImage(GcCameraDevice)

csharp
public bool PauseCameraImage(in GcCameraDevice camera)

指定されたカメラ(外部入力映像)の更新処理を一時停止します

パラメーター

  • camera — カメラ(外部入力映像)

戻り値

停止したかどうか(元から停止していた場合を含まない)

PauseSound(GcSoundTrack)

csharp
public void PauseSound(GcSoundTrack track = GcSoundTrack.BGM1)

指定された音声トラックのサウンドを一時停止します

備考

BGMトラック以外では常に無視されます

パラメーター

  • track — 対象の音声トラック

PlayCameraImage(GcCameraDevice, GcResolution, int2)

csharp
public bool PlayCameraImage(in GcCameraDevice camera, in GcResolution request, out int2 resolution)

指定されたカメラ(外部入力映像)の更新処理を開始します

備考

  • カメラごとにこのAPIを呼び出すことで、それらを同時に更新することが可能です
  • ただし、同じ名称のカメラは、同時に更新することができません
  • 既にテクスチャーが生成済みの場合は、request引数の値は無視されます
  • 生成後に解像度を変更する場合は TryChangeCameraImageResolution 関数を呼び出してください

パラメーター

  • camera — カメラ(外部入力映像)
  • request — テクスチャーが未生成だった場合に、希望する解像度とリフレッシュレート
  • resolution — カメラ(外部入力映像)の解像度

戻り値

開始したかどうか(元から更新していた場合を含まない)

PlayCameraImage(GcCameraDevice, int2)

csharp
public bool PlayCameraImage(in GcCameraDevice camera, out int2 resolution)

指定されたカメラ(外部入力映像)の更新処理を開始します

備考

  • カメラごとにこのAPIを呼び出すことで、それらを同時に更新することが可能です
  • ただし、同じ名称のカメラは、同時に更新することができません
  • テクスチャーが未生成だった場合は、内部で勝手に適当な解像度で生成します

パラメーター

  • camera — カメラ(外部入力映像)
  • resolution — カメラ(外部入力映像)の解像度

戻り値

開始したかどうか(元から更新していた場合を含まない)

PlayCameraImage(GcCameraDevice)

csharp
public bool PlayCameraImage(in GcCameraDevice camera)

指定されたカメラ(外部入力映像)の更新処理を開始します

備考

  • カメラごとにこのAPIを呼び出すことで、それらを同時に更新することが可能です
  • ただし、同じ名称のカメラは、同時に更新することができません

パラメーター

  • camera — カメラ(外部入力映像)

戻り値

開始したかどうか(元から更新していた場合を含まない)

PlaySE(AudioClip)

csharp
public void PlaySE(in AudioClip clip)

サウンドを1回再生します

パラメーター

  • clip — サウンド

PlaySE(GcSound)

csharp
public void PlaySE(in GcSound sound)

サウンドを1回再生します

パラメーター

  • sound — サウンド

PlaySound(AudioClip, GcSoundTrack, bool)

csharp
public void PlaySound(in AudioClip clip, GcSoundTrack track = GcSoundTrack.BGM1, bool loop = false)

サウンドを再生します

パラメーター

  • clip — サウンド
  • track — 対象の音声トラック
  • loop — ループ再生するかどうか(SEトラック以外)

PlaySound(GcSound, GcSoundTrack, bool)

csharp
public void PlaySound(in GcSound sound, GcSoundTrack track = GcSoundTrack.BGM1, bool loop = false)

サウンドを再生します

パラメーター

  • soundId — サウンド
  • track — 対象の音声トラック
  • loop — ループ再生するかどうか(SEトラック以外)

PopCoordinate()

csharp
public void PopCoordinate()

スタックから座標系(変換行列)を取り出し CurrentCoordinate に上書きします

PopStyle()

csharp
public void PopStyle()

スタックから描画スタイルを取り出し CurrentStyle に上書きします

PushCoordinate()

csharp
public void PushCoordinate()

CurrentCoordinate をスタックに保存します

PushStyle()

csharp
public void PushStyle()

CurrentStyle をスタックに保存します

Random()

csharp
public float Random()

0以上1未満のランダムな値を算出します

戻り値

ランダムな値

Random(float, float)

csharp
public float Random(in float min, in float max)

min以上max未満のランダムな値を算出します

パラメーター

  • min — 最小値
  • max — 最大値

戻り値

ランダムな値

Random(int, int)

csharp
public int Random(in int min, in int max)

min以上max以下のランダムな値を算出します

パラメーター

  • min — 最小値
  • max — 最大値

戻り値

ランダムな値

RebuildFontTexture()

csharp
public void RebuildFontTexture()

フォントテクスチャ―を再生成します

備考

  • テキスト描画が乱れた場合にのみ呼び出すことを想定しています
  • 実際に再生成が行われるのは、この関数を呼び出した次のフレームの冒頭です

RegisterScene(GcScene)

csharp
public void RegisterScene(in GcScene scene)

新たなシーンを登録します

備考

登録したシーンは ChangeScene を呼び出すことで有効になります

パラメーター

  • scene — 登録するシーン

RegisterScene<T>()

csharp
public void RegisterScene<T>() where T : GcScene, new()

新たなシーンを登録します

備考

登録したシーンは ChangeScene を呼び出すことで有効になります

型パラメーター

  • T — 登録するシーンの型

RemoveActorAll()

csharp
public void RemoveActorAll()

シーンに登録されているすべてのアクターを登録解除します

Repeat(float, float)

csharp
public float Repeat(in float value, in float max)

値を 0 から max までの範囲を繰り返すよう値を丸めます

パラメーター

  • value — 入力値
  • max — 最大値

RequestUserAuthorizedPermissionCameraAsync(System.Action<bool>)

csharp
public void RequestUserAuthorizedPermissionCameraAsync(in System.Action<bool> callback)

カメラデバイスへのアクセス権限を要求します

パラメーター

  • callback — 結果を通知するコールバック

RequestUserAuthorizedPermissionGeolocationAsync(System.Action<bool>)

csharp
public void RequestUserAuthorizedPermissionGeolocationAsync(in System.Action<bool> callback)

位置情報へのアクセス権限を要求します

パラメーター

  • callback — 結果を通知するコールバック

RotateCoordinate(float, float, float)

csharp
public void RotateCoordinate(in float degree, in float originX, in float originY)

座標系(変換行列)を回転させます

パラメーター

  • degree — 回転量(度数法)
  • originX — 回転中心のX座標
  • originY — 回転中心のY座標

RotateCoordinate(float, float2)

csharp
public void RotateCoordinate(in float degree, in float2 origin)

座標系(変換行列)を指定した座標を中心に回転させます

パラメーター

  • degree — 回転量(度数法)
  • origin — 回転中心

RotateCoordinate(float)

csharp
public void RotateCoordinate(in float degree)

座標系(変換行列)を回転させます

パラメーター

  • degree — 回転量(度数法)

RotateVector(float2, float)

csharp
public float2 RotateVector(in float2 vector, in float degree)

ベクトルを回転します

パラメーター

  • vector — ベクトル
  • degree — 回転量(度数法)

戻り値

回転後のベクトル

Round(double)

csharp
public int Round(in double value)

値を四捨五入します

パラメーター

  • value — 入力値

戻り値

四捨五入された値

Round(float)

csharp
public int Round(in float value)

値を四捨五入します

パラメーター

  • value — 入力値

戻り値

四捨五入された値

Save(string, float?)

csharp
public void Save(in string key, float? value)

ローカルストレージに値を保存します

備考

value に null を渡した場合、キーに紐づくデータを削除します

パラメーター

  • key — キー
  • value — 保存する値

Save(string, int?)

csharp
public void Save(in string key, int? value)

ローカルストレージに値を保存します

備考

value に null を渡した場合、キーに紐づくデータを削除します

パラメーター

  • key — キー
  • value — 保存する値

Save(string, string?)

csharp
public void Save(in string key, string? value)

ローカルストレージに値を保存します

備考

value に null を渡した場合、キーに紐づくデータを削除します

パラメーター

  • key — キー
  • value — 保存する値

SaveScreenshotAsync(System.Action<string?>?)

csharp
public void SaveScreenshotAsync(System.Action<string?>? onComplete = null)

現在の画面を 画像として保存します

備考

  • 保存に成功した場合、onComplete の引数には、画像保存先のパスが渡されます
  • 保存に失敗した場合、onComplete の引数には null が渡されます

パラメーター

  • onComplete — 保存完了後に呼び出されるコールバック

ScaleCoordinate(float, float)

csharp
public void ScaleCoordinate(in float sx, in float sy)

座標系(変換行列)を拡縮させます

パラメーター

  • sx — X軸方向の拡縮率
  • sy — Y軸方向の拡縮率

ScaleCoordinate(float2)

csharp
public void ScaleCoordinate(in float2 scaling)

座標系(変換行列)を拡縮させます

パラメーター

  • scaling — 拡縮率

ScreenToCanvasPoint(float2, float2)

csharp
public void ScreenToCanvasPoint(in float2 screen, out float2 canvas)

端末スクリーン座標をキャンバス座標に変換します

パラメーター

  • screen — 変換元 端末スクリーン座標
  • canvas — 変換後 キャンバス座標

ScreenToCanvasPoint(float2, int2)

csharp
public void ScreenToCanvasPoint(in float2 screen, out int2 canvas)

端末スクリーン座標をキャンバス座標に変換します

パラメーター

  • screen — 変換元 端末スクリーン座標
  • canvas — 変換後 キャンバス座標

SetBackgroundColor(Color)

csharp
public void SetBackgroundColor(in Color color)

背景色を指定します

パラメーター

  • color — 背景色

SetBackgroundColor(float, float, float)

csharp
public void SetBackgroundColor(in float r, in float g, in float b)

背景色を指定します

パラメーター

  • r — 背景色の赤成分
  • g — 背景色の緑成分
  • b — 背景色の青成分

SetColor(byte, byte, byte, byte)

csharp
public void SetColor(in byte r, in byte g, in byte b, byte a = 255)

描画色を指定します

パラメーター

  • r — 描画色の赤成分
  • g — 描画色の緑成分
  • b — 描画色の青成分
  • a — 描画色の不透明度

SetColor(Color, float)

csharp
public void SetColor(in Color color, in float alpha)

描画色を指定します

パラメーター

  • color — 描画色
  • alpha — 描画色の不透明度

SetColor(Color)

csharp
public void SetColor(in Color color)

描画色を指定します

パラメーター

  • color — 描画色

SetColor(float, float, float, float)

csharp
public void SetColor(in float r, in float g, in float b, float a = 1f)

描画色を指定します

パラメーター

  • r — 描画色の赤成分
  • g — 描画色の緑成分
  • b — 描画色の青成分
  • a — 描画色の不透明度

SetCoordinate(float2x3)

csharp
public void SetCoordinate(in float2x3 matrix)

座標系(変換行列)を指定します

パラメーター

  • matrix — 座標系(変換行列)

SetFont(GcFont)

csharp
public void SetFont(in GcFont font)

フォントを指定します

パラメーター

  • font — フォント

SetFontSize(int)

csharp
public void SetFontSize(in int fontSize)

フォントサイズを指定します

パラメーター

  • fontSize — フォントサイズ

SetFrameInterval(double, bool)

csharp
public void SetFrameInterval(in double targetDeltaTime, bool vSyncEnabled = true)

UpdateGame や DrawGame が呼び出される時間間隔を設定します。

備考

垂直同期を無効にした場合、間隔の揺らぎは減少しますが、ディスプレイのリフレッシュレートを常に無視して描画するため、画面のちらつきが発生する場合があります。

パラメーター

  • targetDeltaTime — フレーム更新間隔の目標値(秒)
  • vSyncEnabled — 垂直同期の有無

SetFrameRate(int, bool)

csharp
public void SetFrameRate(in int targetFrameRate, bool vSyncEnabled = true)

フレームレートの目標値を設定します。

小数点以下を指定したい場合は、この関数の代わりに SetFrameInterval を使用してください。

備考

垂直同期を無効にした場合、間隔の揺らぎは減少しますが、ディスプレイのリフレッシュレートを常に無視して描画するため、画面のちらつきが発生する場合があります。

パラメーター

  • targetFrameRate — フレームレート(1秒あたりのフレーム数)の目標値
  • vSyncEnabled — 垂直同期の有無

SetLineCap(GcLineCap)

csharp
public void SetLineCap(in GcLineCap lineCap)

描線の端点の形状を指定します

パラメーター

  • lineCap — 描線の端点の形状

SetLineWidth(float)

csharp
public void SetLineWidth(in float lineWidth)

描線の太さを指定します

パラメーター

  • lineWidth — 描線の太さ

SetRandomSeed(uint)

csharp
public void SetRandomSeed(in uint seed)

乱数計算のシード値を設定します

パラメーター

  • seed — シード値

SetRandomSeedByIndex(uint)

csharp
public void SetRandomSeedByIndex(in uint index)

乱数計算のシード値をインデックスから設定します

パラメーター

  • index — インデックス

SetRectAnchor(GcAnchor)

csharp
public void SetRectAnchor(in GcAnchor anchor)

矩形や画像のアンカー位置を指定します

パラメーター

  • anchor — アンカー位置

SetSoundLevel(float, GcSoundTrack)

csharp
public void SetSoundLevel(in float decibel, GcSoundTrack track = GcSoundTrack.Master)

トラック音量を変更します

パラメーター

  • decibel — 音量(-96db~20db)
  • track — 対象の音声トラック

SetSoundVolume(float, GcSoundTrack)

csharp
public void SetSoundVolume(in float volume, GcSoundTrack track = GcSoundTrack.Master)

トラック音量を変更します

パラメーター

  • volume — 音量(0f~1f)
  • track — 対象の音声トラック

SetStringAnchor(GcAnchor)

csharp
public void SetStringAnchor(in GcAnchor anchor)

文字列のアンカー位置を指定します

パラメーター

  • anchor — アンカー位置

SetStyle(GcStyle)

csharp
public void SetStyle(in GcStyle style)

スタイルを指定します

パラメーター

  • style

ShowScreenKeyboard()

csharp
public bool ShowScreenKeyboard()

スクリーンキーボードを表示します

戻り値

表示できたかどうか

Sin(float)

csharp
public float Sin(in float degree)

サインを計算します

パラメーター

  • degree — 角度(度数法)

戻り値

サイン

Sqrt(float)

csharp
public float Sqrt(in float value)

平方根を計算します

パラメーター

  • value — 入力値

戻り値

平方根

StartGeolocationService(float, float)

csharp
public void StartGeolocationService(float desiredAccuracy = 10, float updateDistance = 10)

位置情報サービスを起動します

備考

位置情報へのアクセス権限がない場合、この処理は失敗します

パラメーター

  • desiredAccuracy — 望ましいサービス精度(メートル単位)
  • updateDistance — 位置情報の更新に必要な最小移動距離(メートル単位)

StopCameraImage(GcCameraDevice)

csharp
public void StopCameraImage(in GcCameraDevice camera)

指定されたカメラ(外部入力映像)の更新処理を完全に停止します

パラメーター

  • camera — カメラ(外部入力映像)

StopGeolocationService()

csharp
public void StopGeolocationService()

位置情報サービスを停止します

StopSound(GcSoundTrack)

csharp
public void StopSound(GcSoundTrack track = GcSoundTrack.BGM1)

指定された音声トラックのサウンドを停止します

備考

BGMトラック以外では常に無視されます

パラメーター

  • track — 対象の音声トラック

SweepTest(GcAABB, float2, float2, GcSweepResult)

csharp
public bool SweepTest(in GcAABB @static, in float2 @dynamic, in float2 delta, out GcSweepResult hit)

移動する点と静的な矩形の連続衝突検出

SweepTest(GcAABB, GcAABB, float2, GcSweepResult)

csharp
public bool SweepTest(in GcAABB @static, in GcAABB @dynamic, in float2 delta, out GcSweepResult hit)

移動する矩形と静的な矩形の連続衝突検出

TranslateCoordinate(float, float)

csharp
public void TranslateCoordinate(in float tx, in float ty)

座標系(変換行列)を平行移動させます

パラメーター

  • tx — X軸方向の移動量
  • ty — Y軸方向の移動量

TranslateCoordinate(float2)

csharp
public void TranslateCoordinate(in float2 translation)

座標系(変換行列)を平行移動させます

パラメーター

  • translation — 移動量

TryChangeCameraImageResolution(GcCameraDevice, GcResolution)

csharp
public int2 TryChangeCameraImageResolution(in GcCameraDevice camera, in GcResolution request)

指定されたカメラ(外部入力映像)の解像度変更を試みます

パラメーター

  • camera — カメラ(外部入力映像)
  • request — 希望する解像度とリフレッシュレート

戻り値

実際に設定された解像度

TryGetAccelerationEvent(int, GcAccelerationEvent)

csharp
public bool TryGetAccelerationEvent(int i, out GcAccelerationEvent e)

前回のフレーム処理以降に検出した 加速度イベントの取得を試みます

パラメーター

  • i — イベントインデックス(0 から AccelerationEventCount-1 までの連番)
  • e — イベント

戻り値

ポインターイベントを取得できたかどうか

TryGetAccelerationEventAll(System.ReadOnlySpan<GcAccelerationEvent>)

csharp
public bool TryGetAccelerationEventAll(out System.ReadOnlySpan<GcAccelerationEvent> events)

前回のフレーム処理以降に検出した 加速度イベントの取得を試みます

パラメーター

  • events — イベント配列

戻り値

1つ以上の加速度イベントがあったかどうか

TryGetActor(int, GcActor?)

csharp
public bool TryGetActor(in int i, [NotNullWhen(true)] out GcActor? actor)

シーンに登録されているアクターを 1つだけ取得します

型パラメーター

  • T — 取得するアクターの型

パラメーター

  • i — 取得するアクターのインデックス(0以上GetActorCount未満)
  • actor — 取得できたアクター

戻り値

取得できたかどうか

TryGetActor<T>(int, T?)

csharp
public bool TryGetActor<T>(in int i, [NotNullWhen(true)] out T? actor) where T : GcActor

シーンに登録されているアクターを 1つだけ取得します

型パラメーター

  • T — 取得するアクターの型

パラメーター

  • i — 取得するアクターのインデックス(0以上GetActorCount{T}未満)
  • actor — 取得できたアクター

戻り値

取得できたかどうか

TryGetActorAll<T>(System.ReadOnlySpan<T>)

csharp
public bool TryGetActorAll<T>(out System.ReadOnlySpan<T> actors) where T : GcActor

シーンに登録されているアクターのうち、指定した型のものを取得します

型パラメーター

  • T — 取得するアクターの型

パラメーター

  • actors — 取得したアクターの一覧

戻り値

1つ以上 取得できたかどうか

TryGetCameraImage(GcCameraDevice?)

csharp
public bool TryGetCameraImage([NotNullWhen(true)] out GcCameraDevice? camera)

カメラ(外部入力映像)の取得を試みます

パラメーター

  • camera — カメラ(外部入力映像)

戻り値

取得できたかどうか

TryGetCameraImage(string, GcCameraDevice?)

csharp
public bool TryGetCameraImage(in string deviceName, [NotNullWhen(true)] out GcCameraDevice? camera)

デバイス名を指定して、カメラ(外部入力映像)の取得を試みます

パラメーター

  • deviceName — デバイス名
  • camera — カメラ(外部入力映像)

戻り値

取得できたかどうか

TryGetCameraImageAll(System.ReadOnlySpan<GcCameraDevice>)

csharp
public bool TryGetCameraImageAll(out System.ReadOnlySpan<GcCameraDevice> devices)

全ての認識可能なカメラ(外部入力映像)の取得を試みます

パラメーター

  • devices — カメラ(外部入力映像)の一覧

戻り値

1つ以上 取得できたかどうか

TryGetCameraImageRotation(GcCameraDevice, float)

csharp
public bool TryGetCameraImageRotation(in GcCameraDevice camera, out float degree)

指定されたカメラ(外部入力映像)の回転角度取得を試みます

パラメーター

  • camera — カメラ(外部入力映像)
  • degree — 回転角度

戻り値

取得できたかどうか

TryGetCameraImageSize(GcCameraDevice, int2)

csharp
public bool TryGetCameraImageSize(in GcCameraDevice camera, out int2 resolution)

指定されたカメラ(外部入力映像)の解像度取得を試みます

備考

  • テクスチャーが未生成の場合は、取得に失敗します
  • テクスチャーを生成するには、PlayCameraImage もしくは GetOrCreateCameraTexture 関数を呼び出してください

パラメーター

  • camera — カメラ(外部入力映像)
  • resolution — カメラ(外部入力映像)の解像度

戻り値

取得できたかどうか

TryGetGeolocationEvent(GcGeolocationEvent)

csharp
public bool TryGetGeolocationEvent(out GcGeolocationEvent data)

前回のフレーム処理以降にあった 位置情報イベントの取得を試みます

パラメーター

  • e — 位置情報イベント

戻り値

前回のフレーム処理以降に 位置情報イベントがあったかどうか

TryGetKeyEvent(Key, GcKeyEvent)

csharp
public bool TryGetKeyEvent(in Key key, out GcKeyEvent e)

指定されたキーのキーイベントがあれば取得します

パラメーター

  • key — キー
  • e — キーイベント

戻り値

取得できたかどうか

TryGetKeyEventAll(GcKeyEventPhase, System.ReadOnlySpan<GcKeyEvent>)

csharp
public bool TryGetKeyEventAll(in GcKeyEventPhase phase, out System.ReadOnlySpan<GcKeyEvent> events)

前回のフレーム処理以降に更新された 指定された状態のキーイベント全てを取得します

パラメーター

  • phase — キーイベント状態
  • events — キーイベントの一覧

戻り値

要素数が1以上かどうか

TryGetKeyEventAll(System.ReadOnlySpan<GcKeyEvent>)

csharp
public bool TryGetKeyEventAll(out System.ReadOnlySpan<GcKeyEvent> events)

前回のフレーム処理以降に更新された キーイベント全てを取得します

パラメーター

  • events — キーイベントの一覧

戻り値

要素数が1以上かどうか

TryGetKeyTrace(Key, GcKeyTrace)

csharp
public bool TryGetKeyTrace(in Key key, out GcKeyTrace trace)

指定されたキーの軌跡があれば取得します

パラメーター

  • key — キー
  • trace — キーの軌跡

戻り値

取得できたかどうか

TryGetKeyTraceAll(GcKeyEventPhase, System.ReadOnlySpan<GcKeyTrace>)

csharp
public bool TryGetKeyTraceAll(in GcKeyEventPhase phase, out System.ReadOnlySpan<GcKeyTrace> traces)

前回のフレーム処理以降に更新された キーの軌跡全てを取得します

パラメーター

  • phase — キーイベント状態
  • traces — キーの軌跡の一覧

戻り値

要素数が1以上かどうか

TryGetKeyTraceAll(System.ReadOnlySpan<GcKeyTrace>)

csharp
public bool TryGetKeyTraceAll(out System.ReadOnlySpan<GcKeyTrace> traces)

前回のフレーム処理以降に更新された キーの軌跡全てを取得します

パラメーター

  • traces — キーの軌跡の一覧

戻り値

要素数が1以上かどうか

TryGetOnlineImage(string, GcAvailability, Texture2D?)

csharp
public bool TryGetOnlineImage(in string url, out GcAvailability availability, [NotNullWhen(true)] out Texture2D? texture)

オンライン画像リソースの取得を試みます

パラメーター

  • url — リソースURL
  • texture — 画像リソース。戻り値がGcAvailability.Ready以外だとNull

戻り値

オンラインリソースの可用性

TryGetOnlineImageSize(string, int2)

csharp
public bool TryGetOnlineImageSize(in string url, out int2 size)

オンライン画像リソースの寸法を取得します

パラメーター

  • url — リソースURL
  • size — オンライン画像リソースの寸法

戻り値

オンラインリソースを取得できたかどうか

TryGetOnlineSound(string, AudioType, GcAvailability, AudioClip?)

csharp
public bool TryGetOnlineSound(in string url, in AudioType type, out GcAvailability availability, [NotNullWhen(true)] out AudioClip? clip)

オンライン音声リソースの取得を試みます

パラメーター

  • url — リソースURL
  • type — 音声リソースの形式
  • clip — 音声リソース。戻り値がGcAvailability.Ready以外だとNull

戻り値

オンラインリソースの可用性

TryGetOnlineSound(string, GcAvailability, AudioClip?)

csharp
public bool TryGetOnlineSound(in string url, out GcAvailability availability, [NotNullWhen(true)] out AudioClip? clip)

オンライン音声リソースの取得を試みます

パラメーター

  • url — リソースURL
  • clip — 音声リソース。戻り値がGcAvailability.Ready以外だとNull

戻り値

オンラインリソースの可用性

TryGetOnlineText(string, GcAvailability, string?)

csharp
public bool TryGetOnlineText(in string url, out GcAvailability availability, [NotNullWhen(true)] out string? str)

オンラインテキストの取得を試みます

パラメーター

戻り値

オンラインリソースの可用性

TryGetPointerEvent(GcPointerEventPhase, int, GcPointerEvent)

csharp
public bool TryGetPointerEvent(in GcPointerEventPhase phase, in int i, out GcPointerEvent e)

前回のフレーム処理以降に検出した ポインターイベントのうち、1つを取得します

パラメーター

  • phase — イベント状態
  • i — イベントインデックス(イベントIDではない)
  • e — イベント

戻り値

取得できたかどうか

TryGetPointerEvent(int, GcPointerEvent)

csharp
public bool TryGetPointerEvent(in int i, out GcPointerEvent e)

前回のフレーム処理以降に検出した ポインターイベントのうち、1つを取得します

パラメーター

  • i — イベントインデックス(0 から PointerCount-1 までの連番。イベントIDではない)
  • e — イベント

戻り値

取得できたかどうか

TryGetPointerEventAll(GcPointerEventPhase, System.ReadOnlySpan<GcPointerEvent>)

csharp
public bool TryGetPointerEventAll(in GcPointerEventPhase phase, out System.ReadOnlySpan<GcPointerEvent> events)

前回のフレーム処理以降に検出した 指定された状態のポインターイベント全てを取得します

パラメーター

  • phase — イベント状態
  • events — イベントの一覧

戻り値

1つ以上 取得できたかどうか

TryGetPointerEventAll(System.ReadOnlySpan<GcPointerEvent>)

csharp
public bool TryGetPointerEventAll(out System.ReadOnlySpan<GcPointerEvent> events)

前回のフレーム処理以降に検出した ポインターイベント全てを取得します

パラメーター

  • events — イベントの一覧

戻り値

1つ以上 取得できたかどうか

TryGetPointerTapPoint(int, float2)

csharp
public bool TryGetPointerTapPoint(in int i, out float2 point)

前回のフレーム処理以降に検出した タップポイントのうち、1つを取得します

パラメーター

  • i — タップインデックス
  • point — タップポイント

戻り値

取得できたかどうか

TryGetPointerTapPointAll(System.ReadOnlySpan<float2>)

csharp
public bool TryGetPointerTapPointAll(out System.ReadOnlySpan<float2> points)

前回のフレーム処理以降に検出した タップポイント全てを取得します

パラメーター

  • points — タップポイントの一覧

戻り値

1つ以上 取得できたかどうか

TryGetPointerTrace(GcPointerEventPhase, int, GcPointerTrace)

csharp
public bool TryGetPointerTrace(in GcPointerEventPhase phase, in int i, out GcPointerTrace trace)

現在有効なポインターのうち、1つの軌跡を取得します

備考

phase に指定できる値は GcPointerEventPhase.Hold または GcPointerEventPhase.End のみです

パラメーター

  • phase — イベント状態
  • i — イベントインデックス(イベントIDではない)
  • trace — 軌跡

戻り値

取得できたかどうか

TryGetPointerTrace(int, GcPointerTrace)

csharp
public bool TryGetPointerTrace(in int i, out GcPointerTrace history)

現在有効なポインターのうち、1つの軌跡を取得します

パラメーター

  • i — イベントインデックス(0 から PointerCount-1 までの連番。イベントIDではない)
  • trace — 軌跡

戻り値

取得できたかどうか

TryGetPointerTraceAll(GcPointerEventPhase, System.ReadOnlySpan<GcPointerTrace>)

csharp
public bool TryGetPointerTraceAll(in GcPointerEventPhase phase, out System.ReadOnlySpan<GcPointerTrace> traces)

前回のフレーム処理以降に検出した 指定された状態のポインターの軌跡全てを取得します

備考

phase に指定できる値は GcPointerEventPhase.Hold または GcPointerEventPhase.End のみです

パラメーター

  • traces — 軌跡の一覧

戻り値

1つ以上 取得できたかどうか

TryGetPointerTraceAll(System.ReadOnlySpan<GcPointerTrace>)

csharp
public bool TryGetPointerTraceAll(out System.ReadOnlySpan<GcPointerTrace> traces)

前回のフレーム処理以降に検出した ポインターの軌跡全てを取得します

パラメーター

  • traces — 軌跡の一覧

戻り値

1つ以上 取得できたかどうか

TryGetScreenKeyboardArea(GcAABB)

csharp
public bool TryGetScreenKeyboardArea(out GcAABB area)

スクリーンキーボードの表示位置を取得します

備考

  • 表示中のみ取得できます
  • 表示直後のアニメーション中は取得できません
  • Android OSでは取得できません

パラメーター

  • area — 表示位置(キャンバス座標系)

戻り値

取得できたかどうか

TryLoad(string, float)

csharp
public bool TryLoad(in string key, out float value)

ローカルストレージに保存された値を取り出します

パラメーター

  • key — キー
  • value — 取り出した値

戻り値

取り出せたかどうか

TryLoad(string, int)

csharp
public bool TryLoad(in string key, out int value)

ローカルストレージに保存された値を取り出します

パラメーター

  • key — キー
  • value — 取り出した値

戻り値

取り出せたかどうか

TryLoad(string, string?)

csharp
public bool TryLoad(in string key, [NotNullWhen(true)] out string? value)

ローカルストレージに保存された値を取り出します

パラメーター

  • key — キー
  • value — 取り出した値

戻り値

取り出せたかどうか

TryRemoveActor(GcActor)

csharp
public bool TryRemoveActor(in GcActor actor)

指定したアクターをシーンから登録解除します

パラメーター

  • actor — 登録解除するアクター

戻り値

登録解除できたかどうか

UnpauseSound(GcSoundTrack)

csharp
public void UnpauseSound(GcSoundTrack track = GcSoundTrack.BGM1)

指定された音声トラックのサウンドを一時停止していた場合、再生を再開します

備考

BGMトラック以外では常に無視されます

パラメーター

  • track — 対象の音声トラック

UnregisterScene(GcScene)

csharp
public void UnregisterScene(in GcScene scene)

指定したシーンをシーン一覧から削除します

備考

もし指定したシーンが現在有効なシーンだった場合、フレームの最後にシーンの離脱処理が走ります

パラメーター

  • scene — 削除するシーン

UnregisterScene<T>()

csharp
public void UnregisterScene<T>() where T : GcScene

指定したシーンをシーン一覧から削除します

備考

もし指定したシーンが現在有効なシーンだった場合、フレームの最後にシーンの離脱処理が走ります

型パラメーター

  • T — 削除するシーンの型

UpdateCameraDevice()

csharp
public int UpdateCameraDevice()

カメラ(外部入力映像)の一覧を更新します

戻り値

更新後の 認識可能なカメラ(外部入力映像)の数

Released under the MIT License.