MCPcopy Create free account
hub / github.com/WarmUpTill/SceneSwitcher / UpdateOpenVRPos

Method UpdateOpenVRPos

plugins/openvr/macro-condition-openvr.cpp:268–287  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

266}
267
268void MacroConditionOpenVREdit::UpdateOpenVRPos()
269{
270 vr::EVRInitError err;
271 TrackingData data = getOpenVRPos(err);
272 if (data.valid) {
273 _xPos->setText(QString::number(data.x));
274 _yPos->setText(QString::number(data.y));
275 _zPos->setText(QString::number(data.z));
276 } else {
277 _xPos->setText("-");
278 _yPos->setText("-");
279 _zPos->setText("-");
280 _errLabel->setText(
281 QString(obs_module_text(
282 "AdvSceneSwitcher.condition.openvr.errorStatus")) +
283 QString(vr::VR_GetVRInitErrorAsEnglishDescription(err)));
284 }
285 _errLabel->setVisible(!data.valid);
286 adjustSize();
287}
288
289void MacroConditionOpenVREdit::UpdateEntryData()
290{

Callers

nothing calls this directly

Calls 3

getOpenVRPosFunction · 0.85
obs_module_textFunction · 0.85
setTextMethod · 0.80

Tested by

no test coverage detected