6 Replies Latest reply: Jul 3, 2010 6:13 AM by 843802 RSS

    Converting tinto Tiff file

    843802
      Hi,

      I want to convert following mentioned file into tiff file.

      Is it possible in java?

      File extension: doc, tiff, text

      Please help me.
        • 1. Re: Converting tinto Tiff file
          793415
          santanu wrote:
          ..I want to convert following mentioned file into tiff file.

          Is it possible in java?
          Yes. Though parts of it will require Java based, 3rd party APIs.

          This task is best split into two parts.
          1) Gain an image (e.g. BufferedImage) of the document as it might be rendered on screen (or printer etc.).
          2) Write the image to TIFF format.
          File extension: doc, tiff, text
          Part 1:
          - For text files, gaining an image is relatively trivial. Put the text in a JTextArea and render that to the Graphics object of a new BufferedImage.
          - For doc files, you'd need to add a 3rd party API that renders Word docs.
          - What do you mean you want to 'convert' tiff --> tiff? No conversion is necessary.

          Part 2:
          The only part of your question relevant to this forum. I've had not dealings with TIFF or creating them.
          Please help me.
          Please try not to sound quite so pathetic. It reduces your chance of getting help.
          • 2. Re: Converting tinto Tiff file
            843802
            Thanks for the reply.

            if anyone knows the exact solution please mention.
            • 3. Re: Converting tinto Tiff file
              793415
              santanu wrote:
              Thanks for the reply.
              You're welcome. OTOH, if you cannot frame a more specific question or request based on my reply than..
              if anyone knows the exact solution please mention.
              Then this basically translates to "Plz gv me da codez!!!".

              Nobody here is going to post the exact solution to your original question. Especially since it made little sense in ways I pointed out & which you seemingly ignored.
              • 4. Re: Converting tinto Tiff file
                843802
                Hi,

                Using Java Imaging is it possible to do that.
                • 5. Re: Converting tinto Tiff file
                  793415
                  santanu wrote:
                  ..Using Java Imaging..
                  What is 'Java Imaging'? I understand the Java part, but the 'Imaging' has got me. It might be Graphics2D, ImageIO or JAI. In any case, for those three, JAI will be necessary for writing the TIFF, Graphics2D will be handy for rendering a BufferedImage, and it seems ImageIO will be redundant.
                  ..is it possible to do that.
                  But as I explained earlier. Part of 'that' was about loading files of type .txt, .doc & .tiff.

                  J2SE can do .txt, J2SE cannot do .doc, and I do not understand the bit about TIFF.

                  Sheeesh.. why do I feel I am repeating myself?
                  • 6. Re: Converting tinto Tiff file
                    843802
                    Hi,

                    is there anyone who can help me to convert text file into tiff or tif file?

                    Please send me some hint or any sample code.

                    It would be great, if anyone help me out.