Package net.imglib2

Examples of net.imglib2.Point


                               interleave);
    }

    public static long shuffle(Space space, double x, double y)
    {
        Point point = new Point(x, y);
        long[] zValues = new long[1];
        space.decompose(point, zValues);
        long z = zValues[0];
        assert z != Space.Z_NULL;
        return z;
View Full Code Here


                    }
                    pbits.write(0, bits, 0, bits.length);
                    SIZE size = new SIZE();
                    size.cx = w;
                    size.cy = h;
                    POINT srcLoc = new POINT();
                    BLENDFUNCTION blend = new BLENDFUNCTION();
                    POINT loc = new POINT();
                    loc.x = win.getX();
                    loc.y = win.getY();
                    HWND hWnd = getHWnd(win);
                    // extract current constant alpha setting, if possible
                    ByteByReference bref = new ByteByReference();
View Full Code Here

                pbits.write(0, bits, 0, bits.length);
               
                SIZE size = new SIZE();
                size.cx = w;
                size.cy = h;
                POINT loc = new POINT();
                loc.x = alphaWindow.getX();
                loc.y = alphaWindow.getY();
                POINT srcLoc = new POINT();
                BLENDFUNCTION blend = new BLENDFUNCTION();
                blend.SourceConstantAlpha = (byte)(alpha * 255);
                blend.AlphaFormat = User32.AC_SRC_ALPHA;
                user.UpdateLayeredWindow(hWnd, screenDC, loc, size, memDC, srcLoc,
                                         0, blend, User32.ULW_ALPHA);
View Full Code Here

            List sizes = new ArrayList();
            while (!pi.isDone()) {
                int type = pi.currentSegment(coords);
                if (type == PathIterator.SEG_MOVETO) {
                    size = 1;
                    points.add(new POINT((int)coords[0], (int)coords[1]));
                }
                else if (type == PathIterator.SEG_LINETO) {
                    ++size;
                    points.add(new POINT((int)coords[0], (int)coords[1]));
                }
                else if (type == PathIterator.SEG_CLOSE) {
                    sizes.add(new Integer(size));
                }
                else {
                    throw new RuntimeException("Area is not polygonal: " + area);
                }
                pi.next();
            }
            POINT[] lppt = (POINT[])new POINT().toArray(points.size());
            POINT[] pts = (POINT[])points.toArray(new POINT[points.size()]);
            for (int i=0;i < lppt.length;i++) {
                lppt[i].x = pts[i].x;
                lppt[i].y = pts[i].y;
            }
View Full Code Here

                        pbits.write((v*ww+origin.x)*4, bits, 0, bits.length);
                    }
                    SIZE winSize = new SIZE();
                    winSize.cx = win.getWidth();
                    winSize.cy = win.getHeight();
                    POINT winLoc = new POINT();
                    winLoc.x = win.getX();
                    winLoc.y = win.getY();
                    POINT srcLoc = new POINT();
                    BLENDFUNCTION blend = new BLENDFUNCTION();
                    HWND hWnd = getHWnd(win);
                    // extract current constant alpha setting, if possible
                    ByteByReference bref = new ByteByReference();
                    IntByReference iref = new IntByReference();
View Full Code Here

                pbits.write(0, bits, 0, bits.length);
               
                SIZE size = new SIZE();
                size.cx = w;
                size.cy = h;
                POINT loc = new POINT();
                loc.x = alphaWindow.getX();
                loc.y = alphaWindow.getY();
                POINT srcLoc = new POINT();
                BLENDFUNCTION blend = new BLENDFUNCTION();
                blend.SourceConstantAlpha = (byte)(alpha * 255);
                blend.AlphaFormat = User32.AC_SRC_ALPHA;
                user.UpdateLayeredWindow(hWnd, screenDC, loc, size, memDC, srcLoc,
                                         0, blend, User32.ULW_ALPHA);
View Full Code Here

       
        String description = "";
        if ( fdbo.getString("description") != null )
          description = fdbo.getString("description");
                 
        Point placemark = placemarksFolder.createAndAddPlacemark()
           .withName(fdbo.getString("title")).withOpen(Boolean.TRUE)
           .withDescription(description)
           .createAndSetPoint().addToCoordinates(-0.126236, 51.500152);
      }
    }
View Full Code Here

    max[ dimX ] = target.max( X );
    max[ dimY ] = target.max( Y );

    // TODO: this is ugly, but the only way to make sure, that iteration
    // order fits in the case of one sized dims. Tobi?
    final IterableInterval< A > ii = Views.iterable( Views.interval( source, new FinalInterval( min, max ) ) );

    final Cursor< A > sourceCursor = ii.cursor();

    if ( target.iterationOrder().equals( ii.iterationOrder() ) && !( sourceCursor instanceof RandomAccessibleIntervalCursor ) )
    {
      final Cursor< B > targetCursor = target.cursor();
      while ( targetCursor.hasNext() )
      {
        converter.convert( sourceCursor.next(), targetCursor.next() );
      }
    }
    else if ( target.iterationOrder() instanceof FlatIterationOrder )
    {
      final Cursor< B > targetCursor = target.cursor();
      targetCursor.fwd();
      final FinalInterval sourceInterval = new FinalInterval( min, max );

      // use localizing cursor
      final RandomAccess< A > sourceRandomAccess = source.randomAccess( sourceInterval );
      sourceRandomAccess.setPosition( position );
View Full Code Here

    min[ dimX ] = target.min( dimX );
    min[ dimY ] = target.min( dimY );
    max[ dimX ] = target.max( dimX );
    max[ dimY ] = target.max( dimY );
    final FinalInterval sourceInterval = new FinalInterval( min, max );

    final long cr = -target.dimension( dimX );

    final RandomAccess< B > targetRandomAccess = target.randomAccess( target );
    final RandomAccess< A > sourceRandomAccess = source.randomAccess( sourceInterval );
View Full Code Here

    if ( dimIndex < 0 )
    {
      // there is only converter[0]
      // use it to map the current position
      final RandomAccess< A > sourceRandomAccess = source.randomAccess( new FinalInterval( min, max ) );
      sourceRandomAccess.setPosition( min );
      mapSingle( sourceRandomAccess, converters.get( 0 ) );
      return;
    }

    final int size = updateCurrentArrays();

    min[ dimIndex ] = max[ dimIndex ] = currentPositions[ 0 ];
    for ( int i = 1; i < size; ++i )
      if ( currentPositions[ i ] < min[ dimIndex ] )
        min[ dimIndex ] = currentPositions[ i ];
      else if ( currentPositions[ i ] > max[ dimIndex ] )
        max[ dimIndex ] = currentPositions[ i ];
    final RandomAccess< A > sourceRandomAccess = source.randomAccess( new FinalInterval( min, max ) );
    sourceRandomAccess.setPosition( min );

    if ( size == 1 )
    {
      // there is only one active converter: converter[0]
View Full Code Here

TOP

Related Classes of net.imglib2.Point

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.