jaruba / wcjs-player

Node Player made for WebChimera.js (libVLC wrapper)
http://webchimera.org/
GNU Lesser General Public License v2.1
178 stars 46 forks source link

[Linux] App Crash when Start Playing #2

Closed smolleyes closed 8 years ago

smolleyes commented 9 years ago

hello jaruba :)

ok just trying your new project on my old laptop

the pluginbuild and load fineinmy realllyyy basic nw app

when i start it, it s buffeering then just crash no vlc infos or anything in the terminal... an idear on how to debug this?

thanks

jaruba commented 9 years ago

What OS are you trying it on?

smolleyes commented 9 years ago

lsb_release -a No LSB modules are available. Distributor ID: Ubuntu Description: Ubuntu 14.04.1 LTS Release: 14.04.1 Codename: trusty

smolleyes commented 9 years ago

nw12

jaruba commented 9 years ago

Uhm.. If it's buffering correctly and works with a basic app, then it means that vlc and the webchimera.js modules have been added correctly to the app.

If it breaks right after buffering then there must be a problem with drawing to the canvas, it is most probably an issue in webchimera.js or something that breaks in wcjs-renderer's functions (either frameSetup() or render())

I've not seen JavaScript freeze NW.js or the Browser yet (not unless it gets stuck in an infinite loop or waits for a synchroneous response that it never receives). I'm pretty sure that wcjs-player can't be the reason for this..

For debugging, @RSATom or @Ivshti should be able to help more, as I did not work on the C++ side of webchimera.js at all.

I know @Ivshti is already using it in Stremio and has not reported any such behavior.

In the meanwhile (as they should be online only after at least 4-5 hours from now), you can try some of the following tests (in order of importance):

smolleyes commented 9 years ago

will try the wcjs-renderer

i m on a old laptop with basic radeon drivers maybe this is the issue

brb

smolleyes commented 9 years ago

wcjs-ugly-demo crash directly too just seevthe nw window then crash

jaruba commented 9 years ago

Then it's something with the graphic's card (or the drivers), webchimera.js module or VLC itself that's creating the problem..

smolleyes commented 9 years ago

don t seem to have problem with hw accel

http://paste.ubuntu.com/11738019/

from chrome://gpu in my test nw app

smolleyes commented 9 years ago

http://webglsamples.org/aquarium/aquarium.html works and do not crash my app too (very very slow 6 fps/sec with 50 fish ...) but no crash

smolleyes commented 9 years ago

i ll install fglrx.. brb

jaruba commented 9 years ago

http://webglsamples.org/aquarium/aquarium.html works and do not crash my app too (very very slow 6 fps/sec with 50 fish ...) but no crash

Awesome sample! I'm having so much fun with it right now. :))

don t seem to have problem with hw accel

We've had some issues with WebChimera and some graphics cards in the past but with the NPAPI Plugin not webchimera.js, it would not be impossible for the issue to arise in webchimera.js too..

Only two specific cards wore reported though: https://github.com/RSATom/WebChimera/issues/64#issuecomment-71331977

jaruba commented 9 years ago

very very slow 6 fps/sec with 50 fish

Your FPS is incredibly low for only 50 fish though.. Maybe the graphic's card simply can't handle the weight of playback.

Have you tried running the same video in VLC directly? From our tests webchimera.js only uses a tiny bit more resources then VLC.

Ivshti commented 9 years ago

If you don't have a GPU problem, then I know this behavior - VLC cannot find its plugins and stars rendering with some stupid fallback that is slow and crashes the app. Check for VLC error messages in the command prompt

Ivshti commented 9 years ago

We should disable this, whatever it is, because users might think webchimera.js is at fault.

@RSATom any idea what might it be? I've seen it on OS X

RSATom commented 9 years ago

@Ivshti, don't know. For me it works on linux. Tried right now.

RSATom commented 9 years ago

@smolleyes, what exactly did you try run? And where did you get it, from npm or github repo?

smolleyes commented 9 years ago

hello

just installed wcjs-player from npm...

created a basic package.json installed nw12 files

created a html with a #player div in the body and the exemple js file on the readme....

i can read any file with vlc on this old pc even hevc with few lags sometimes but 3d is very slow yes but it don t explain why the app totally crash it s not just slow as the aquarium test...

i don t have any infos in the terminal from vlc ivshti

when i startthe app i have

./nw .
[5640:0619/152204:ERROR:browser_main_loop.cc(170)] Running without the SUID sandbox! See https://code.google.com/p/chromium/wiki/LinuxSUIDSandboxDevelopment for more information on developing with the sandbox on.
ATTENTION: default value of option force_s3tc_enable overridden by environment.
[5660:0619/152205:ERROR:sandbox_linux.cc(325)] InitializeSandbox() called with multiple threads in process gpu-process

(have the same errors in my streamstudio app and nothing crash when playing videos thru videoelement.js)

maybe he doesn t like my vlc 2.2.1 from ppa?

thx :)

smolleyes commented 9 years ago

i ll try the nw 0.12.1

it fix the crashdump not available in 0.12 then maybe rogerwang or someone else can get more infos with it (don t know how to read this dump...)

smolleyes commented 9 years ago

ok here s the dump file

same crash with nw 12.1

https://www.streamstudio.me/StreamStudio/nw12/dump.zip

++

RSATom commented 9 years ago

@smolleyes, could you please try run this: https://github.com/RSATom/wcjs-ugly-demo ?

smolleyes commented 9 years ago

tried yesterday

same problem direct crash:p

RSATom commented 9 years ago

ok, will try myself on xubuntu...

RSATom commented 9 years ago

tried on xubuntu 14 - didn't get any crash

RSATom commented 9 years ago

@smolleyes, could you please try with Electron? I've updated repo with instructions and required scripts: https://github.com/RSATom/wcjs-ugly-demo

smolleyes commented 9 years ago

hello

just tried on my normal pc (just used the build and run.cmd for each as asked)

(why ia32 hardcoded in build_nwjs.cmd ?)

for electron

Renderer process started [24894:0620/181903:INFO:CONSOLE(83)] "Uncaught Error: Module version mismatch. Expected 44, got 43.", source: /tmp/wcjs-ugly-demo/node_modules/wcjs-renderer/node_modules/webchimera.js/node_modules/bindings/bindings.js (83)

won t start or crash

for nwjs12.2

/tmp/wcjs-ugly-demo/nw: symbol lookup error: /tmp/wcjs-ugly-demo/node_modules/wcjs-renderer/node_modules/webchimera.js/build/Release/WebChimera.js.node: undefined symbol: libvlc_new

... :p

RSATom commented 9 years ago
smolleyes commented 9 years ago

just updated vlc and libvlc-dev from ppa to 2.2.1 then reinstalled wcjs-player

it install and build fine but still

/tmp/test/nw: symbol lookup error: /tmp/test/node_modules/wcjs-player/node_modules/wcjs-renderer/node_modules/webchimera.js/build/Release/WebChimera.js.node: undefined symbol: libvlc_new

don t understand

RSATom commented 9 years ago

I think it just can't find libvlc from your ppa installation.

RSATom commented 9 years ago

try install vlc not from ppa, and if it will work - we will try find the way to solve problem with libvlc from ppa

RSATom commented 9 years ago

tbh, I didn't try use vlc from ppa

smolleyes commented 9 years ago

without ppa vlc on ubuntu is a shame... too old

i ll try

i added th same ppa yesterday on my old laptop without this error... strange

smolleyes commented 9 years ago

damn!

removed all my ppa, vlc libvlc-dev....

reinstalled in 2.1.6 from ubuntu repo and same error

/tmp/test/nw: symbol lookup error: /tmp/test/node_modules/wcjs-player/node_modules/wcjs-renderer/node_modules/webchimera.js/build/Release/WebChimera.js.node: undefined symbol: libvlc_new

:/

RSATom commented 9 years ago

what exactly vlc packages did you install?

smolleyes commented 9 years ago

vlc (2.1.6-0ubuntu14.04.1)

http://fr.archive.ubuntu.com/ubuntu/ trusty-updates/universe libvlc-dev amd64 2.1.6-0ubuntu14.04.1 [25,4 kB]

RSATom commented 9 years ago

sudo apt-get install vlc libvlc-dev - right?

smolleyes commented 9 years ago

sudo apt-get install vlc libvlc-dev yes

smolleyes commented 9 years ago

dpkg -l | grep libvlc

give me (seems right)

ii libvlc-dev 2.1.6-0ubuntu14.04.1 amd64 development files for libvlc ii libvlc5 2.1.6-0ubuntu14.04.1 amd64 multimedia player and streamer library ii libvlccore7 2.1.6-0ubuntu14.04.1 amd64 base library for VLC and its modules

smolleyes commented 9 years ago

don t know if i must have a libvlc_new.so somewhere but can t find it...

RSATom commented 9 years ago

it seems I just forget link vlc on linux: https://github.com/RSATom/ya-libvlc-wrapper/blob/master/CMakeLists.txt

RSATom commented 9 years ago

but don't understand why it worked for me...

smolleyes commented 9 years ago

:) don t know

i ll wait for your fix

RSATom commented 9 years ago

you could try add target_link_libraries( ${PROJECT_NAME} vlc ) to https://github.com/RSATom/WebChimera.js/blob/master/CMakeLists.txt#L30

smolleyes commented 9 years ago

ok

add it then node rebuild.js

it load and no crash but won t play file

Fontconfig warning: FcPattern object size does not accept value "0" Fontconfig warning: FcPattern object size does not accept value "0" Fontconfig warning: FcPattern object size does not accept value "0" Fontconfig warning: FcPattern object size does not accept value "0" [0x3774efcdfe98] main vout display error: Failed to change zoom [0x3774efcdfe98] main vout display error: Failed to set on top [0x3774efcdfe98] main vout display error: Failed to change source AR

RSATom commented 9 years ago

link used in ugly demo is little bit slow, try set your own link there.

smolleyes commented 9 years ago

trying with http://clips.vorwaerts-gmbh.de/big_buck_bunny.mp4

same thing

smolleyes commented 9 years ago

./nw . [16441:0620/194224:ERROR:browser_main_loop.cc(170)] Running without the SUID sandbox! See https://code.google.com/p/chromium/wiki/LinuxSUIDSandboxDevelopment for more information on developing with the sandbox on. ATTENTION: default value of option force_s3tc_enable overridden by environment. [16461:0620/194224:ERROR:sandbox_linux.cc(325)] InitializeSandbox() called with multiple threads in process gpu-process [mov,mp4,m4a,3gp,3g2,mj2 @ 0x30b7075a4800] max_analyze_duration reached Fontconfig warning: FcPattern object size does not accept value "0" Fontconfig warning: FcPattern object size does not accept value "0" Fontconfig warning: FcPattern object size does not accept value "0" Fontconfig warning: FcPattern object size does not accept value "0" [0x30b7071e4898] main vout display error: Failed to change zoom [0x30b7071e4898] main vout display error: Failed to set on top [0x30b7071e4898] main vout display error: Failed to change source AR [16441:0620/194227:ERROR:backend_impl.cc(1364)] Unable to map Index file

RSATom commented 9 years ago

ok, I'll look again by myself tomorrow. It seems I missed something.

smolleyes commented 9 years ago

more infos...

ATTENTION: default value of option force_s3tc_enable overridden by environment. [17998:0620/194646:ERROR:sandbox_linux.cc(325)] InitializeSandbox() called with multiple threads in process gpu-process [00001f23e771f098] core vout display error: Failed to change zoom [00001f23e771f098] core vout display error: Failed to set on top [00001f23e771f098] core vout display error: Failed to change source AR [00001f23e792abf8] core input error: ES_OUTSET(GROUP_)PCR is called too late (pts_delay increased to 1041 ms) [00001f23e792abf8] core input error: ES_OUT_RESET_PCR called Non-reference picture received and no reference available [h264 @ 0x1f23e75e7c00] decode_slice_header error

RSATom commented 9 years ago

could you try some local file?

smolleyes commented 9 years ago

ok brb