4
$\begingroup$

I get the output that I need from

r = 100000000000;
ParametricPlot3D[r {Cos[ϕ]*Sin[θ], Sin[ϕ]*Sin[θ], Cos[θ]}, {ϕ, 0, 2 π}, {θ, 0, π}, 
  ColorFunction -> Function[{x, y, z}, Glow[GrayLevel[z]]],
  Lighting -> None, Axes -> False, Mesh -> None]

However if r = 1, then the sphere goes black.
Why does it do that, and how to get the correct color despite r = 1?

Output in V11.3 on windows with Intel(R) HD Graphics 5500: enter image description here I think it's a bug now, I tried V11.2 and it worked.

$\endgroup$
6
  • $\begingroup$ Hm, looks normal on my computer. What about values of r in between? $\endgroup$ Jul 18, 2018 at 14:13
  • $\begingroup$ @GregoryRut Fewer zeros than r = 10000000000; makes it black. Do you use V11.3 on windows? $\endgroup$
    – MeMyselfI
    Jul 18, 2018 at 14:18
  • $\begingroup$ 11.1.1 on Ubuntu. Have you tried to reset your kernel? Seems like there is a hidden constant that might affect your result. $\endgroup$ Jul 18, 2018 at 14:20
  • $\begingroup$ @GregoryRut Yes it's restarted, but now I tried also V11.2 and got the correct output $\endgroup$
    – MeMyselfI
    Jul 18, 2018 at 14:25
  • 2
    $\begingroup$ Same black sphere on OSX with 11.3 $\endgroup$
    – halirutan
    Jul 18, 2018 at 14:27

1 Answer 1

4
$\begingroup$

On MacOS 10.13.6 and Mathematica 11.3, I also observed this issue. I was able to fix it by going to the advanced options (Preferences), and setting

"3DRenderingMethod" $\rightarrow$ "BSPTree"

You can find this option by entering it in the search field.

I do think this should be tagged as a bug.

See also Weird behaviour of multiple transparent Raster3D objects in one Graphics3D

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.