Solved

Picture-formats other than BMP?

Posted on 1998-09-10
4
262 Views
Last Modified: 2013-11-19
How can I view some pictures (in Delphi3), others than BMP-files? I want to put some different pictures (different formats) in an image-box. Thanx. Jan van Barchum.
0
Comment
Question by:roosiedb
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
4 Comments
 
LVL 4

Expert Comment

by:erajoj
ID: 1339263
What formats are you looking for?
JPEG, ICO, WMF, EMF is already available, just take a look in the help file.

/// John
0
 
LVL 1

Accepted Solution

by:
duke_n earned 20 total points
ID: 1339264
I know how to insert *.jpg without any additional components needed to install.
Just include JPEG in uses list and then call Timage.picture.loadfromfile.
Like this:


unit Unit1;

interface

uses
  Windows,JPEG{!!!}, Messages, SysUtils, Classes, Graphics, Controls, Forms, Dialogs,Buttons, ExtCtrls;

type
  TForm1 = class(TForm)
    Image1: TImage;
    SpeedButton1: TSpeedButton;
    procedure SpeedButton1Click(Sender: TObject);
  private
    { Private declarations }
  public
    { Public declarations }
  end;

var
  Form1: TForm1;

implementation

{$R *.DFM}

procedure TForm1.SpeedButton1Click(Sender: TObject);
begin
image1.Picture.LoadFromFile('myjpeg.jpg');
end;

end.

0
 
LVL 4

Expert Comment

by:d003303
ID: 1339265
There are also GIF extensions for TPicture available on the DSP.

Slash/d003303
0
 
LVL 4

Expert Comment

by:erajoj
ID: 1339266
Yes, there is. The reason I didn't mention it, is because
you need a license from UNISYS in order to use it's LZW compression algorithm commercially.

See http://corp2.unisys.com/LeadStory/lzwfaq.html

/// John
0

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This article explains how to create forms/units independent of other forms/units object names in a delphi project. Have you ever created a form for user input in a Delphi project and then had the need to have that same form in a other Delphi proj…
Have you ever had your Delphi form/application just hanging while waiting for data to load? This is the article to read if you want to learn some things about adding threads for data loading in the background. First, I'll setup a general applica…
Not only does Prezi allow you to create non-linear presentations, it also makes it easy to apply transition animations between your frames. Learn how to apply a fade-in transition to select items and entire frames in this tutorial Select "Edit Path"…
Learn how to download your full Prezi presentation for offline presenting. Prezi doesn’t have to be viewed and shared in a web browser, even with a free account you can download your full presentation to share with others. Be sure to download any vi…
Suggested Courses
Course of the Month5 days, 8 hours left to enroll

626 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question