Search in sources :

Example 16 with APIBuffer

use of com.jme3.lwjgl3.utils.APIBuffer in project jmonkeyengine by jMonkeyEngine.

the class InfoQueryInt method getStringASCII.

/**
     * Returns the string value for the specified {@code param_name}. The raw
     * bytes returned are assumed to be ASCII encoded.
     *
     * @param object the object to query
     * @param arg an integer argument
     * @param param_name the parameter to query
     *
     * @return the parameter's string value
     */
String getStringASCII(long object, int arg, int param_name) {
    APIBuffer __buffer = apiBuffer();
    int bytes = getString(object, arg, param_name, __buffer);
    return __buffer.stringValueASCII(0, bytes);
}
Also used : APIBuffer(com.jme3.lwjgl3.utils.APIBuffer)

Example 17 with APIBuffer

use of com.jme3.lwjgl3.utils.APIBuffer in project jmonkeyengine by jMonkeyEngine.

the class InfoQueryInt method getStringUTF8.

/**
     * Returns the string value for the specified {@code param_name}. The raw
     * bytes returned are assumed to be UTF-8 encoded and have length equal to {@code
     * param_value_size}.
     *
     * @param object the object to query
     * @param arg an integer argument
     * @param param_name the parameter to query
     * @param param_value_size the explicit string length
     *
     * @return the parameter's string value
     */
String getStringUTF8(long object, int arg, int param_name, int param_value_size) {
    APIBuffer __buffer = apiBuffer();
    int errcode = get(object, arg, param_name, param_value_size, __buffer.address(), NULL);
    if (DEBUG) {
        checkCLError(errcode);
    }
    return __buffer.stringValueUTF8(0, param_value_size);
}
Also used : APIBuffer(com.jme3.lwjgl3.utils.APIBuffer)

Example 18 with APIBuffer

use of com.jme3.lwjgl3.utils.APIBuffer in project jmonkeyengine by jMonkeyEngine.

the class InfoQuery method getStringASCII.

/**
     * Returns the string value for the specified {@code param_name}. The raw
     * bytes returned are assumed to be ASCII encoded and have length equal to {@code
     * param_value_size}.
     *
     * @param object the object to query
     * @param param_name the parameter to query
     * @param param_value_size the explicit string length
     *
     * @return the parameter's string value
     */
String getStringASCII(long object, int param_name, int param_value_size) {
    APIBuffer __buffer = apiBuffer();
    int errcode = get(object, param_name, param_value_size, __buffer.address(), NULL);
    if (DEBUG) {
        checkCLError(errcode);
    }
    return __buffer.stringValueASCII(0, param_value_size);
}
Also used : APIBuffer(com.jme3.lwjgl3.utils.APIBuffer)

Aggregations

APIBuffer (com.jme3.lwjgl3.utils.APIBuffer)18