2017-05-26 16:33:29 +10:00
|
|
|
/*
|
2018-08-04 15:24:36 +10:00
|
|
|
* This Source Code Form is subject to the terms of the Mozilla Public
|
|
|
|
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
|
|
|
* file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
2017-05-26 16:33:29 +10:00
|
|
|
*
|
|
|
|
* Copyright:
|
|
|
|
* 2017, Danny Robson <danny@nerdcruft.net>
|
|
|
|
*/
|
|
|
|
|
2017-09-05 17:20:17 +10:00
|
|
|
#include <cruft/util/iterator.hpp>
|
|
|
|
|
2017-05-26 16:33:29 +10:00
|
|
|
#include <cruft/vk/instance.hpp>
|
|
|
|
#include <cruft/vk/physical_device.hpp>
|
|
|
|
#include <cruft/vk/ostream.hpp>
|
|
|
|
|
|
|
|
#include <iostream>
|
|
|
|
|
2017-09-05 17:20:17 +10:00
|
|
|
|
2018-08-24 17:33:09 +10:00
|
|
|
#include "../icd/vendor.hpp"
|
|
|
|
|
|
|
|
|
2017-05-26 16:33:29 +10:00
|
|
|
///////////////////////////////////////////////////////////////////////////////
|
|
|
|
int
|
|
|
|
main (int, char**)
|
|
|
|
{
|
2018-08-24 17:33:09 +10:00
|
|
|
auto all = cruft::vk::icd::enumerate ();
|
|
|
|
for (auto const &i: all) {
|
|
|
|
cruft::vk::icd::vendor v (i);
|
|
|
|
}
|
|
|
|
|
|
|
|
|
2017-09-05 17:20:17 +10:00
|
|
|
std::cout << "available_layers: [ "
|
2018-08-05 14:51:18 +10:00
|
|
|
<< cruft::make_infix (cruft::vk::instance::available_layers ())
|
2017-09-05 17:20:17 +10:00
|
|
|
<< " ]\n";
|
|
|
|
|
2017-09-01 12:34:24 +10:00
|
|
|
cruft::vk::instance instance;
|
2017-05-26 16:33:29 +10:00
|
|
|
std::cout << "instance: " << instance << '\n';
|
|
|
|
|
2017-09-01 12:14:36 +10:00
|
|
|
for (const auto &d: cruft::vk::physical_device::find (instance))
|
2017-05-26 16:33:29 +10:00
|
|
|
std::cout << d << '\n';
|
|
|
|
}
|