All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.diirt.graphene.profile.impl.ProfileBubbleGraph2D Maven / Gradle / Ivy

There is a newer version: 3.1.7
Show newest version
/**
 * Copyright (C) 2010-14 diirt developers. See COPYRIGHT.TXT
 * All rights reserved. Use is subject to license terms. See LICENSE.TXT
 */
package org.diirt.graphene.profile.impl;

import java.awt.Graphics2D;
import java.util.LinkedHashMap;
import org.diirt.graphene.BubbleGraph2DRenderer;
import org.diirt.graphene.Graph2DRendererUpdate;
import org.diirt.graphene.Point3DWithLabelDataset;
import org.diirt.graphene.profile.ProfileGraph2D;
import org.diirt.graphene.profile.utils.DatasetFactory;

/**
 * Handles profiling for BubbleGraph2DRenderer.
 * Takes a Point3DWithLabelDataset dataset and repeatedly renders 
 * through a Point3DWithLabelDataset.
 * 
 * @author asbarber
 */
public class ProfileBubbleGraph2D extends ProfileGraph2D{

    @Override
    protected Point3DWithLabelDataset getDataset() {
        return DatasetFactory.makePoint3DWithLabelGaussianRandomData(super.getNumDataPoints());
    }

    @Override
    protected BubbleGraph2DRenderer getRenderer(int imageWidth, int imageHeight) {
        return new BubbleGraph2DRenderer(imageWidth, imageHeight);
    }

    @Override
    protected void render(Graphics2D graphics, BubbleGraph2DRenderer renderer, Point3DWithLabelDataset data) {
        renderer.draw(graphics, data);
    }
   
    @Override
    public LinkedHashMap getVariations() {
        LinkedHashMap map = new LinkedHashMap<>();
        
        map.put("None", null);

        return map;
    }

    @Override
    public String getGraphTitle() {
        return "BubbleGraph2D";
    }
    
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy