animated gif issue

General TRichView support forum. Please post your questions here
Post Reply
cychia
Posts: 104
Joined: Mon Jan 16, 2006 1:52 am

animated gif issue

Post by cychia »

function getgraphicclass: TGraphicClass;
-> this function i used to return proper graphic class TGifImage is class uses for gif image

procedure InsertPicture(mstrmPhoto);
begin
gr := RV_CreateGraphics(TGraphicClass(getgraphicclass));
gr.LoadFromStream(mstrmPhoto);
InsertPicture(strTageContent, gr, PictureAlign);
end;

initialization
RegisterClasses([TGifImage]);
TPicture.RegisterFileFormat('gif', 'Gif Image', TGifImage);

RVGifAnimate2007 is already added to my project

but the gif is still not animate. anything i miss?
Sergey Tkachenko
Site Admin
Posts: 17557
Joined: Sat Aug 27, 2005 10:28 am
Contact:

Post by Sergey Tkachenko »

Assign RichViewEdit1.AnimationMode := rvaniOnFormat.
cychia
Posts: 104
Joined: Mon Jan 16, 2006 1:52 am

Post by cychia »

oops sorry actually i did assign
RichViewEdit1.AnimationMode := rvaniOnFormat.

but forget to list down in my post.

the gif still not animating, any clue?
cychia
Posts: 104
Joined: Mon Jan 16, 2006 1:52 am

Post by cychia »

additional info, rv editor is built into a dll.
Sergey Tkachenko
Site Admin
Posts: 17557
Joined: Sat Aug 27, 2005 10:28 am
Contact:

Post by Sergey Tkachenko »

Sorry, I do not know why it does not work.
Including RVGifAnimate2007 in the project (providing that you use Delphi 2007 or 2009) and assigning AnimationMode must be enough.
Animation uses a simple timer, so I think there must be no problems with DLL.
Total Commander plugin for displaying RVF files displays gif animation (though it was compiled with older version of Delphi and RVGifAnimate unit), and it is implemented as a dll.

Can you create a simple example demonstrating the problem?
Post Reply