gsl-shell.git - gsl-shell

index : gsl-shell.git
gsl-shell
summary refs log tree commit diff
path: root/agg-plot/utils.cpp
diff options
context:
space:
mode:
authorFrancesco Abbate <francesco.bbt@gmail.com>2012年09月14日 18:16:50 +0200
committerFrancesco Abbate <francesco.bbt@gmail.com>2012年10月15日 00:16:41 +0200
commite46aa3980de06ac7b03eea246c0c15abd8b70c50 (patch)
treef576bf83574a5ce0ba2548dd11eea0be159c1d6e /agg-plot/utils.cpp
parent909a55f830086edad64577b7c0f1386c42fd32ea (diff)
downloadgsl-shell-e46aa3980de06ac7b03eea246c0c15abd8b70c50.tar.gz
Add support for multiple plot windows in FOX interface
Diffstat (limited to 'agg-plot/utils.cpp')
-rw-r--r--agg-plot/utils.cpp 7
1 files changed, 7 insertions, 0 deletions
diff --git a/agg-plot/utils.cpp b/agg-plot/utils.cpp
index 7f6f8697..eb0e908a 100644
--- a/agg-plot/utils.cpp
+++ b/agg-plot/utils.cpp
@@ -14,3 +14,10 @@ trans_affine_compose (agg::trans_affine& a, const agg::trans_affine& b)
a.tx = b.sx * a_tx + b.shx * a_ty + b.tx;
a.ty = b.shy * a_tx + b.sy * a_ty + b.ty;
}
+
+agg::trans_affine affine_matrix(const agg::rect_i& r)
+{
+ double w = r.x2 - r.x1, h = r.y2 - r.y1;
+ double tx = r.x1, ty = r.y1;
+ return agg::trans_affine(w, 0.0, 0.0, h, tx, ty);
+}
generated by cgit v1.2.3 (git 2.25.1) at 2025年09月17日 12:22:39 +0000

AltStyle によって変換されたページ (->オリジナル) /