Debug DllAvFormat?
#1
Hello,

I was wondering if it is possible to debug (step through the source code of) avformat.dll using Visual Studio when running xbmc on Windows?

I notice that all the functions in the dll appeared to be wrapped by DllAvFormat which inherits from DynamicDll.

Is debugging possible?

Is the dll wrapper needed because avformat.dll is compiled with gcc?

Thanks,
rdg
Reply
#2
No you can't debug them with vs.
The wrapper was needed to allow dll's using XBMC's virtual filesystem. This is obsolete now but the wrapper is still in place.
I started to remove it and to link the dll's statically (https://github.com/wsoltys/xbmc/commits/ffmpeg) but after a while the overall interest wasn't there to bring that to an end.
Always read the XBMC online-manual, FAQ and search the forum before posting.
Do not e-mail XBMC-Team members directly asking for support. Read/follow the forum rules.
For troubleshooting and bug reporting please make sure you read this first.
Reply
#3
WiSo,

Thanks for explaining this. I was wondering about the purpose of the wrapper.

I haven't looked as closely at the Linux build but I would imagine the wrappers are not needed for Linux.

Thanks,
rdg
Reply
#4
A question I am trying to answer is how the buffer is sized. For example in DVDDemuxFFmpeg.cpp in the Open function there is this:

m_ioContext = m_dllAvFormat.avio_alloc_context(buffer, FFMPEG_FILE_BUFFER_SIZE, 0, this, dvd_file_read, NULL, dvd_file_seek);

If I change the value of FFMPEG_FILE_BUFFER_SIZE to 48128 and then recompile I would expect the size in the dvd_file_read function to be 48128

static int dvd_file_read(void *h, uint8_t* buf, int size)

However it seems that the size is still 32768. So the size must be getting set somewhere else in the code. Because of the wrapper code this cannot be easily traced with the debugger.

-rdg
Reply

Logout Mark Read Team Forum Stats Members Help
Debug DllAvFormat?0