1
# -*- coding: utf-8 -*-
3
# Copyright © 2009-2010 CEA
5
# Licensed under the terms of the CECILL License
6
# (see guidata/__init__.py for details)
8
"""RGB Image test, creating the RGBImageItem object via make.rgbimage"""
10
SHOW = True # Show test in GUI-based test launcher
14
from guiqwt.plot import ImageDialog
15
from guiqwt.builder import make
18
SHOW = True # Show test in GUI-based test launcher
20
TESTDIR = osp.abspath(osp.dirname(__file__))
21
IMGFILE = osp.join(TESTDIR, "..", "images", "items", "image.png")
24
win = ImageDialog(edit=False, toolbar=True, wintitle="RGB image item test")
25
item = make.rgbimage(data, xdata=[-1, 1], ydata=[-1, 1])
33
# -- Create QApplication
35
_app = guidata.qapplication()
37
from PIL.Image import open
38
img = np.array(open(IMGFILE))
42
if __name__ == "__main__":