forked from bartvdbraak/blender
BGE: removing remaining reference to sce->world->gravity/physics/... (it's all in sce->gm now) + Dome UI changes
UI changes: splitting dome options for different dome modes (eg angle doesn't work for envmap mode) if anyone wants to tweak that, feel free to do it. * I put a remaining to bring setEyeSeparation + Focal Length to the Stereo GUI. I'm still not sure what would be the default parameters for that, and that will require other changes (eg remove the flag m_setfocallength and m_seteyesep). For so far only a label remind :)
This commit is contained in:
parent
7c8c83f30d
commit
77d79ffb5d
@ -176,19 +176,36 @@ class SCENE_PT_game_stereo(SceneButtonsPanel):
|
|||||||
# stereo:
|
# stereo:
|
||||||
if stereo_mode == 'STEREO':
|
if stereo_mode == 'STEREO':
|
||||||
layout.itemR(gs, "stereo_mode")
|
layout.itemR(gs, "stereo_mode")
|
||||||
|
layout.itemL(text="To do: Focal Length")
|
||||||
|
layout.itemL(text="To do: Eye Separation")
|
||||||
|
|
||||||
# dome:
|
# dome:
|
||||||
if stereo_mode == 'DOME':
|
elif stereo_mode == 'DOME':
|
||||||
layout.itemR(gs, "dome_mode", text="Dome Type")
|
layout.itemR(gs, "dome_mode", text="Dome Type")
|
||||||
|
|
||||||
|
dome_type = gs.dome_mode
|
||||||
|
|
||||||
split=layout.split()
|
split=layout.split()
|
||||||
|
|
||||||
col=split.column()
|
if dome_type == 'FISHEYE' or \
|
||||||
col.itemR(gs, "dome_angle", slider=True)
|
dome_type == 'TRUNCATED_REAR' or \
|
||||||
col.itemR(gs, "dome_tesselation", text="Tesselation")
|
dome_type == 'TRUNCATED_FRONT':
|
||||||
|
|
||||||
col=split.column()
|
col=split.column()
|
||||||
|
col.itemR(gs, "dome_angle", slider=True)
|
||||||
col.itemR(gs, "dome_tilt")
|
col.itemR(gs, "dome_tilt")
|
||||||
|
|
||||||
|
col=split.column()
|
||||||
|
col.itemR(gs, "dome_tesselation", text="Tesselation")
|
||||||
|
col.itemR(gs, "dome_buffer_resolution", text="Resolution", slider=True)
|
||||||
|
|
||||||
|
elif dome_type == 'PANORAM_SPH':
|
||||||
|
col=split.column()
|
||||||
|
col.itemR(gs, "dome_tesselation", text="Tesselation")
|
||||||
|
col.itemR(gs, "dome_buffer_resolution", text="Resolution", slider=True)
|
||||||
|
|
||||||
|
else: # cube map
|
||||||
|
col=split.column()
|
||||||
col.itemR(gs, "dome_buffer_resolution", text="Resolution", slider=True)
|
col.itemR(gs, "dome_buffer_resolution", text="Resolution", slider=True)
|
||||||
|
|
||||||
layout.itemR(gs, "dome_text")
|
layout.itemR(gs, "dome_text")
|
||||||
@ -246,30 +263,6 @@ class WORLD_PT_game_world(WorldButtonsPanel):
|
|||||||
row.itemR(world.mist, "start")
|
row.itemR(world.mist, "start")
|
||||||
row.itemR(world.mist, "depth")
|
row.itemR(world.mist, "depth")
|
||||||
|
|
||||||
|
|
||||||
"""
|
|
||||||
class WORLD_PT_game(WorldButtonsPanel):
|
|
||||||
__space_type__ = "LOGIC_EDITOR"
|
|
||||||
__region_type__ = "UI"
|
|
||||||
__label__ = "Game Settings"
|
|
||||||
|
|
||||||
def draw(self, context):
|
|
||||||
layout = self.layout
|
|
||||||
world = context.world
|
|
||||||
|
|
||||||
flow = layout.column_flow()
|
|
||||||
flow.itemR(world, "physics_engine")
|
|
||||||
flow.itemR(world, "physics_gravity")
|
|
||||||
|
|
||||||
flow.itemR(world, "game_fps")
|
|
||||||
flow.itemR(world, "game_logic_step_max")
|
|
||||||
flow.itemR(world, "game_physics_substep")
|
|
||||||
flow.itemR(world, "game_physics_step_max")
|
|
||||||
|
|
||||||
flow.itemR(world, "game_use_occlusion_culling", text="Enable Occlusion Culling")
|
|
||||||
flow.itemR(world, "game_occlusion_culling_resolution")
|
|
||||||
"""
|
|
||||||
|
|
||||||
class WORLD_PT_game_physics(WorldButtonsPanel):
|
class WORLD_PT_game_physics(WorldButtonsPanel):
|
||||||
__label__ = "Physics"
|
__label__ = "Physics"
|
||||||
|
|
||||||
|
@ -260,14 +260,12 @@ void KX_BlenderSceneConverter::ConvertScene(class KX_Scene* destinationscene,
|
|||||||
if (blenderscene)
|
if (blenderscene)
|
||||||
{
|
{
|
||||||
|
|
||||||
if (blenderscene->world)
|
switch (blenderscene->gm.physicsEngine)
|
||||||
{
|
|
||||||
switch (blenderscene->world->physicsEngine)
|
|
||||||
{
|
{
|
||||||
case WOPHY_BULLET:
|
case WOPHY_BULLET:
|
||||||
{
|
{
|
||||||
physics_engine = UseBullet;
|
physics_engine = UseBullet;
|
||||||
useDbvtCulling = (blenderscene->world->mode & WO_DBVT_CULLING) != 0;
|
useDbvtCulling = (blenderscene->gm.mode & WO_DBVT_CULLING) != 0;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -291,8 +289,6 @@ void KX_BlenderSceneConverter::ConvertScene(class KX_Scene* destinationscene,
|
|||||||
physics_engine = UseNone;
|
physics_engine = UseNone;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
switch (physics_engine)
|
switch (physics_engine)
|
||||||
|
Loading…
Reference in New Issue
Block a user