A
Achim Domma (Procoders)
Hi,
I still try to implement a .Net wrapper to handel AVI Files. I'm unsing
managed C++ with VStudio 2003. The structure of my classes looks like this:
class AudioStream {
...
}
class VideoStream {
...
}
class AviFile {
IAVIFile* file_;
AudioStream* audio_;
VideoStream* video_;
public:
void Open(const char* path) {
AVIFileOpen(&file_,path,OF_SHARED_DENY_WRITE,NULL);
audio_ = new AudioStream();
video_ = new VideoStream();
}
}
audio_ and video_ are pointers to unmanaged classes and, according to
the documentation, are therefore implicit unmanaged pointers. But what
about file_?
The call to AVIFileOpen results in the error "'AVIFileOpenA' : cannot
convert parameter 1 from 'IAVIFile* __gc*' to 'PAVIFILE*'. AVIFileOpen
is a windows function defined in Vfw.h.
How do I have to define file_ to get my example working?
regards,
Achim
I still try to implement a .Net wrapper to handel AVI Files. I'm unsing
managed C++ with VStudio 2003. The structure of my classes looks like this:
class AudioStream {
...
}
class VideoStream {
...
}
class AviFile {
IAVIFile* file_;
AudioStream* audio_;
VideoStream* video_;
public:
void Open(const char* path) {
AVIFileOpen(&file_,path,OF_SHARED_DENY_WRITE,NULL);
audio_ = new AudioStream();
video_ = new VideoStream();
}
}
audio_ and video_ are pointers to unmanaged classes and, according to
the documentation, are therefore implicit unmanaged pointers. But what
about file_?
The call to AVIFileOpen results in the error "'AVIFileOpenA' : cannot
convert parameter 1 from 'IAVIFile* __gc*' to 'PAVIFILE*'. AVIFileOpen
is a windows function defined in Vfw.h.
How do I have to define file_ to get my example working?
regards,
Achim