Welcome to Doom9's Forum, THE in-place to be for everyone interested in DVD conversion.

Before you start posting please read the forum rules. By posting to this forum you agree to abide by the rules.

 

Go Back   Doom9's Forum > Capturing and Editing Video > Avisynth Development

Reply
 
Thread Tools Search this Thread Display Modes
Old 2nd January 2003, 21:10   #1  |  Link
WarpEnterprises
C64
 
WarpEnterprises's Avatar
 
Join Date: Apr 2002
Location: Austria
Posts: 830
Compiling AviSynth

Could someone please summarize what is necessary to compile AviSynth?

I've installed VC6, SP5, ProcessorPack.

There is still an error regarding DirectShow.

Do I have to download some whole SDKs or are only some files needed?
WarpEnterprises is offline   Reply With Quote
Old 2nd January 2003, 22:11   #2  |  Link
sh0dan
Retired AviSynth Dev ;)
 
sh0dan's Avatar
 
Join Date: Nov 2001
Location: Dark Side of the Moon
Posts: 3,480
Unfortunately it seems to require both the DirectX 8.1 SDK and the newest platform SDK, which are both rather big.
__________________
Regards, sh0dan // VoxPod
sh0dan is offline   Reply With Quote
Old 7th January 2003, 22:13   #3  |  Link
WarpEnterprises
C64
 
WarpEnterprises's Avatar
 
Join Date: Apr 2002
Location: Austria
Posts: 830
Can you give me a hint what the "newest platform SDK" is?
At MS it seems to me it is only a combination of SDK's including DX8.1 which would then not be necessary.

Sadly DX8.1 SDK is not enough - now it compiles but there are linker errors (non-resolved external symbols, regarding ACM it seems).

Some clues for me? Or are there some settings necessary for the project I am not aware of?
WarpEnterprises is offline   Reply With Quote
Old 7th January 2003, 22:22   #4  |  Link
sh0dan
Retired AviSynth Dev ;)
 
sh0dan's Avatar
 
Join Date: Nov 2001
Location: Dark Side of the Moon
Posts: 3,480
http://www.microsoft.com/msdownload/...sdk/sdkupdate/

Install the Core SDK and DirectX SDK. You can de-select download of 64bit stuff (you can also do fine without samples and documentation), but Choosing Downloads/Install from the menu at the top.

If you take only "Build environment", you only have to download about 37mb.
__________________
Regards, sh0dan // VoxPod
sh0dan is offline   Reply With Quote
Old 7th January 2003, 22:51   #5  |  Link
scmccarthy
Registered User
 
Join Date: Oct 2002
Posts: 462
'only' 37mb hehe.
scmccarthy is offline   Reply With Quote
Old 8th January 2003, 05:24   #6  |  Link
JohnMK
Registered User
 
Join Date: Sep 2002
Location: Seattle
Posts: 551
So how easy is it to build this thing with VC6 SP5 w/ ICL7? Does the code come with a project file that would streamline the process? I'd love to compile with P4-optimized switches and see if there's any difference.
JohnMK is offline   Reply With Quote
Old 8th January 2003, 07:31   #7  |  Link
WarpEnterprises
C64
 
WarpEnterprises's Avatar
 
Join Date: Apr 2002
Location: Austria
Posts: 830
I will tell my stepwise progress.
The project file is I think a VC7-file, no VC6. But I only added all files to an empty DLL project and at least compiling worked.
Let's see what happens with the complete core SDK... (just downloading 342MB - still faster as 37MB on 56k)
WarpEnterprises is offline   Reply With Quote
Old 8th January 2003, 08:18   #8  |  Link
sh0dan
Retired AviSynth Dev ;)
 
sh0dan's Avatar
 
Join Date: Nov 2001
Location: Dark Side of the Moon
Posts: 3,480
Load the .dsw into VC6. AviSynth is being developed on VC6, so you shouldn't need to create a new project.
__________________
Regards, sh0dan // VoxPod
sh0dan is offline   Reply With Quote
Old 8th January 2003, 11:49   #9  |  Link
WarpEnterprises
C64
 
WarpEnterprises's Avatar
 
Join Date: Apr 2002
Location: Austria
Posts: 830
Where is such a DSW? (at sourceforge there is nothing, only a "hidden" quite old DSW and a "vcproj" file).
WarpEnterprises is offline   Reply With Quote
Old 8th January 2003, 12:49   #10  |  Link
sh0dan
Retired AviSynth Dev ;)
 
sh0dan's Avatar
 
Join Date: Nov 2001
Location: Dark Side of the Moon
Posts: 3,480
When you do a complete checkout there is both a dsw and a dsp. Neither of them should be hidden.
__________________
Regards, sh0dan // VoxPod
sh0dan is offline   Reply With Quote
Old 8th January 2003, 13:42   #11  |  Link
Bidoche
Avisynth 3.0 Developer
 
Join Date: Jan 2002
Location: France
Posts: 639
I got these dsw files with a checkout, and VC6 has no problem dealing with them.
But I got errors with the asm file when building, does the Core SDK solve this ?
Bidoche is offline   Reply With Quote
Old 8th January 2003, 13:56   #12  |  Link
WarpEnterprises
C64
 
WarpEnterprises's Avatar
 
Join Date: Apr 2002
Location: Austria
Posts: 830
are we talking about this file:
http://cvs.sourceforge.net/cgi-bin/v...c/avisynth.dsw
WarpEnterprises is offline   Reply With Quote
Old 8th January 2003, 14:20   #13  |  Link
sh0dan
Retired AviSynth Dev ;)
 
sh0dan's Avatar
 
Join Date: Nov 2001
Location: Dark Side of the Moon
Posts: 3,480
Hmmm.. strange - but doesn't VC6 generate a dsw, when you open the project file, avisynth.dsp ?
__________________
Regards, sh0dan // VoxPod
sh0dan is offline   Reply With Quote
Old 9th January 2003, 10:35   #14  |  Link
WarpEnterprises
C64
 
WarpEnterprises's Avatar
 
Join Date: Apr 2002
Location: Austria
Posts: 830
Ok, my mistake: .DSW is the workspace file, .DSP the project file which is ok from SF.

As you mentioned, both the core SDK + DirectX SDK are necessary

What is necessary too and was nowhere mentioned when setting up the project from scratch:

* include the convert_a.asm file and set up the assembler for this file (this is logical)

* add some lib files to the project (penter.lib msacm32.lib quartz.lib ddraw.lib amstrmid.lib vfw32.lib version.lib user32.lib winmm.lib) - how do you know that these files are necessary?

* (maybe) setting to PentiumPro code generation

With these changes it compiles.
Don't have checked if working flawlessly.
WarpEnterprises is offline   Reply With Quote
Old 9th January 2003, 14:16   #15  |  Link
sh0dan
Retired AviSynth Dev ;)
 
sh0dan's Avatar
 
Join Date: Nov 2001
Location: Dark Side of the Moon
Posts: 3,480
1) convert_a.asm is included in the project file, and is compiling fine, when you have the preprocessor pack 5 installed. No user action required here if your installation is ok.

2) These lib files are in the platform SDK, and if you read the documentation for these, it says you must add the lib directories in Tools/Options/Directories - no need to add them manually. You must have DirectX and Core SDK headers/libraries here, and move them to the top (I cannot remember the exact order of these two).

3) This is stored in the .dsp file, so you get the optimizations from the CVS. Be careful - enabling "Maximize speed" may break temporalsoften - it seems to cause a bug in the experimental cache.
__________________
Regards, sh0dan // VoxPod
sh0dan is offline   Reply With Quote
Old 9th January 2003, 14:42   #16  |  Link
WarpEnterprises
C64
 
WarpEnterprises's Avatar
 
Join Date: Apr 2002
Location: Austria
Posts: 830
ad 2) I understand that I have to add the path to the lib files, but isn't it necessary to add the libs in the project properties (under the c++ tab)? I did mean _this_ action, not copying the LIB-files.
So from where comes the information that those LIB's are used?

Only the linker complains about missing symbols.

Maybe I simply don't know enough what a .LIB file is
WarpEnterprises is offline   Reply With Quote
Old 9th January 2003, 17:14   #17  |  Link
scmccarthy
Registered User
 
Join Date: Oct 2002
Posts: 462
Quote:
Maybe I simply don't know enough what a .LIB file is
I hope you don't mind if I point out some basics of compiling?

First, the lib file is only added by the linker. That means if you tried compiling without linking, you would not get an error if you did not have the libs you need. I think there are two catagories of libs: ones that the linker looks for for any c++ project and ones that the program calls for. I am not sure of that, but it doesn't matter, we're only focusing on the specific ones for each project.

lib files contain methods, fuctions, procedures, or whatever you want to call them, that are called by the program. The linker only has to read the object files to know the names of the needed lib files. The only thing it doesn't know is where the lib files are. So all you need to do in this case is put the lib folder for the Platform SDK and DirectX SDK on the search path for the linker. There is no need to name each lib file it is going to need.

So my main point is to explain why the linker only needs the search path to the lib directories it will need and not the names of the lib files themselves.

Of course, the compiler still needs to know which libs contain the code for the procedures called. I'm guessing that information is in the sources.

Stephen
scmccarthy is offline   Reply With Quote
Old 11th January 2003, 21:57   #18  |  Link
WarpEnterprises
C64
 
WarpEnterprises's Avatar
 
Join Date: Apr 2002
Location: Austria
Posts: 830
Thx, after reading a little bit MSDN I think I get it now.
("explicit and implicit linking")

1.You need a LIB file if you link to a DLL statically (implicit). This is the way AviSynth calls OS DLLs. Each function call (e.g. to ACM) aims at a DLL and each of those DLLs must have a LIB. So only complete knowledge of the source will tell you which DLLs are involved as they are not written somewhere. And the header files defining the functions don't have always simply the same name as the DLL.

2.If the DLL is linked explicit / dynamically you don't need a LIB, the functions are returned as pointers. This is a little more complex to program, it seems, but this is the way AviSynth calls the plugins. It has to be that way because the name of the DLL is of course not fixed when compiling AviSynth.
WarpEnterprises is offline   Reply With Quote
Old 12th January 2003, 00:45   #19  |  Link
scmccarthy
Registered User
 
Join Date: Oct 2002
Posts: 462
@WarpEnterprises

I think you need the lib file for the os dlls whether you link to them dynamically or statically. It you link to it dynamically, you still need the address of the function within the dll you are calling. Unlike the little dll we write for AviSynth or even the AviSynth dll itself, a dll like kernel32.dll has multiple indepentant programs. The calling program needs the address of the specific program being called within the dll. That information is given to the calling program by the linker through kernel32.lib. So I believe that you always need the lib file for an os dll whether you link to it statically or dynamically.

My guess is that AviSynth is able to load its own dlls from a script mainly because there is a set starting place for the one program within each dll.

That is great work though, and I wonder if static and implicit are not really synonymous. So that you are half right.

Stephen
scmccarthy is offline   Reply With Quote
Old 7th April 2003, 23:18   #20  |  Link
WarpEnterprises
C64
 
WarpEnterprises's Avatar
 
Join Date: Apr 2002
Location: Austria
Posts: 830
HELP

help needed again...

AviSynth won't compile anymore, there are many linker errors (mainly imagelib, softwire) regardless which configuration I use.

Is there something I must do except using the .DSP file?
WarpEnterprises is offline   Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +1. The time now is 10:54.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2019, vBulletin Solutions Inc.