WebGL renderer


Re: WebGL renderer
#23
Steffen Wrote:the improvements which I spontaneously like to collect here, jumping to my eye or mind, are

(a) rotation center:
The center of rotation currently seems to be hardcoded 0/0/0.
I would better like to have it at the model's center, like in LDView.
Using the mouse currently in your web app feels so different than LDView,
that it confuses me. I would love to see a big similarity in mouse handling between the 2 tools.

Yes that's hardcoded now. I don't know if ldview calculates the center automatically or uses some metadata in the file. i have to make some tests.
About the mouse, i just thrown in a working system, it surely can be improved, and it needs zooming with the wheel Smile

Steffen Wrote:(b) incremental parts display:
perhaps it is very easy to do, and you could show the model already while it is loading.
the user can watch the downloaded parts appear in the model.
I think it could be quite cheap to do, because you already know all the matrices etc, just the "real" part data is missing.
Thus, you could already build up the necessary data structures, and skip them on rendering, while the model is not fully loaded.
I think this would be an evern more "incremental" load than displaying the progress status message Big Grin

Yeah i considered it too.. Seeing the model progressively being built would be awesome. It might not be very hard but needs some modifications on the program.

Steffen Wrote:(d) default color 16:
Nicola, you seem to currently use 0/0/0 always for default color 16.
I would prefer if you would use the color specified explicitly in LDConfig.ldr (some "medium" default grey).
To you already use that file? You can always get the most recent version also from the ldraw.org site.

I've yet to understand completely how color works, but i got that 16 is actually the "current color", and i correcly substitute it with what "parent lines" says, it's not hardcoded to 0. What i miss is the whole "complementary" colors and code 24.

Steffen Wrote:(e) edges:
you currently are not rendering edges at all.
I would like to have a checkbox or button for toggling that on and off.
It should be nearly trivial to add the drawing of them to your existing implementation.

Normal edges would be trivial, conditional edges will be not Smile They're one of the most puzzling quirks of LDraw file model. Basically you cannot just send them to OpenGL as a bunch of vectors, you have to manually test one by one and decide if you should draw them with a quite complex algorithm. It looks like some kind of hardcoded, precalculated "toon shading" like algorithm?
What i'd like to do is to use them to see if faces should be smooth or flat (basically what they tell is if the two faces should be "curved" or separated) so that i can render curved part nicely, but that require some work.

Steffen Wrote:Nicola, I am again falling of my chair, impressed.
I just tested the attached file, which uses an LSYNTH synthesized cable,
plus unofficial parts, it loaded quickly and smooth, and looked beautiful!

That's not my merit, LSynth generates standard faces, i didn't do anything special for it Smile

Steffen Wrote:
Code:
var flip = geometry._inverting ^ (det<0.0) ^ (!ccw); // kungfu

hahahaha, liked that

Lol, that code required quite a lot of trial and error Smile Another quirk of LDraw is how it mixes CCW and CW faces and how it "inverts" subparts Smile
Reply
« Next Oldest | Next Newest »



Messages In This Thread
WebGL renderer - by Nicola - 2012-11-16, 14:58
Re: WebGL renderer - by Michael Heidemann - 2012-11-16, 21:08
Re: WebGL renderer - by Michael Heidemann - 2012-11-25, 16:00
Re: WebGL renderer - by Nicola - 2012-11-26, 9:15
Re: WebGL renderer - by Travis Cobbs - 2012-11-26, 20:31
Re: WebGL renderer - by Michael Heidemann - 2013-01-01, 8:03
Re: WebGL renderer - by Nicola - 2013-01-15, 16:29
Re: WebGL renderer - by Nicola - 2013-01-15, 20:25
Re: WebGL renderer - by Roland Melkert - 2013-01-15, 22:16
Re: WebGL renderer - by Nicola - 2013-01-16, 8:31
Re: WebGL renderer - by Michael Heidemann - 2013-01-16, 15:57
Re: WebGL renderer - by Nicola - 2013-01-16, 16:37
Re: WebGL renderer - by Philippe Hurbain - 2012-11-16, 21:51
Re: WebGL renderer - by Tim Gould - 2012-11-16, 22:12
Re: WebGL renderer - by Steffen - 2012-11-17, 0:57
Re: WebGL renderer - by Nicola - 2012-11-17, 16:23
Re: WebGL renderer - by Steffen - 2012-11-17, 23:28
Re: WebGL renderer - by Tim Gould - 2012-11-17, 23:57
Re: WebGL renderer - by Nicola - 2012-11-18, 13:05
Re: WebGL renderer - by Travis Cobbs - 2012-11-18, 2:17
Re: WebGL renderer - by Nicola - 2012-11-18, 13:15
Re: WebGL renderer - by Steffen - 2012-11-18, 14:14
Re: WebGL renderer - by Tim Gould - 2012-11-18, 20:58
Re: WebGL renderer - by Nicola - 2012-11-21, 19:23
Re: WebGL renderer - by Willy Tschager - 2012-11-21, 21:49
Re: WebGL renderer - by Philippe Hurbain - 2012-11-22, 5:51
Re: WebGL renderer - by Nicola - 2012-11-22, 8:47
Re: WebGL renderer - by Philippe Hurbain - 2012-11-22, 9:09
Re: WebGL renderer - by Willy Tschager - 2012-11-22, 9:45
Re: WebGL renderer - by Philippe Hurbain - 2012-11-22, 10:01
Re: WebGL renderer - by Nicola - 2012-11-22, 10:26
Re: WebGL renderer - by Philippe Hurbain - 2012-11-22, 10:55
Re: WebGL renderer - by Philippe Hurbain - 2012-11-22, 9:05
Re: WebGL renderer - by Steffen - 2012-11-21, 23:41
Re: WebGL renderer - by Steffen - 2012-11-21, 23:52
Re: WebGL renderer - by Nicola - 2012-11-22, 9:02
Re: WebGL renderer - by Philippe Hurbain - 2012-11-22, 9:21
Re: WebGL renderer - by Steffen - 2012-11-22, 20:29
Re: WebGL renderer - by Nicola - 2012-11-23, 10:44
Re: WebGL renderer - by Philippe Hurbain - 2012-11-23, 12:18
Re: WebGL renderer - by Steffen - 2012-11-23, 19:07
Re: WebGL renderer - by Steffen - 2012-11-23, 18:57
Re: WebGL renderer - by Steffen - 2012-11-22, 0:02
Re: WebGL renderer - by Steffen - 2012-11-22, 0:13
Re: WebGL renderer - by Ken Drew - 2012-11-22, 1:25
Re: WebGL renderer - by Willy Tschager - 2012-11-22, 16:05
Re: WebGL renderer - by Nicola - 2012-11-22, 18:45
Re: WebGL renderer - by Steffen - 2012-11-22, 20:34
Re: WebGL renderer - by Willy Tschager - 2014-11-13, 11:51
Re: WebGL renderer - by Steffen - 2014-11-14, 22:53
Re: WebGL renderer - by Nicola - 2012-11-28, 22:22
Re: WebGL renderer - by Philippe Hurbain - 2012-11-29, 8:19
Re: WebGL renderer - by Travis Cobbs - 2012-11-29, 23:42
Re: WebGL renderer - by Nicola - 2012-12-14, 11:05
Re: WebGL renderer - by Philippe Hurbain - 2012-12-14, 12:29
Re: WebGL renderer - by Nicola - 2012-12-14, 13:06
Re: WebGL renderer - by Philippe Hurbain - 2012-12-14, 13:11
Re: WebGL renderer - by Steffen - 2012-12-15, 22:44
Also trying LDraw in WebGL - by Daniel B - 2012-12-28, 13:10
Re: Also trying LDraw in WebGL - by Daniel B - 2012-12-28, 21:23
Re: Also trying LDraw in WebGL - by Nicola - 2013-01-15, 16:31
Re: WebGL renderer - by Michael Horvath - 2012-12-31, 17:28
Re: WebGL renderer - by Nicola - 2013-01-15, 16:34
Re: WebGL renderer - by Michael Heidemann - 2013-01-15, 16:38
Re: WebGL renderer - by Michael Horvath - 2013-01-25, 22:46
Re: WebGL renderer - by Nicola - 2013-01-28, 12:49
Re: WebGL renderer - by Roland Melkert - 2013-01-28, 21:56
Re: WebGL renderer - by Michael Horvath - 2014-11-30, 1:19
Re: WebGL renderer - by Michael Heidemann - 2013-01-28, 22:19
Re: WebGL renderer - by Steffen - 2013-01-28, 22:37
Re: WebGL renderer - by Travis Cobbs - 2013-01-28, 22:45
Re: WebGL renderer - by Rolf Osterthun - 2013-08-21, 14:52
Re: WebGL renderer - by Nicola - 2013-08-21, 15:01
Re: WebGL renderer - by Willy Tschager - 2013-08-30, 14:39
Re: WebGL renderer - by Nicola - 2013-08-30, 14:57
Re: WebGL renderer - by Rolf Osterthun - 2013-09-12, 17:23
Re: WebGL renderer - by Orion Pobursky - 2013-09-12, 18:38
Re: WebGL renderer - by Steffen - 2013-09-14, 1:19
Re: WebGL renderer - by Nathanel Titane - 2014-12-06, 22:20
Re: WebGL renderer - by Steffen - 2013-08-30, 17:29
Re: WebGL renderer - by Orion Pobursky - 2013-09-18, 23:09
Re: WebGL renderer - by Rolf Osterthun - 2013-09-19, 8:30
Re: WebGL renderer - by Orion Pobursky - 2013-09-19, 20:40
Re: WebGL renderer - by Orion Pobursky - 2013-09-19, 21:00
Re: WebGL renderer - by Orion Pobursky - 2013-09-19, 21:49
Re: WebGL renderer - by Orion Pobursky - 2013-09-19, 23:15
Re: WebGL renderer - by Nicola - 2013-11-19, 13:39
Re: WebGL renderer - by Steffen - 2013-11-21, 0:54
Re: WebGL renderer - by Orion Pobursky - 2013-11-21, 1:56
Re: WebGL renderer - by Steffen - 2013-11-23, 2:44
Re: WebGL renderer - by Lucas GIRARD - 2014-03-08, 16:34
Re: WebGL renderer - by Nathanel Titane - 2014-12-06, 7:10
Re: WebGL renderer - by Rolf Osterthun - 2014-12-06, 20:28
Re: WebGL renderer - by Nathanel Titane - 2014-12-06, 21:51
Re: WebGL renderer - by Nathanel Titane - 2014-12-06, 23:05
Re: WebGL renderer - by Nicola - 2014-12-15, 11:59
Re: WebGL renderer - by Nathanel Titane - 2014-12-06, 23:05
Re: WebGL renderer - by Nathanel Titane - 2014-12-07, 6:26
Re: WebGL renderer - by Hazen Babcock - 2016-02-23, 2:19
Re: WebGL renderer - by Nicola - 2016-02-23, 8:45
Re: WebGL renderer - by Hazen Babcock - 2016-02-24, 2:34
Re: WebGL renderer - by Merlijn Wissink - 2016-02-28, 9:31
Re: WebGL renderer - by Hazen Babcock - 2016-03-05, 23:15
Re: WebGL renderer - by Merlijn Wissink - 2016-03-06, 9:29
Re: WebGL renderer - by Hazen Babcock - 2016-03-06, 13:45
Re: WebGL renderer - by Merlijn Wissink - 2016-03-06, 18:20
Re: WebGL renderer - by Hazen Babcock - 2016-03-06, 21:01
Re: WebGL renderer - by Merlijn Wissink - 2016-03-06, 18:33
Re: WebGL renderer - by Orion Pobursky - 2016-03-06, 21:29
Re: WebGL renderer - by Merlijn Wissink - 2016-03-07, 7:45
Re: WebGL renderer - by Rolf Osterthun - 2016-03-07, 10:39
Re: WebGL renderer - by Orion Pobursky - 2016-03-08, 3:31
Re: WebGL renderer - by Jaco van der Molen - 2016-03-07, 14:53
RE: WebGL renderer - by Hazen Babcock - 2016-04-12, 1:04
RE: WebGL renderer - by Michael Horvath - 2016-07-28, 10:20
RE: WebGL renderer - by Merlijn Wissink - 2016-07-31, 8:23
RE: WebGL renderer - by Michael Horvath - 2016-08-20, 4:55
RE: WebGL renderer - by Merlijn Wissink - 2016-08-21, 8:23
RE: WebGL renderer - by Michael Horvath - 2016-08-21, 13:00
RE: WebGL renderer - by Michael Horvath - 2016-08-21, 20:05
RE: WebGL renderer - by Michael Horvath - 2016-08-22, 14:40
RE: WebGL renderer - by Hazen Babcock - 2018-02-19, 22:59
RE: WebGL renderer - by Orion Pobursky - 2018-02-20, 1:36
RE: WebGL renderer - by Hazen Babcock - 2018-02-20, 2:02
RE: WebGL renderer - by Jaco van der Molen - 2018-02-20, 12:01
RE: WebGL renderer - by Hazen Babcock - 2018-02-20, 12:34
RE: WebGL renderer - by Jaco van der Molen - 2018-02-20, 14:22
RE: WebGL renderer - by Hazen Babcock - 2018-02-21, 1:30
RE: WebGL renderer - by Michael Horvath - 2018-08-20, 5:03
RE: WebGL renderer - by Michael Horvath - 2019-06-28, 6:57
RE: WebGL renderer - by Magnus Forsberg - 2019-06-28, 15:32
RE: WebGL renderer - by Michael Horvath - 2019-06-28, 19:01
RE: WebGL renderer - by Michael Horvath - 2019-06-29, 22:38
RE: WebGL renderer - by Orion Pobursky - 2019-06-28, 15:41
RE: WebGL renderer - by Michael Horvath - 2019-06-28, 18:52
RE: WebGL renderer - by Orion Pobursky - 2019-06-28, 19:02
RE: WebGL renderer - by Hazen Babcock - 2019-06-29, 16:00
RE: WebGL renderer - by Orion Pobursky - 2019-06-29, 16:17
RE: WebGL renderer - by Hazen Babcock - 2019-06-29, 16:23
RE: WebGL renderer - by Hazen Babcock - 2019-07-02, 18:06
RE: WebGL renderer - by Michael Horvath - 2019-06-28, 18:53
RE: WebGL renderer - by Lasse Deleuran - 2019-06-29, 16:36
RE: WebGL renderer - by Michael Horvath - 2019-06-30, 7:06
RE: WebGL renderer - by Michael Horvath - 2019-07-07, 6:51
RE: WebGL renderer - by Lasse Deleuran - 2019-07-07, 12:18
RE: WebGL renderer - by Michael Horvath - 2019-07-10, 22:28
RE: WebGL renderer - by Lasse Deleuran - 2019-07-11, 7:31
RE: WebGL renderer - by caesar - 2019-07-18, 15:02
RE: WebGL renderer - by Lasse Deleuran - 2019-07-18, 17:49
RE: WebGL renderer - by caesar - 2019-07-18, 18:35

Forum Jump:


Users browsing this thread: 21 Guest(s)