LDraw.org Discussion Forums
PT renders wrong image - Printable Version

+- LDraw.org Discussion Forums (https://forums.ldraw.org)
+-- Forum: Administrative (https://forums.ldraw.org/forum-4.html)
+--- Forum: Website Suggestions/Requests/Discussion (https://forums.ldraw.org/forum-23.html)
+--- Thread: PT renders wrong image (/thread-23114.html)



PT renders wrong image - Steffen - 2018-12-28

can someone please investigate on the server side why the PT shows an all-wrong image for
http://www.ldraw.org/cgi-bin/ptdetail.cgi?f=p/stud-high-contrast.dat
?

The image shown is all-black, whereas the file implementation instead only has black vertical surfaces.
The top surface is color 16


RE: PT renders wrong image - Travis Cobbs - 2018-12-29

(2018-12-28, 5:31)Steffen Wrote: can someone please investigate on the server side why the PT shows an all-wrong image for
http://www.ldraw.org/cgi-bin/ptdetail.cgi?f=p/stud-high-contrast.dat
?

The image shown is all-black, whereas the file implementation instead only has black vertical surfaces.
The top surface is color 16

I suspect that the same bug that caused another part to render wrong is causing this. I will be investigating both problems.


RE: PT renders wrong image - Chris Dee - 2018-12-29

(2018-12-29, 5:50)Travis Cobbs Wrote:
(2018-12-28, 5:31)Steffen Wrote: can someone please investigate on the server side why the PT shows an all-wrong image for
http://www.ldraw.org/cgi-bin/ptdetail.cgi?f=p/stud-high-contrast.dat
?

The image shown is all-black, whereas the file implementation instead only has black vertical surfaces.
The top surface is color 16

I suspect that the same bug that caused another part to render wrong is causing this. I will be investigating both problems.

I think these two files may have the same problem:
http://www.ldraw.org/cgi-bin/ptdetail.cgi?f=p/typestup.dat
http://www.ldraw.org/cgi-bin/ptdetail.cgi?f=p/typestuu.dat


RE: PT renders wrong image - Philippe Hurbain - 2018-12-29

(2018-12-29, 7:28)Chris Dee Wrote:
(2018-12-29, 5:50)Travis Cobbs Wrote: I suspect that the same bug that caused another part to render wrong is causing this. I will be investigating both problems.

I think these two files may have the same problem:
http://www.ldraw.org/cgi-bin/ptdetail.cgi?f=p/typestup.dat
http://www.ldraw.org/cgi-bin/ptdetail.cgi?f=p/typestuu.dat
The problem doesn't look the same, but there is also the strange color of studs on baseplates: http://www.ldraw.org/cgi-bin/ptdetail.cgi?f=parts/10p01.dat


RE: PT renders wrong image - Travis Cobbs - 2018-12-29

(2018-12-28, 5:31)Steffen Wrote: can someone please investigate on the server side why the PT shows an all-wrong image for
http://www.ldraw.org/cgi-bin/ptdetail.cgi?f=p/stud-high-contrast.dat
?

The image shown is all-black, whereas the file implementation instead only has black vertical surfaces.
The top surface is color 16

I tracked down the underlying problem, and fixed the ldview executable on the parts tracker. Unfortunately, this likely affected a lot of parts, so a lot of images will need to be regenerated. I let Chris know about the underlying cause, so hopefully things will be fixed in the not-too-distant future.

For reference, the problem was caused by a bug in the OSMesa library that the command line ldview uses to do its rendering. That bug caused color pushing and popping to not work. I had already found and worked around the bug in the past, but my workaround was disabled in the source code by default, and I didn't have it enabled when I last build the ldview executable being used by the parts tracker. The problem will show up on any parts that have submodels that are anything other than color 16, followed by other submodels that are color 16. ("Submodels" includes both subparts and all primitives.)


RE: PT renders wrong image - Chris Dee - 2018-12-29

(2018-12-29, 8:22)Travis Cobbs Wrote:
(2018-12-28, 5:31)Steffen Wrote: can someone please investigate on the server side why the PT shows an all-wrong image for
http://www.ldraw.org/cgi-bin/ptdetail.cgi?f=p/stud-high-contrast.dat
?

The image shown is all-black, whereas the file implementation instead only has black vertical surfaces.
The top surface is color 16

I tracked down the underlying problem, and fixed the ldview executable on the parts tracker. Unfortunately, this likely affected a lot of parts, so a lot of images will need to be regenerated. I let Chris know about the underlying cause, so hopefully things will be fixed in the not-too-distant future.

For reference, the problem was caused by a bug in the OSMesa library that the command line ldview uses to do its rendering. That bug caused color pushing and popping to not work. I had already found and worked around the bug in the past, but my workaround was disabled in the source code by default, and I didn't have it enabled when I last build the ldview executable being used by the parts tracker. The problem will show up on any parts that have submodels that are anything other than color 16, followed by other submodels that are color 16. ("Submodels" includes both subparts and all primitives.)

All the unofficial library and official library images have been re-generated.


RE: PT renders wrong image - Steffen - 2018-12-29

thank you very much, Travis and Chris, for fixing this.
images look good now.


RE: PT renders wrong image - Travis Cobbs - 2018-12-29

(2018-12-29, 7:46)Philippe Hurbain Wrote:
(2018-12-29, 7:28)Chris Dee Wrote: I think these two files may have the same problem:
http://www.ldraw.org/cgi-bin/ptdetail.cgi?f=p/typestup.dat
http://www.ldraw.org/cgi-bin/ptdetail.cgi?f=p/typestuu.dat
The problem doesn't look the same, but there is also the strange color of studs on baseplates: http://www.ldraw.org/cgi-bin/ptdetail.cgi?f=parts/10p01.dat

This is in fact a different problem. I am still investigating the cause.