Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
Python_超人
宇宙模拟器
提交
f9fdbea7
宇宙模拟器
项目概览
Python_超人
/
宇宙模拟器
通知
19
Star
2
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
DevOps
流水线
流水线任务
计划
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
宇宙模拟器
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
DevOps
DevOps
流水线
流水线任务
计划
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
流水线任务
提交
Issue看板
提交
f9fdbea7
编写于
7月 04, 2023
作者:
三月三net
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
Python超人-宇宙模拟器
上级
3afaee81
变更
3
显示空白变更内容
内联
并排
Showing
3 changed file
with
5 addition
and
1 deletion
+5
-1
sim_scenes/func.py
sim_scenes/func.py
+1
-1
sim_scenes/science/speed_of_light_3d.py
sim_scenes/science/speed_of_light_3d.py
+1
-0
tools/sim_video_3d_cap_ext.py
tools/sim_video_3d_cap_ext.py
+3
-0
未找到文件。
sim_scenes/func.py
浏览文件 @
f9fdbea7
...
...
@@ -290,7 +290,7 @@ def create_light_ship(size_scale, init_position, speed=LIGHT_SPEED):
from
objs.space_ship
import
SpaceShip
return
SpaceShip
(
name
=
'光速飞船'
,
mass
=
0
,
size_scale
=
size_scale
,
color
=
(
255
,
110
,
0
),
init_position
=
init_position
,
init_velocity
=
[
0
,
0
,
speed
]).
set_light_disable
(
Tru
e
)
init_velocity
=
[
0
,
0
,
speed
]).
set_light_disable
(
Fals
e
)
def
create_3d_card
(
left
=-
.
885
,
top
=
0.495
,
width
=
0.02
,
height
=
0.02
):
...
...
sim_scenes/science/speed_of_light_3d.py
浏览文件 @
f9fdbea7
...
...
@@ -54,6 +54,7 @@ elif camera_pos == "left": # 摄像机左眼
init
.
light_init_position
[
0
]
=
5000000
init
.
light_init_position
[
1
]
=
1500000
# init.auto_control_speed = True
init
.
camera_position
=
(
0
,
-
AU
/
100
,
-
AU
/
50
)
# 从 init 对象中获取 光体的大小(light_size_scale),光体的位置(light_init_position)
# 创建一个以光速前进的天体(模拟一个光子) speed=1光速=299792.458千米/秒,注意:质量为0才能达到光速,虽然如此,但也可以试试超光速
...
...
tools/sim_video_3d_cap_ext.py
浏览文件 @
f9fdbea7
...
...
@@ -241,11 +241,14 @@ def make_3d_video():
_3d_card
=
img
[
4
:
20
,
3
:
20
,
]
_3d_card_p
=
_3d_card
[
10
,
10
,]
index
=
int
(
_3d_card_p
[
1
])
+
int
(
_3d_card_p
[
0
])
if
index
<
last_index
:
index_base
+=
(
last_index
+
1
)
create_frame_temp_files
(
index
+
index_base
,
l_frames
,
r_frames
)
r_frames
.
clear
()
l_frames
.
clear
()
r_frames
=
{}
l_frames
=
{}
last_index
=
index
index
=
index
+
index_base
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录