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 9190263
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 17, 20262026-06-17T20:25:18+00:00 2026-06-17T20:25:18+00:00

Is there a way to fuse the Jpeg image with the correspondant pixel temperature

  • 0

enter image description here

enter image description here

Is there a way to fuse the Jpeg image with the correspondant pixel temperature shown in the stringgrid attached.
After the fusion, mouse arround and read the temperatures from the image.
If there is, please can anyone show me how.

Thank you, AmmadeuX

  • 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-17T20:25:19+00:00Added an answer on June 17, 2026 at 8:25 pm

    What I understand is that you have three different questions at hand. I will point them out below, along with an answer. But please, you need to do your best to get these types of projects done yourself, and only ask questions here if you have a specific issue which needs to be resolved. It’s always subjective to ask “How to do something”.

    Questions 2 and 3 are either-or solutions, meaning each one could be a different question and answer all-together, completely separate. But they both still depend on the first question.

    Question 1: “How do I identify the color of a pixel which the mouse is pointed over?”

    I am assuming you’re using a standard TImage control with its default properties, and is not set to re-size, stretch, or center the image. If you need to do that, there’s a different approach.

    First, you have to identify which pixel the mouse is pointed over. There are a few ways of doing this, but depending on what control you are using to display the image (I’m assuming a standard TImage), I would recommend using the Mouse Move event (OnMouseMove) to capture movement of the mouse over this control. At this point, you need to identify the current mouse position. Thankfully, this event comes with the X and Y position of the mouse pointer.

    Then, you need to get the canvas of the image. You can get this with:

    TImage.Picture.Bitmap.Canvas
    

    Next, read the Canvas’ Pixels[] property to get the color.

    Question 2: “How do I identify where a color falls on a From/To scale?”

    Now that you know what color the mouse is pointed over, you need to identify in which position of your scale this color belongs. For this, it’s easiest to stick with only 1 color channel. Your example above illustrates a combination and fade of different colors, which is way too tricky for me to try to explain. Please ask this as an additional question, because it requires its own thought which I cannot do (requires extensive math which I’m not good at).

    Question 3: “How do I link an image to a table of data?”

    Since you have a table of temperature readings, you need to read this table by column/row based on the individual pixel provided in the first question above.

    Since you already know the X/Y position of the mouse, use these same variables to identify the column/row of the grid. (I discourage using a grid as your primary base of storing this data, you should use a client-dataset instead, and dynamically load the grid with that data.)

    Conclusion:

    Here’s the code of a sample app I prepared for you. It should help you understand the basics behind what you’re doing. You’ll have to pick your own image, as I didn’t want to pollute this answer’s code with raw image data.

    NOTE: Once you edit your question to be clear as to how you expect the image to be linked to the data, then I will modify my answer. Otherwise, this is the best I can explain in its current state.

    Unit1.pas

    unit Unit1;
    
    interface
    
    uses
      Winapi.Windows, Winapi.Messages, System.SysUtils, System.Variants, System.Classes, Vcl.Graphics,
      Vcl.Controls, Vcl.Forms, Vcl.Dialogs, Vcl.ExtCtrls, Vcl.StdCtrls, Vcl.ComCtrls;
    
    type
      TForm1 = class(TForm)
        Image1: TImage;
        Shape1: TShape;
        StatusBar1: TStatusBar;
        procedure Image1MouseMove(Sender: TObject; Shift: TShiftState; X,
          Y: Integer);
      end;
    
    var
      Form1: TForm1;
    
    implementation
    
    {$R *.dfm}
    
    procedure TForm1.Image1MouseMove(Sender: TObject; Shift: TShiftState;
      X, Y: Integer);
    var
      Color: TColor;
      Canvas: TCanvas;
      R, G, B: Byte;
    begin
      Canvas:= Image1.Picture.Bitmap.Canvas;
      Color:= Canvas.Pixels[X, Y];
      Shape1.Brush.Color:= Color;
      R:= GetRValue(Color);
      G:= GetGValue(Color);
      B:= GetBValue(Color);
      StatusBar1.Panels[0].Text:= 'Pos: '+IntToStr(X)+' x '+IntToStr(Y);
      StatusBar1.Panels[1].Text:= 'Clr: '+IntToStr(Color);
      StatusBar1.Panels[2].Text:= 'RGB: '+IntToStr(R)+' x '+IntToStr(G)+' x '+IntToStr(B);
    end;
    
    end.
    

    Unit1.dfm

    object Form1: TForm1
      Left = 315
      Top = 113
      Caption = 'Form1'
      ClientHeight = 415
      ClientWidth = 548
      Color = clBtnFace
      Font.Charset = DEFAULT_CHARSET
      Font.Color = clWindowText
      Font.Height = -11
      Font.Name = 'Tahoma'
      Font.Style = []
      OldCreateOrder = False
      DesignSize = (
        548
        415)
      PixelsPerInch = 96
      TextHeight = 13
      object Image1: TImage
        Left = 0
        Top = 0
        Width = 548
        Height = 281
        Align = alTop
        Anchors = [akLeft, akTop, akRight, akBottom]
        OnClick = Image1Click
        OnMouseMove = Image1MouseMove
      end
      object Label1: TLabel
        Left = 8
        Top = 285
        Width = 31
        Height = 13
        Anchors = [akLeft, akBottom]
        Caption = 'Label1'
      end
      object Shape1: TShape
        Left = 8
        Top = 312
        Width = 532
        Height = 57
        Anchors = [akLeft, akRight, akBottom]
      end
      object StatusBar1: TStatusBar
        Left = 0
        Top = 396
        Width = 548
        Height = 19
        Panels = <
          item
            Width = 150
          end
          item
            Width = 150
          end
          item
            Width = 50
          end>
      end
    end
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Is there way to fire the System.Timers.Timer.Elapsed only after the previous Elapsed event has
Is there way to update a record after something has been rendered without putting
Is there way to get file from windows xp command prompt? I tried to
Is there way to automatically maximize the output window on hitting build and then
Is there way to copy a file into Plone with WebDAV and have Plone
is there way how to get name ov event from Lambda expression like with
Is there way to better identify design pattern in source codes, esp. if you
Is there way to mute an audio stream or at least control the volume?
Is there way to set @include mixin(); to variable? I tried this @mixin bg-gradient($fallback,
Is there way that I can read the file from remote server using fopen

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.