jeremias    2003/03/27 03:07:17

  Modified:    src/java/org/apache/fop/pdf BitmapImage.java
  Log:
  Adjust to changes in PDFImage design.
  
  Revision  Changes    Path
  1.2       +23 -16    xml-fop/src/java/org/apache/fop/pdf/BitmapImage.java
  
  Index: BitmapImage.java
  ===================================================================
  RCS file: /home/cvs/xml-fop/src/java/org/apache/fop/pdf/BitmapImage.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- BitmapImage.java  11 Mar 2003 13:05:09 -0000      1.1
  +++ BitmapImage.java  27 Mar 2003 11:07:17 -0000      1.2
  @@ -51,7 +51,8 @@
   package org.apache.fop.pdf;
   
   import java.io.IOException;
  -import java.util.Map;
  +import java.io.OutputStream;
  +//import java.util.Map;
   
   /**
    * Bitmap image.
  @@ -67,7 +68,7 @@
       private String maskRef;
       private PDFColor transparent = null;
       private String key;
  -    private Map filters;
  +    private PDFDocument pdfDoc;
   
       /**
        * Create a bitmap image.
  @@ -96,7 +97,7 @@
        * @param doc the pdf document this will be inserted into
        */
       public void setup(PDFDocument doc) {
  -        filters = doc.getFilterMap();
  +        this.pdfDoc = doc;
       }
   
       /**
  @@ -204,21 +205,12 @@
       }
   
       /**
  -     * Get the pdf data stream for the bitmap data.
  -     *
  -     * @return a pdf stream containing the filtered image data
  -     * @throws IOException if there is an error handling the data
  +     * @see org.apache.fop.pdf.PDFImage#outputContents(OutputStream)
        */
  -    public PDFStream getDataStream() throws IOException {
  -        // delegate the stream work to PDFStream
  -        PDFStream imgStream = new PDFStream(0);
  -
  -        imgStream.setData(bitmaps);
  -
  -        imgStream.addDefaultFilters(filters, PDFStream.CONTENT_FILTER);
  -        return imgStream;
  +    public void outputContents(OutputStream out) throws IOException {
  +        out.write(bitmaps);
       }
  -
  +    
       /**
        * Get the ICC stream.
        * @return always returns null since this has no icc color space
  @@ -234,6 +226,21 @@
       public boolean isPS() {
           return false;
       }
  +
  +    /**
  +     * @see org.apache.fop.pdf.PDFImage#isDCT()
  +     */
  +    public boolean isDCT() {
  +        return false;
  +    }
  +
  +    /**
  +     * @see org.apache.fop.pdf.PDFImage#getFilterHint()
  +     */
  +    public String getFilterHint() {
  +        return PDFFilterList.IMAGE_FILTER;
  +    }
  +
   }
   
   
  
  
  

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to