NVIDIA Index example code nvidia_logo_transpbg.gif Up
create_stylized_points_and_lines.cpp
Go to the documentation of this file.
1/******************************************************************************
2 * Copyright 2023 NVIDIA Corporation. All rights reserved.
3 *****************************************************************************/
6
7#include <mi/dice.h>
8
9// Include code shared by all examples.
10#include "utility/example_shared.h"
11
12#include <nv/index/icamera.h>
13#include <nv/index/iconfig_settings.h>
14#include <nv/index/iindex.h>
15#include <nv/index/ilight.h>
16#include <nv/index/iline_set.h>
17#include <nv/index/imaterial.h>
18#include <nv/index/ipoint_set.h>
19#include <nv/index/iscene.h>
20#include <nv/index/isession.h>
21
22#include <nv/index/app/index_connect.h>
23#include <nv/index/app/string_dict.h>
24
25#include "utility/canvas_utility.h"
26
27#include <iostream>
28#include <sstream>
29
30//----------------------------------------------------------------------
32 public nv::index::app::Index_connect
33{
34public:
36 :
37 Index_connect()
38 {
39 // INFO_LOG << "DEBUG: Create_stylized_point_and_lines() ctor";
40 }
41
43 {
44 // Note: Index_connect::~Index_connect() will be called after here.
45 // INFO_LOG << "DEBUG: ~Create_stylized_point_and_lines() dtor";
46 }
47
48 // launch application
49 mi::Sint32 launch();
50
51protected:
52 virtual bool evaluate_options(nv::index::app::String_dict& sdict) CPP11_OVERRIDE;
53 // override
55 mi::neuraylib::INetwork_configuration* network_configuration,
56 nv::index::app::String_dict& options) CPP11_OVERRIDE
57 {
58 check_success(network_configuration != 0);
59
60 check_success(options.is_defined("unittest"));
61 const bool is_unittest = nv::index::app::get_bool(options.get("unittest"));
62 if (is_unittest)
63 {
64 info_cout("NETWORK: disabled networking mode.", options);
65 network_configuration->set_mode(mi::neuraylib::INetwork_configuration::MODE_OFF);
66 return true;
67 }
68
69 return initialize_networking_as_default_udp(network_configuration, options);
70 }
71
72private:
73 // Create point set in the scene.
74 //
75 // \param[in] scene_edit IScene for the scene edit.
76 // \param[in] pick_line_style pick line style
77 // \param[in] pick_point_style pick point style
78 // \param[in] transparency true when transparency is on.
79 // \param[in] dice_transaction dice transaction
80 // \return true when success
81 bool create_stylized_lines_and_points(
82 nv::index::IScene* scene_edit,
83 mi::Uint32 pick_line_style,
84 mi::Uint32 pick_point_style,
85 bool transparency,
86 mi::neuraylib::IDice_transaction* dice_transaction);
87
88 // setup camera to see this example scene
89 // \param[in] cam a camera
90 void setup_camera(nv::index::IPerspective_camera* cam) const;
91
92 // render a frame
93 // \param[in] output_fname output rendering image filename
94 // \return performance values
95 nv::index::IFrame_results* render_frame(const std::string& output_fname) const;
96
97 // This session tag
98 mi::neuraylib::Tag m_session_tag;
99 // NVIDIA IndeX cluster configuration
100 mi::base::Handle<nv::index::ICluster_configuration> m_cluster_configuration;
101 // Application layer image file canvas (a render target)
102 mi::base::Handle<nv::index::app::canvas_infrastructure::IIndex_image_file_canvas> m_image_file_canvas;
103 // Create_icons options
104 std::string m_outfname;
105 bool m_is_unittest;
106 std::string m_verify_image_fname;
107 mi::Uint32 m_line_style;
108 mi::Uint32 m_point_style;
109 bool m_transparency;
110};
111
112//----------------------------------------------------------------------
114{
115 mi::Sint32 exit_code = 0;
116
117 // Get DiCE database components
118 {
119 m_cluster_configuration =
120 get_index_interface()->get_api_component<nv::index::ICluster_configuration>();
121 check_success(m_cluster_configuration.is_valid_interface());
122
123 // create image canvas in application_layer
124 m_image_file_canvas = create_image_file_canvas(get_application_layer_interface());
125 check_success(m_image_file_canvas.is_valid_interface());
126
127 // Verifying that local host has joined
128 // This may fail when there is a license problem.
129 check_success(is_local_host_joined(m_cluster_configuration.get()));
130 {
131 // DiCE database access
132 mi::base::Handle<mi::neuraylib::IDice_transaction> dice_transaction(
133 m_global_scope->create_transaction<mi::neuraylib::IDice_transaction>());
134 check_success(dice_transaction.is_valid_interface());
135 {
136 // Setup session information
137 m_session_tag =
138 m_index_session->create_session(dice_transaction.get());
139 check_success(m_session_tag.is_valid());
140 mi::base::Handle< nv::index::ISession const > session(
141 dice_transaction->access< nv::index::ISession const >(
142 m_session_tag));
143 check_success(session.is_valid_interface());
144
145 mi::base::Handle< nv::index::IScene > scene_edit(
146 dice_transaction->edit<nv::index::IScene>(session->get_scene()));
147 check_success(scene_edit.is_valid_interface());
148
149 //----------------------------------------------------------------------
150 // Scene setup: add stylized points and lines, scene parameters, camera.
151 //----------------------------------------------------------------------
152 // Add stylized point and lines to the scene
153 check_success(create_stylized_lines_and_points(scene_edit.get(),
154 m_line_style, m_point_style, m_transparency,
155 dice_transaction.get()));
156
157 // Create and edit a camera. Data distribution is based on
158 // the camera. (Because only visible massive data are
159 // considered)
160 mi::base::Handle< nv::index::IPerspective_camera > cam(
161 scene_edit->create_camera<nv::index::IPerspective_camera>());
162 check_success(cam.is_valid_interface());
163 setup_camera(cam.get());
164 const mi::neuraylib::Tag camera_tag = dice_transaction->store(cam.get());
165 check_success(camera_tag.is_valid());
166
167 const mi::math::Vector<mi::Uint32, 2> buffer_resolution(1025, 1024);
168 m_image_file_canvas->set_resolution(buffer_resolution);
169
170 // Set up the scene
171 mi::math::Bbox_struct< mi::Float32, 3 > const xyz_roi_st = {
172 { 0.0f, 0.0f, 0.0f, },
173 { 500.0f, 500.0f, 500.0f, },
174 };
175
176 // set the region of interest
177 const mi::math::Bbox< mi::Float32, 3 > xyz_roi(xyz_roi_st);
178 check_success(xyz_roi.is_volume());
179 scene_edit->set_clipped_bounding_box(xyz_roi_st);
180
181 // Set the scene global transformation matrix.
182 // only change the coordinate system
183 mi::math::Matrix<mi::Float32, 4, 4> transform_mat(
184 1.0f, 0.0f, 0.0f, 0.0f,
185 0.0f, 1.0f, 0.0f, 0.0f,
186 0.0f, 0.0f, -1.0f, 0.0f,
187 0.0f, 0.0f, 0.0f, 1.0f
188 );
189 scene_edit->set_transform_matrix(transform_mat);
190
191 // Set the current camera to the scene.
192 check_success(camera_tag.is_valid());
193 scene_edit->set_camera(camera_tag);
194 }
195 dice_transaction->commit();
196 }
197
198 // Rendering
199 {
200 const std::string fname = m_transparency ?
201 get_output_file_name(m_outfname, m_point_style) :
202 get_output_file_name(m_outfname, m_line_style);
203 mi::base::Handle<nv::index::IFrame_results> frame_results(render_frame(fname));
204 const mi::base::Handle<nv::index::IError_set> err_set(frame_results->get_error_set());
205 if (err_set->any_errors())
206 {
207 std::ostringstream os;
208
209
210 const mi::Uint32 nb_err = err_set->get_nb_errors();
211 for (mi::Uint32 e = 0; e < nb_err; ++e)
212 {
213 if (e != 0) os << '\n';
214 const mi::base::Handle<nv::index::IError> err(err_set->get_error(e));
215 os << err->get_error_string();
216 }
217
218 ERROR_LOG << "IIndex_rendering rendering call failed with the following error(s): " << '\n'
219 << os.str();
220 exit_code = 1;
221 }
222
223 // verify the generated frame
224 if (!(verify_canvas_result(get_application_layer_interface(),
225 m_image_file_canvas.get(), m_verify_image_fname, get_options())))
226 {
227 exit_code = 1;
228 }
229 }
230 }
231
232 return exit_code;
233}
234
235//----------------------------------------------------------------------
236bool Create_stylized_point_and_lines::evaluate_options(nv::index::app::String_dict& sdict)
237{
238 const std::string com_name = sdict.get("command:", "<unknown_command>");
239 m_is_unittest = nv::index::app::get_bool(sdict.get("unittest", "false"));
240
241 if (m_is_unittest)
242 {
243 if (nv::index::app::get_bool(sdict.get("is_call_from_test", "false")))
244 {
245 sdict.insert("is_dump_comparison_image_when_failed", "0");
246 }
247 sdict.insert("outfname", ""); // turn off file output in the unit test mode
248 sdict.insert("dice::verbose", "2");
249 }
250
251 m_outfname = sdict.get("outfname");
252 m_verify_image_fname = sdict.get("verify_image_fname");
253 m_line_style = nv::index::app::get_uint32(sdict.get("line_style"));
254 m_point_style = nv::index::app::get_uint32(sdict.get("point_style"));
255 m_transparency = nv::index::app::get_bool(sdict.get("transparency", "false"));
256
257 info_cout(std::string("running ") + com_name, sdict);
258 info_cout("outfname = [" + m_outfname +
259 "], verify_image_fname = [" + m_verify_image_fname +
260 "], dice::verbose = " + sdict.get("dice::verbose"), sdict);
261
262 // print help and exit if -h
263 if(sdict.is_defined("h"))
264 {
265 std::cout
266 << "info: Usage: " << com_name << " [option]\n"
267 << "Option: [-h]\n"
268 << " printout this message\n"
269 << " [-dice::verbose severity_level]\n"
270 << " verbose severity level (3 is info.). (default: " + sdict.get("dice::verbose")
271 << ")\n"
272
273 << " [-outfname string]\n"
274 << " output ppm file base name. When empty, no output.\n"
275 << " A frame number and extension (.ppm) will be added.\n"
276 << " (default: [" << m_outfname << "])\n"
277
278 << " [-verify_image_fname [image_fname]]\n"
279 << " when image_fname exist, verify the rendering image. (default: ["
280 << m_verify_image_fname << "])\n"
281
282 << " [-transparency bool]\n"
283 << " to render transparent points. (default: ["
284 << m_transparency << "])\n"
285
286 << " [-line_style unsigned int]\n"
287 << " to choose a line style [0..8]. (default: ["
288 << m_line_style << "])\n"
289
290 << " [-point_style unsigned int]\n"
291 << " to choose a point style [0..3]. (default: ["
292 << m_point_style << "])\n"
293
294 << " [-unittest bool]\n"
295 << " when true, unit test mode (create smaller volume). "
296 << "(default: " << m_is_unittest << ")"
297 << std::endl;
298 exit(1);
299 }
300
301 return true;
302}
303
304//----------------------------------------------------------------------
305bool Create_stylized_point_and_lines::create_stylized_lines_and_points(
306 nv::index::IScene* scene_edit,
307 mi::Uint32 pick_line_style,
308 mi::Uint32 pick_point_style,
309 bool transparency,
310 mi::neuraylib::IDice_transaction* dice_transaction)
311{
312 check_success(scene_edit != 0);
313 check_success(dice_transaction != 0);
314
315 mi::base::Handle<nv::index::ITransformed_scene_group> group_node(
316 scene_edit->create_scene_group<nv::index::ITransformed_scene_group>());
317 check_success(group_node.is_valid_interface());
318
319 // Add a light and a material
320 {
321 // Add a light
322 mi::base::Handle<nv::index::IDirectional_headlight> headlight(
323 scene_edit->create_attribute<nv::index::IDirectional_headlight>());
324 check_success(headlight.is_valid_interface());
325 const mi::math::Color_struct color_intensity = { 1.0f, 1.0f, 1.0f, 1.0f, };
326 headlight->set_intensity(color_intensity);
327 headlight->set_direction(mi::math::Vector<mi::Float32, 3>(1.0f, -1.0f, -1.0f));
328 const mi::neuraylib::Tag headlight_tag = dice_transaction->store_for_reference_counting(headlight.get());
329 check_success(headlight_tag.is_valid());
330 group_node->append(headlight_tag, dice_transaction);
331
332 // add material for 3D points shape (the material is only effective for 3D shape)
333 mi::base::Handle<nv::index::IPhong_gl> phong_1(scene_edit->create_attribute<nv::index::IPhong_gl>());
334 check_success(phong_1.is_valid_interface());
335 phong_1->set_ambient(mi::math::Color(0.3f, 0.3f, 0.3f, 1.0f));
336 phong_1->set_diffuse(mi::math::Color(0.4f, 0.4f, 0.4f, 1.0f));
337 phong_1->set_specular(mi::math::Color(0.4f));
338 phong_1->set_shininess(100.f);
339 const mi::neuraylib::Tag phong_1_tag = dice_transaction->store_for_reference_counting(phong_1.get());
340 check_success(phong_1_tag.is_valid());
341 group_node->append(phong_1_tag, dice_transaction);
342 }
343
344 // square shaped positions
345 const mi::Sint32 column_count = 20;
346 const mi::Sint32 point_count = 200;
347 const mi::Float32 x_mag = 25.f;
348 const mi::Float32 y_mag = 25.f;
349 const mi::Float32 z = 30.f;
350 const mi::Float32 y_offset_points = 0.f;
351 const mi::Float32 y_offset_lines = 255.f;
352
353 // Point coordinates and its attributes. According to the
354 // attributes, color and radius are defined.
355 // Here, we create two point sets.
356 std::vector< mi::math::Vector_struct< mi::Float32, 3> > vertices;
357 std::vector< mi::math::Color_struct> colors;
358 std::vector< mi::Float32 > radii;
359 for(mi::Sint32 i = 0; i < point_count; ++i)
360 {
361 mi::math::Vector_struct< mi::Float32, 3> pos;
362 pos.x = static_cast< mi::Float32 >(i % column_count) * x_mag;
363 pos.y = static_cast< mi::Float32 >(i / column_count) * y_mag + y_offset_points;
364 pos.z = z;
365 vertices.push_back(pos);
366
367 mi::math::Color_struct color;
368 color.r = static_cast<mi::Float32>(i)/static_cast< mi::Float32 >(point_count);
369 color.g = static_cast<mi::Float32>(0.1);
370 color.b = 1.f - static_cast<mi::Float32>(i)/static_cast< mi::Float32 >(point_count);
371 color.a = static_cast<mi::Float32>(1.f);
372 colors.push_back(color);
373
374 mi::Float32 radius = (static_cast<mi::Float32>(i%(column_count))/static_cast<mi::Float32>(column_count)) * 18;
375 radii.push_back(static_cast<mi::Float32>(1+radius));
376 }
377 if(transparency)
378 {
379 for(mi::Sint32 i = 0; i < point_count*2; ++i)
380 {
381 mi::math::Vector_struct< mi::Float32, 3> pos;
382 pos.x = static_cast< mi::Float32 >(i % column_count) * x_mag;
383 pos.y = static_cast< mi::Float32 >(i / column_count) * y_mag + y_offset_points;
384 pos.z = z-3;
385 vertices.push_back(pos);
386
387 mi::math::Color_struct color;
388 color.r = 1.f - static_cast<mi::Float32>(i)/static_cast< mi::Float32 >(point_count);
389 color.g = static_cast<mi::Float32>(i)/static_cast< mi::Float32 >(point_count);
390 color.b = static_cast<mi::Float32>(0.3);
391 color.a = static_cast<mi::Float32>(0.7f);
392 colors.push_back(color);
393
394 mi::Float32 radius = (static_cast<mi::Float32>(i%(column_count))/static_cast<mi::Float32>(column_count)) * 12;
395 radii.push_back(static_cast<mi::Float32>(14-radius));
396 }
397 }
398
399 // Create a point sets
400 nv::index::IPoint_set::Point_style available_point_styles[] =
401 {
402 nv::index::IPoint_set::FLAT_CIRCLE,
403 nv::index::IPoint_set::SHADED_CIRCLE,
404 nv::index::IPoint_set::FLAT_SQUARE,
405 nv::index::IPoint_set::FLAT_TRIANGLE
406 };
407 nv::index::IPoint_set::Point_style chosen_point_style = available_point_styles[pick_point_style];
408
409 // Create point set using the scene's factory
410 mi::base::Handle<nv::index::IPoint_set> point_set(scene_edit->create_shape<nv::index::IPoint_set>());
411 check_success(point_set.is_valid_interface());
412 // ... set the point styles (see IPoint_set)
413 point_set->set_point_style(chosen_point_style);
414 // ... and the vertices with colors and radii.
415 point_set->set_vertices(&vertices[0], vertices.size());
416 point_set->set_colors(&colors[0], colors.size());
417 point_set->set_radii(&radii[0], radii.size());
418
419 // Add the point set to the database.
420 const mi::neuraylib::Tag point_set_scene_element_tag = dice_transaction->store_for_reference_counting(point_set.get());
421 check_success(point_set_scene_element_tag.is_valid());
422
423 // Add to the scene description
424 group_node->append(point_set_scene_element_tag, dice_transaction);
425
426 INFO_LOG << "Added point_set (size: " << vertices.size() << ") to the scene (tag id: " << point_set_scene_element_tag.id << ").";
427
428 nv::index::ILine_set::Line_style available_line_styles[] =
429 {
430 nv::index::ILine_set::LINE_STYLE_SOLID,
431 nv::index::ILine_set::LINE_STYLE_DASHED,
432 nv::index::ILine_set::LINE_STYLE_DOTTED,
433 nv::index::ILine_set::LINE_STYLE_CENTER,
434 nv::index::ILine_set::LINE_STYLE_HIDDEN,
435 nv::index::ILine_set::LINE_STYLE_PHANTOM,
436 nv::index::ILine_set::LINE_STYLE_DASHDOT,
437 nv::index::ILine_set::LINE_STYLE_BORDER,
438 nv::index::ILine_set::LINE_STYLE_DIVIDE
439 };
440
441 nv::index::ILine_set::Line_style chosen_line_style = available_line_styles[pick_line_style];
442
443 // Create a line sets
444 const mi::Uint32 nb_lines = 10;
445 for(mi::Uint32 j=0; j<nb_lines; ++j)
446 {
447 std::vector< mi::math::Vector_struct< mi::Float32, 3> > segment_vertices;
448 std::vector< mi::math::Color_struct> color_per_segment;
449 std::vector< mi::Float32 > width_per_segment;
450
451 mi::math::Vector_struct< mi::Float32, 3> v0;
452 v0.x = static_cast< mi::Float32 >(0.f);
453 v0.y = static_cast< mi::Float32 >(j) * y_mag + y_offset_lines;
454 v0.z = z;
455
456 mi::math::Vector_struct< mi::Float32, 3> v1;
457 v1.x = static_cast< mi::Float32 >(column_count) * x_mag;
458 v1.y = static_cast< mi::Float32 >(j) * y_mag + y_offset_lines;
459 v1.z = z;
460
461 segment_vertices.push_back(v0);
462 segment_vertices.push_back(v1);
463
464 mi::math::Color_struct color;
465 color.r = static_cast<mi::Float32>(j)/static_cast< mi::Float32 >(nb_lines);
466 color.g = static_cast<mi::Float32>(0.1);
467 color.b = 1.f - static_cast<mi::Float32>(j)/static_cast< mi::Float32 >(nb_lines);
468 color.a = static_cast<mi::Float32>(1.f);
469 color_per_segment.push_back(color);
470
471 mi::Float32 width = static_cast<mi::Float32>(1.3*nb_lines+1-j);
472 width_per_segment.push_back(static_cast<mi::Float32>(width));
473
474 // Create line set using the scene's factory
475 mi::base::Handle<nv::index::ILine_set> line_set(scene_edit->create_shape<nv::index::ILine_set>());
476 check_success(line_set.is_valid_interface());
477 // ... set the line style such a dashed or dotted or solid linestyle (see ILine_set)
478 line_set->set_line_style(chosen_line_style);
479 // ... set the line type. Currently only line segments are supported (see ILine_set)
480 line_set->set_line_type(nv::index::ILine_set::LINE_TYPE_SEGMENTS);
481 // ... and the lines with colors and widths all in line segment order.
482 line_set->set_lines(&segment_vertices[0], segment_vertices.size());
483 line_set->set_colors(&color_per_segment[0], color_per_segment.size());
484 line_set->set_widths(&width_per_segment[0], width_per_segment.size());
485
486 // Add the lines to the database
487 const mi::neuraylib::Tag line_set_scene_element_tag = dice_transaction->store_for_reference_counting(line_set.get());
488 // If you haven't registered the Line_set, the next check fails.
489 check_success(line_set_scene_element_tag.is_valid());
490 // Add to the scene description
491 group_node->append(line_set_scene_element_tag, dice_transaction);
492 INFO_LOG << "Added line_set with line style " << pick_line_style << " to the scene (tag id: " << line_set_scene_element_tag.id << ").";
493 }
494
495 mi::neuraylib::Tag group_node_tag = dice_transaction->store_for_reference_counting(group_node.get());
496 check_success(group_node_tag.is_valid());
497 scene_edit->append(group_node_tag, dice_transaction);
498
499 return true;
500}
501
502//----------------------------------------------------------------------
503void Create_stylized_point_and_lines::setup_camera(nv::index::IPerspective_camera* cam) const
504{
505 check_success(cam != 0);
506
507 // Set the camera parameters to see the whole scene
508 mi::math::Vector< mi::Float32, 3 > const from( 254.0f, 254.0f, 550.0f);
509 mi::math::Vector< mi::Float32, 3 > const to ( 255.0f, 255.0f, -255.0f);
510 mi::math::Vector< mi::Float32, 3 > const up ( 0.0f, 1.0f, 0.0f);
511 mi::math::Vector<mi::Float32, 3> viewdir = to - from;
512 viewdir.normalize();
513
514 cam->set(from, viewdir, up);
515 cam->set_aperture(0.033f);
516 cam->set_aspect(1.0f);
517 cam->set_focal(0.03f);
518 cam->set_clip_min(10.0f);
519 cam->set_clip_max(5000.0f);
520}
521
522//----------------------------------------------------------------------
523nv::index::IFrame_results* Create_stylized_point_and_lines::render_frame(const std::string& output_fname) const
524{
525 check_success(m_index_rendering.is_valid_interface());
526
527 // set output filename, empty string is valid
528 m_image_file_canvas->set_rgba_file_name(output_fname.c_str());
529
530 check_success(m_session_tag.is_valid());
531
532 mi::base::Handle<mi::neuraylib::IDice_transaction> dice_transaction(
533 m_global_scope->create_transaction<mi::neuraylib::IDice_transaction>());
534 check_success(dice_transaction.is_valid_interface());
535
536 m_index_session->update(m_session_tag, dice_transaction.get());
537
538 mi::base::Handle<nv::index::IFrame_results> frame_results(
539 m_index_rendering->render(
540 m_session_tag,
541 m_image_file_canvas.get(),
542 dice_transaction.get()));
543 check_success(frame_results.is_valid_interface());
544
545 dice_transaction->commit();
546
547 frame_results->retain();
548 return frame_results.get();
549}
550
551//----------------------------------------------------------------------
552// This example shows how to create stylized points and lines in the scene.
553int main(int argc, const char* argv[])
554{
555 const std::string com_name(argv[0]);
556
557 nv::index::app::String_dict sdict;
558 sdict.insert("dice::verbose", "3"); // log level
559 sdict.insert("outfname", "frame_create_stylized_points_and_lines"); // output file base name
560 sdict.insert("verify_image_fname", ""); // for unit test
561 sdict.insert("line_style", "0"); //
562 sdict.insert("point_style", "0"); //
563 sdict.insert("transparency", "0"); //
564 sdict.insert("unittest", "0"); // default mode
565 sdict.insert("is_dump_comparison_image_when_failed", "1"); // default: dump images when failed.
566 sdict.insert("is_call_from_test", "0"); // default: not call from make check.
567
568 // Load IndeX library via Index_connect
569 sdict.insert("dice::network::mode", "OFF");
570
571 // index setting
572 sdict.insert("index::config::set_monitor_performance_values", "true");
573 sdict.insert("index::service", "rendering_and_compositing");
574 sdict.insert("index::cuda_debug_checks", "false");
575
576 // application_layer component loading
577 sdict.insert("index::app::components::application_layer::component_name_list",
578 "canvas_infrastructure image io");
579
580 // Initialize application
581 Create_stylized_point_and_lines create_stylized_point_and_lines;
582 create_stylized_point_and_lines.initialize(argc, argv, sdict);
583 check_success(create_stylized_point_and_lines.is_initialized());
584
585 // launch the application. creating the scene and rendering.
586 const mi::Sint32 exit_code = create_stylized_point_and_lines.launch();
587 INFO_LOG << "Shutting down ...";
588
589 return exit_code;
590}
virtual bool initialize_networking(mi::neuraylib::INetwork_configuration *network_configuration, nv::index::app::String_dict &options) CPP11_OVERRIDE
virtual bool evaluate_options(nv::index::app::String_dict &sdict) CPP11_OVERRIDE
int main(int argc, const char *argv[])
#define check_success(expr)