Solved

LOAD AVI FROM DLL IN TANIMATION

Posted on 2004-03-23
6
365 Views
Last Modified: 2010-04-05

I use this code to load avi from dll in Tanimation (A1)
but I recieve error 'can not open avi'.

//*********************************
DLLHANDLE := LoadLibrary('resdll.dll');

  with A1 do
  try
     try
        ResHandle := DLLHANDLE;
     finally

        ResName := 'myavi';
     end;
  finally
  StartFrame := 25;
  StopFrame :=61;

  end;
//****************************
0
Comment
Question by:sal1150
  • 3
  • 2
6 Comments
 
LVL 14

Expert Comment

by:DragonSlayer
ID: 10656764
TAnimate can only open uncompressed AVI and/or those compressed using RLE. If your AVI in the DLL is compressed using some other codec, TAnimate won't work
0
 

Author Comment

by:sal1150
ID: 10657540
my AVI in the DLL is not compressed
0
 
LVL 14

Expert Comment

by:DragonSlayer
ID: 10659003
erm... make sure the spelling is correct? It is case-sensitive.
0
IT, Stop Being Called Into Every Meeting

Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

 
LVL 15

Accepted Solution

by:
simonet earned 250 total points
ID: 10659461


I have written an example on how to do it:

http://www.bhnet.com.br/~simonet/howtoprojs.htm
(check the sample app "How to create and use resource-only DLLs". the techniques described are exactly what you want).

Yours,

Alex
0
 

Author Comment

by:sal1150
ID: 10662688
hi simonet
I test ur example but u do not solve the problem which happen when u tray to play avi.
this is ur mark and the code:-

  // Always check if the module is loaded before
  // Trying to access it.
  if ResDLLMod=0 then exit;
  // Ok, the routine below looks like a real mess.
  // The problem is that this TAnimate component is anything but a
  // friendly guy.
  // There are ways to improve the routine below, but I just don't have
  // the patience right now.
  try
  with Animate1 do
  try
     try
        ResHandle := ResDLLMod;
     finally
        ResName := 'BORLANDCOOL';
     end;
  finally
     Play(1, FrameCount, 0);
  end;
  except
//
  end;
end;

0
 

Author Comment

by:sal1150
ID: 10662792
spelling is correct.
0

Featured Post

Free Trending Threat Insights Every Day

Enhance your security with threat intelligence from the web. Get trending threat insights on hackers, exploits, and suspicious IP addresses delivered to your inbox with our free Cyber Daily.

Join & Write a Comment

A lot of questions regard threads in Delphi.   One of the more specific questions is how to show progress of the thread.   Updating a progressbar from inside a thread is a mistake. A solution to this would be to send a synchronized message to the…
Hello everybody This Article will show you how to validate number with TEdit control, What's the TEdit control? TEdit is a standard Windows edit control on a form, it allows to user to write, read and copy/paste single line of text. Usua…
This tutorial demonstrates a quick way of adding group price to multiple Magento products.
You have products, that come in variants and want to set different prices for them? Watch this micro tutorial that describes how to configure prices for Magento super attributes. Assigning simple products to configurable: We assigned simple products…

706 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

Need Help in Real-Time?

Connect with top rated Experts

17 Experts available now in Live!

Get 1:1 Help Now