Page 1 of 1

how to Streaming video for iphone using vmem

Posted: 13 Dec 2010 02:49
by ian168
As the topic,i implement the code like this:
the following part for vmem callback function,
typedef struct CTX
{
unsigned short* surf;
} CTX;

static void lock(CTX *ctx, void **pp_ret)
{
*pp_ret = ctx->surf;
}

static void unlock(CTX *ctx)
{
//uint16_t *pixels = (uint16_t *)ctx->surf;
}

and part of source code:
sprintf(clock, "--vmem-lock=%lld", (long long int)(intptr_t)lock);
sprintf(cunlock, "--vmem-unlock=%lld", (long long int)(intptr_t)unlock);
sprintf(cdata, "--vmem-data=%lld", (long long int)(intptr_t)&ctx);
.....
some log message as following:
[e[32;1m0xe96344e[0m] vmem generic error: e[31;1mmissing lock callbacke[0m
[e[32;1m0xe96344e[0m] main generic debug: e[0mno vout display module matching "vmem" could be loadede[0m
[e[32;1m0xe96344e[0m] main generic debug: e[0mTIMER module_need() : 0.757 ms - Total 0.757 ms / 1 intvls (Avg 0.757 ms)e[0m
[e[32;1m0x112b0a4e[0m] main video output error: e[31;1mvideo output creation failede[0m
[e[32;1m0x11302a4e[0m] main spu text debug: e[0mremoving module "dummy"e[0m
[e[32;1m0x1132ca4e[0m] main scale debug: e[0mremoving module "yuvp"e[0m
[e[32;1m0x11306a4e[0m] main scale debug: e[0mremoving module "swscale"e[0m
[e[32;1m0x11176a4e[0m] main decoder error: e[31;1mfailed to create video outpute[0m
[e[32;1m0x11176a4e[0m] main decoder warning: e[0;33mcan't get output picturee[0m

Why can't i get the callback raw data????
Please everybody help me!

ian168