Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7780101
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 1, 20262026-06-01T18:48:41+00:00 2026-06-01T18:48:41+00:00

I want to load a bmp file (in Java) and manipulate the image data

  • 0

I want to load a bmp file (in Java) and manipulate the image data within the syntax of a java program. How can I do this? I tried just loading the image, like so:

   public static void main(String[] args) {
            System.out.println("START");
            loadbitmap lbm = new loadbitmap();
            lbm.loadBMPFile();
            System.out.println("END");
        }

        private void loadBMPFile()
        {
            {
                try{

                    FileInputStream fstream = new FileInputStream("sample_fingerprint_grayscale.bmp");
                    DataInputStream in = new DataInputStream(fstream);
                    BufferedReader br = new BufferedReader(new InputStreamReader(in));
                    String inputString;
                    while ((inputString = br.readLine()) != null)   {

                        readBMPFile.add(inputString);
                    }
                    in.close();
                }
                catch (Exception e){
                    System.out.println("IN ERROR");
                    System.err.println("Error: " + e.getMessage());
                }
                System.out.println("IN loadBMPFile");
                System.out.println("BMP size is " + readBMPFile.size());
                System.out.println(readBMPFile.get(2));
            }
        }
}

But when I inspect the data, its not really there. I’m a noob at this, so any points in the right direction is appreciated.

Here is the output:

START
IN loadBMPFile
BM¸U

(At this point there is a large amount of gibberish characters that won't paste into Stack Overflow)

END

I have a hex reader(Frhed) that formats these characters into hex format, I was hoping I could bring them characters into an arraylist and manipulate them from there.

Here is the hex reader output:

BM<bh:b8>U<bh:01><bh:00><bh:00><bh:00><bh:00><bh:00>6<bh:04><bh:00><bh:00>(<bh:00><bh:00><bh:00><bh:f0><bh:00><bh:00><bh:00><bh:98><bh:fe><bh:ff><bh:ff><bh:01><bh:00><bh:08><bh:00><bh:00><bh:00><bh:00><bh:00><bh:82>Q<bh:01><bh:00><bh:12><bh:0b><bh:00><bh:00><bh:12><bh:0b><bh:00><bh:00><bh:00><bh:00><bh:00><bh:00><bh:00><bh:00><bh:00><bh:00><bh:00><bh:00><bh:00><bh:00><bh:01><bh:01><bh:01><bh:00><bh:02><bh:02><bh:02><bh:00><bh:03><bh:03><bh:03><bh:00><bh:04><bh:04><bh:04><bh:00><bh:05><bh:05><bh:05><bh:00><bh:06><bh:06><bh:06><bh:00><bh:07><bh:07><bh:07><bh:00><bh:08><bh:08><bh:08><bh:00><bh:09><bh:09><bh:09><bh:00>


<bh:00><bh:0b><bh:0b><bh:0b><bh:00><bh:0c><bh:0c><bh:0c><bh:00>


<bh:00><bh:0e><bh:0e><bh:0e><bh:00><bh:0f><bh:0f><bh:0f><bh:00><bh:10><bh:10><bh:10><bh:00><bh:11><bh:11><bh:11><bh:00><bh:12><bh:12><bh:12><bh:00><bh:13><bh:13><bh:13><bh:00><bh:14><bh:14><bh:14><bh:00><bh:15><bh:15><bh:15><bh:00><bh:16><bh:16><bh:16><bh:00><bh:17><bh:17><bh:17><bh:00><bh:18><bh:18><bh:18><bh:00><bh:19><bh:19><bh:19><bh:00><bh:1a><bh:1a><bh:1a><bh:00><bh:1b><bh:1b><bh:1b><bh:00><bh:1c><bh:1c><bh:1c><bh:00><bh:1d><bh:1d><bh:1d><bh:00><bh:1e><bh:1e><bh:1e><bh:00><bh:1f><bh:1f><bh:1f><bh:00>   <bh:00>!!!<bh:00>"""<bh:00>###<bh:00>$$$<bh:00>%%%<bh:00>&&&<bh:00>'''<bh:00>(((<bh:00>)))<bh:00>***<bh:00>+++<bh:00>,,,<bh:00>---<bh:00>...<bh:00>///<bh:00>000<bh:00>111<bh:00>222<bh:00>333<bh:00>444<bh:00>555<bh:00>666<bh:00>777<bh:00>888<bh:00>999<bh:00>:::<bh:00>;;;<bh:00>\<\<\<<bh:00>===<bh:00>>>><bh:00>???<bh:00>@@@<bh:00>AAA<bh:00>BBB<bh:00>CCC<bh:00>DDD<bh:00>EEE<bh:00>FFF<bh:00>GGG<bh:00>HHH<bh:00>III<bh:00>JJJ<bh:00>KKK<bh:00>LLL<bh:00>MMM<bh:00>NNN<bh:00>OOO<bh:00>PPP<bh:00>QQQ<bh:00>RRR<bh:00>SSS<bh:00>TTT<bh:00>UUU<bh:00>VVV<bh:00>WWW<bh:00>XXX<bh:00>YYY<bh:00>ZZZ<bh:00>[[[<bh:00>\\\\\\<bh:00>]]]<bh:00>^^^<bh:00>___<bh:00>```<bh:00>aaa<bh:00>bbb<bh:00>ccc<bh:00>ddd<bh:00>eee<bh:00>fff<bh:00>ggg<bh:00>hhh<bh:00>iii<bh:00>jjj<bh:00>kkk<bh:00>lll<bh:00>mmm<bh:00>nnn<bh:00>ooo<bh:00>ppp<bh:00>qqq<bh:00>rrr<bh:00>sss<bh:00>ttt<bh:00>uuu<bh:00>vvv<bh:00>www<bh:00>xxx<bh:00>yyy<bh:00>zzz<bh:00>{{{<bh:00>|||<bh:00>}}}<bh:00>~~~<bh:00><bh:7f><bh:7f><bh:7f><bh:00><bh:80><bh:80><bh:80><bh:00><bh:81><bh:81><bh:81><bh:00><bh:82><bh:82><bh:82><bh:00><bh:83><bh:83><bh:83><bh:00><bh:84><bh:84><bh:84><bh:00><bh:85><bh:85><bh:85><bh:00><bh:86><bh:86><bh:86><bh:00><bh:87><bh:87><bh:87><bh:00><bh:88><bh:88><bh:88><bh:00><bh:89><bh:89><bh:89><bh:00><bh:8a><bh:8a><bh:8a><bh:00><bh:8b><bh:8b><bh:8b><bh:00><bh:8c><bh:8c><bh:8c><bh:00><bh:8d><bh:8d><bh:8d><bh:00><bh:8e><bh:8e><bh:8e><bh:00><bh:8f><bh:8f><bh:8f><bh:00><bh:90><bh:90><bh:90><bh:00><bh:91><bh:91><bh:91><bh:00><bh:92><bh:92><bh:92><bh:00><bh:93><bh:93><bh:93><bh:00><bh:94><bh:94><bh:94><bh:00><bh:95><bh:95><bh:95><bh:00><bh:96><bh:96><bh:96><bh:00><bh:97><bh:97><bh:97><bh:00><bh:98><bh:98><bh:98><bh:00><bh:99><bh:99><bh:99><bh:00><bh:9a><bh:9a><bh:9a><bh:00><bh:9b><bh:9b><bh:9b><bh:00><bh:9c><bh:9c><bh:9c><bh:00><bh:9d><bh:9d><bh:9d><bh:00><bh:9e><bh:9e><bh:9e><bh:00><bh:9f><bh:9f><bh:9f><bh:00><bh:a0><bh:a0><bh:a0><bh:00><bh:a1><bh:a1><bh:a1><bh:00><bh:a2><bh:a2><bh:a2><bh:00><bh:a3><bh:a3><bh:a3><bh:00><bh:a4><bh:a4><bh:a4><bh:00><bh:a5><bh:a5><bh:a5><bh:00><bh:a6><bh:a6><bh:a6><bh:00><bh:a7><bh:a7><bh:a7><bh:00><bh:a8><bh:a8><bh:a8><bh:00><bh:a9><bh:a9><bh:a9><bh:00><bh:aa><bh:aa><bh:aa><bh:00><bh:ab><bh:ab><bh:ab><bh:00><bh:ac><bh:ac><bh:ac><bh:00><bh:ad><bh:ad><bh:ad><bh:00><bh:ae><bh:ae><bh:ae><bh:00><bh:af><bh:af><bh:af><bh:00><bh:b0><bh:b0><bh:b0><bh:00><bh:b1><bh:b1><bh:b1><bh:00><bh:b2><bh:b2><bh:b2><bh:00><bh:b3><bh:b3><bh:b3><bh:00><bh:b4><bh:b4><bh:b4><bh:00><bh:b5><bh:b5><bh:b5><bh:00><bh:b6><bh:b6><bh:b6><bh:00><bh:b7><bh:b7><bh:b7><bh:00><bh:b8><bh:b8><bh:b8><bh:00><bh:b9><bh:b9><bh:b9><bh:00><bh:ba><bh:ba><bh:ba><bh:00><bh:bb><bh:bb><bh:bb><bh:00><bh:bc><bh:bc><bh:bc><bh:00><bh:bd><bh:bd><bh:bd><bh:00><bh:be><bh:be><bh:be><bh:00><bh:bf><bh:bf><bh:bf><bh:00><bh:c0><bh:c0><bh:c0><bh:00><bh:c1><bh:c1><bh:c1><bh:00><bh:c2><bh:c2><bh:c2><bh:00><bh:c3><bh:c3><bh:c3><bh:00><bh:c4><bh:c4><bh:c4><bh:00><bh:c5><bh:c5><bh:c5><bh:00><bh:c6><bh:c6><bh:c6><bh:00><bh:c7><bh:c7><bh:c7><bh:00><bh:c8><bh:c8><bh:c8><bh:00><bh:c9><bh:c9><bh:c9><bh:00><bh:ca><bh:ca><bh:ca><bh:00><bh:cb><bh:cb><bh:cb><bh:00><bh:cc><bh:cc><bh:cc><bh:00><bh:cd><bh:cd><bh:cd><bh:00><bh:ce><bh:ce><bh:ce><bh:00><bh:cf><bh:cf><bh:cf><bh:00><bh:d0><bh:d0><bh:d0><bh:00><bh:d1><bh:d1><bh:d1><bh:00><bh:d2><bh:d2><bh:d2><bh:00><bh:d3><bh:d3><bh:d3><bh:00><bh:d4><bh:d4><bh:d4><bh:00><bh:d5><bh:d5><bh:d5><bh:00><bh:d6><bh:d6><bh:d6><bh:00><bh:d7><bh:d7><bh:d7><bh:00><bh:d8><bh:d8><bh:d8><bh:00><bh:d9><bh:d9><bh:d9><bh:00><bh:da><bh:da><bh:da><bh:00><bh:db><bh:db><bh:db><bh:00><bh:dc><bh:dc><bh:dc><bh:00><bh:dd><bh:dd><bh:dd><bh:00><bh:de><bh:de><bh:de><bh:00><bh:df><bh:df><bh:df><bh:00><bh:e0><bh:e0><bh:e0><bh:00><bh:e1><bh:e1><bh:e1><bh:00><bh:e2><bh:e2><bh:e2><bh:00><bh:e3><bh:e3><bh:e3><bh:00><bh:e4><bh:e4><bh:e4><bh:00><bh:e5><bh:e5><bh:e5><bh:00><bh:e6><bh:e6><bh:e6><bh:00><bh:e7><bh:e7><bh:e7><bh:00><bh:e8><bh:e8><bh:e8><bh:00><bh:e9><bh:e9><bh:e9><bh:00><bh:ea><bh:ea><bh:ea><bh:00><bh:eb><bh:eb><bh:eb><bh:00><bh:ec><bh:ec><bh:ec><bh:00><bh:ed><bh:ed><bh:ed><bh:00><bh:ee><bh:ee><bh:ee><bh:00><bh:ef><bh:ef><bh:ef><bh:00><bh:f0><bh:f0><bh:f0><bh:00><bh:f1><bh:f1><bh:f1><bh:00><bh:f2><bh:f2><bh:f2><bh:00><bh:f3><bh:f3><bh:f3><bh:00><bh:f4><bh:f4><bh:f4><bh:00><bh:f5><bh:f5><bh:f5><bh:00><bh:f6><bh:f6><bh:f6><bh:00><bh:f7><bh:f7><bh:f7><bh:00><bh:f8><bh:f8><bh:f8><bh:00><bh:f9><bh:f9><bh:f9><bh:00><bh:fa><bh:fa><bh:fa><bh:00><bh:fb><bh:fb><bh:fb><bh:00><bh:fc><bh:fc><bh:fc><bh:00><bh:fd><bh:fd><bh:fd><bh:00><bh:fe><bh:fe><bh:fe><bh:00><bh:ff><bh:ff><bh:ff><bh:00><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff><bh:ff>
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-01T18:48:42+00:00Added an answer on June 1, 2026 at 6:48 pm

    Use javax.imageio.ImageIO.

    BufferedImage img = ImageIO.read(new File("... .bmp"));
    

    A BufferedImage may be altered too, so quite suitable for modifying.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I want to load some helper in a model. How to do this? Tried
I want a image loader library to help me load images (bmp, jpg, gif,
I want to load uimage with image in path like this /var/mobile/Applications/429E283A-6E89-4BCE-861F-252C5327F711/Library/Application Support/Students/43y. F./1.2.840.113564.3.1.2.180.0.0.90.20081228203734483950/1.2.840.113564.10.1.226230117146661685815524478531105858244/Thumbnail.bmp
I want to load a bmp file into memory in C. I've found many
I want to load the data into session so that when the next button
I want to load some images into my application from the file system. There's
I want to load some data from mysql into my cocoa application view before
I want to load key/values configuration pairs stored in XML file. To bind a
We have a requirement that a user can load any standard image into a
Can someone write up a source for a program that just has a game

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.