Re: Pyglet 1.2 Avbin 10 - video play from MKV - black screen

124 views
Skip to first unread message

Nathan

unread,
May 5, 2013, 11:44:12 PM5/5/13
to pyglet...@googlegroups.com
You should begin by downloading the pyglet source code and looking at examples/media_player.py

media_player.py isn't perfect, but it usually works pretty well.  If it gives you a black screen as well, maybe you could make a small sample .mkv file that you could share so I could try to debug the issue.

~ Nathan


On Wed, Mar 13, 2013 at 3:45 PM, Tomas <top...@gmail.com> wrote:
I use simple as possible code to create a video player:

source = pyglet.media.load("some_file.mkv")
format = source.video_format
if not format:
    print 'No video track in this source.'
    sys.exit(1)

player = pyglet.media.Player()
player.queue(source)

window = pyglet.window.Window(width=format.width, height=format.height)

@window.event
def on_draw():
    #window.clear()
    player.get_texture().blit(0, 0)

pyglet.app.run()

Screen size is adjusted according to video, but texture is empty (or black?) With AVI there is no such problem and everything works fine. MKV contains video which is encoded with h264
on_draw() event is handled to. No other warnings or any kind of messages.

Any thoughts where to begin?

Thanks,  T.

--
You received this message because you are subscribed to the Google Groups "pyglet-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to pyglet-users...@googlegroups.com.
To post to this group, send email to pyglet...@googlegroups.com.
Visit this group at http://groups.google.com/group/pyglet-users?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.
 
 

Tomas

unread,
May 13, 2013, 7:58:26 AM5/13/13
to pyglet...@googlegroups.com
I've tried with 5 or 6 mkv files (different a/v codecs). Result is the same.
FFplay, VLC, mplayer plays those file flawless.

Nathan

unread,
May 19, 2013, 11:13:44 PM5/19/13
to pyglet...@googlegroups.com
Can you give me access to a small mkv file that I could test with?

~ Nathan

Tomas

unread,
Jun 19, 2013, 5:22:34 PM6/19/13
to pyglet...@googlegroups.com
Any file from torrent. I don't have any small files - smallest about 4gb.
To unsubscribe from this group and stop receiving emails from it, send an email to pyglet-users+unsubscribe@googlegroups.com.

Nathan

unread,
Jun 28, 2013, 5:32:17 PM6/28/13
to pyglet...@googlegroups.com
Quick status update: I have uncovered some pretty fundamental flaws in the original design of the AVbin API have affected the decoding of ANY codec that is more complicated than basic in-order frame encoding.

I've been working for a few weeks on the issue, and have ended up rewriting a lot of the AVbin API and Pyglet module that's using it.  I'm getting somewhat close to completion (I hope).  I'll be starting some new threads on this mailing list as I get a little closer to completion.

~ Nathan


Reply all
Reply to author
Forward
0 new messages