UFO: Alien Invasion Issue Tracker
UFO: Alien Invasion
Go to the previous open issue
Go to the previous issue (open or closed)
star_faded.png
Please log in to bookmark issues
icon_project.png UFO: Alien Invasion / Closed Bug report #1952 moon can pass through earth
Go to the next issue (open or closed)
Go to the next open issue
This issue has been closed with status "Closed" and resolution "Not determined".
Issue basics
  • Type of issue
    Bug report
  • Category
    Campaign
  • Targetted for
    Not determined
  • Status
    Closed
  • Priority
    1. Very low
User pain
  • Type of bug
    Not triaged
  • Likelihood
    Not triaged
  • Effect
    Not triaged
Affected by this issue (0)
There are no items
People involved
Times and dates
  • Posted at
  • Last updated
  • Estimated time
    Not estimated
Issue details
  • Resolution
    Not determined
  • Reproducability
    Not determined
  • Severity
    Not determined
  • Complexity
    Not determined
  • Platform
    Not determined
  • Architecture
    Not determined
Attachments (0)
There is nothing attached to this issue
Duplicate issues (0)
This issue does not have any duplicates
Description
[http://sourceforge.net/p/ufoai/bugs/1952 Item 1952] imported from sourceforge.net tracker on 2013-01-28 19:14:56

in trunk, r21139.

Open a new game, rotate earth until the moon is behind earth. zoom on earth, the moon pass through earth.

I think this is due to this line (in r_state.c):
glOrtho(0, viddef.width, viddef.height, 0, 9999.0f, SKYBOX_DEPTH);

that should be "glOrtho(0, viddef.width, viddef.height, 0, SKYBOX_DEPTH, 9999.0f);"

I already started to fix that, but reverted it because it changes the sign of all depth value in 2D mode (eg all models in base are flipped). This is something I plan to do later (after 2.3, we really have more important stuff to do now): I need to check that, and all model modifications angles in .ufo script is going to take time. I just use this bug tracker as a reminder ;)
I reverted this fix in r21054. Log was:
"* reverted glOrtho() fix I made in r20990, in order to have model drawn in the good direction
* I still think this is not the proper way to render the scene (see: http://www.opengl.org/sdk/docs/man/xhtml/glOrtho.xml -- for us the values behind the viewer are the positive values)
* (that makes the bug 'moon can pass through earth if you zoom on earth when moon is behind' reappear)"

Note that when we call glOrtho() in MYgluPerspective(), the fourth paramter is smaller than fifth as I would expect (see web link above) expected.

The thing I don't understand is that in r21053, the models on the geoscape are invisible on my eeePC (debian Lenny), whereas I can see them on my other computer (debien Etch). Mattn told me he could see the models too. Further testing needed.

This problem will probably need to be fixed before I start improving the drawing on model on geoscape (that is: us z depth not only for sphere but also for models and make models rotate instead of the hack I made and that is currently in trunk)
Please add any comment if you can enlight me on that subject ;)
===== Comments Ported from Sourceforge =====

====== bayo-fr (2009-07-15 19:36:28) ======

I fix it in r25183

I remove the depth test and sort the rendering from sun, moon, earth atmospher (semi transparent), and earth. Then it should be slower than the last code.

Maybe we also can activate the depth test rendering the earth, then the sun, the moon and the earth atmospher, it should be faster. But it is not easy to me to change the opengl code.
Steps to reproduce this issue
Nothing entered.
Todos (0 / 0)
Issue created
footer_logo.png The Bug Genie 4.3.1 | Support | Feedback spinning_16.gif