Package org.apache.sanselan.formats.png.chunks

Examples of org.apache.sanselan.formats.png.chunks.PNGChunkgAMA


                else if (chunkType == pHYs)
                    result.add(new PNGChunkpHYs(length, chunkType, CRC, bytes));
                else if (chunkType == IDAT)
                    result.add(new PNGChunkIDAT(length, chunkType, CRC, bytes));
                else if (chunkType == gAMA)
                    result.add(new PNGChunkgAMA(length, chunkType, CRC, bytes));
                else if (chunkType == iTXt)
                    result.add(new PNGChunkiTXt(length, chunkType, CRC, bytes));
                else
                    result.add(new PNGChunk(length, chunkType, CRC, bytes));
View Full Code Here


                byte bytes[] = pngChunkiCCP.UncompressedProfile;

                icc_profile = ICC_Profile.getInstance(bytes);
            } else if (gAMAs.size() == 1)
            {
                PNGChunkgAMA pngChunkgAMA = (PNGChunkgAMA) gAMAs.get(0);
                double gamma = pngChunkgAMA.getGamma();

                // charles: what is the correct target value here?
                // double targetGamma = 2.2;
                double targetGamma = 1.0;
                double diff = Math.abs(targetGamma - gamma);
View Full Code Here

        else if (chunkType == pHYs)
          result.add(new PNGChunkpHYs(length, chunkType, CRC, bytes));
        else if (chunkType == IDAT)
          result.add(new PNGChunkIDAT(length, chunkType, CRC, bytes));
        else if (chunkType == gAMA)
          result.add(new PNGChunkgAMA(length, chunkType, CRC, bytes));
        else
          result.add(new PNGChunk(length, chunkType, CRC, bytes));

        if (return_after_first)
          return result;
View Full Code Here

        byte bytes[] = pngChunkiCCP.UncompressedProfile;

        icc_profile = ICC_Profile.getInstance(bytes);
      } else if (gAMAs.size() == 1)
      {
        PNGChunkgAMA pngChunkgAMA = (PNGChunkgAMA) gAMAs.get(0);
        double gamma = pngChunkgAMA.getGamma();

        // charles: what is the correct target value here?
        // double targetGamma = 2.2;
        double targetGamma = 1.0;
        double diff = Math.abs(targetGamma - gamma);
View Full Code Here

        else if (chunkType == pHYs)
          result.add(new PNGChunkpHYs(length, chunkType, CRC, bytes));
        else if (chunkType == IDAT)
          result.add(new PNGChunkIDAT(length, chunkType, CRC, bytes));
        else if (chunkType == gAMA)
          result.add(new PNGChunkgAMA(length, chunkType, CRC, bytes));
        else if (chunkType == iTXt)
          result.add(new PNGChunkiTXt(length, chunkType, CRC, bytes));
        else
          result.add(new PNGChunk(length, chunkType, CRC, bytes));
View Full Code Here

        byte bytes[] = pngChunkiCCP.UncompressedProfile;

        icc_profile = ICC_Profile.getInstance(bytes);
      } else if (gAMAs.size() == 1)
      {
        PNGChunkgAMA pngChunkgAMA = (PNGChunkgAMA) gAMAs.get(0);
        double gamma = pngChunkgAMA.getGamma();

        // charles: what is the correct target value here?
        // double targetGamma = 2.2;
        double targetGamma = 1.0;
        double diff = Math.abs(targetGamma - gamma);
View Full Code Here

        else if (chunkType == pHYs)
          result.add(new PNGChunkpHYs(length, chunkType, CRC, bytes));
        else if (chunkType == IDAT)
          result.add(new PNGChunkIDAT(length, chunkType, CRC, bytes));
        else if (chunkType == gAMA)
          result.add(new PNGChunkgAMA(length, chunkType, CRC, bytes));
        else if (chunkType == iTXt)
          result.add(new PNGChunkiTXt(length, chunkType, CRC, bytes));
        else
          result.add(new PNGChunk(length, chunkType, CRC, bytes));
View Full Code Here

        if (debug)
          System.out.println("sRGB, no color management neccesary.");
      }
      else if (gAMAs.size() == 1)
      {
        PNGChunkgAMA pngChunkgAMA = (PNGChunkgAMA) gAMAs.get(0);
        double gamma = pngChunkgAMA.getGamma();

        // double targetGamma = 2.2;
        double targetGamma = 1.0;
        double diff = Math.abs(targetGamma - gamma);
        if (diff >= 0.5)
View Full Code Here

                else if (chunkType == pHYs)
                    result.add(new PNGChunkpHYs(length, chunkType, CRC, bytes));
                else if (chunkType == IDAT)
                    result.add(new PNGChunkIDAT(length, chunkType, CRC, bytes));
                else if (chunkType == gAMA)
                    result.add(new PNGChunkgAMA(length, chunkType, CRC, bytes));
                else if (chunkType == iTXt)
                    result.add(new PNGChunkiTXt(length, chunkType, CRC, bytes));
                else
                    result.add(new PNGChunk(length, chunkType, CRC, bytes));
View Full Code Here

                // TODO(maybe): ICC color profile
                //icc_profile = ICC_Profile.getInstance(bytes);
                icc_profile = null;
            } else if (gAMAs.size() == 1)
            {
                PNGChunkgAMA pngChunkgAMA = (PNGChunkgAMA) gAMAs.get(0);
                double gamma = pngChunkgAMA.getGamma();

                // charles: what is the correct target value here?
                // double targetGamma = 2.2;
                double targetGamma = 1.0;
                double diff = Math.abs(targetGamma - gamma);
View Full Code Here

TOP

Related Classes of org.apache.sanselan.formats.png.chunks.PNGChunkgAMA

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.