Skip to content

Instantly share code, notes, and snippets.

@msg7086
Created March 7, 2020 06:40
Show Gist options
  • Save msg7086/a6d4591081f3417ea2f5c6634bebcbc9 to your computer and use it in GitHub Desktop.
Save msg7086/a6d4591081f3417ea2f5c6634bebcbc9 to your computer and use it in GitHub Desktop.
#include <cstdio>
#include <avisynth.h>
#include <windows.h>
#define AVS_INTERFACE_26 6
typedef IScriptEnvironment * __stdcall CREATE_ENV(int);
const AVS_Linkage *AVS_linkage = NULL;
IScriptEnvironment * env;
int main()
{
HMODULE lib = LoadLibraryW(L"avisynth");
CREATE_ENV* avs_create_script_environment = (CREATE_ENV*)GetProcAddress(lib, "CreateScriptEnvironment");
env = avs_create_script_environment(AVS_INTERFACE_26);
puts("A");
AVS_linkage = env->GetAVSLinkage();
puts("B");
return 0;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment