xbmc
Static Public Member Functions | List of all members
CWIN32Util Class Reference

Static Public Member Functions

static char FirstDriveFromMask (ULONG unitmask)
 
static int GetDriveStatus (const std::string &strPath, bool bStatusEx=false)
 
static bool XBMCShellExecute (const std::string &strPath, bool bWaitForScriptExit=false)
 
static std::string GetResInfoString ()
 
static int GetDesktopColorDepth ()
 
static size_t GetSystemMemorySize ()
 
static std::string GetSystemPath ()
 
static std::string GetProfilePath (const bool platformDirectories)
 
static std::string UncToSmb (const std::string &strPath)
 
static std::string SmbToUnc (const std::string &strPath)
 
static bool AddExtraLongPathPrefix (std::wstring &path)
 
static bool RemoveExtraLongPathPrefix (std::wstring &path)
 
static std::wstring ConvertPathToWin32Form (const std::string &pathUtf8)
 
static std::wstring ConvertPathToWin32Form (const CURL &url)
 
static __time64_t fileTimeToTimeT (const __int64 ftimei64)
 
static __time64_t fileTimeToTimeT (const FILETIME &ftimeft)
 
static __time64_t fileTimeToTimeT (const LARGE_INTEGER &ftimeli)
 
static HRESULT ToggleTray (const char cDriveLetter='\0')
 
static HRESULT EjectTray (const char cDriveLetter='\0')
 
static HRESULT CloseTray (const char cDriveLetter='\0')
 
static BOOL IsCurrentUserLocalAdministrator ()
 
static void CropSource (CRect &src, CRect &dst, CRect target, UINT rotation=0)
 
static std::string WUSysMsg (DWORD dwError)
 
static bool SetThreadLocalLocale (bool enable=true)
 
static HDR_STATUS ToggleWindowsHDR (DXGI_MODE_DESC &modeDesc)
 
static HDR_STATUS GetWindowsHDRStatus ()
 
static bool GetSystemSdrWhiteLevel (const std::wstring &gdiDeviceName, float *sdrWhiteLevel)
 Retrieve from the system the max luminance of SDR content in HDR. More...
 
static void PlatformSyslog ()
 
static VideoDriverInfo GetVideoDriverInfo (const UINT vendorId, const std::wstring &driverDesc)
 
static std::wstring GetDisplayFriendlyName (const std::wstring &GdiDeviceName)
 
static bool SetThreadName (const HANDLE handle, const std::string &name)
 Set the thread name using SetThreadDescription when available. More...
 

Member Function Documentation

◆ GetSystemSdrWhiteLevel()

bool CWIN32Util::GetSystemSdrWhiteLevel ( const std::wstring &  gdiDeviceName,
float *  sdrWhiteLevel 
)
static

Retrieve from the system the max luminance of SDR content in HDR.

Retrieve from the system the max luminance of SDR content in HDR. Note: always returns 80 nits when the screen is in SDR mode.

Parameters
gdiDeviceNameThe screen to retrieve the information for
sdrWhiteLevelMax luminance in nits, clamped to 10000
Returns
true if a value could be read from the system and copied to sdrWhiteLevel, false otherwise

◆ SetThreadName()

bool CWIN32Util::SetThreadName ( const HANDLE  handle,
const std::string &  name 
)
static

Set the thread name using SetThreadDescription when available.

Parameters
handlehandle of the thread
namename of the thread
Returns
true if the name was successfully set, false otherwise (API not supported or API failure)

◆ XBMCShellExecute()

bool CWIN32Util::XBMCShellExecute ( const std::string &  strPath,
bool  bWaitForScriptExit = false 
)
static
Todo:
Pause music and video playback

The documentation for this class was generated from the following files: