Метод | Описание | |
---|---|---|
AddButton ( |
This function adds a button entry to a tweak bar. When the button is clicked by a user, the callback function provided to this function is called.
|
|
AddSeparator ( |
This function adds a horizontal separator line to a tweak bar. It may be useful if one wants to separate several sets of variables inside a same group.
|
|
AddVarCB ( |
This function adds a new variable to a tweak bar by providing CallBack (CB) functions to access it.
|
|
AddVarRO ( |
This function adds a new variable to a tweak bar by specifying the variable’s pointer. The variable is declared Read-Only (RO), so it could not be modified interactively by the user.
|
|
AddVarRW ( |
This function adds a new variable to a tweak bar by specifying the variable’s pointer. The variable is declared Read-Write (RW), so it could be modified interactively by the user.
|
|
Define ( String def ) : void |
This function defines optional parameters for tweak bars and variables. For instance, it allows you to change the color of a tweak bar, to set a min and a max value for a variable, to add an help message that inform users of the meaning of a variable, and so on...
|
|
DefineEnum ( String name, String>.IDictionary |
This function creates a new variable type corresponding to an enum.
|
|
DefineEnumFromString ( String name, String enumString ) : VariableType |
This function creates a new variable type corresponding to an enum.
|
|
DefineStruct ( String name, StructMemberInfo>.IDictionary |
This function creates a new AntTweakBar.Tw.VariableType corresponding to a structure.
|
|
DeleteAllBars ( ) : void |
Delete all bars previously created by AntTweakBar.Tw.NewBar.
|
|
DeleteBar ( |
This function deletes a tweak bar previously created by AntTweakBar.Tw.NewBar.
|
|
Draw ( ) : void |
Draws all the created tweak bars. This function must be called once per frame, after all the other drawing calls and just before the application presents (swaps) the frame buffer.
|
|
EventSDL ( |
The SDL event handler.
|
|
EventSFML ( |
The SFML event handler.
|
|
EventWin ( |
The Windows event handler.
|
|
EventX11 ( |
The X11 event handler.
|
|
GetBarByIndex ( int barIndex ) : |
Returns the bar of a given index.
|
|
GetBarByName ( String barName ) : |
Returns the bar of a given name.
|
|
GetBarCount ( ) : int |
Returns the number of created bars.
|
|
GetBarName ( |
Returns the name of a given tweak bar.
|
|
GetBooleanParam ( |
This function returns the current value of a bar or variable parameter.
|
|
GetBottomBar ( ) : |
Returns the identifier of the current background bar (the bar displayed behind the others).
|
|
GetColorParam ( |
This function returns the current value of a bar or variable parameter.
|
|
GetCurrentWindow ( ) : int |
Returns the current window context identifier previously set by AntTweakBar.Tw.SetCurrentWindow.
|
|
GetDoubleParam ( |
This function returns the current value of a bar or variable parameter.
|
|
GetIntParam ( |
This function returns the current value of a bar or variable parameter.
|
|
GetLastError ( ) : String |
Returns the last error that has occured during a previous AntTweakBar function call.
|
|
GetPointParam ( |
This function returns the current value of a bar or variable parameter.
|
|
GetSingleParam ( |
This function returns the current value of a bar or variable parameter.
|
|
GetSizeParam ( |
This function returns the current value of a bar or variable parameter.
|
|
GetStringParam ( |
This function returns the current value of a bar or variable parameter.
|
|
GetTopBar ( ) : |
Returns the identifier of the current foreground bar (the bar displayed on top of the others).
|
|
Init ( GraphicsAPI graphicsAPI, |
This function initializes the AntTweakBar library. It must be called once at the beginning of the program, just after graphic mode is initialized.
|
|
KeyPressed ( |
Call this function to inform AntTweakBar when a keyboard event occurs.
|
|
KeyPressed ( char key, KeyModifiers modifiers ) : bool |
Call this function to inform AntTweakBar when a keyboard event occurs.
|
|
KeyTest ( |
This function checks if a key event would be processed but without processing it. This could be helpful to prevent bad handling report.
|
|
KeyTest ( char key, KeyModifiers modifiers ) : bool |
This function checks if a key event would be processed but without processing it. This could be helpful to prevent bad handling report.
|
|
MouseClick ( MouseAction action, MouseButton button ) : bool |
Call this function to inform AntTweakBar that a mouse button is pressed.
|
|
MouseMotion ( int mouseX, int mouseY ) : bool |
Call this function to inform AntTweakBar that the mouse has moved.
|
|
MouseWheel ( int pos ) : bool |
Call this function to inform AntTweakBar that the mouse wheel has been used.
|
|
NewBar ( string barName ) : |
Creates a new tweak bar.
|
|
RefreshBar ( |
Forces bar content to be updated. By default bar content is periodically refreshed when AntTweakBar.Tw.Draw is called (the update frequency is defined by the bar parameter refresh).
|
|
RemoveAllVars ( |
This function removes all the variables, buttons and separators previously added to a tweak bar.
|
|
RemoveVar ( |
This function removes a variable, button or separator from a tweak bar.
|
|
SetBottomBar ( |
Set the specified bar as the background bar. It will be displayed behind the other bars.
|
|
SetCurrentWindow ( int windowID ) : void |
This function is intended to be used by applications with multiple graphical windows. It tells AntTweakBar to switch its current context to the context associated to the identifier windowID.
|
|
SetParam ( |
This function modifies the value(s) of a bar or variable parameter.
|
|
SetParam ( |
This function modifies the value(s) of a bar or variable parameter.
|
|
SetParam ( |
This function modifies the value(s) of a bar or variable parameter.
|
|
SetParam ( |
This function modifies the value(s) of a bar or variable parameter.
|
|
SetParam ( |
This function modifies the value(s) of a bar or variable parameter.
|
|
SetParam ( |
This function modifies the value(s) of a bar or variable parameter.
|
|
SetTopBar ( |
Set the specified bar as the foreground bar. It will be displayed on top of the other bars.
|
|
Terminate ( ) : void |
Uninitialize the AntTweakBar API. Must be called at the end of the program, before terminating the graphics API.
|
|
WindowExists ( int windowID ) : bool |
Check if a window context associated to the identifier windowID exists. A window context exists if it has previously been created by AntTweakBar.Tw.SetCurrentWindow.
|
|
WindowSize ( int width, int height ) : void |
Call this function to inform AntTweakBar of the size of the application graphics window, or to restore AntTweakBar graphics resources (after a fullscreen switch for instance).
|
Метод | Описание | |
---|---|---|
AlreadyUnpacked ( String path, String checksum ) : bool | ||
Tw ( ) : System |
Initializes the AntTweakBar.NET wrapper.
|
|
UnpackDLL ( ) : void |
public static AddButton ( |
||
bar | The tweak bar to which adding a new variable. | |
name | String | The name of the button. It will be displayed in the tweak bar if no label is specified for this button. It will also be used to refer to this button in other functions. |
callback | ButtonCallback | The callback function that will be called by AntTweakBar when the button is clicked. |
clientData | For your convenience, this is a supplementary pointer that will be passed to the callback function when it is called. | |
def | String | An optional definition string used to modify the behavior of this new entry. |
Результат | void |
public static AddSeparator ( |
||
bar | The tweak bar to which adding the separator. | |
name | String | The name of the separator. It is optional, this parameter can be set to NULL. |
def | String | An optional definition string used to modify the behavior of this new entry. |
Результат | void |
public static AddVarCB ( |
||
bar | The tweak bar to which adding a new variable. | |
name | String | The name of the variable. It will be displayed in the tweak bar if no label is specified for this variable. It will also be used to refer to this variable in other functions. |
type | VariableType | Type of the variable. It must be one of the |
setCallback | SetVarCallback | The callback function that will be called by AntTweakBar to change the variable’s value. |
getCallback | GetVarCallback | The callback function that will be called by AntTweakBar to get the variable’s value. |
clientData | For your convenience, this is a supplementary pointer that will be passed to the callback functions when they are called. | |
def | String | An optional definition string used to modify the behavior of this new entry. |
Результат | void |
public static AddVarRO ( |
||
bar | The tweak bar to which adding a new variable. | |
name | String | The name of the variable. It will be displayed in the tweak bar if no label is specified for this variable. It will also be used to refer to this variable in other functions. |
type | VariableType | Type of the variable. It must be one of the |
var | Pointer to the variable linked to this entry. | |
def | String | An optional definition string used to modify the behavior of this new entry. |
Результат | void |
public static AddVarRW ( |
||
bar | The tweak bar to which adding a new variable. | |
name | String | The name of the variable. It will be displayed in the tweak bar if no label is specified for this variable. It will also be used to refer to this variable in other functions. |
type | VariableType | Type of the variable. It must be one of the |
var | Pointer to the variable linked to this entry. | |
def | String | An optional definition string used to modify the behavior of this new entry. |
Результат | void |
public static Define ( String def ) : void | ||
def | String | A string containing one or more parameter assignments (separated by newlines). |
Результат | void |
public static DefineEnum ( String name, String>.IDictionary |
||
name | String | Specify a name for the enum type (must be unique). |
labels | String>.IDictionary | A mapping from admissible values to their labels. |
Результат | VariableType |
public static DefineEnumFromString ( String name, String enumString ) : VariableType | ||
name | String | Specify a name for the enum type (must be unique). |
enumString | String | Comma-separated list of labels. |
Результат | VariableType |
public static DefineStruct ( String name, StructMemberInfo>.IDictionary |
||
name | String | |
structMembers | StructMemberInfo>.IDictionary | |
structSize | int | |
callback | ||
clientData | ||
Результат | VariableType |
public static DeleteBar ( |
||
bar | Identifier to the tweak bar to delete. | |
Результат | void |
public static EventSDL ( |
||
sdlEvent | ||
majorVersion | byte | |
minorVersion | byte | |
Результат | bool |
public static EventSFML ( |
||
sfmlEvent | ||
majorVersion | byte | |
minorVersion | byte | |
Результат | bool |
public static EventWin ( |
||
wnd | ||
msg | int | |
wParam | ||
lParam | ||
Результат | bool |
public static EventX11 ( |
||
xEvent | ||
Результат | bool |
public static GetBarByIndex ( int barIndex ) : |
||
barIndex | int | Index of the requested bar. |
Результат |
public static GetBarByName ( String barName ) : |
||
barName | String | Name of the requested bar. |
Результат |
public static GetBarName ( |
||
bar | Identifier to the tweak bar. | |
Результат | String |
public static GetBooleanParam ( |
||
bar | ||
varName | String | |
paramName | String | |
Результат | System.Boolean |
public static GetBottomBar ( ) : |
||
Результат |
public static GetColorParam ( |
||
bar | ||
varName | String | |
paramName | String | |
Результат | Color |
public static GetCurrentWindow ( ) : int | ||
Результат | int |
public static GetDoubleParam ( |
||
bar | ||
varName | String | |
paramName | String | |
paramCount | int | |
Результат | Double[] |
public static GetIntParam ( |
||
bar | ||
varName | String | |
paramName | String | |
paramCount | int | |
Результат | System.Int32[] |
public static GetPointParam ( |
||
bar | ||
varName | String | |
paramName | String | |
Результат | Point |
public static GetSingleParam ( |
||
bar | ||
varName | String | |
paramName | String | |
paramCount | int | |
Результат | System.Single[] |
public static GetSizeParam ( |
||
bar | ||
varName | String | |
paramName | String | |
Результат |
public static GetStringParam ( |
||
bar | ||
varName | String | |
paramName | String | |
Результат | String |
public static GetTopBar ( ) : |
||
Результат |
public static Init ( GraphicsAPI graphicsAPI, |
||
graphicsAPI | GraphicsAPI | This parameter specifies which graphic API is used: OpenGL, OpenGL core profile (3.2 and higher), Direct3D 9, Direct3D 10 or Direct3D 11. |
device | Pointer to the Direct3D device, or IntPtr.Zero for OpenGL. | |
Результат | void |
public static KeyPressed ( |
||
key | One of the |
|
modifiers | KeyModifiers | One or a combination of the |
Результат | bool |
public static KeyPressed ( char key, KeyModifiers modifiers ) : bool | ||
key | char | The ASCII code of the pressed key. |
modifiers | KeyModifiers | One or a combination of the |
Результат | bool |
public static KeyTest ( |
||
key | One of the |
|
modifiers | KeyModifiers | One or a combination of the |
Результат | bool |
public static KeyTest ( char key, KeyModifiers modifiers ) : bool | ||
key | char | The ASCII code of the pressed key. |
modifiers | KeyModifiers | One or a combination of the |
Результат | bool |
public static MouseClick ( MouseAction action, MouseButton button ) : bool | ||
action | MouseAction | Tells if the button is pressed or released. It is one of the |
button | MouseButton | Tells which button is pressed. It is one of the |
Результат | bool |
public static MouseMotion ( int mouseX, int mouseY ) : bool | ||
mouseX | int | The new X position of the mouse, relative to the left border of the graphics window. |
mouseY | int | The new Y position of the mouse, relative to the top border of the graphics window. |
Результат | bool |
public static MouseWheel ( int pos ) : bool | ||
pos | int | The new position of the wheel. |
Результат | bool |
public static NewBar ( string barName ) : |
||
barName | string | Name of the new tweak bar. |
Результат |
public static RefreshBar ( |
||
bar | Bar identifier. | |
Результат | void |
public static RemoveAllVars ( |
||
bar | The tweak bar from which to remove all variables. | |
Результат | void |
public static RemoveVar ( |
||
bar | The tweak bar from which to remove a variable. | |
name | String | The name of the variable. |
Результат | void |
public static SetBottomBar ( |
||
bar | Bar identifier. | |
Результат | void |
public static SetCurrentWindow ( int windowID ) : void | ||
windowID | int | Window context identifier. This identifier could be any integer. |
Результат | void |
public static SetParam ( |
||
bar | ||
varName | String | |
paramName | String | |
Результат | void |
public static SetParam ( |
||
bar | ||
varName | String | |
paramName | String | |
boolean | System.Boolean | |
Результат | void |
public static SetParam ( |
||
bar | ||
varName | String | |
paramName | String | |
color | Color | |
Результат | void |
public static SetParam ( |
||
bar | ||
varName | String | |
paramName | String | |
point | Point | |
Результат | void |
public static SetParam ( |
||
bar | ||
varName | String | |
paramName | String | |
size | ||
Результат | void |
public static SetParam ( |
||
bar | ||
varName | String | |
paramName | String | |
value | String | |
Результат | void |
public static SetTopBar ( |
||
bar | Bar identifier. | |
Результат | void |
public static WindowExists ( int windowID ) : bool | ||
windowID | int | Window context identifier. |
Результат | bool |
public static WindowSize ( int width, int height ) : void | ||
width | int | Width of the graphics window. |
height | int | Height of the graphics window. |
Результат | void |