Skip to content

Commit

Permalink
Mapping simple demo added
Browse files Browse the repository at this point in the history
  • Loading branch information
T-Troll committed Oct 6, 2022
1 parent fcf0c19 commit 716b17a
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions AlienFX Sample App/AlienFX Sample App.cpp
Original file line number Diff line number Diff line change
@@ -1,8 +1,7 @@
// This define disable ACPI-based lights (Aurora R6/R7). You will need to use AlienFan_SDK to control it.
#define NOACPILIGHTS
#include "AlienFX_SDK.h"
#include <iostream>
#include <stdio.h>
#include <tchar.h>

using namespace std;

Expand All @@ -11,7 +10,9 @@ int main()
AlienFX_SDK::Mappings afx_map;
// Loading stored devices and maps (optional, in case you need to know which lights every device has)
afx_map.LoadMappings();
// Now detect devices...
for (auto it = afx_map.fxdevs.begin(); it != afx_map.fxdevs.end(); it++)
cout << "Stored device " << it->name << ", " << it->lights.size() << " lights\n";
// Now detect active devices...
vector<AlienFX_SDK::Functions*> devs = afx_map.AlienFXEnumDevices();
cout << devs.size() << " device(s) detected." << endl;
// And try to set it lights...
Expand Down

0 comments on commit 716b17a

Please sign in to comment.