<html><body><div style="color:#000; background-color:#fff; font-family:times new roman, new york, times, serif;font-size:12pt"><div><br></div><div>Folks,</div><div><br></div><div>Environment: Ubuntu 10.x. VLC source 2.0.1<br></div><div><br></div><div>I have created a module that shows special watermark when a movie is played. <br></div><div><br></div><div>The following command works as expected:<br></div><div><br></div><div>$ ./vlc --sub-source="mywatermark" myfile.mp4</div><div><br></div><div>The watermark module gets loaded appropriately and the watermark is displayed on screen.<br></div><div><br></div><div>For our purpose, it is mandatory that this module be loaded. As a user may bypass this command line parameter, I customized vlc-source/bin/vlc.c for our needs. In the first line of main(), I replace original argc and argv with my own argc and argv. The new argument list contains my sub-source parameter.</div><div><br></div><div>int main( int
i_argc, const char *ppsz_argv[] )<br>{<br> ppsz_argv = GetCmdArguments(i_argc, ppsz_argv, &i_argc);<br><br> for(int i=0;i<i_argc;i++) {<br> printf("Arg: %s\n", ppsz_argv[i]);<br> }<br></div><div><br></div><div>The print line displays the parameters and they are exactly as I desire, including my "sub-source" parameter. However, when done this way, my filter never gets created.</div><div><br></div><div>There are other hard-coded parameters that seem to work except "sub-source" parameter type.<br></div><div><br></div><div>This sounds silly. I don't understand why the parameter works when passed from command line but not when overridden within the main function. <br></div><div><br></div><div>The only thing I could think of is that VLC is obtaining some parameters from the process table.<br></div><div><br></div><div>I am wondering if anyone has any insight on what
could be happening here.</div><div><br></div><div>Regards,</div><div>Peter<br></div><div><br></div><div><br></div><div><br></div><div><br></div></div></body></html>