Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How to make the image into a little planet effect #45

Open
heshanghuixitou123 opened this issue Jul 14, 2016 · 1 comment
Open

How to make the image into a little planet effect #45

heshanghuixitou123 opened this issue Jul 14, 2016 · 1 comment

Comments

@heshanghuixitou123
Copy link

hi, please add a function that can make the image into a little planet effect, thanks

@mayakraft
Copy link
Owner

If you want to view the textured sphere from the outside, the first step is to translate the sphere, right now the camera is set to the origin (0,0,0) same as the sphere.

If you add a glTranslatef(x, y, z) let me know if that begins to create the effect.

You want to animate the translation. And if you are dealing with viewing the textured sphere from the outside, do you want to see the inside texture or the outside texture?

glEnable(GL_CULL_FACE);

then

glCullFace(GL_BACK);
or
glCullFace(GL_FRONT_AND_BACK);
or
glCullFace(GL_FRONT);

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants