mirror of
https://github.com/HifiExperiments/overte.git
synced 2025-08-09 01:07:09 +02:00
PlatformInfo JSDoc
This commit is contained in:
parent
9df873cff5
commit
e3ff0bbcdf
1 changed files with 53 additions and 32 deletions
|
@ -13,69 +13,90 @@
|
||||||
|
|
||||||
class QScriptValue;
|
class QScriptValue;
|
||||||
|
|
||||||
|
/**jsdoc
|
||||||
|
* The <code>PlatformInfo</code> API provides information about the computer and controllers being used.
|
||||||
|
*
|
||||||
|
* @namespace PlatformInfo
|
||||||
|
*
|
||||||
|
* @hifi-interface
|
||||||
|
* @hifi-client-entity
|
||||||
|
* @hifi-avatar
|
||||||
|
*/
|
||||||
class PlatformInfoScriptingInterface : public QObject {
|
class PlatformInfoScriptingInterface : public QObject {
|
||||||
Q_OBJECT
|
Q_OBJECT
|
||||||
|
|
||||||
public slots:
|
public slots:
|
||||||
|
/**jsdoc
|
||||||
|
* @function PlatformInfo.getInstance
|
||||||
|
* @deprecated This function is deprecated and will be removed.
|
||||||
|
*/
|
||||||
static PlatformInfoScriptingInterface* getInstance();
|
static PlatformInfoScriptingInterface* getInstance();
|
||||||
|
|
||||||
/**jsdoc
|
/**jsdoc
|
||||||
* Returns the Operating Sytem type
|
* Gets the operating system type.
|
||||||
* @function Test.getOperatingSystemType
|
* @function PlatformInfo.getOperatingSystemType
|
||||||
* @returns {string} "WINDOWS", "MACOS" or "UNKNOWN"
|
* @returns {string} <code>"WINDOWS"</code>, <code>"MACOS"</code>, or <code>"UNKNOWN"</code>.
|
||||||
*/
|
*/
|
||||||
QString getOperatingSystemType();
|
QString getOperatingSystemType();
|
||||||
|
|
||||||
/**jsdoc
|
/**jsdoc
|
||||||
* Returns the CPU brand
|
* Gets information on the CPU.
|
||||||
*function PlatformInfo.getCPUBrand()
|
* @function PlatformInfo.getCPUBrand
|
||||||
* @returns {string} brand of CPU
|
* @returns {string} Information on the CPU.
|
||||||
*/
|
* @example <caption>Report the CPU being used.</caption>
|
||||||
|
* print("CPU: " + PlatformInfo.getCPUBrand());
|
||||||
|
* // Example: Intel(R) Core(TM) i7-7820HK CPU @ 2.90GHz
|
||||||
|
*/
|
||||||
QString getCPUBrand();
|
QString getCPUBrand();
|
||||||
|
|
||||||
/**jsdoc
|
/**jsdoc
|
||||||
* Returns the number of logical CPU cores
|
* Gets the number of logical CPU cores.
|
||||||
*function PlatformInfo.getNumLogicalCores()
|
* @function PlatformInfo.getNumLogicalCores
|
||||||
* @returns {int} number of logical CPU cores
|
* @returns {number} The number of logical CPU cores.
|
||||||
*/
|
*/
|
||||||
unsigned int getNumLogicalCores();
|
unsigned int getNumLogicalCores();
|
||||||
|
|
||||||
/**jsdoc
|
/**jsdoc
|
||||||
* Returns the total system memory in megabyte
|
* Returns the total system memory in megabytes.
|
||||||
*function PlatformInfo.getTotalSystemMemory()
|
* @function PlatformInfo.getTotalSystemMemoryMB
|
||||||
* @returns {int} size of memory in megabytes
|
* @returns {number} the total system memory in megabytes.
|
||||||
*/
|
*/
|
||||||
int getTotalSystemMemoryMB();
|
int getTotalSystemMemoryMB();
|
||||||
|
|
||||||
/**jsdoc
|
/**jsdoc
|
||||||
* Returns the graphics card type
|
* Gets the graphics card type.
|
||||||
* @function Test.getGraphicsCardType
|
* @function PlatformInfo.getGraphicsCardType
|
||||||
* @returns {string} graphics card type
|
* @returns {string} The graphics card type.
|
||||||
*/
|
*/
|
||||||
QString getGraphicsCardType();
|
QString getGraphicsCardType();
|
||||||
|
|
||||||
/**jsdoc
|
/**jsdoc
|
||||||
* Returns true if Oculus Rift is connected (looks for hand controllers)
|
* Checks whether Oculus Touch controllers are connected.
|
||||||
* @function Window.hasRift
|
* @function PlatformInfo.hasRiftControllers
|
||||||
* @returns {boolean} <code>true</code> if running on Windows, otherwise <code>false</code>.*/
|
* @returns {boolean} <code>true</code> if Oculus Touch controllers are connected, <code>false</code> if they aren't.
|
||||||
|
*/
|
||||||
bool hasRiftControllers();
|
bool hasRiftControllers();
|
||||||
|
|
||||||
/**jsdoc
|
/**jsdoc
|
||||||
* Returns true if HTC Vive is connected (looks for hand controllers)
|
* Checks whether Vive controllers are connected.
|
||||||
* @function Window.hasRift
|
* @function PlatformInfo.hasViveControllers
|
||||||
* @returns {boolean} <code>true</code> if running on Windows, otherwise <code>false</code>.*/
|
* @returns {boolean} <code>true</code> if Vive controllers are connected, <code>false</code> if they aren't.
|
||||||
|
*/
|
||||||
bool hasViveControllers();
|
bool hasViveControllers();
|
||||||
|
|
||||||
/**jsdoc
|
/**jsdoc
|
||||||
* Returns true if device supports 3d HTML
|
* Checks whether HTML on 3D surfaces (e.g., Web entities) is supported.
|
||||||
* @function Window.has3DHTML
|
* @function PlatformInfo.has3DHTML
|
||||||
* @returns {boolean} <code>true</code> if device supports 3d HTML, otherwise <code>false</code>.*/
|
* @returns {boolean} <code>true</code> if the current display supports HTML on 3D surfaces, <code>false</code> if it
|
||||||
|
* doesn't.
|
||||||
|
*/
|
||||||
bool has3DHTML();
|
bool has3DHTML();
|
||||||
|
|
||||||
/**jsdoc
|
/**jsdoc
|
||||||
* Returns true if device is standalone
|
* Checks whether Interface is running on a stand-alone HMD device (CPU incorporated into the HMD display).
|
||||||
* @function Window.hasRift
|
* @function PlatformInfo.isStandalone
|
||||||
* @returns {boolean} <code>true</code> if device is a standalone device, otherwise <code>false</code>.*/
|
* @returns {boolean} <code>true</code> if Interface is running on a stand-alone device, <code>false</code> if it isn't.
|
||||||
|
*/
|
||||||
bool isStandalone();
|
bool isStandalone();
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue