当前位置: 首页>>代码示例>>Java>>正文


Java StackWindow类代码示例

本文整理汇总了Java中ij.gui.StackWindow的典型用法代码示例。如果您正苦于以下问题:Java StackWindow类的具体用法?Java StackWindow怎么用?Java StackWindow使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。


StackWindow类属于ij.gui包,在下文中一共展示了StackWindow类的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: SurfacePlotGroup

import ij.gui.StackWindow; //导入依赖的package包/类
/**
 * Constructs a surface plot for the given Content.
 * 
 * @param c
 */
public SurfacePlotGroup(final ContentInstant c) {
	super();
	this.c = c;
	final int res = c.getResamplingFactor();
	final ImagePlus imp =
		res == 1 ? c.getImage() : NaiveResampler.resample(c.getImage(), res, res,
			1);
	final Volume volume = new Volume(imp);
	volume.setChannels(c.getChannels());
	surfacep =
		new SurfacePlot(volume, c.getColor(), c.getTransparency(), c.getImage()
			.getSlice() - 1);

	surfacep.calculateMinMaxCenterPoint(min, max, center);
	addChild(surfacep);
	if (c.getImage().getStackSize() == 1) return;
	final StackWindow win = (StackWindow) c.getImage().getWindow();
	if (win == null) return;
	final Component[] co = win.getComponents();
	for (int i = 0; i < co.length; i++) {
		if (co[i] instanceof Scrollbar) {
			((Scrollbar) co[i]).addAdjustmentListener(this);
		}
	}
}
 
开发者ID:fiji,项目名称:3D_Viewer,代码行数:31,代码来源:SurfacePlotGroup.java

示例2: read

import ij.gui.StackWindow; //导入依赖的package包/类
public ImageWindow read(
        FileLinkElement elementToRead) 
        throws SlideSetException {
    String path = elementToRead.getUnderlying();
    String wd = elementToRead.getOwner().getWorkingDirectory();
    wd = wd == null ? "" : wd;
    if(!(new File(path)).isAbsolute())
        path = wd + File.separator + path;
    if(!(new File(path).exists()))
       throw new LinkNotFoundException(path + " does not exist!");
    ImagePlus img = IJ.openImage(path);
    if(img == null)
        throw new ImgLinkException("Unable to read " + path);
    return new StackWindow(img);
}
 
开发者ID:bnanes,项目名称:slideset,代码行数:16,代码来源:ImageFileToImageWindowReader.java

示例3: getCanvas

import ij.gui.StackWindow; //导入依赖的package包/类
Component getCanvas(ImagePlus imp) {
	StackWindow window = new StackWindow(imp);
	window.setVisible(false);
	return window.getComponents()[0];
}
 
开发者ID:akmaier,项目名称:CONRAD,代码行数:6,代码来源:GeometricCalibrationGUI.java


注:本文中的ij.gui.StackWindow类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。