From 4c066a82962a9a0634dcfe0a305de7b2a4cacc5b Mon Sep 17 00:00:00 2001 From: Samuel Fadel Date: Sat, 16 Jan 2016 20:55:45 +0100 Subject: Added the Colormap component. * The Colormap component is a simple rect with a texture mapped that displays a ColorScale with a fixed number of samples. This number of samples is exported as a member const, which is used on other components (such as VoronoiSplat). * The texture mapping is reflecting the colormap lookup used in VoronoiSplat. * The ColorScale class now has a method for sampling the color scale and outputs the samples to iterator-style objects, providing easy intergration with existing code. --- main_view.qml | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'main_view.qml') diff --git a/main_view.qml b/main_view.qml index dc3fe45..68d6fea 100644 --- a/main_view.qml +++ b/main_view.qml @@ -125,6 +125,15 @@ ApplicationWindow { y: parent.y anchors.fill: parent } + + Colormap { + id: colormap + objectName: "colormap" + x: parent.x + 5 + y: parent.y + 5 + width: 128 + height: 10 + } } Rectangle { -- cgit v1.2.3