[vlc-devel] [Android] Hi, I'm not from the vlc team, but I really appreciate your help with writing a module to vlc

Dafna Hirschfeld dafna3 at gmail.com
Thu Aug 17 01:56:38 CEST 2017

I write a video decoder module for vlc on android.
The decoder is for a custom encoding format that I developed myself.
The files with my encoding are mp4 , but they I have a custom fourcc (say
"abcd" ) and a different file extension.

When I click the file from the app, the app does not play it , instead
there is the vlc icon rulling around. looking at the logs, I see:

[*b84a40f8/58c6] mp4 demux: ISO Media (isom) version 512.*
*[b84a40f8/58c6] mp4 demux: found 1 tracks*
*[b84a40f8/58c6] mp4 demux: elst box found*
*[b84a40f8/58c6] mp4 demux:    - [0] duration=33ms media time=-1ms)
*[b84a40f8/58c6] mp4 demux:    - [1] duration=19253ms media time=0ms)
*[b84a40f8/58c6] mp4 demux: track[Id 0x1] read 3 chunk*
*[b84a40f8/58c6] mp4 demux: STTS table of 2 entries*
*[b84a40f8/58c6] mp4 demux: track[Id 0x1] read 578 samples length:19s*
*[b84a40f8/58c6] essetup demux: Unrecognized FourCC abcd*
*[b87af180/58c6] core input: selecting program id=0*
*[b84a40f8/58c6] mp4 demux: adding track[Id 0x1] video (enable) language
*[b84a40f8/58c6] core demux: using demux module "mp4"*
*[b87af180/58c6] core input: looking for a subtitle file in
*[b87af180/58c6] core input: video is disabled, not selecting ES 0x0*
*[b8685fd0/58c6] core demux meta: looking for meta reader module matching
"any": 2 candidates*
*[b8685fd0/58c6] lua demux meta: Trying Lua scripts in
*[b8685fd0/58c6] lua demux meta: Trying Lua playlist script
*[b8685fd0/58c6] lua demux meta: Trying Lua scripts in
*[b8685fd0/58c6] core demux meta: no meta reader modules matched*
*[b87af180/58c6] core input:
`file:///storage/emulated/0/pinwheel_abcd_fourcc.abcd' successfully opened*
*[b87af180/58c6] core input: EOF reached*
*[b84a40f8/58c6] core demux: removing module "mp4"*

the red line seems to indicate the problem, looking at the code, this log
comes from the function *static void EsSelect( es_out_t *out, es_out_id_t
*es )* in the file *vlc/src/input/es_out.c*
and the code is:

*if( es->fmt.i_cat == VIDEO_ES || es->fmt.i_cat == SPU_ES )*
*        {*
*            if( !var_GetBool( p_input, b_sout ? "sout-video" : "video" ) )*
*            {*
*                msg_Dbg( p_input, "video is disabled, not selecting ES
*                         es->i_id );*
*                return;*
*            }*
*        }*

If I comment out the *return * command, it fixes the problem and the video
is played with my decoder.
I added some debug logs and the found out that the *b_sout *is 0 so
the *var_GetBool
* return the value of the *"video" *

the places that I found related to it are:

*vlc/src/input/var.c:436:        var_Create( p_input, "video", VLC_VAR_BOOL
*vlc/src/input/var.c:771:        var_SetBool( p_input, "video", true );*

in more debug prints that I added , the first line sets *"video"* to 0x8020
and the second lines does called.

I'm a bit stuck with that and really appreciate any help.

Thanks a lot
Dafna Hirschfeld
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.videolan.org/pipermail/vlc-devel/attachments/20170817/3a654f2c/attachment.html>

More information about the vlc-devel mailing list