Revision: 56548
http://sourceforge.net/p/brlcad/code/56548
Author: brlcad
Date: 2013-08-05 04:00:33 +0000 (Mon, 05 Aug 2013)
Log Message:
-----------
took me a while to get why mike added this snippet, but it's basically an
example of how (via code) to reverse construct the model2view matrix from the
information output to the rt log. keep it for reference, but make it code
comment documentation instead of dead code.
Modified Paths:
--------------
brlcad/trunk/src/rt/do.c
Modified: brlcad/trunk/src/rt/do.c
===================================================================
--- brlcad/trunk/src/rt/do.c 2013-08-05 03:46:56 UTC (rev 56547)
+++ brlcad/trunk/src/rt/do.c 2013-08-05 04:00:33 UTC (rev 56548)
@@ -633,28 +633,28 @@
bu_log("Orientation: %g, %g, %g, %g\n", V4ARGS(quat));
bu_log("Eye_pos: %g, %g, %g\n", V3ARGS(eye_model));
bu_log("Size: %gmm\n", viewsize);
-#if 0
- /*
+
+ /**
* This code shows how the model2view matrix can be
* reconstructed using the information from the Orientation,
- * Eye_pos, and Size messages.
+ * Eye_pos, and Size messages in the rt log output.
+ @code
+ {
+ mat_t rotscale, xlate, newmat;
+ quat_t newquat;
+ bn_mat_print("model2view", model2view);
+ quat_quat2mat(rotscale, quat);
+ rotscale[15] = 0.5 * viewsize;
+ MAT_IDN(xlate);
+ MAT_DELTAS_VEC_NEG(xlate, eye_model);
+ bn_mat_mul(newmat, rotscale, xlate);
+ bn_mat_print("reconstructed m2v", newmat);
+ quat_mat2quat(newquat, newmat);
+ HPRINT("reconstructed orientation:", newquat);
+ @endcode
+ *
*/
- {
- mat_t rotscale, xlate;
- mat_t newmat;
- quat_t newquat;
- bn_mat_print("model2view", model2view);
- quat_quat2mat(rotscale, quat);
- rotscale[15] = 0.5 * viewsize;
- MAT_IDN(xlate);
- MAT_DELTAS_VEC_NEG(xlate, eye_model);
- bn_mat_mul(newmat, rotscale, xlate);
- bn_mat_print("reconstructed m2v", newmat);
- quat_mat2quat(newquat, newmat);
- HPRINT("reconstructed orientation:", newquat);
- }
-#endif
bu_log("Grid: (%g, %g) mm, (%zu, %zu) pixels\n",
cell_width, cell_height,
width, height);
This was sent by the SourceForge.net collaborative development platform, the
world's largest Open Source development site.
------------------------------------------------------------------------------
Get your SQL database under version control now!
Version control is standard for application code, but databases havent
caught up. So what steps can you take to put your SQL databases under
version control? Why should you start doing it? Read more to find out.
http://pubads.g.doubleclick.net/gampad/clk?id=49501711&iu=/4140/ostg.clktrk
_______________________________________________
BRL-CAD Source Commits mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/brlcad-commits