15 #include <visiontransfer/deviceenumeration.h> 16 #include <visiontransfer/imagetransfer.h> 17 #include <visiontransfer/imageset.h> 18 #include <visiontransfer/deviceparameters.h> 30 int main(
int argc,
const char** argv) {
36 if(devices.size() == 0) {
37 std::cout <<
"No devices discovered!" << std::endl;
42 std::cout <<
"Discovered devices:" << std::endl;
43 for(
unsigned int i = 0; i< devices.size(); i++) {
44 std::cout << devices[i].toString() << std::endl;
46 std::cout << std::endl;
53 bool uni = parameters.getParameter(
"uniqueness_check_enabled").getCurrent<
bool>();
54 bool tex = parameters.getParameter(
"texture_filter_enabled").getCurrent<
bool>();
55 std::cout <<
"Current values:" << std::endl;
56 std::cout <<
" uniqueness_check_enabled == " << (uni?
"true":
"false") << std::endl;
57 std::cout <<
" texture_filter_enabled == " << (tex?
"true":
"false") << std::endl;
61 std::cout <<
"Starting transaction" << std::endl;
63 auto transactionLock = parameters.transactionLock();
64 parameters.setParameter(
"uniqueness_check_enabled", !uni);
65 parameters.setParameter(
"texture_filter_enabled", !tex);
67 std::cout <<
"Transaction complete" << std::endl;
70 uni = parameters.getParameter(
"uniqueness_check_enabled").getCurrent<
bool>();
71 tex = parameters.getParameter(
"texture_filter_enabled").getCurrent<
bool>();
72 std::cout <<
"New values:" << std::endl;
73 std::cout <<
" uniqueness_check_enabled == " << (uni?
"true":
"false") << std::endl;
74 std::cout <<
" texture_filter_enabled == " << (tex?
"true":
"false") << std::endl;
77 }
catch(
const std::exception& ex) {
84 std::cerr <<
"Exception occurred: " << ex.what() << std::endl;
DeviceList discoverDevices()
Discovers new devices and returns the list of all devices that have been found.
Allows for configuration of the parameters of a Nerian stereo device through a network connection...
Allows for the discovery of devices in the network.