Java-Gaming.org    
Featured games (79)
games approved by the League of Dukes
Games in Showcase (475)
Games in Android Showcase (106)
games submitted by our members
Games in WIP (530)
games currently in development
News: Read the Java Gaming Resources, or peek at the official Java tutorials
 
    Home     Help   Search   Login   Register   
Pages: 1 2 [3]
  ignore  |  Print  
  is video playback in java really as complicated as it seems?  (Read 9548 times)
0 Members and 1 Guest are viewing this topic.
Offline Cero
« Reply #60 - Posted 2012-01-30 00:12:45 »

what also strikes me - there have to be java games with video playback
dont think minecraft has video
but what about other big games like wakfu and spiral knights ? I'm sure they have something

Offline Cero
« Reply #61 - Posted 2012-02-20 20:41:31 »

so Wakfu uses xuggler apparently
does anyone here has any experience with it ?

Offline princec

JGO Kernel


Medals: 339
Projects: 3
Exp: 16 years


Eh? Who? What? ... Me?


« Reply #62 - Posted 2012-02-20 21:16:15 »

Yes. It works. Big piece of complicated native code. Based off of ffmpeg. Has licensing issues with some formats.

Cas Smiley

Games published by our own members! Check 'em out!
Legends of Yore - The Casual Retro Roguelike
Offline Cero
« Reply #63 - Posted 2012-02-20 21:41:11 »

Big piece of complicated native code. Based off of ffmpeg.
Yeah you cant even download the jar anymore, you have to build it yourself
its all... exhausting

Has licensing issues with some formats.
Well thats a given - gotta go Theora and OGG Vorbis.

Which is why I'm looking into cortado again.
Being an Applet sucks - but if I can get the frames to render in OpenGL...
and for sync, well, if you do play audio and video separately, it never appears to have a problem
going try some more cortado...

Offline Cero
« Reply #64 - Posted 2012-02-26 23:10:07 »

there is a site requesting more codecs for javafx 2 obviously, saying
Quote
The on2 Vp6 codec not only is unsupported, but is also not that much of a platform dependent format (the encoder library exists only as a dll vp6vfw.dll and nothing else). It defeats the purpose of the end-goal of JavaFx.

we wrote some code to get cortado working right, or to be more precise jheora with the help of POGG

it basically boils down to these problems:
- you would have to do audio sync yourself, because only theora files without audio work reliably
- also its too slow, decoding the video is just too slow, something like a 800x500 video on a 2,4ghz single core and it does stutter here and there, which of course doesnt help sync


the only way out, that I can see - is writing some piece of xuggler code with uses theora because of the licensing

stuff like VLCJ works in theory, but only if you wanna GPL your code and everything

but now, there arent even xuggler builds any more to download, you have to build it yourself somehow
now, i cannot even start coding using Xuggler because the set-up is so complex - and apart from getting it to work, I do have to understand it a little to deploy it, so that it would work on all users PCs, regardless of what they have installed
which is what I could say about VLCJ, but again there are other issues there...

Offline princec

JGO Kernel


Medals: 339
Projects: 3
Exp: 16 years


Eh? Who? What? ... Me?


« Reply #65 - Posted 2012-02-26 23:35:12 »

Hmm I'm a little surprised about the speed - contrary to popular believe Java's pretty reasonable at number crunching tasks - I should think it came in at around 50% of the speed of optimised C code for a decoder... maybe more work back at the labs required?

Cas Smiley

Offline Riven
« League of Dukes »

JGO Overlord


Medals: 742
Projects: 4
Exp: 16 years


Hand over your head.


« Reply #66 - Posted 2012-02-26 23:42:09 »

Hmm I'm a little surprised about the speed - contrary to popular believe Java's pretty reasonable at number crunching tasks - I should think it came in at around 50% of the speed of optimised C code for a decoder... maybe more work back at the labs required?
Don't underestimate the lack of SIMD (SSE) in Java.

Hi, appreciate more people! Σ ♥ = ¾
Learn how to award medals... and work your way up the social rankings
Offline princec

JGO Kernel


Medals: 339
Projects: 3
Exp: 16 years


Eh? Who? What? ... Me?


« Reply #67 - Posted 2012-02-26 23:45:47 »

I had thought that it was using some of those SIMD instructions under the hood by now?

Cas Smiley

Offline Riven
« League of Dukes »

JGO Overlord


Medals: 742
Projects: 4
Exp: 16 years


Hand over your head.


« Reply #68 - Posted 2012-02-27 00:22:24 »

I had thought that it was using some of those SIMD instructions under the hood by now?

HotSpot is using SSE2, but only operating on single values, never 4.

Hi, appreciate more people! Σ ♥ = ¾
Learn how to award medals... and work your way up the social rankings
Offline Cero
« Reply #69 - Posted 2012-02-27 02:40:53 »

I only used POGG in java2D no opengl stuff yet, but syncing issues would still be there

@Cas:  I have read the old thread "Cortado works", and you never said that you're going to give up on video
Reading the thread one might think that you really came up with a solid theora player, especially with your background being in TV/video
So what chance does anyone have, if not even you can get it to work - kinda demoralizing

also tried a little JMF again: basically only MPEG looks good, but those videos are of course quite big
and not easily (or not fast) rendered to opengl...

Games published by our own members! Check 'em out!
Legends of Yore - The Casual Retro Roguelike
Offline Roquen
« Reply #70 - Posted 2012-02-27 05:04:45 »

I had thought that it was using some of those SIMD instructions under the hood by now?

HotSpot is using SSE2, but only operating on single values, never 4.
SISD usage has been around for awhile.  The painful fact is that even if there was some SIMD usage the gains would be less than one might expect because auto-vectorization technology is very limited and doesn't seem to be making much progress.
Offline Riven
« League of Dukes »

JGO Overlord


Medals: 742
Projects: 4
Exp: 16 years


Hand over your head.


« Reply #71 - Posted 2012-02-27 09:13:48 »

auto-vectorization technology is very limited and doesn't seem to be making much progress.
That's why it's handcoded in most codecs. I was merely making the point that SIMD is impossible in Java (though not trivial in C).

Hi, appreciate more people! Σ ♥ = ¾
Learn how to award medals... and work your way up the social rankings
Offline princec

JGO Kernel


Medals: 339
Projects: 3
Exp: 16 years


Eh? Who? What? ... Me?


« Reply #72 - Posted 2012-02-27 10:24:39 »

@Cas:  I have read the old thread "Cortado works", and you never said that you're going to give up on video
Reading the thread one might think that you really came up with a solid theora player, especially with your background being in TV/video
So what chance does anyone have, if not even you can get it to work - kinda demoralizing
My expertise is in integration work rather than actually writing and/or debugging codecs, and a lot of the issues I had were basically down to slightly crappily designed codecs or APIs (making OpenGL integration basically difficult and/or slow) or just plain "it doesn't work" bugs. I got one single piece of test video to work with cortado - some silent lunar module launch footage - and nothing else I tried to encode with Theora worked with it. This is a great shame because it would just be an absolutely perfect fit for a large number of hobby developers to get Theora and OpenGL working together properly.

I wonder why autovectorisation is proving such a tough nut to crack. The same processes that people go through to vectorise C code should be... hmmm... "definable" I thought. Though it is rather a specialised area. In fact I can't think of any other general purpose computing task that seriously requires this sort of effort. All the cool kids are using multithreaded decoding anyway now - far easier to throw multiple cores at this problem than write custom machine code for every chip out there...

Cas Smiley

Offline Roquen
« Reply #73 - Posted 2012-02-27 11:11:19 »

auto-vectorization technology is very limited and doesn't seem to be making much progress.
That's why it's handcoded in most codecs. I was merely making the point that SIMD is impossible in Java (though not trivial in C).
Sure...I was intending to augment what you were saying.  If java were to add SIMD & state-of-the-art auto-vectorization then the gains would not be what most people might expect.  We're sorta in the same boat as lacking structs here.  The only was to really use SIMD is to be able to directly express the operations.
Pages: 1 2 [3]
  ignore  |  Print  
 
 
You cannot reply to this message, because it is very, very old.

 

Add your game by posting it in the WIP section,
or publish it in Showcase.

The first screenshot will be displayed as a thumbnail.

ctomni231 (34 views)
2014-07-18 06:55:21

Zero Volt (30 views)
2014-07-17 23:47:54

danieldean (25 views)
2014-07-17 23:41:23

MustardPeter (27 views)
2014-07-16 23:30:00

Cero (42 views)
2014-07-16 00:42:17

Riven (44 views)
2014-07-14 18:02:53

OpenGLShaders (32 views)
2014-07-14 16:23:47

Riven (34 views)
2014-07-14 11:51:35

quew8 (30 views)
2014-07-13 13:57:52

SHC (66 views)
2014-07-12 17:50:04
HotSpot Options
by dleskov
2014-07-08 03:59:08

Java and Game Development Tutorials
by SwordsMiner
2014-06-14 00:58:24

Java and Game Development Tutorials
by SwordsMiner
2014-06-14 00:47:22

How do I start Java Game Development?
by ra4king
2014-05-17 11:13:37

HotSpot Options
by Roquen
2014-05-15 09:59:54

HotSpot Options
by Roquen
2014-05-06 15:03:10

Escape Analysis
by Roquen
2014-04-29 22:16:43

Experimental Toys
by Roquen
2014-04-28 13:24:22
java-gaming.org is not responsible for the content posted by its members, including references to external websites, and other references that may or may not have a relation with our primarily gaming and game production oriented community. inquiries and complaints can be sent via email to the info‑account of the company managing the website of java‑gaming.org
Powered by MySQL Powered by PHP Powered by SMF 1.1.18 | SMF © 2013, Simple Machines | Managed by Enhanced Four Valid XHTML 1.0! Valid CSS!