DebugConsole
in package
Table of Contents
Constants
- EVENT_CONSOLE_COMMAND = 'console.command'
- The event that is dispatched when a console command is executed
- INPUT_CONTEXT = 'visu/dev/console'
- The input context for the console
Properties
- $charInputListenerId : int|null
- The char signal listener function id
- $debugTextRenderer : DebugOverlayTextRenderer
- Debug font renderer
- $dispatcher : Dispatcher
- $enabled : bool
- Is the console currently enabled?
- $input : Input
- $inputLine : string
- The string that is currently beeing written to
- $inputLineHistory : array<string|int, string>
- The input line history
- $inputLineHistoryIndex : int
- The current history index
- $inputLineHistoryLimit : int
- The input line history limit
- $inputLineHistoryRenderLimit : int
- The maximum number of lines to be rendered
- $quadVA : QuadVertexArray
- Quad we render as a background
- $shaderProgram : ShaderProgram
- The debug font shader program.
Methods
- __construct() : mixed
- Constructor
- attachPass() : void
- Handles rendering of the scene, here you can attach additional render passes, modify the render pipeline or customize rendering related data.
- clearHistory() : void
- Clears the console history
- handleKeyboardCharSignal() : void
- Char input handler
- handleKeyboardInputSignal() : void
- Keyboard event handler
- writeLine() : void
- Writes a line to the console This will simply append it to the input line history
Constants
EVENT_CONSOLE_COMMAND
The event that is dispatched when a console command is executed
public
mixed
EVENT_CONSOLE_COMMAND
= 'console.command'
INPUT_CONTEXT
The input context for the console
private
mixed
INPUT_CONTEXT
= 'visu/dev/console'
Properties
$charInputListenerId
The char signal listener function id
private
int|null
$charInputListenerId
= null
$debugTextRenderer
Debug font renderer
private
DebugOverlayTextRenderer
$debugTextRenderer
$dispatcher
private
Dispatcher
$dispatcher
$enabled
Is the console currently enabled?
private
bool
$enabled
= false
$input
private
Input
$input
$inputLine
The string that is currently beeing written to
private
string
$inputLine
= ""
$inputLineHistory
The input line history
private
array<string|int, string>
$inputLineHistory
= []
$inputLineHistoryIndex
The current history index
private
int
$inputLineHistoryIndex
= 0
$inputLineHistoryLimit
The input line history limit
private
int
$inputLineHistoryLimit
= 100
$inputLineHistoryRenderLimit
The maximum number of lines to be rendered
private
int
$inputLineHistoryRenderLimit
= 10
$quadVA
Quad we render as a background
private
QuadVertexArray
$quadVA
$shaderProgram
The debug font shader program.
private
ShaderProgram
$shaderProgram
Methods
__construct()
Constructor
public
__construct(GLState $gl, Input $input, Dispatcher $dispatcher) : mixed
Parameters
- $gl : GLState
- $input : Input
- $dispatcher : Dispatcher
attachPass()
Handles rendering of the scene, here you can attach additional render passes, modify the render pipeline or customize rendering related data.
public
attachPass(RenderPipeline $pipeline, PipelineResources $resources, RenderTargetResource $rt) : void
Parameters
- $pipeline : RenderPipeline
- $resources : PipelineResources
- $rt : RenderTargetResource
clearHistory()
Clears the console history
public
clearHistory() : void
handleKeyboardCharSignal()
Char input handler
public
handleKeyboardCharSignal(CharSignal $signal) : void
Parameters
- $signal : CharSignal
handleKeyboardInputSignal()
Keyboard event handler
public
handleKeyboardInputSignal(KeySignal $signal) : void
Parameters
- $signal : KeySignal
writeLine()
Writes a line to the console This will simply append it to the input line history
public
writeLine(string $line) : void
Parameters
- $line : string