chetto1983 / jsc3d

Automatically exported from code.google.com/p/jsc3d
0 stars 0 forks source link

Chrome 30 crashes during texture rendering #47

Open GoogleCodeExporter opened 8 years ago

GoogleCodeExporter commented 8 years ago
= What steps will reproduce the problem?
1. Open Chrome 30.0.1599.101 (Windows or Mac)
2. Go to this URL : http://www.fabzat.com/tmp/bug_demo/
3. The browser often (or sometimes ?) crash after loading textures

= What is the expected output? What do you see instead?
Expected : 3D model is loaded normally
Reality : Chrome crashes with the "aw snap" message 
http://fabzat.com/tmp/bug_demo/aw-snap.png

= What version of the product are you using? On what operating system?
I can reproduce the problem on WIndows & Mac with Chrome version 30.0.1599.101 
(tested on 5 differents computers)
The version of the lib used is "JSC3D 1.4.2 full release"

= Please provide any additional information below.
The problem occurs in texture smooth rendering when calling method 
"transformVectorZs" (the first of two).
I tried to replace my textures with textures from one of the demos provided 
(bank), result is the same.
The problem does not occur if I remove texture files from server (aka 404 
errors on image files).
Problem occurs more often if webpage if on a remote server and not in a local 
network.
Problem occurs on the first load only. When files are in the browser cache, the 
problem dos not occur anymore.
Files to reproduce can be found here : 
http://fabzat.com/tmp/bug_demo/bug_demo.zip

I understand that this is a browser bug and not a jsc3d bug. But I need to find 
a workarournd for my production use.

Thanks for your help

Original issue reported on code.google.com by laurent....@fabzat.com on 12 Nov 2013 at 12:13

GoogleCodeExporter commented 8 years ago
That's too bad. 

It looks very similar to a known issue 
http://code.google.com/p/chromium/issues/detail?id=277297. It is tested to be 
relevant to some incorrect optimization for nested loops in V8 javascript 
engine for Chrome 29 and above, which internally results in an 
EXC_BAD_ACCESS/KERN_PROTECTION_FAILURE error and makes the browser crash down.

A guy from the Chromium team told me that the problem does not recur on early 
built of Chrome 32. They are working on to fix this bug in future release.

For now, you could try jsc3d's (experimental) webgl rendering backend to avoid 
this problem. 

To achieve this, first download the latest jsc3d.js 
http://jsc3d.googlecode.com/svn/trunk/jsc3d/jsc3d.js and jsc3d.webgl.js 
http://jsc3d.googlecode.com/svn/trunk/jsc3d/jsc3d.webgl.js from the repository 
and include them in your application page.

Then, enable webgl rendering using an currently undocumented startup parameter 
'Renderer' before initialization of the viewer instance:

  ...
  viewer3d.setParameter('Renderer', 'webgl');
  ...

By setting this, jsc3d will try to launch its webgl accelerated rendering 
backend to replace the traditional software rendering routine where webgl is 
available. It's harmless for browsers which do not support webgl.

I modified your demo using the method mentioned above and it seems to work fine 
in my own test. You can get it in the attacment.

Jsc3d's webgl support is still very experimental at this moment. You are 
welcome to submit issues if you have problem using it.

Original comment by Humu2...@gmail.com on 12 Nov 2013 at 4:44

Attachments:

GoogleCodeExporter commented 8 years ago
Thanks a lot for your support.
I will make many tests and so I will report you if I have any problem with 
webgl.
Great library by the way.

Original comment by laurent....@fabzat.com on 12 Nov 2013 at 5:52