提交 0f2062b6 编写于 作者: 三月三net's avatar 三月三net

Python超人-宇宙模拟器

上级 29dd3807
...@@ -50,18 +50,19 @@ class LookAtSkyOnEarth(UniverseSimScenes): ...@@ -50,18 +50,19 @@ class LookAtSkyOnEarth(UniverseSimScenes):
clouds_texture = "transparent.png" clouds_texture = "transparent.png"
earth_size_scale = 1 earth_size_scale = 1
else: else:
earth_texture = "earth-huge.jpg" earth_texture = "earth_miller_projection_sw.png" # "earth_miller_projection_SW.jpg"
clouds_texture = "transparent_clouds.png" clouds_texture = "transparent_clouds.png"
earth_size_scale = 5e3 earth_size_scale = 6e3
# 运动的地球 # 运动的地球
self.earth, self.earth_clouds, self.earth_cn = create_earth(earth_texture=earth_texture, self.earth, self.earth_clouds, self.earth_cn = create_earth(earth_texture=earth_texture,
earth_size_scale=earth_size_scale, earth_size_scale=earth_size_scale,
earth_cn_texture=None, earth_cn_texture=None,
clouds_texture=clouds_texture, clouds_texture=None,
with_clouds=True, earth_rotation_speed=16, with_clouds=True, earth_rotation_speed=4,
clouds_rotation_speed=17, clouds_rotation_speed=4,
earth_cn_size_factor=earth_cn_size_factor, earth_cn_size_factor=earth_cn_size_factor,
earth_clouds_size_factor=earth_clouds_size_factor) earth_clouds_size_factor=earth_clouds_size_factor)
self.earth.set_resolution(200)
# # 地球立春的位置和速度 # # 地球立春的位置和速度
# self.earth.init_position = [-9.1507536e+07, 0.0000000e+00, 1.1907757e+08] # self.earth.init_position = [-9.1507536e+07, 0.0000000e+00, 1.1907757e+08]
...@@ -80,7 +81,7 @@ class LookAtSkyOnEarth(UniverseSimScenes): ...@@ -80,7 +81,7 @@ class LookAtSkyOnEarth(UniverseSimScenes):
self.earth.init_velocity = pos_vel["vel"] self.earth.init_velocity = pos_vel["vel"]
self.bodies = [ self.bodies = [
self.sun, self.earth, self.earth_clouds self.sun, self.earth #, self.earth_clouds
] ]
if self.show_china: if self.show_china:
...@@ -93,9 +94,10 @@ class LookAtSkyOnEarth(UniverseSimScenes): ...@@ -93,9 +94,10 @@ class LookAtSkyOnEarth(UniverseSimScenes):
def on_ready(self): def on_ready(self):
self.earth.planet.rotation_y -= 180 # 一开始就正对太阳 self.earth.planet.rotation_y -= 180 # 一开始就正对太阳
self.earth.planet.alpha = 0.9
# self.earth_cn.planet.rotation_y -= 185 # 一开始就正对太阳 # self.earth_cn.planet.rotation_y -= 185 # 一开始就正对太阳
if hasattr(self.earth_clouds, "planet"):
self.earth_clouds.planet.rotation_y -= 50 # 一开始就正对太阳 self.earth_clouds.planet.rotation_y -= 50 # 一开始就正对太阳
if self.show_name: if self.show_name:
font = find_file("fonts/DroidSansFallback.ttf", UrsinaConfig.CN_FONT) font = find_file("fonts/DroidSansFallback.ttf", UrsinaConfig.CN_FONT)
...@@ -158,14 +160,16 @@ class LookAtSkyOnEarth(UniverseSimScenes): ...@@ -158,14 +160,16 @@ class LookAtSkyOnEarth(UniverseSimScenes):
if self.look_point is None: if self.look_point is None:
# 摄像机始终看向移动的地球 # 摄像机始终看向移动的地球
camera_look_at(self.earth, rotation_z=0) camera_look_at(self.earth, rotation_z=0)
# camera.fov = 120 # 默认:60
# camera.parent = self.sun.planet # camera.parent = self.sun.planet
else: else:
camera.parent = self.earth.planet camera.parent = self.earth.planet
camera.rotation_z = 90 camera.rotation_z = 90
camera.fov = 75 # 默认:60
camera.clip_plane_near = 10 camera.clip_plane_near = 10
camera.clip_plane_far = 1000000 camera.clip_plane_far = 1000000
camera.fov = 75 # 默认:60
def delay_app_start(): def delay_app_start():
import time import time
......
...@@ -410,7 +410,7 @@ def create_foreground(foreground_img): ...@@ -410,7 +410,7 @@ def create_foreground(foreground_img):
color=color.white, color=color.white,
origin=(-.48, .48, -.48), origin=(-.48, .48, -.48),
scale=(width*2, height), scale=(width*2, height),
position=(-0.85, -0.33, 0) position=(-0.86, -0.33, 0)
) )
# foreground = Entity(model='quad', scale=(1, 1), texture=foreground_img, eternal=True) # foreground = Entity(model='quad', scale=(1, 1), texture=foreground_img, eternal=True)
......
textures/armazonesdusk_1.png

568.0 KB | W: | H:

textures/armazonesdusk_1.png

565.5 KB | W: | H:

textures/armazonesdusk_1.png
textures/armazonesdusk_1.png
textures/armazonesdusk_1.png
textures/armazonesdusk_1.png
  • 2-up
  • Swipe
  • Onion skin
textures/armazonesdusk_2.png

518.8 KB | W: | H:

textures/armazonesdusk_2.png

509.1 KB | W: | H:

textures/armazonesdusk_2.png
textures/armazonesdusk_2.png
textures/armazonesdusk_2.png
textures/armazonesdusk_2.png
  • 2-up
  • Swipe
  • Onion skin
textures/armazonesdusk_3.png

520.4 KB | W: | H:

textures/armazonesdusk_3.png

516.5 KB | W: | H:

textures/armazonesdusk_3.png
textures/armazonesdusk_3.png
textures/armazonesdusk_3.png
textures/armazonesdusk_3.png
  • 2-up
  • Swipe
  • Onion skin
textures/armazonesdusk_4.png

468.2 KB | W: | H:

textures/armazonesdusk_4.png

461.6 KB | W: | H:

textures/armazonesdusk_4.png
textures/armazonesdusk_4.png
textures/armazonesdusk_4.png
textures/armazonesdusk_4.png
  • 2-up
  • Swipe
  • Onion skin
textures/earth_miller_projection_SW.jpg

830.8 KB | W: | H:

textures/earth_miller_projection_SW.jpg

829.4 KB | W: | H:

textures/earth_miller_projection_SW.jpg
textures/earth_miller_projection_SW.jpg
textures/earth_miller_projection_SW.jpg
textures/earth_miller_projection_SW.jpg
  • 2-up
  • Swipe
  • Onion skin
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册