Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/supermerill/SuperSlicer.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEnrico Turri <enricoturri@seznam.cz>2019-10-21 12:06:18 +0300
committerEnrico Turri <enricoturri@seznam.cz>2019-10-21 12:06:18 +0300
commita065c923029e104097c6145d4313327a5f2cb633 (patch)
tree16e335485a8ed6849b657419ce9326ded75abac9 /src/slic3r/GUI/Mouse3DController.cpp
parente773f667b11fd25e847047144d8b2878f4cae46f (diff)
Mouse3DController -> Enabled debug output to check device connection on Linux and Max
Diffstat (limited to 'src/slic3r/GUI/Mouse3DController.cpp')
-rw-r--r--src/slic3r/GUI/Mouse3DController.cpp14
1 files changed, 13 insertions, 1 deletions
diff --git a/src/slic3r/GUI/Mouse3DController.cpp b/src/slic3r/GUI/Mouse3DController.cpp
index 631844c5c..80bc6eb6c 100644
--- a/src/slic3r/GUI/Mouse3DController.cpp
+++ b/src/slic3r/GUI/Mouse3DController.cpp
@@ -345,7 +345,8 @@ bool Mouse3DController::connect_device()
std::wcout << ((cur->manufacturer_string != nullptr) ? cur->manufacturer_string : L"Unknown");
std::cout << "::";
std::wcout << ((cur->product_string != nullptr) ? cur->product_string : L"Unknown");
- std::cout << "' code: " << cur->vendor_id << "/" << cur->product_id << " (" << std::hex << cur->vendor_id << "/" << cur->product_id << std::dec << ")" << std::endl;
+ std::cout << "' code: " << cur->vendor_id << "/" << cur->product_id << " (" << std::hex << cur->vendor_id << "/" << cur->product_id << std::dec << ")";
+ std::cout << " usage page: " << cur->usage_page << " usage: " << cur->usage << std::endl;
cur = cur->next;
}
@@ -411,6 +412,7 @@ bool Mouse3DController::connect_device()
std::cout << "Manufacturer/product: " << m_device_str << std::endl;
std::cout << "Manufacturer id.....: " << vendor_id << " (" << std::hex << vendor_id << std::dec << ")" << std::endl;
std::cout << "Product id..........: " << product_id << " (" << std::hex << product_id << std::dec << ")" << std::endl;
+ std::cout << "Path................: '" << path << "'" << std::endl;
#endif // ENABLE_3DCONNEXION_DEVICES_DEBUG_OUTPUT
// get device parameters from the config, if present
@@ -428,6 +430,16 @@ bool Mouse3DController::connect_device()
m_state.set_rotation_scale(State::DefaultRotationScale * std::max(0.5f, std::min(2.0f, rotation_speed)));
m_state.set_rotation_deadzone(std::max(0.0f, std::min(State::MaxRotationDeadzone, rotation_deadzone)));
}
+#if ENABLE_3DCONNEXION_DEVICES_DEBUG_OUTPUT
+ else
+ {
+ std::cout << std::endl << "Unable to connect to device:" << std::endl;
+ std::cout << "Manufacturer/product: " << m_device_str << std::endl;
+ std::cout << "Manufacturer id.....: " << vendor_id << " (" << std::hex << vendor_id << std::dec << ")" << std::endl;
+ std::cout << "Product id..........: " << product_id << " (" << std::hex << product_id << std::dec << ")" << std::endl;
+ std::cout << "Path................: '" << path << "'" << std::endl;
+ }
+#endif // ENABLE_3DCONNEXION_DEVICES_DEBUG_OUTPUT
return (m_device != nullptr);
}