Updated linux example
#include <stereokit.h>
using namespace sk;
+mesh_t cube;
+material_t orange_mat;
+
int main() {
- log_set_filter(log_diagnostic);
- sk_init("StereoKit Linux Test", runtime_mixedreality);
- while (sk_step([]() {})) {}
+ // log_set_filter(log_diagnostic);
+ // sk_init("StereoKit Linux Test (OpenXR)", runtime_mixedreality);
+ sk_init("StereoKit Linux Test (Flatscreen)", runtime_flatscreen);
+
+ cube = mesh_gen_rounded_cube(vec3_one, 0.1f, 4);
+
+ orange_mat = material_copy(material_find(default_id_material));
+ material_set_color(orange_mat, "color", { 1,0.5,0,1 });
+
+ while (sk_step([]() {
+ render_add_mesh(cube, orange_mat, matrix_trs(vec3_forward, quat_identity, vec3_one*0.5));
+ })) {}
sk_shutdown();
}
-
-//
-// mesh_t cube;
-// material_t mat;
-//
-// int main() {
-// log_set_filter(log_diagnostic);
-// sk_init("Fabrica C", runtime_flatscreen);
-// render_set_clear_color({ 1,1,1,1 });
-// render_enable_skytex(false);
-//
-// cube = mesh_find (default_id_mesh_cube);
-// mat = material_find(default_id_material);
-//
-// while (sk_step([]() {
-// render_add_mesh(cube, mat, matrix_trs(vec3_zero, quat_identity, vec3_one*0.01));
-// })) {}
-// sk_shutdown();
-// }
