MXVK Vulkan Framework 0.24.0
C++20 Vulkan rendering framework for practical 2D and 3D application development with SDL3.
Loading...
Searching...
No Matches
shaders.cpp File Reference
#include "mxvk/argz.hpp"
#include "mxvk/mxvk.hpp"
#include "mxvk/mxvk_abstract_model.hpp"
#include "mxvk/mxvk_cv.hpp"
#include "mxvk/mxvk_exception.hpp"
#include <algorithm>
#include <array>
#include <cctype>
#include <chrono>
#include <cmath>
#include <cstdlib>
#include <filesystem>
#include <format>
#include <fstream>
#include <iostream>
#include <opencv2/videoio.hpp>
#include <string>
#include <vector>
#include <glm/ext/matrix_clip_space.hpp>
#include <glm/ext/matrix_transform.hpp>
#include <glm/glm.hpp>

Go to the source code of this file.

Classes

class  example::ExampleWindow

Namespaces

namespace  example

Macros

#define shader_viewer_ASSET_DIR   "."
#define shader_viewer_SHADER_DIR   "."
#define shader_viewer_SOURCE_DIR   "."

Functions

std::string example::joinPath (const std::string &base, const std::string &file)
int main (int argc, char **argv)
std::string example::resolveShaderEntry (const std::string &shader_path, const std::string &entry)
std::string example::trimLine (const std::string &text)

Macro Definition Documentation

◆ shader_viewer_ASSET_DIR

#define shader_viewer_ASSET_DIR   "."

Definition at line 25 of file shaders.cpp.

◆ shader_viewer_SHADER_DIR

#define shader_viewer_SHADER_DIR   "."

Definition at line 29 of file shaders.cpp.

◆ shader_viewer_SOURCE_DIR

#define shader_viewer_SOURCE_DIR   "."

Definition at line 33 of file shaders.cpp.

Function Documentation

◆ main()

int main ( int argc,
char ** argv )

Definition at line 688 of file shaders.cpp.

688 {
689 try {
690 Arguments args = proc_args(argc, argv);
691 example::ExampleWindow ex_window(args, "Shader Viewer");
692 ex_window.loop();
693 } catch (mxvk::Exception &e) {
694 std::cerr << std::format("mxvk: Exception: {}\n", e.text());
695 return EXIT_FAILURE;
696 } catch (ArgException<std::string> &e) {
697 std::cerr << std::format("mxvk: Argument Exception: {}\n", e.text());
698 }
699 return EXIT_SUCCESS;
700}
Arguments proc_args(int &argc, char **argv)
Parse standard libmx2 command-line options from main()'s argv.
Definition argz.hpp:872
Exception thrown by Argz::proc() on unrecognised or malformed options.
Definition argz.hpp:178
String text() const
Definition argz.hpp:182
std::string text() const
Plain data structure returned by proc_args() with all common libmx2 CLI options.
Definition argz.hpp:730