[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]
[pygame] Using sdl_surface for the movie module
- To: pygame-users@xxxxxxxx
- Subject: [pygame] Using sdl_surface for the movie module
- From: Tyler Laing <trinioler@xxxxxxxxx>
- Date: Tue, 16 Jun 2009 09:19:30 -0700
- Delivered-to: archiver@xxxxxxxx
- Delivered-to: pygame-users-outgoing@xxxxxxxx
- Delivered-to: pygame-users@xxxxxxxx
- Delivery-date: Tue, 16 Jun 2009 12:19:33 -0400
- Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:date:message-id:subject :from:to:content-type; bh=R35HvFwCUJy2wfP/gAAwetEgnWDpxuZD6jU4bprJht8=; b=oWU+H6WboPHNuT1NIfsLQXLDW7w7egym9ajwOd2UUg8RVAi8rsgqciOvNhlnst1VJa QonnXYmdfNycl9AnhnNsooIXFFCfYpzTUhnLyXiWjKn7vrg1lv6Q5AXuBSlwqs1y9irV EP6tlrafeuDE1X2ia2XeHBoz0ICYefn7ABy5c=
- Domainkey-signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:date:message-id:subject:from:to:content-type; b=PCHzFnDZNaUXNNKOo8uqo+/GC+9FUiXoGO+nq7V82hO14eqPKIdfcrgQwo20XlS02L Zs+kcw2adwtN0iOSX9b8Sa56RM/qWxLsgOzEVf3NbbHvgYs8kq1tEqa5ZrtoHxz1mPnB JOCmLUAFbY6CSKpeg2nhbni6m12xtQeXFKWX0=
- Reply-to: pygame-users@xxxxxxxx
- Sender: owner-pygame-users@xxxxxxxx
I have a quick question here:
I'm trying to figure what would be the best way to work with an sdl_surface for the movie module. Let me give some quick background here. All the code I've been able to find with ffmpeg seems to use only sdl_overlays. The way the overlays work, is that you can write to them, then you have to explicitly display them. I've figured out a good way to write arbritary video formats to a surface(AVFrame->sws_scale to YUV420P in an AVPicture->conversion algorithm which writes to the SDL_Surface). But I'm wondering if I need to do any more than that. I do have picture queue set up, which stores finished pictures, as the decoding goes a lot faster than waiting the amount of time to show a new frame. The picture queue stores VidPicture objects which uses either an overlay or a surface, depending on arguments passed in by the user at the initialization of the object. What else do I have to do to "display" the written surface? I'm thinking just writing to the given surface by the user would be satisfactory? If so, what is the fastest way?
-Tyler
--
Visit my blog at http://oddco.ca/zeroth/zblog