Beta1 Attempt #1
-=-==-=-=-=-=-=- -Small fixes in canvas item light shader -Fixed compilation in server target -Export for Android makes 32 bits display as default -changed version to 1.1beta1
This commit is contained in:
parent
1572238adb
commit
68e42f53ba
@ -235,7 +235,7 @@ FRAGMENT_SHADER_CODE
|
|||||||
#if defined(USE_LIGHT_SHADER_CODE)
|
#if defined(USE_LIGHT_SHADER_CODE)
|
||||||
//light is written by the light shader
|
//light is written by the light shader
|
||||||
{
|
{
|
||||||
vec4 light_out=vec4(0.0,0.0,0.0,0.0);
|
vec4 light_out=light*color;
|
||||||
LIGHT_SHADER_CODE
|
LIGHT_SHADER_CODE
|
||||||
color=light_out;
|
color=light_out;
|
||||||
}
|
}
|
||||||
|
@ -1546,7 +1546,7 @@ EditorExportPlatformAndroid::EditorExportPlatformAndroid() {
|
|||||||
quit_request=false;
|
quit_request=false;
|
||||||
orientation=0;
|
orientation=0;
|
||||||
remove_prev=true;
|
remove_prev=true;
|
||||||
use_32_fb=false;
|
use_32_fb=true;
|
||||||
|
|
||||||
device_thread=Thread::create(_device_poll_thread,this);
|
device_thread=Thread::create(_device_poll_thread,this);
|
||||||
devices_changed=true;
|
devices_changed=true;
|
||||||
|
@ -57,7 +57,6 @@ void OS_Server::initialize(const VideoMode& p_desired,int p_video_driver,int p_a
|
|||||||
current_videomode=p_desired;
|
current_videomode=p_desired;
|
||||||
main_loop=NULL;
|
main_loop=NULL;
|
||||||
|
|
||||||
|
|
||||||
rasterizer = memnew( RasterizerDummy );
|
rasterizer = memnew( RasterizerDummy );
|
||||||
|
|
||||||
visual_server = memnew( VisualServerRaster(rasterizer) );
|
visual_server = memnew( VisualServerRaster(rasterizer) );
|
||||||
@ -163,6 +162,12 @@ OS::VideoMode OS_Server::get_video_mode(int p_screen) const {
|
|||||||
|
|
||||||
return current_videomode;
|
return current_videomode;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Size2 OS_Server::get_window_size() const {
|
||||||
|
|
||||||
|
return Vector2(current_videomode.width,current_videomode.height) ;
|
||||||
|
}
|
||||||
|
|
||||||
void OS_Server::get_fullscreen_mode_list(List<VideoMode> *p_list,int p_screen) const {
|
void OS_Server::get_fullscreen_mode_list(List<VideoMode> *p_list,int p_screen) const {
|
||||||
|
|
||||||
|
|
||||||
|
@ -109,6 +109,8 @@ public:
|
|||||||
virtual VideoMode get_video_mode(int p_screen=0) const;
|
virtual VideoMode get_video_mode(int p_screen=0) const;
|
||||||
virtual void get_fullscreen_mode_list(List<VideoMode> *p_list,int p_screen=0) const;
|
virtual void get_fullscreen_mode_list(List<VideoMode> *p_list,int p_screen=0) const;
|
||||||
|
|
||||||
|
virtual Size2 get_window_size() const;
|
||||||
|
|
||||||
virtual void move_window_to_foreground();
|
virtual void move_window_to_foreground();
|
||||||
|
|
||||||
void run();
|
void run();
|
||||||
|
@ -1351,15 +1351,24 @@ const ShaderGraph::InOutParamInfo ShaderGraph::inout_param_info[]={
|
|||||||
{MODE_CANVAS_ITEM,SHADER_TYPE_FRAGMENT,"Normal","NORMAL","",SLOT_TYPE_VEC,SLOT_OUT},
|
{MODE_CANVAS_ITEM,SHADER_TYPE_FRAGMENT,"Normal","NORMAL","",SLOT_TYPE_VEC,SLOT_OUT},
|
||||||
//canvas item light in
|
//canvas item light in
|
||||||
{MODE_CANVAS_ITEM,SHADER_TYPE_LIGHT,"Color","COLOR.rgb","",SLOT_TYPE_VEC,SLOT_IN},
|
{MODE_CANVAS_ITEM,SHADER_TYPE_LIGHT,"Color","COLOR.rgb","",SLOT_TYPE_VEC,SLOT_IN},
|
||||||
|
{MODE_CANVAS_ITEM,SHADER_TYPE_LIGHT,"Alpha","COLOR.a","",SLOT_TYPE_SCALAR,SLOT_IN},
|
||||||
{MODE_CANVAS_ITEM,SHADER_TYPE_LIGHT,"Normal","NORMAL","",SLOT_TYPE_VEC,SLOT_IN},
|
{MODE_CANVAS_ITEM,SHADER_TYPE_LIGHT,"Normal","NORMAL","",SLOT_TYPE_VEC,SLOT_IN},
|
||||||
{MODE_CANVAS_ITEM,SHADER_TYPE_LIGHT,"LightDist","LIGHT_DISTANCE","",SLOT_TYPE_SCALAR,SLOT_IN},
|
{MODE_CANVAS_ITEM,SHADER_TYPE_LIGHT,"UV","vec3(UV,0)","",SLOT_TYPE_VEC,SLOT_IN},
|
||||||
{MODE_CANVAS_ITEM,SHADER_TYPE_LIGHT,"LightDir","vec3(LIGHT_DIR,0)","",SLOT_TYPE_VEC,SLOT_IN},
|
{MODE_CANVAS_ITEM,SHADER_TYPE_LIGHT,"LightColor","LIGHT_COLOR.rgb","",SLOT_TYPE_VEC,SLOT_IN},
|
||||||
|
{MODE_CANVAS_ITEM,SHADER_TYPE_LIGHT,"LightAlpha","LIGHT_COLOR.a","",SLOT_TYPE_SCALAR,SLOT_IN},
|
||||||
|
{MODE_CANVAS_ITEM,SHADER_TYPE_LIGHT,"LightHeight","LIGHT_HEIGHT","",SLOT_TYPE_SCALAR,SLOT_IN},
|
||||||
|
{MODE_CANVAS_ITEM,SHADER_TYPE_LIGHT,"TexPixelSize","vec3(TEXTURE_PIXEL_SIZE,0)","",SLOT_TYPE_VEC,SLOT_IN},
|
||||||
|
{MODE_CANVAS_ITEM,SHADER_TYPE_LIGHT,"Var1","VAR1.rgb","",SLOT_TYPE_VEC,SLOT_IN},
|
||||||
|
{MODE_CANVAS_ITEM,SHADER_TYPE_LIGHT,"Var2","VAR2.rgb","",SLOT_TYPE_VEC,SLOT_IN},
|
||||||
{MODE_CANVAS_ITEM,SHADER_TYPE_LIGHT,"PointCoord","POINT_COORD","",SLOT_TYPE_VEC,SLOT_IN},
|
{MODE_CANVAS_ITEM,SHADER_TYPE_LIGHT,"PointCoord","POINT_COORD","",SLOT_TYPE_VEC,SLOT_IN},
|
||||||
//canvas item light out
|
//canvas item light out
|
||||||
{MODE_CANVAS_ITEM,SHADER_TYPE_LIGHT,"Light","LIGHT","",SLOT_TYPE_VEC,SLOT_OUT},
|
{MODE_CANVAS_ITEM,SHADER_TYPE_LIGHT,"LightColor","LIGHT.rgb","",SLOT_TYPE_VEC,SLOT_OUT},
|
||||||
|
{MODE_CANVAS_ITEM,SHADER_TYPE_LIGHT,"LightAlpha","LIGHT.a","",SLOT_TYPE_SCALAR,SLOT_OUT},
|
||||||
//end
|
//end
|
||||||
{MODE_MATERIAL,SHADER_TYPE_FRAGMENT,NULL,NULL,NULL,SLOT_TYPE_SCALAR,SLOT_OUT},
|
{MODE_MATERIAL,SHADER_TYPE_FRAGMENT,NULL,NULL,NULL,SLOT_TYPE_SCALAR,SLOT_OUT},
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
void ShaderGraph::get_input_output_node_slot_info(Mode p_mode, ShaderType p_type, List<SlotInfo> *r_slots) {
|
void ShaderGraph::get_input_output_node_slot_info(Mode p_mode, ShaderType p_type, List<SlotInfo> *r_slots) {
|
||||||
|
@ -1543,11 +1543,38 @@ void RasterizerDummy::end_shadow_map() {
|
|||||||
void RasterizerDummy::end_frame() {
|
void RasterizerDummy::end_frame() {
|
||||||
|
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
RID RasterizerDummy::canvas_light_occluder_create() {
|
||||||
|
return RID();
|
||||||
|
}
|
||||||
|
|
||||||
|
void RasterizerDummy::canvas_light_occluder_set_polylines(RID p_occluder, const DVector<Vector2>& p_lines) {
|
||||||
|
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
RID RasterizerDummy::canvas_light_shadow_buffer_create(int p_width) {
|
||||||
|
|
||||||
|
return RID();
|
||||||
|
}
|
||||||
|
|
||||||
|
void RasterizerDummy::canvas_light_shadow_buffer_update(RID p_buffer, const Matrix32& p_light_xform, int p_light_mask,float p_near, float p_far, CanvasLightOccluderInstance* p_occluders, CameraMatrix *p_xform_cache) {
|
||||||
|
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
void RasterizerDummy::canvas_debug_viewport_shadows(CanvasLight* p_lights_with_shadow) {
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/* CANVAS API */
|
/* CANVAS API */
|
||||||
|
|
||||||
|
|
||||||
|
void RasterizerDummy::begin_canvas_bg() {
|
||||||
|
|
||||||
|
}
|
||||||
void RasterizerDummy::canvas_begin() {
|
void RasterizerDummy::canvas_begin() {
|
||||||
|
|
||||||
|
|
||||||
@ -1761,6 +1788,11 @@ bool RasterizerDummy::is_environment(const RID& p_rid) const {
|
|||||||
return environment_owner.owns(p_rid);
|
return environment_owner.owns(p_rid);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
bool RasterizerDummy::is_canvas_light_occluder(const RID& p_rid) const {
|
||||||
|
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
bool RasterizerDummy::is_shader(const RID& p_rid) const {
|
bool RasterizerDummy::is_shader(const RID& p_rid) const {
|
||||||
|
|
||||||
return false;
|
return false;
|
||||||
|
@ -696,6 +696,7 @@ public:
|
|||||||
|
|
||||||
/* CANVAS API */
|
/* CANVAS API */
|
||||||
|
|
||||||
|
virtual void begin_canvas_bg();
|
||||||
virtual void canvas_begin();
|
virtual void canvas_begin();
|
||||||
virtual void canvas_disable_blending();
|
virtual void canvas_disable_blending();
|
||||||
virtual void canvas_set_opacity(float p_opacity);
|
virtual void canvas_set_opacity(float p_opacity);
|
||||||
@ -712,6 +713,14 @@ public:
|
|||||||
|
|
||||||
virtual void canvas_render_items(CanvasItem *p_item_list,int p_z,const Color& p_modulate,CanvasLight *p_light);
|
virtual void canvas_render_items(CanvasItem *p_item_list,int p_z,const Color& p_modulate,CanvasLight *p_light);
|
||||||
|
|
||||||
|
virtual RID canvas_light_occluder_create();
|
||||||
|
virtual void canvas_light_occluder_set_polylines(RID p_occluder, const DVector<Vector2>& p_lines);
|
||||||
|
|
||||||
|
virtual RID canvas_light_shadow_buffer_create(int p_width);
|
||||||
|
virtual void canvas_light_shadow_buffer_update(RID p_buffer, const Matrix32& p_light_xform, int p_light_mask,float p_near, float p_far, CanvasLightOccluderInstance* p_occluders, CameraMatrix *p_xform_cache);
|
||||||
|
|
||||||
|
virtual void canvas_debug_viewport_shadows(CanvasLight* p_lights_with_shadow);
|
||||||
|
|
||||||
/* ENVIRONMENT */
|
/* ENVIRONMENT */
|
||||||
|
|
||||||
virtual RID environment_create();
|
virtual RID environment_create();
|
||||||
@ -747,6 +756,7 @@ public:
|
|||||||
virtual bool is_particles_instance(const RID& p_rid) const;
|
virtual bool is_particles_instance(const RID& p_rid) const;
|
||||||
virtual bool is_skeleton(const RID& p_rid) const;
|
virtual bool is_skeleton(const RID& p_rid) const;
|
||||||
virtual bool is_environment(const RID& p_rid) const;
|
virtual bool is_environment(const RID& p_rid) const;
|
||||||
|
virtual bool is_canvas_light_occluder(const RID& p_rid) const;
|
||||||
|
|
||||||
virtual bool is_shader(const RID& p_rid) const;
|
virtual bool is_shader(const RID& p_rid) const;
|
||||||
|
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
short_name="godot"
|
short_name="godot"
|
||||||
name="Godot Engine"
|
name="Godot Engine"
|
||||||
major=1
|
major=1
|
||||||
minor=0
|
minor=1
|
||||||
status="stable"
|
status="beta1"
|
||||||
|
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user