Fix typos in source code using codespell
From https://github.com/lucasdemarchi/codespell
This commit is contained in:
parent
c103f32ea3
commit
debeee56f7
|
@ -12,7 +12,7 @@ Sections covered in this file:
|
||||||
|
|
||||||
The golden rule is to **always open *one* issue for *one* bug**. If you notice several bugs and want to report them, make sure to create one new issue for each of them.
|
The golden rule is to **always open *one* issue for *one* bug**. If you notice several bugs and want to report them, make sure to create one new issue for each of them.
|
||||||
|
|
||||||
Everything refered to hereafter as "bug" also applies for feature requests.
|
Everything referred to hereafter as "bug" also applies for feature requests.
|
||||||
|
|
||||||
If you are reporting a new issue, you will make our life much simpler (and the fix come much sooner) by following those guidelines:
|
If you are reporting a new issue, you will make our life much simpler (and the fix come much sooner) by following those guidelines:
|
||||||
|
|
||||||
|
|
|
@ -387,7 +387,7 @@ if selected_platform in platform_list:
|
||||||
# env['MSVS_VERSION']='9.0'
|
# env['MSVS_VERSION']='9.0'
|
||||||
|
|
||||||
# Calls a CMD with /C(lose) and /V(delayed environment variable expansion) options.
|
# Calls a CMD with /C(lose) and /V(delayed environment variable expansion) options.
|
||||||
# And runs vcvarsall bat for the propper arhitecture and scons for propper configuration
|
# And runs vcvarsall bat for the proper architecture and scons for proper configuration
|
||||||
env['MSVSBUILDCOM'] = 'cmd /V /C set "plat=$(PlatformTarget)" ^& (if "$(PlatformTarget)"=="x64" (set "plat=x86_amd64")) ^& set "tools=yes" ^& (if "$(Configuration)"=="release" (set "tools=no")) ^& call "$(VCInstallDir)vcvarsall.bat" !plat! ^& scons platform=windows target=$(Configuration) tools=!tools! -j2'
|
env['MSVSBUILDCOM'] = 'cmd /V /C set "plat=$(PlatformTarget)" ^& (if "$(PlatformTarget)"=="x64" (set "plat=x86_amd64")) ^& set "tools=yes" ^& (if "$(Configuration)"=="release" (set "tools=no")) ^& call "$(VCInstallDir)vcvarsall.bat" !plat! ^& scons platform=windows target=$(Configuration) tools=!tools! -j2'
|
||||||
env['MSVSREBUILDCOM'] = 'cmd /V /C set "plat=$(PlatformTarget)" ^& (if "$(PlatformTarget)"=="x64" (set "plat=x86_amd64")) ^& set "tools=yes" ^& (if "$(Configuration)"=="release" (set "tools=no")) & call "$(VCInstallDir)vcvarsall.bat" !plat! ^& scons platform=windows target=$(Configuration) tools=!tools! vsproj=yes -j2'
|
env['MSVSREBUILDCOM'] = 'cmd /V /C set "plat=$(PlatformTarget)" ^& (if "$(PlatformTarget)"=="x64" (set "plat=x86_amd64")) ^& set "tools=yes" ^& (if "$(Configuration)"=="release" (set "tools=no")) & call "$(VCInstallDir)vcvarsall.bat" !plat! ^& scons platform=windows target=$(Configuration) tools=!tools! vsproj=yes -j2'
|
||||||
env['MSVSCLEANCOM'] = 'cmd /V /C set "plat=$(PlatformTarget)" ^& (if "$(PlatformTarget)"=="x64" (set "plat=x86_amd64")) ^& set "tools=yes" ^& (if "$(Configuration)"=="release" (set "tools=no")) ^& call "$(VCInstallDir)vcvarsall.bat" !plat! ^& scons --clean platform=windows target=$(Configuration) tools=!tools! -j2'
|
env['MSVSCLEANCOM'] = 'cmd /V /C set "plat=$(PlatformTarget)" ^& (if "$(PlatformTarget)"=="x64" (set "plat=x86_amd64")) ^& set "tools=yes" ^& (if "$(Configuration)"=="release" (set "tools=no")) ^& call "$(VCInstallDir)vcvarsall.bat" !plat! ^& scons --clean platform=windows target=$(Configuration) tools=!tools! -j2'
|
||||||
|
|
|
@ -550,12 +550,12 @@ class CommandQueueMT {
|
||||||
if ((COMMAND_MEM_SIZE - write_ptr) < alloc_size + 4) {
|
if ((COMMAND_MEM_SIZE - write_ptr) < alloc_size + 4) {
|
||||||
// no room at the end, wrap down;
|
// no room at the end, wrap down;
|
||||||
|
|
||||||
if (read_ptr == 0) // dont want write_ptr to become read_ptr
|
if (read_ptr == 0) // don't want write_ptr to become read_ptr
|
||||||
return NULL;
|
return NULL;
|
||||||
|
|
||||||
// if this happens, it's a bug
|
// if this happens, it's a bug
|
||||||
ERR_FAIL_COND_V((COMMAND_MEM_SIZE - write_ptr) < sizeof(uint32_t), NULL);
|
ERR_FAIL_COND_V((COMMAND_MEM_SIZE - write_ptr) < sizeof(uint32_t), NULL);
|
||||||
// zero means, wrap to begining
|
// zero means, wrap to beginning
|
||||||
|
|
||||||
uint32_t *p = (uint32_t *)&command_mem[write_ptr];
|
uint32_t *p = (uint32_t *)&command_mem[write_ptr];
|
||||||
*p = 0;
|
*p = 0;
|
||||||
|
|
|
@ -40,7 +40,7 @@ enum Error {
|
||||||
OK,
|
OK,
|
||||||
FAILED, ///< Generic fail error
|
FAILED, ///< Generic fail error
|
||||||
ERR_UNAVAILABLE, ///< What is requested is unsupported/unavailable
|
ERR_UNAVAILABLE, ///< What is requested is unsupported/unavailable
|
||||||
ERR_UNCONFIGURED, ///< The object being used hasnt been properly set up yet
|
ERR_UNCONFIGURED, ///< The object being used hasn't been properly set up yet
|
||||||
ERR_UNAUTHORIZED, ///< Missing credentials for requested resource
|
ERR_UNAUTHORIZED, ///< Missing credentials for requested resource
|
||||||
ERR_PARAMETER_RANGE_ERROR, ///< Parameter given out of range (5)
|
ERR_PARAMETER_RANGE_ERROR, ///< Parameter given out of range (5)
|
||||||
ERR_OUT_OF_MEMORY, ///< Out of memory
|
ERR_OUT_OF_MEMORY, ///< Out of memory
|
||||||
|
|
|
@ -282,7 +282,7 @@ Error GlobalConfig::setup(const String &p_path, const String &p_main_pack) {
|
||||||
|
|
||||||
//Try to use the filesystem for files, according to OS. (only Android -when reading from pck- and iOS use this)
|
//Try to use the filesystem for files, according to OS. (only Android -when reading from pck- and iOS use this)
|
||||||
if (OS::get_singleton()->get_resource_dir() != "") {
|
if (OS::get_singleton()->get_resource_dir() != "") {
|
||||||
//OS will call Globals->get_resource_path which will be empty if not overriden!
|
//OS will call Globals->get_resource_path which will be empty if not overridden!
|
||||||
//if the OS would rather use somewhere else, then it will not be empty.
|
//if the OS would rather use somewhere else, then it will not be empty.
|
||||||
|
|
||||||
resource_path = OS::get_singleton()->get_resource_dir().replace("\\", "/");
|
resource_path = OS::get_singleton()->get_resource_dir().replace("\\", "/");
|
||||||
|
|
|
@ -414,7 +414,7 @@ static _GlobalConstant _global_constants[] = {
|
||||||
BIND_GLOBAL_CONSTANT(OK),
|
BIND_GLOBAL_CONSTANT(OK),
|
||||||
BIND_GLOBAL_CONSTANT(FAILED), ///< Generic fail error
|
BIND_GLOBAL_CONSTANT(FAILED), ///< Generic fail error
|
||||||
BIND_GLOBAL_CONSTANT(ERR_UNAVAILABLE), ///< What is requested is unsupported/unavailable
|
BIND_GLOBAL_CONSTANT(ERR_UNAVAILABLE), ///< What is requested is unsupported/unavailable
|
||||||
BIND_GLOBAL_CONSTANT(ERR_UNCONFIGURED), ///< The object being used hasnt been properly set up yet
|
BIND_GLOBAL_CONSTANT(ERR_UNCONFIGURED), ///< The object being used hasn't been properly set up yet
|
||||||
BIND_GLOBAL_CONSTANT(ERR_UNAUTHORIZED), ///< Missing credentials for requested resource
|
BIND_GLOBAL_CONSTANT(ERR_UNAUTHORIZED), ///< Missing credentials for requested resource
|
||||||
BIND_GLOBAL_CONSTANT(ERR_PARAMETER_RANGE_ERROR), ///< Parameter given out of range
|
BIND_GLOBAL_CONSTANT(ERR_PARAMETER_RANGE_ERROR), ///< Parameter given out of range
|
||||||
BIND_GLOBAL_CONSTANT(ERR_OUT_OF_MEMORY), ///< Out of memory
|
BIND_GLOBAL_CONSTANT(ERR_OUT_OF_MEMORY), ///< Out of memory
|
||||||
|
|
|
@ -413,7 +413,7 @@ public:
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Erase an item, return true if erasing was succesful
|
* Erase an item, return true if erasing was successful
|
||||||
*/
|
*/
|
||||||
|
|
||||||
bool erase(const TKey &p_key) {
|
bool erase(const TKey &p_key) {
|
||||||
|
|
|
@ -171,7 +171,7 @@ public:
|
||||||
void get_mipmap_offset_size_and_dimensions(int p_mipmap, int &r_ofs, int &r_size, int &w, int &h) const; //get where the mipmap begins in data
|
void get_mipmap_offset_size_and_dimensions(int p_mipmap, int &r_ofs, int &r_size, int &w, int &h) const; //get where the mipmap begins in data
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Resize the image, using the prefered interpolation method.
|
* Resize the image, using the preferred interpolation method.
|
||||||
* Indexed-Color images always use INTERPOLATE_NEAREST.
|
* Indexed-Color images always use INTERPOLATE_NEAREST.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
|
@ -34,7 +34,7 @@
|
||||||
#include "variant.h"
|
#include "variant.h"
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Miscelaneous helpers for marshalling data types, and encoding
|
* Miscellaneous helpers for marshalling data types, and encoding
|
||||||
* in an endian independent way
|
* in an endian independent way
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
|
@ -39,7 +39,7 @@ static bool _equalsn(const CharType *str1, const CharType *str2, int len) {
|
||||||
return false;
|
return false;
|
||||||
|
|
||||||
// if one (or both) of the strings was smaller then they
|
// if one (or both) of the strings was smaller then they
|
||||||
// are only equal if they have the same lenght
|
// are only equal if they have the same length
|
||||||
return (i == len) || (str1[i] == 0 && str2[i] == 0);
|
return (i == len) || (str1[i] == 0 && str2[i] == 0);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -179,7 +179,7 @@ private:
|
||||||
|
|
||||||
public:
|
public:
|
||||||
/**
|
/**
|
||||||
* return an const iterator to the begining of the list.
|
* return an const iterator to the beginning of the list.
|
||||||
*/
|
*/
|
||||||
_FORCE_INLINE_ const Element *front() const {
|
_FORCE_INLINE_ const Element *front() const {
|
||||||
|
|
||||||
|
@ -187,7 +187,7 @@ public:
|
||||||
};
|
};
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* return an iterator to the begining of the list.
|
* return an iterator to the beginning of the list.
|
||||||
*/
|
*/
|
||||||
_FORCE_INLINE_ Element *front() {
|
_FORCE_INLINE_ Element *front() {
|
||||||
return _data ? _data->first : 0;
|
return _data ? _data->first : 0;
|
||||||
|
@ -251,7 +251,7 @@ public:
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* store a new element at the begining of the list
|
* store a new element at the beginning of the list
|
||||||
*/
|
*/
|
||||||
Element *push_front(const T &value) {
|
Element *push_front(const T &value) {
|
||||||
|
|
||||||
|
|
|
@ -136,7 +136,7 @@ Face3::Side Face3::get_side_of(const Face3 &p_face, ClockDirection p_clock_dir)
|
||||||
|
|
||||||
const Vector3 &v = p_face.vertex[i];
|
const Vector3 &v = p_face.vertex[i];
|
||||||
|
|
||||||
if (plane.has_point(v)) //coplanar, dont bother
|
if (plane.has_point(v)) //coplanar, don't bother
|
||||||
continue;
|
continue;
|
||||||
|
|
||||||
if (plane.is_point_over(v))
|
if (plane.is_point_over(v))
|
||||||
|
|
|
@ -990,7 +990,7 @@ void Geometry::make_atlas(const Vector<Size2i> &p_rects, Vector<Point2i> &r_resu
|
||||||
|
|
||||||
//super simple, almost brute force scanline stacking fitter
|
//super simple, almost brute force scanline stacking fitter
|
||||||
//it's pretty basic for now, but it tries to make sure that the aspect ratio of the
|
//it's pretty basic for now, but it tries to make sure that the aspect ratio of the
|
||||||
//resulting atlas is somehow square. This is necesary because video cards have limits
|
//resulting atlas is somehow square. This is necessary because video cards have limits
|
||||||
//on texture size (usually 2048 or 4096), so the more square a texture, the more chances
|
//on texture size (usually 2048 or 4096), so the more square a texture, the more chances
|
||||||
//it will work in every hardware.
|
//it will work in every hardware.
|
||||||
// for example, it will prioritize a 1024x1024 atlas (works everywhere) instead of a
|
// for example, it will prioritize a 1024x1024 atlas (works everywhere) instead of a
|
||||||
|
@ -1057,7 +1057,7 @@ void Geometry::make_atlas(const Vector<Size2i> &p_rects, Vector<Point2i> &r_resu
|
||||||
if (end_w > max_w)
|
if (end_w > max_w)
|
||||||
max_w = end_w;
|
max_w = end_w;
|
||||||
|
|
||||||
if (ofs == 0 || end_h > limit_h) //while h limit not reched, keep stacking
|
if (ofs == 0 || end_h > limit_h) //while h limit not reached, keep stacking
|
||||||
ofs += wrects[j].s.width;
|
ofs += wrects[j].s.width;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -108,7 +108,7 @@ public:
|
||||||
//do the function 'd' as defined by pb. I think is is dot product of some sort
|
//do the function 'd' as defined by pb. I think is is dot product of some sort
|
||||||
#define d_of(m, n, o, p) ((m.x - n.x) * (o.x - p.x) + (m.y - n.y) * (o.y - p.y) + (m.z - n.z) * (o.z - p.z))
|
#define d_of(m, n, o, p) ((m.x - n.x) * (o.x - p.x) + (m.y - n.y) * (o.y - p.y) + (m.z - n.z) * (o.z - p.z))
|
||||||
|
|
||||||
//caluclate the parpametric position on the 2 curves, mua and mub
|
//calculate the parametric position on the 2 curves, mua and mub
|
||||||
real_t mua = ( d_of(p1,q1,q2,q1) * d_of(q2,q1,p2,p1) - d_of(p1,q1,p2,p1) * d_of(q2,q1,q2,q1) ) / ( d_of(p2,p1,p2,p1) * d_of(q2,q1,q2,q1) - d_of(q2,q1,p2,p1) * d_of(q2,q1,p2,p1) );
|
real_t mua = ( d_of(p1,q1,q2,q1) * d_of(q2,q1,p2,p1) - d_of(p1,q1,p2,p1) * d_of(q2,q1,q2,q1) ) / ( d_of(p2,p1,p2,p1) * d_of(q2,q1,q2,q1) - d_of(q2,q1,p2,p1) * d_of(q2,q1,p2,p1) );
|
||||||
real_t mub = ( d_of(p1,q1,q2,q1) + mua * d_of(q2,q1,p2,p1) ) / d_of(q2,q1,q2,q1);
|
real_t mub = ( d_of(p1,q1,q2,q1) + mua * d_of(q2,q1,p2,p1) ) / d_of(q2,q1,q2,q1);
|
||||||
|
|
||||||
|
|
|
@ -229,7 +229,7 @@ Vector3 Basis::get_scale() const {
|
||||||
// FIXME: We eventually need a proper polar decomposition.
|
// FIXME: We eventually need a proper polar decomposition.
|
||||||
// As a cheap workaround until then, to ensure that R is a proper rotation matrix with determinant +1
|
// As a cheap workaround until then, to ensure that R is a proper rotation matrix with determinant +1
|
||||||
// (such that it can be represented by a Quat or Euler angles), we absorb the sign flip into the scaling matrix.
|
// (such that it can be represented by a Quat or Euler angles), we absorb the sign flip into the scaling matrix.
|
||||||
// As such, it works in conjuction with get_rotation().
|
// As such, it works in conjunction with get_rotation().
|
||||||
real_t det_sign = determinant() > 0 ? 1 : -1;
|
real_t det_sign = determinant() > 0 ? 1 : -1;
|
||||||
return det_sign * Vector3(
|
return det_sign * Vector3(
|
||||||
Vector3(elements[0][0], elements[1][0], elements[2][0]).length(),
|
Vector3(elements[0][0], elements[1][0], elements[2][0]).length(),
|
||||||
|
|
|
@ -116,7 +116,7 @@ bool Plane::intersects_ray(Vector3 p_from, Vector3 p_dir, Vector3 *p_intersectio
|
||||||
real_t dist = (normal.dot(p_from) - d) / den;
|
real_t dist = (normal.dot(p_from) - d) / den;
|
||||||
//printf("dist is %i\n",dist);
|
//printf("dist is %i\n",dist);
|
||||||
|
|
||||||
if (dist > CMP_EPSILON) { //this is a ray, before the emiting pos (p_from) doesnt exist
|
if (dist > CMP_EPSILON) { //this is a ray, before the emitting pos (p_from) doesn't exist
|
||||||
|
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
|
@ -95,7 +95,7 @@ public:
|
||||||
|
|
||||||
Rect3 expand(const Vector3 &p_vector) const;
|
Rect3 expand(const Vector3 &p_vector) const;
|
||||||
_FORCE_INLINE_ void project_range_in_plane(const Plane &p_plane, real_t &r_min, real_t &r_max) const;
|
_FORCE_INLINE_ void project_range_in_plane(const Plane &p_plane, real_t &r_min, real_t &r_max) const;
|
||||||
_FORCE_INLINE_ void expand_to(const Vector3 &p_vector); /** expand to contain a point if necesary */
|
_FORCE_INLINE_ void expand_to(const Vector3 &p_vector); /** expand to contain a point if necessary */
|
||||||
|
|
||||||
operator String() const;
|
operator String() const;
|
||||||
|
|
||||||
|
|
|
@ -53,7 +53,7 @@ enum PropertyHint {
|
||||||
PROPERTY_HINT_RANGE, ///< hint_text = "min,max,step,slider; //slider is optional"
|
PROPERTY_HINT_RANGE, ///< hint_text = "min,max,step,slider; //slider is optional"
|
||||||
PROPERTY_HINT_EXP_RANGE, ///< hint_text = "min,max,step", exponential edit
|
PROPERTY_HINT_EXP_RANGE, ///< hint_text = "min,max,step", exponential edit
|
||||||
PROPERTY_HINT_ENUM, ///< hint_text= "val1,val2,val3,etc"
|
PROPERTY_HINT_ENUM, ///< hint_text= "val1,val2,val3,etc"
|
||||||
PROPERTY_HINT_EXP_EASING, /// exponential easing funciton (Math::ease)
|
PROPERTY_HINT_EXP_EASING, /// exponential easing function (Math::ease)
|
||||||
PROPERTY_HINT_LENGTH, ///< hint_text= "length" (as integer)
|
PROPERTY_HINT_LENGTH, ///< hint_text= "length" (as integer)
|
||||||
PROPERTY_HINT_SPRITE_FRAME,
|
PROPERTY_HINT_SPRITE_FRAME,
|
||||||
PROPERTY_HINT_KEY_ACCEL, ///< hint_text= "length" (as integer)
|
PROPERTY_HINT_KEY_ACCEL, ///< hint_text= "length" (as integer)
|
||||||
|
|
|
@ -231,7 +231,7 @@ PoolAllocator::ID PoolAllocator::alloc(int p_size) {
|
||||||
Entry &entry = entry_array[entry_indices[new_entry_indices_pos]];
|
Entry &entry = entry_array[entry_indices[new_entry_indices_pos]];
|
||||||
|
|
||||||
entry.len = p_size;
|
entry.len = p_size;
|
||||||
entry.pos = (new_entry_indices_pos == 0) ? 0 : entry_end(entry_array[entry_indices[new_entry_indices_pos - 1]]); //alloc either at begining or end of previous
|
entry.pos = (new_entry_indices_pos == 0) ? 0 : entry_end(entry_array[entry_indices[new_entry_indices_pos - 1]]); //alloc either at beginning or end of previous
|
||||||
entry.lock = 0;
|
entry.lock = 0;
|
||||||
entry.check = (check_count++) & CHECK_MASK;
|
entry.check = (check_count++) & CHECK_MASK;
|
||||||
free_mem -= size_to_alloc;
|
free_mem -= size_to_alloc;
|
||||||
|
|
|
@ -369,7 +369,7 @@ void ScriptDebuggerRemote::_get_output() {
|
||||||
void ScriptDebuggerRemote::line_poll() {
|
void ScriptDebuggerRemote::line_poll() {
|
||||||
|
|
||||||
//the purpose of this is just processing events every now and then when the script might get too busy
|
//the purpose of this is just processing events every now and then when the script might get too busy
|
||||||
//otherwise bugs like infinite loops cant be catched
|
//otherwise bugs like infinite loops can't be caught
|
||||||
if (poll_every % 2048 == 0)
|
if (poll_every % 2048 == 0)
|
||||||
_poll_events();
|
_poll_events();
|
||||||
poll_every++;
|
poll_every++;
|
||||||
|
|
|
@ -661,7 +661,7 @@
|
||||||
</argument>
|
</argument>
|
||||||
<description>
|
<description>
|
||||||
Stop the function execution and return the current state. Call [method GDFunctionState.resume] on the state to resume execution. This invalidates the state.
|
Stop the function execution and return the current state. Call [method GDFunctionState.resume] on the state to resume execution. This invalidates the state.
|
||||||
Returns anything that was passed to the resume function call. If passed an object and a signal, the execution is resumed when the object's signal is emmited.
|
Returns anything that was passed to the resume function call. If passed an object and a signal, the execution is resumed when the object's signal is emitted.
|
||||||
</description>
|
</description>
|
||||||
</method>
|
</method>
|
||||||
</methods>
|
</methods>
|
||||||
|
@ -2521,7 +2521,7 @@
|
||||||
</signal>
|
</signal>
|
||||||
<signal name="finished">
|
<signal name="finished">
|
||||||
<description>
|
<description>
|
||||||
Emitted when the animation is finished (when it plays the last frame). If the animation is looping, this signal is emitted everytime the last frame is drawn, before looping.
|
Emitted when the animation is finished (when it plays the last frame). If the animation is looping, this signal is emitted every time the last frame is drawn, before looping.
|
||||||
</description>
|
</description>
|
||||||
</signal>
|
</signal>
|
||||||
</signals>
|
</signals>
|
||||||
|
@ -7805,7 +7805,7 @@
|
||||||
Tint the entire canvas
|
Tint the entire canvas
|
||||||
</brief_description>
|
</brief_description>
|
||||||
<description>
|
<description>
|
||||||
CanvasModulate tints the canvas elements using its asigned color
|
CanvasModulate tints the canvas elements using its assigned color
|
||||||
</description>
|
</description>
|
||||||
<methods>
|
<methods>
|
||||||
<method name="get_color" qualifiers="const">
|
<method name="get_color" qualifiers="const">
|
||||||
|
@ -9088,7 +9088,7 @@
|
||||||
<argument index="0" name="colors" type="ColorArray">
|
<argument index="0" name="colors" type="ColorArray">
|
||||||
</argument>
|
</argument>
|
||||||
<description>
|
<description>
|
||||||
Sets the colors for the specified amount of elements. Calling this function with a different number of elements than previously defined causes the ramp to resize its colors and offsets array to accomodate the new elements.
|
Sets the colors for the specified amount of elements. Calling this function with a different number of elements than previously defined causes the ramp to resize its colors and offsets array to accommodate the new elements.
|
||||||
</description>
|
</description>
|
||||||
</method>
|
</method>
|
||||||
<method name="set_offset">
|
<method name="set_offset">
|
||||||
|
@ -9104,7 +9104,7 @@
|
||||||
<argument index="0" name="offsets" type="RealArray">
|
<argument index="0" name="offsets" type="RealArray">
|
||||||
</argument>
|
</argument>
|
||||||
<description>
|
<description>
|
||||||
Sets the offset for the specified amount of elements. Calling this function with a different number of elements than previously defined causes the ramp to resize its colors and offsets array to accomodate the new elements, all new colors will be black by default.
|
Sets the offset for the specified amount of elements. Calling this function with a different number of elements than previously defined causes the ramp to resize its colors and offsets array to accommodate the new elements, all new colors will be black by default.
|
||||||
</description>
|
</description>
|
||||||
</method>
|
</method>
|
||||||
</methods>
|
</methods>
|
||||||
|
@ -13167,7 +13167,7 @@
|
||||||
<argument index="0" name="enable" type="bool">
|
<argument index="0" name="enable" type="bool">
|
||||||
</argument>
|
</argument>
|
||||||
<description>
|
<description>
|
||||||
Set whether to swap the endianess of the file. Enable this if you're dealing with files written in big endian machines.
|
Set whether to swap the endianness of the file. Enable this if you're dealing with files written in big endian machines.
|
||||||
Note that this is about the file format, not CPU type. This is always reseted to [code]false[/code] whenever you open the file.
|
Note that this is about the file format, not CPU type. This is always reseted to [code]false[/code] whenever you open the file.
|
||||||
</description>
|
</description>
|
||||||
</method>
|
</method>
|
||||||
|
@ -19951,7 +19951,7 @@
|
||||||
Adds the value of pixels corresponding to the Light2D to the values of pixels under it. This is the common behaviour of a light.
|
Adds the value of pixels corresponding to the Light2D to the values of pixels under it. This is the common behaviour of a light.
|
||||||
</constant>
|
</constant>
|
||||||
<constant name="MODE_SUB" value="1">
|
<constant name="MODE_SUB" value="1">
|
||||||
Substract the value of pixels corresponding to the Light2D to the values of pixels under it, resulting in inversed light effect.
|
Subtract the value of pixels corresponding to the Light2D to the values of pixels under it, resulting in inversed light effect.
|
||||||
</constant>
|
</constant>
|
||||||
<constant name="MODE_MIX" value="2">
|
<constant name="MODE_MIX" value="2">
|
||||||
Mix the value of pixels corresponding to the Light2D to the values of pixels under it by linear interpolation.
|
Mix the value of pixels corresponding to the Light2D to the values of pixels under it by linear interpolation.
|
||||||
|
@ -26286,7 +26286,7 @@
|
||||||
<argument index="1" name="value" type="float">
|
<argument index="1" name="value" type="float">
|
||||||
</argument>
|
</argument>
|
||||||
<description>
|
<description>
|
||||||
Sets the randomness value of the specified emitter parameter (see the constants secction for the list of parameters), 0 means no randomness, so every particle will have the parameters specified, 1 means that the parameter will be choosen at random, the closer the randomness value gets to 0 the more conservative the variation of the parameter will be.
|
Sets the randomness value of the specified emitter parameter (see the constants secction for the list of parameters), 0 means no randomness, so every particle will have the parameters specified, 1 means that the parameter will be chosen at random, the closer the randomness value gets to 0 the more conservative the variation of the parameter will be.
|
||||||
</description>
|
</description>
|
||||||
</method>
|
</method>
|
||||||
<method name="set_texture">
|
<method name="set_texture">
|
||||||
|
@ -27207,7 +27207,7 @@
|
||||||
collider_id: Id of the object the shape intersected.
|
collider_id: Id of the object the shape intersected.
|
||||||
collider: Object the shape intersected.
|
collider: Object the shape intersected.
|
||||||
rid: [RID] of the object the shape intersected.
|
rid: [RID] of the object the shape intersected.
|
||||||
The number of intersections can be limited with the second paramater, to reduce the processing time.
|
The number of intersections can be limited with the second parameter, to reduce the processing time.
|
||||||
</description>
|
</description>
|
||||||
</method>
|
</method>
|
||||||
</methods>
|
</methods>
|
||||||
|
@ -32714,7 +32714,7 @@
|
||||||
<argument index="0" name="name" type="Variant" default="0">
|
<argument index="0" name="name" type="Variant" default="0">
|
||||||
</argument>
|
</argument>
|
||||||
<description>
|
<description>
|
||||||
Returns the end position of the match in the string. An interger can be specified for numeric groups or a string for named groups. Returns -1 if that group wasn't found or doesn't exist. Defaults to 0 (whole pattern).
|
Returns the end position of the match in the string. An integer can be specified for numeric groups or a string for named groups. Returns -1 if that group wasn't found or doesn't exist. Defaults to 0 (whole pattern).
|
||||||
</description>
|
</description>
|
||||||
</method>
|
</method>
|
||||||
<method name="get_group_array" qualifiers="const">
|
<method name="get_group_array" qualifiers="const">
|
||||||
|
@ -32751,7 +32751,7 @@
|
||||||
<argument index="0" name="name" type="Variant" default="0">
|
<argument index="0" name="name" type="Variant" default="0">
|
||||||
</argument>
|
</argument>
|
||||||
<description>
|
<description>
|
||||||
Returns the starting position of the match in the string. An interger can be specified for numeric groups or a string for named groups. Returns -1 if that group wasn't found or doesn't exist. Defaults to 0 (whole pattern).
|
Returns the starting position of the match in the string. An integer can be specified for numeric groups or a string for named groups. Returns -1 if that group wasn't found or doesn't exist. Defaults to 0 (whole pattern).
|
||||||
</description>
|
</description>
|
||||||
</method>
|
</method>
|
||||||
<method name="get_string" qualifiers="const">
|
<method name="get_string" qualifiers="const">
|
||||||
|
@ -32760,7 +32760,7 @@
|
||||||
<argument index="0" name="name" type="Variant" default="0">
|
<argument index="0" name="name" type="Variant" default="0">
|
||||||
</argument>
|
</argument>
|
||||||
<description>
|
<description>
|
||||||
Returns the result of the match in the string. An interger can be specified for numeric groups or a string for named groups. Returns -1 if that group wasn't found or doesn't exist. Defaults to 0 (whole pattern).
|
Returns the result of the match in the string. An integer can be specified for numeric groups or a string for named groups. Returns -1 if that group wasn't found or doesn't exist. Defaults to 0 (whole pattern).
|
||||||
</description>
|
</description>
|
||||||
</method>
|
</method>
|
||||||
</methods>
|
</methods>
|
||||||
|
@ -38140,7 +38140,7 @@
|
||||||
<return type="int">
|
<return type="int">
|
||||||
</return>
|
</return>
|
||||||
<description>
|
<description>
|
||||||
Return visibility of the split dragger(One of [DRAGGER_VISIBLE], [DRAGGER_HIDDEN] or [DRAGGER_HIDDEN_COLLAPSED]).
|
Return visibility of the split dragger (one of [DRAGGER_VISIBLE], [DRAGGER_HIDDEN] or [DRAGGER_HIDDEN_COLLAPSED]).
|
||||||
</description>
|
</description>
|
||||||
</method>
|
</method>
|
||||||
<method name="get_split_offset" qualifiers="const">
|
<method name="get_split_offset" qualifiers="const">
|
||||||
|
@ -38168,7 +38168,7 @@
|
||||||
<argument index="0" name="mode" type="int">
|
<argument index="0" name="mode" type="int">
|
||||||
</argument>
|
</argument>
|
||||||
<description>
|
<description>
|
||||||
Set visibility of the split dragger([i]mode[/i] must be one of [DRAGGER_VISIBLE], [DRAGGER_HIDDEN] or [DRAGGER_HIDDEN_COLLAPSED]).
|
Set visibility of the split dragger ([i]mode[/i] must be one of [DRAGGER_VISIBLE], [DRAGGER_HIDDEN] or [DRAGGER_HIDDEN_COLLAPSED]).
|
||||||
</description>
|
</description>
|
||||||
</method>
|
</method>
|
||||||
<method name="set_split_offset">
|
<method name="set_split_offset">
|
||||||
|
@ -38184,7 +38184,7 @@
|
||||||
<argument index="0" name="offset" type="int">
|
<argument index="0" name="offset" type="int">
|
||||||
</argument>
|
</argument>
|
||||||
<description>
|
<description>
|
||||||
Emmited when the dragger is gragged by user.
|
Emitted when the dragger is dragged by user.
|
||||||
</description>
|
</description>
|
||||||
</signal>
|
</signal>
|
||||||
</signals>
|
</signals>
|
||||||
|
@ -44227,7 +44227,7 @@
|
||||||
tween.start()
|
tween.start()
|
||||||
[/codeblock]
|
[/codeblock]
|
||||||
Some of the methods of this class require a property name. You can get the property name by hovering over the property in the inspector of the editor.
|
Some of the methods of this class require a property name. You can get the property name by hovering over the property in the inspector of the editor.
|
||||||
Many of the methods accept [code]trans_type[/code] and [code]ease_type[/code]. The first accepts an TRANS_* constant, and refers to the way the timing of the animation is handled (you might want to see [code]http://easings.net/[/code] for some examples). The second accepts an EASE_* constant, and controls the where [code]trans_type[/code] is applied to the interpolation (in the begining, the end, or both). If you don't know which transision and easing to pick, you can try different TRANS_* constants with EASE_IN_OUT, and use the one that looks best.
|
Many of the methods accept [code]trans_type[/code] and [code]ease_type[/code]. The first accepts an TRANS_* constant, and refers to the way the timing of the animation is handled (you might want to see [code]http://easings.net/[/code] for some examples). The second accepts an EASE_* constant, and controls the where [code]trans_type[/code] is applied to the interpolation (in the beginning, the end, or both). If you don't know which transision and easing to pick, you can try different TRANS_* constants with EASE_IN_OUT, and use the one that looks best.
|
||||||
</description>
|
</description>
|
||||||
<methods>
|
<methods>
|
||||||
<method name="follow_method">
|
<method name="follow_method">
|
||||||
|
@ -44253,7 +44253,7 @@
|
||||||
</argument>
|
</argument>
|
||||||
<description>
|
<description>
|
||||||
Follow [code]method[/code] of [code]object[/code] and apply the returned value on [code]target_method[/code] of [code]target[/code], beginning from [code]initial_val[/code] for [code]duration[/code] seconds, [code]delay[/code] later. Methods are animated by calling them with consequitive values.
|
Follow [code]method[/code] of [code]object[/code] and apply the returned value on [code]target_method[/code] of [code]target[/code], beginning from [code]initial_val[/code] for [code]duration[/code] seconds, [code]delay[/code] later. Methods are animated by calling them with consequitive values.
|
||||||
[code]trans_type[/code] accepts TRANS_* constants, and is the way the animation is interpolated, while [code]ease_type[/code] accepts EASE_* constants, and controls the place of the interpolation (the begining, the end, or both). You can read more about them in the class description.
|
[code]trans_type[/code] accepts TRANS_* constants, and is the way the animation is interpolated, while [code]ease_type[/code] accepts EASE_* constants, and controls the place of the interpolation (the beginning, the end, or both). You can read more about them in the class description.
|
||||||
</description>
|
</description>
|
||||||
</method>
|
</method>
|
||||||
<method name="follow_property">
|
<method name="follow_property">
|
||||||
|
@ -44279,7 +44279,7 @@
|
||||||
</argument>
|
</argument>
|
||||||
<description>
|
<description>
|
||||||
Follow [code]property[/code] of [code]object[/code] and apply it on [code]target_property[/code] of [code]target[/code], beginning from [code]initial_val[/code] for [code]duration[/code] seconds, [code]delay[/code] seconds later. Note that [code]target:target_property[/code] would equal [code]object:property[/code] at the end of the tween.
|
Follow [code]property[/code] of [code]object[/code] and apply it on [code]target_property[/code] of [code]target[/code], beginning from [code]initial_val[/code] for [code]duration[/code] seconds, [code]delay[/code] seconds later. Note that [code]target:target_property[/code] would equal [code]object:property[/code] at the end of the tween.
|
||||||
[code]trans_type[/code] accepts TRANS_* constants, and is the way the animation is interpolated, while [code]ease_type[/code] accepts EASE_* constants, and controls the place of the interpolation (the begining, the end, or both). You can read more about them in the class description.
|
[code]trans_type[/code] accepts TRANS_* constants, and is the way the animation is interpolated, while [code]ease_type[/code] accepts EASE_* constants, and controls the place of the interpolation (the beginning, the end, or both). You can read more about them in the class description.
|
||||||
</description>
|
</description>
|
||||||
</method>
|
</method>
|
||||||
<method name="get_runtime" qualifiers="const">
|
<method name="get_runtime" qualifiers="const">
|
||||||
|
@ -44370,7 +44370,7 @@
|
||||||
</argument>
|
</argument>
|
||||||
<description>
|
<description>
|
||||||
Animate [code]method[/code] of [code]object[/code] from [code]initial_val[/code] to [code]final_val[/code] for [code]duration[/code] seconds, [code]delay[/code] seconds later. Methods are animated by calling them with consecuitive values.
|
Animate [code]method[/code] of [code]object[/code] from [code]initial_val[/code] to [code]final_val[/code] for [code]duration[/code] seconds, [code]delay[/code] seconds later. Methods are animated by calling them with consecuitive values.
|
||||||
[code]trans_type[/code] accepts TRANS_* constants, and is the way the animation is interpolated, while [code]ease_type[/code] accepts EASE_* constants, and controls the place of the interpolation (the begining, the end, or both). You can read more about them in the class description.
|
[code]trans_type[/code] accepts TRANS_* constants, and is the way the animation is interpolated, while [code]ease_type[/code] accepts EASE_* constants, and controls the place of the interpolation (the beginning, the end, or both). You can read more about them in the class description.
|
||||||
</description>
|
</description>
|
||||||
</method>
|
</method>
|
||||||
<method name="interpolate_property">
|
<method name="interpolate_property">
|
||||||
|
@ -44394,7 +44394,7 @@
|
||||||
</argument>
|
</argument>
|
||||||
<description>
|
<description>
|
||||||
Animate [code]property[/code] of [code]object[/code] from [code]initial_val[/code] to [code]final_val[/code] for [code]duration[/code] seconds, [code]delay[/code] seconds later.
|
Animate [code]property[/code] of [code]object[/code] from [code]initial_val[/code] to [code]final_val[/code] for [code]duration[/code] seconds, [code]delay[/code] seconds later.
|
||||||
[code]trans_type[/code] accepts TRANS_* constants, and is the way the animation is interpolated, while [code]ease_type[/code] accepts EASE_* constants, and controls the place of the interpolation (the begining, the end, or both). You can read more about them in the class description.
|
[code]trans_type[/code] accepts TRANS_* constants, and is the way the animation is interpolated, while [code]ease_type[/code] accepts EASE_* constants, and controls the place of the interpolation (the beginning, the end, or both). You can read more about them in the class description.
|
||||||
</description>
|
</description>
|
||||||
</method>
|
</method>
|
||||||
<method name="is_active" qualifiers="const">
|
<method name="is_active" qualifiers="const">
|
||||||
|
@ -44550,7 +44550,7 @@
|
||||||
</argument>
|
</argument>
|
||||||
<description>
|
<description>
|
||||||
Animate [code]method[/code] of [code]object[/code] from the value returned by [code]initial.initial_method[/code] to [code]final_val[/code] for [code]duration[/code] seconds, [code]delay[/code] seconds later. Methods are animated by calling them with consecuitive values.
|
Animate [code]method[/code] of [code]object[/code] from the value returned by [code]initial.initial_method[/code] to [code]final_val[/code] for [code]duration[/code] seconds, [code]delay[/code] seconds later. Methods are animated by calling them with consecuitive values.
|
||||||
[code]trans_type[/code] accepts TRANS_* constants, and is the way the animation is interpolated, while [code]ease_type[/code] accepts EASE_* constants, and controls the place of the interpolation (the begining, the end, or both). You can read more about them in the class description.
|
[code]trans_type[/code] accepts TRANS_* constants, and is the way the animation is interpolated, while [code]ease_type[/code] accepts EASE_* constants, and controls the place of the interpolation (the beginning, the end, or both). You can read more about them in the class description.
|
||||||
</description>
|
</description>
|
||||||
</method>
|
</method>
|
||||||
<method name="targeting_property">
|
<method name="targeting_property">
|
||||||
|
@ -44576,7 +44576,7 @@
|
||||||
</argument>
|
</argument>
|
||||||
<description>
|
<description>
|
||||||
Animate [code]property[/code] of [code]object[/code] from the current value of the [code]initial_val[/code] property of [code]initial[/code] to [code]final_val[/code] for [code]duration[/code] seconds, [code]delay[/code] seconds later.
|
Animate [code]property[/code] of [code]object[/code] from the current value of the [code]initial_val[/code] property of [code]initial[/code] to [code]final_val[/code] for [code]duration[/code] seconds, [code]delay[/code] seconds later.
|
||||||
[code]trans_type[/code] accepts TRANS_* constants, and is the way the animation is interpolated, while [code]ease_type[/code] accepts EASE_* constants, and controls the place of the interpolation (the begining, the end, or both). You can read more about them in the class description.
|
[code]trans_type[/code] accepts TRANS_* constants, and is the way the animation is interpolated, while [code]ease_type[/code] accepts EASE_* constants, and controls the place of the interpolation (the beginning, the end, or both). You can read more about them in the class description.
|
||||||
</description>
|
</description>
|
||||||
</method>
|
</method>
|
||||||
<method name="tell" qualifiers="const">
|
<method name="tell" qualifiers="const">
|
||||||
|
@ -44680,7 +44680,7 @@
|
||||||
</brief_description>
|
</brief_description>
|
||||||
<description>
|
<description>
|
||||||
Helper to maange UndoRedo in the editor or custom tools. It works by storing calls to functions in both 'do' an 'undo' lists.
|
Helper to maange UndoRedo in the editor or custom tools. It works by storing calls to functions in both 'do' an 'undo' lists.
|
||||||
Common behavior is to create an action, then add do/undo calls to functions or property changes, then commiting the action.
|
Common behavior is to create an action, then add do/undo calls to functions or property changes, then committing the action.
|
||||||
</description>
|
</description>
|
||||||
<methods>
|
<methods>
|
||||||
<method name="add_do_method" qualifiers="vararg">
|
<method name="add_do_method" qualifiers="vararg">
|
||||||
|
@ -44767,7 +44767,7 @@ do_property].
|
||||||
<return type="int">
|
<return type="int">
|
||||||
</return>
|
</return>
|
||||||
<description>
|
<description>
|
||||||
Get the version, each time a new action is commited, the version number of the UndoRedo is increased automatically.
|
Get the version, each time a new action is committed, the version number of the UndoRedo is increased automatically.
|
||||||
This is useful mostly to check if something changed from a saved version.
|
This is useful mostly to check if something changed from a saved version.
|
||||||
</description>
|
</description>
|
||||||
</method>
|
</method>
|
||||||
|
@ -46057,7 +46057,7 @@ do_property].
|
||||||
<return type="Image">
|
<return type="Image">
|
||||||
</return>
|
</return>
|
||||||
<description>
|
<description>
|
||||||
Return the captured screenshot after [method queue_screen_capture]. You might need to check more than one frame untill the right image is returned.
|
Return the captured screenshot after [method queue_screen_capture]. You might need to check more than one frame until the right image is returned.
|
||||||
</description>
|
</description>
|
||||||
</method>
|
</method>
|
||||||
<method name="get_size_override" qualifiers="const">
|
<method name="get_size_override" qualifiers="const">
|
||||||
|
|
|
@ -1579,7 +1579,7 @@ Variant RasterizerGLES2::shader_get_default_param(RID p_shader, const StringName
|
||||||
Shader *shader = shader_owner.get(p_shader);
|
Shader *shader = shader_owner.get(p_shader);
|
||||||
ERR_FAIL_COND_V(!shader, Variant());
|
ERR_FAIL_COND_V(!shader, Variant());
|
||||||
|
|
||||||
//update shader params if necesary
|
//update shader params if necessary
|
||||||
//make sure the shader is compiled and everything
|
//make sure the shader is compiled and everything
|
||||||
//so the actual parameters can be properly retrieved!
|
//so the actual parameters can be properly retrieved!
|
||||||
if (shader->dirty_list.in_list()) {
|
if (shader->dirty_list.in_list()) {
|
||||||
|
@ -1651,7 +1651,7 @@ Variant RasterizerGLES2::material_get_param(RID p_material, const StringName &p_
|
||||||
ERR_FAIL_COND_V(!material, Variant());
|
ERR_FAIL_COND_V(!material, Variant());
|
||||||
|
|
||||||
if (material->shader.is_valid()) {
|
if (material->shader.is_valid()) {
|
||||||
//update shader params if necesary
|
//update shader params if necessary
|
||||||
//make sure the shader is compiled and everything
|
//make sure the shader is compiled and everything
|
||||||
//so the actual parameters can be properly retrieved!
|
//so the actual parameters can be properly retrieved!
|
||||||
material->shader_cache = shader_owner.get(material->shader);
|
material->shader_cache = shader_owner.get(material->shader);
|
||||||
|
@ -5684,7 +5684,7 @@ void RasterizerGLES2::_render(const Geometry *p_geometry, const Material *p_mate
|
||||||
};
|
};
|
||||||
|
|
||||||
} else if (use_attribute_instancing) {
|
} else if (use_attribute_instancing) {
|
||||||
//if not, using atributes instead of uniforms can be really fast in forward rendering architectures
|
//if not, using attributes instead of uniforms can be really fast in forward rendering architectures
|
||||||
if (s->index_array_len > 0) {
|
if (s->index_array_len > 0) {
|
||||||
|
|
||||||
glBindBuffer(GL_ELEMENT_ARRAY_BUFFER, s->index_id);
|
glBindBuffer(GL_ELEMENT_ARRAY_BUFFER, s->index_id);
|
||||||
|
|
|
@ -1661,7 +1661,7 @@ public:
|
||||||
|
|
||||||
void set_base_framebuffer(GLuint p_id, Vector2 p_size = Vector2(0, 0));
|
void set_base_framebuffer(GLuint p_id, Vector2 p_size = Vector2(0, 0));
|
||||||
|
|
||||||
virtual void flush_frame(); //not necesary in most cases
|
virtual void flush_frame(); //not necessary in most cases
|
||||||
void set_extensions(const char *p_strings);
|
void set_extensions(const char *p_strings);
|
||||||
|
|
||||||
virtual bool needs_to_draw_next_frame() const;
|
virtual bool needs_to_draw_next_frame() const;
|
||||||
|
|
|
@ -5886,7 +5886,7 @@ bool RasterizerStorageGLES3::free(RID p_rid) {
|
||||||
} else if (texture_owner.owns(p_rid)) {
|
} else if (texture_owner.owns(p_rid)) {
|
||||||
// delete the texture
|
// delete the texture
|
||||||
Texture *texture = texture_owner.get(p_rid);
|
Texture *texture = texture_owner.get(p_rid);
|
||||||
ERR_FAIL_COND_V(texture->render_target, true); //cant free the render target texture, dude
|
ERR_FAIL_COND_V(texture->render_target, true); //can't free the render target texture, dude
|
||||||
info.texture_mem -= texture->total_data_size;
|
info.texture_mem -= texture->total_data_size;
|
||||||
texture_owner.free(p_rid);
|
texture_owner.free(p_rid);
|
||||||
memdelete(texture);
|
memdelete(texture);
|
||||||
|
|
|
@ -267,7 +267,7 @@ void main() {
|
||||||
|
|
||||||
for(int i=0;i<7;i++) {
|
for(int i=0;i<7;i++) {
|
||||||
|
|
||||||
float op_len = 2.0 * tan(cone_angle) * cone_len; //oposite side of iso triangle
|
float op_len = 2.0 * tan(cone_angle) * cone_len; //opposite side of iso triangle
|
||||||
float radius;
|
float radius;
|
||||||
{
|
{
|
||||||
//fit to sphere inside cone (sphere ends at end of cone), something like this:
|
//fit to sphere inside cone (sphere ends at end of cone), something like this:
|
||||||
|
|
|
@ -39,7 +39,7 @@
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
|
||||||
[03:57] <reduz> yessopie, so i dont havemak to rely on unicows
|
[03:57] <reduz> yessopie, so i don't havemak to rely on unicows
|
||||||
[03:58] <yessopie> reduz- yeah, all of the functions fail, and then you can call GetLastError () which will return 120
|
[03:58] <yessopie> reduz- yeah, all of the functions fail, and then you can call GetLastError () which will return 120
|
||||||
[03:58] <drumstick> CategoryApl, hehe, what? :)
|
[03:58] <drumstick> CategoryApl, hehe, what? :)
|
||||||
[03:59] <CategoryApl> didn't Verona lead to some trouble
|
[03:59] <CategoryApl> didn't Verona lead to some trouble
|
||||||
|
|
|
@ -2503,7 +2503,7 @@ void AnimationKeyEditor::_track_editor_gui_input(const InputEvent &p_input) {
|
||||||
float newpos = E->get().pos - from_t + motion;
|
float newpos = E->get().pos - from_t + motion;
|
||||||
/*
|
/*
|
||||||
if (newpos<0)
|
if (newpos<0)
|
||||||
continue; //no add at the begining
|
continue; //no add at the beginning
|
||||||
*/
|
*/
|
||||||
undo_redo->add_do_method(animation.ptr(), "track_insert_key", E->key().track, newpos, animation->track_get_key_value(E->key().track, E->key().key), animation->track_get_key_transition(E->key().track, E->key().key));
|
undo_redo->add_do_method(animation.ptr(), "track_insert_key", E->key().track, newpos, animation->track_get_key_value(E->key().track, E->key().key), animation->track_get_key_transition(E->key().track, E->key().key));
|
||||||
}
|
}
|
||||||
|
|
|
@ -241,7 +241,7 @@ void FindReplaceBar::_replace_all() {
|
||||||
}
|
}
|
||||||
|
|
||||||
text_edit->set_v_scroll(vsval);
|
text_edit->set_v_scroll(vsval);
|
||||||
set_error(vformat(TTR("Replaced %d Ocurrence(s)."), rc));
|
set_error(vformat(TTR("Replaced %d occurrence(s)."), rc));
|
||||||
}
|
}
|
||||||
|
|
||||||
void FindReplaceBar::_get_search_from(int &r_line, int &r_col) {
|
void FindReplaceBar::_get_search_from(int &r_line, int &r_col) {
|
||||||
|
@ -703,7 +703,7 @@ void FindReplaceDialog::_replace() {
|
||||||
|
|
||||||
text_edit->set_v_scroll(vsval);
|
text_edit->set_v_scroll(vsval);
|
||||||
//text_edit->set_h_scroll(hsval);
|
//text_edit->set_h_scroll(hsval);
|
||||||
error_label->set_text(vformat(TTR("Replaced %d ocurrence(s)."), rc));
|
error_label->set_text(vformat(TTR("Replaced %d occurrence(s)."), rc));
|
||||||
|
|
||||||
//hide();
|
//hide();
|
||||||
} else {
|
} else {
|
||||||
|
|
|
@ -1697,7 +1697,7 @@ Collada::Node *Collada::_parse_visual_scene_node(XMLParser &parser) {
|
||||||
|
|
||||||
} else if (section != "node") {
|
} else if (section != "node") {
|
||||||
//usually what defines the type of node
|
//usually what defines the type of node
|
||||||
//print_line(" dont know what to do with "+section);
|
//print_line(" don't know what to do with "+section);
|
||||||
if (section.begins_with("instance_")) {
|
if (section.begins_with("instance_")) {
|
||||||
|
|
||||||
if (!node) {
|
if (!node) {
|
||||||
|
@ -2444,7 +2444,7 @@ bool Collada::_move_geometry_to_skeletons(VisualScene *p_vscene, Node *p_node, L
|
||||||
//p_node->default_transform=Transform(); //this seems to be correct, because bind shape makes the object local to the skeleton
|
//p_node->default_transform=Transform(); //this seems to be correct, because bind shape makes the object local to the skeleton
|
||||||
p_node->ignore_anim = true; // collada may animate this later, if it does, then this is not supported (redo your original asset and don't animate the base mesh)
|
p_node->ignore_anim = true; // collada may animate this later, if it does, then this is not supported (redo your original asset and don't animate the base mesh)
|
||||||
p_node->parent = sk;
|
p_node->parent = sk;
|
||||||
//sk->children.push_back(0,p_node); //avoid INFINIT loop
|
//sk->children.push_back(0,p_node); //avoid INFINITE loop
|
||||||
p_mgeom->push_back(p_node);
|
p_mgeom->push_back(p_node);
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
|
@ -121,7 +121,7 @@ void ConnectDialog::_tree_node_selected() {
|
||||||
continue; // hidden method, not show!
|
continue; // hidden method, not show!
|
||||||
|
|
||||||
if (ClassDB::has_method(node->get_type(),"Node") || ClassDB::has_method(node->get_type(),"Control",true))
|
if (ClassDB::has_method(node->get_type(),"Node") || ClassDB::has_method(node->get_type(),"Control",true))
|
||||||
continue; //avoid too much unnecesary stuff
|
continue; //avoid too much unnecessary stuff
|
||||||
|
|
||||||
String method=E->get().name+"(";
|
String method=E->get().name+"(";
|
||||||
for(int i=0;i<E->get().arguments.size();i++) {
|
for(int i=0;i<E->get().arguments.size();i++) {
|
||||||
|
|
|
@ -29,12 +29,12 @@
|
||||||
#include "create_dialog.h"
|
#include "create_dialog.h"
|
||||||
|
|
||||||
#include "class_db.h"
|
#include "class_db.h"
|
||||||
#include "editor_node.h"
|
|
||||||
#include "print_string.h"
|
|
||||||
#include "scene/gui/box_container.h"
|
|
||||||
#include "editor_help.h"
|
#include "editor_help.h"
|
||||||
|
#include "editor_node.h"
|
||||||
#include "editor_settings.h"
|
#include "editor_settings.h"
|
||||||
#include "os/keyboard.h"
|
#include "os/keyboard.h"
|
||||||
|
#include "print_string.h"
|
||||||
|
#include "scene/gui/box_container.h"
|
||||||
|
|
||||||
void CreateDialog::popup_create(bool p_dontclear) {
|
void CreateDialog::popup_create(bool p_dontclear) {
|
||||||
|
|
||||||
|
@ -86,7 +86,6 @@ void CreateDialog::popup_create(bool p_dontclear) {
|
||||||
|
|
||||||
_update_favorite_list();
|
_update_favorite_list();
|
||||||
|
|
||||||
|
|
||||||
// Restore valid window bounds or pop up at default size.
|
// Restore valid window bounds or pop up at default size.
|
||||||
if (EditorSettings::get_singleton()->has("interface/dialogs/create_new_node_bounds")) {
|
if (EditorSettings::get_singleton()->has("interface/dialogs/create_new_node_bounds")) {
|
||||||
popup(EditorSettings::get_singleton()->get("interface/dialogs/create_new_node_bounds"));
|
popup(EditorSettings::get_singleton()->get("interface/dialogs/create_new_node_bounds"));
|
||||||
|
@ -94,7 +93,6 @@ void CreateDialog::popup_create(bool p_dontclear) {
|
||||||
popup_centered_ratio();
|
popup_centered_ratio();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
if (p_dontclear)
|
if (p_dontclear)
|
||||||
search_box->select_all();
|
search_box->select_all();
|
||||||
else {
|
else {
|
||||||
|
@ -213,7 +211,7 @@ void CreateDialog::_update_search() {
|
||||||
continue; // do not show editor nodes
|
continue; // do not show editor nodes
|
||||||
|
|
||||||
if (!ClassDB::can_instance(type))
|
if (!ClassDB::can_instance(type))
|
||||||
continue; // cant create what can't be instanced
|
continue; // can't create what can't be instanced
|
||||||
|
|
||||||
if (search_box->get_text() == "") {
|
if (search_box->get_text() == "") {
|
||||||
add_type(type, types, root, &to_select);
|
add_type(type, types, root, &to_select);
|
||||||
|
@ -316,7 +314,7 @@ void CreateDialog::_confirmed() {
|
||||||
|
|
||||||
void CreateDialog::_notification(int p_what) {
|
void CreateDialog::_notification(int p_what) {
|
||||||
|
|
||||||
switch (p_what) {
|
switch (p_what) {
|
||||||
case NOTIFICATION_ENTER_TREE: {
|
case NOTIFICATION_ENTER_TREE: {
|
||||||
connect("confirmed", this, "_confirmed");
|
connect("confirmed", this, "_confirmed");
|
||||||
favorite->set_icon(get_icon("Favorites", "EditorIcons"));
|
favorite->set_icon(get_icon("Favorites", "EditorIcons"));
|
||||||
|
|
|
@ -210,7 +210,7 @@ void DocData::generate(bool p_basic_types) {
|
||||||
for (List<MethodInfo>::Element *E = method_list.front(); E; E = E->next()) {
|
for (List<MethodInfo>::Element *E = method_list.front(); E; E = E->next()) {
|
||||||
|
|
||||||
if (E->get().name == "" || (E->get().name[0] == '_' && !(E->get().flags & METHOD_FLAG_VIRTUAL)))
|
if (E->get().name == "" || (E->get().name[0] == '_' && !(E->get().flags & METHOD_FLAG_VIRTUAL)))
|
||||||
continue; //hiden, dont count
|
continue; //hidden, don't count
|
||||||
|
|
||||||
MethodDoc method;
|
MethodDoc method;
|
||||||
|
|
||||||
|
|
|
@ -1807,7 +1807,7 @@ Error EditorExportPlatform::export_project_files(EditorExportSaveFunction p_func
|
||||||
|
|
||||||
if (slices.size()!=10) {
|
if (slices.size()!=10) {
|
||||||
atlas_valid=false;
|
atlas_valid=false;
|
||||||
print_line("CANT SLICE IN 10");
|
print_line("CAN'T SLICE IN 10");
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
uint64_t mod_time = slices[0].to_int64();
|
uint64_t mod_time = slices[0].to_int64();
|
||||||
|
@ -1946,7 +1946,7 @@ Error EditorExportPlatform::export_project_files(EditorExportSaveFunction p_func
|
||||||
if (f) {
|
if (f) {
|
||||||
//recreating deps..
|
//recreating deps..
|
||||||
String depline;
|
String depline;
|
||||||
//depline=String(F->get())+"::"+itos(FileAccess::get_modified_time(F->get()))+"::"+FileAccess::getD_METHOD5(F->get()); name unneccesary by top md5
|
//depline=String(F->get())+"::"+itos(FileAccess::get_modified_time(F->get()))+"::"+FileAccess::getD_METHOD5(F->get()); name unnecessary by top md5
|
||||||
depline=itos(FileAccess::get_modified_time(F->get()))+"::"+FileAccess::getD_METHOD5(F->get());
|
depline=itos(FileAccess::get_modified_time(F->get()))+"::"+FileAccess::getD_METHOD5(F->get());
|
||||||
depline+="::"+itos(region.pos.x)+"::"+itos(region.pos.y)+"::"+itos(region.size.x)+"::"+itos(region.size.y);
|
depline+="::"+itos(region.pos.x)+"::"+itos(region.pos.y)+"::"+itos(region.size.x)+"::"+itos(region.size.y);
|
||||||
depline+="::"+itos(margin.pos.x)+"::"+itos(margin.pos.y)+"::"+itos(margin.size.x)+"::"+itos(margin.size.y);
|
depline+="::"+itos(margin.pos.x)+"::"+itos(margin.pos.y)+"::"+itos(margin.size.x)+"::"+itos(margin.size.y);
|
||||||
|
|
|
@ -162,7 +162,7 @@ private:
|
||||||
virtual void _post_popup();
|
virtual void _post_popup();
|
||||||
|
|
||||||
void _save_to_recent();
|
void _save_to_recent();
|
||||||
//callback funtion is callback(String p_path,Ref<Texture> preview,Variant udata) preview null if could not load
|
//callback function is callback(String p_path,Ref<Texture> preview,Variant udata) preview null if could not load
|
||||||
|
|
||||||
void _thumbnail_result(const String &p_path, const Ref<Texture> &p_preview, const Variant &p_udata);
|
void _thumbnail_result(const String &p_path, const Ref<Texture> &p_preview, const Variant &p_udata);
|
||||||
void _thumbnail_done(const String &p_path, const Ref<Texture> &p_preview, const Variant &p_udata);
|
void _thumbnail_done(const String &p_path, const Ref<Texture> &p_preview, const Variant &p_udata);
|
||||||
|
|
|
@ -779,7 +779,7 @@ Error EditorHelp::_goto_desc(const String &p_class, int p_vscr) {
|
||||||
class_desc->set_table_column_expand(1, 1);
|
class_desc->set_table_column_expand(1, 1);
|
||||||
|
|
||||||
for (int i = 0; i < cd.properties.size(); i++) {
|
for (int i = 0; i < cd.properties.size(); i++) {
|
||||||
property_line[cd.properties[i].name] = class_desc->get_line_count() - 2; //gets overriden if description
|
property_line[cd.properties[i].name] = class_desc->get_line_count() - 2; //gets overridden if description
|
||||||
|
|
||||||
class_desc->push_cell();
|
class_desc->push_cell();
|
||||||
class_desc->push_align(RichTextLabel::ALIGN_RIGHT);
|
class_desc->push_align(RichTextLabel::ALIGN_RIGHT);
|
||||||
|
@ -874,7 +874,7 @@ Error EditorHelp::_goto_desc(const String &p_class, int p_vscr) {
|
||||||
|
|
||||||
class_desc->push_cell();
|
class_desc->push_cell();
|
||||||
|
|
||||||
method_line[methods[i].name] = class_desc->get_line_count() - 2; //gets overriden if description
|
method_line[methods[i].name] = class_desc->get_line_count() - 2; //gets overridden if description
|
||||||
class_desc->push_align(RichTextLabel::ALIGN_RIGHT);
|
class_desc->push_align(RichTextLabel::ALIGN_RIGHT);
|
||||||
class_desc->push_font(doc_code_font);
|
class_desc->push_font(doc_code_font);
|
||||||
_add_type(methods[i].return_type);
|
_add_type(methods[i].return_type);
|
||||||
|
@ -959,7 +959,7 @@ Error EditorHelp::_goto_desc(const String &p_class, int p_vscr) {
|
||||||
|
|
||||||
for (int i = 0; i < cd.theme_properties.size(); i++) {
|
for (int i = 0; i < cd.theme_properties.size(); i++) {
|
||||||
|
|
||||||
theme_property_line[cd.theme_properties[i].name] = class_desc->get_line_count() - 2; //gets overriden if description
|
theme_property_line[cd.theme_properties[i].name] = class_desc->get_line_count() - 2; //gets overridden if description
|
||||||
class_desc->push_font(doc_code_font);
|
class_desc->push_font(doc_code_font);
|
||||||
_add_type(cd.theme_properties[i].type);
|
_add_type(cd.theme_properties[i].type);
|
||||||
class_desc->push_color(EditorSettings::get_singleton()->get("text_editor/highlighting/text_color"));
|
class_desc->push_color(EditorSettings::get_singleton()->get("text_editor/highlighting/text_color"));
|
||||||
|
@ -1002,7 +1002,7 @@ Error EditorHelp::_goto_desc(const String &p_class, int p_vscr) {
|
||||||
|
|
||||||
for (int i = 0; i < cd.signals.size(); i++) {
|
for (int i = 0; i < cd.signals.size(); i++) {
|
||||||
|
|
||||||
signal_line[cd.signals[i].name] = class_desc->get_line_count() - 2; //gets overriden if description
|
signal_line[cd.signals[i].name] = class_desc->get_line_count() - 2; //gets overridden if description
|
||||||
class_desc->push_font(doc_code_font); // monofont
|
class_desc->push_font(doc_code_font); // monofont
|
||||||
//_add_type("void");
|
//_add_type("void");
|
||||||
//class_desc->add_text(" ");
|
//class_desc->add_text(" ");
|
||||||
|
|
|
@ -2606,7 +2606,7 @@ void EditorNode::_menu_option_confirm(int p_option, bool p_confirmed) {
|
||||||
current_option=-1;
|
current_option=-1;
|
||||||
//accept->get_cancel()->hide();
|
//accept->get_cancel()->hide();
|
||||||
accept->get_ok()->set_text("I see..");
|
accept->get_ok()->set_text("I see..");
|
||||||
accept->set_text("Can't import if edited scene was not saved."); //i dont think this code will ever run
|
accept->set_text("Can't import if edited scene was not saved."); //i don't think this code will ever run
|
||||||
accept->popup_centered(Size2(300,70));
|
accept->popup_centered(Size2(300,70));
|
||||||
break;
|
break;
|
||||||
|
|
||||||
|
@ -4846,7 +4846,7 @@ EditorNode::EditorNode() {
|
||||||
ResourceLoader::set_timestamp_on_load(true);
|
ResourceLoader::set_timestamp_on_load(true);
|
||||||
ResourceSaver::set_timestamp_on_save(true);
|
ResourceSaver::set_timestamp_on_save(true);
|
||||||
|
|
||||||
{ //register importers at the begining, so dialogs are created with the right extensions
|
{ //register importers at the beginning, so dialogs are created with the right extensions
|
||||||
Ref<ResourceImporterTexture> import_texture;
|
Ref<ResourceImporterTexture> import_texture;
|
||||||
import_texture.instance();
|
import_texture.instance();
|
||||||
ResourceFormatImporter::get_singleton()->add_importer(import_texture);
|
ResourceFormatImporter::get_singleton()->add_importer(import_texture);
|
||||||
|
|
|
@ -41,7 +41,7 @@ bool EditorResourcePreviewGenerator::handles(const String &p_type) const {
|
||||||
if (get_script_instance() && get_script_instance()->has_method("handles")) {
|
if (get_script_instance() && get_script_instance()->has_method("handles")) {
|
||||||
return get_script_instance()->call("handles", p_type);
|
return get_script_instance()->call("handles", p_type);
|
||||||
}
|
}
|
||||||
ERR_EXPLAIN("EditorResourcePreviewGenerator::handles needs to be overriden");
|
ERR_EXPLAIN("EditorResourcePreviewGenerator::handles needs to be overridden");
|
||||||
ERR_FAIL_V(false);
|
ERR_FAIL_V(false);
|
||||||
}
|
}
|
||||||
Ref<Texture> EditorResourcePreviewGenerator::generate(const RES &p_from) {
|
Ref<Texture> EditorResourcePreviewGenerator::generate(const RES &p_from) {
|
||||||
|
@ -49,7 +49,7 @@ Ref<Texture> EditorResourcePreviewGenerator::generate(const RES &p_from) {
|
||||||
if (get_script_instance() && get_script_instance()->has_method("generate")) {
|
if (get_script_instance() && get_script_instance()->has_method("generate")) {
|
||||||
return get_script_instance()->call("generate", p_from);
|
return get_script_instance()->call("generate", p_from);
|
||||||
}
|
}
|
||||||
ERR_EXPLAIN("EditorResourcePreviewGenerator::generate needs to be overriden");
|
ERR_EXPLAIN("EditorResourcePreviewGenerator::generate needs to be overridden");
|
||||||
ERR_FAIL_V(Ref<Texture>());
|
ERR_FAIL_V(Ref<Texture>());
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -113,7 +113,7 @@ protected:
|
||||||
public:
|
public:
|
||||||
static EditorResourcePreview *get_singleton();
|
static EditorResourcePreview *get_singleton();
|
||||||
|
|
||||||
//callback funtion is callback(String p_path,Ref<Texture> preview,Variant udata) preview null if could not load
|
//callback function is callback(String p_path,Ref<Texture> preview,Variant udata) preview null if could not load
|
||||||
void queue_resource_preview(const String &p_res, Object *p_receiver, const StringName &p_receiver_func, const Variant &p_userdata);
|
void queue_resource_preview(const String &p_res, Object *p_receiver, const StringName &p_receiver_func, const Variant &p_userdata);
|
||||||
void queue_edited_resource_preview(const Ref<Resource> &p_path, Object *p_receiver, const StringName &p_receiver_func, const Variant &p_userdata);
|
void queue_edited_resource_preview(const Ref<Resource> &p_path, Object *p_receiver, const StringName &p_receiver_func, const Variant &p_userdata);
|
||||||
|
|
||||||
|
|
|
@ -774,7 +774,7 @@ Error ColladaImport::_create_mesh_surfaces(bool p_optimize, Ref<Mesh> &p_mesh, c
|
||||||
weights.resize(4);
|
weights.resize(4);
|
||||||
}
|
}
|
||||||
|
|
||||||
//make sure weights allways add up to 1
|
//make sure weights always add up to 1
|
||||||
float total = 0;
|
float total = 0;
|
||||||
for (int i = 0; i < weights.size(); i++)
|
for (int i = 0; i < weights.size(); i++)
|
||||||
total += weights[i].weight;
|
total += weights[i].weight;
|
||||||
|
@ -818,7 +818,7 @@ Error ColladaImport::_create_mesh_surfaces(bool p_optimize, Ref<Mesh> &p_mesh, c
|
||||||
/* CREATE PRIMITIVE ARRAY */
|
/* CREATE PRIMITIVE ARRAY */
|
||||||
/**************************/
|
/**************************/
|
||||||
|
|
||||||
// The way collada uses indices is more optimal, and friendlier with 3D modelling sofware,
|
// The way collada uses indices is more optimal, and friendlier with 3D modelling software,
|
||||||
// because it can index everything, not only vertices (similar to how the WII works).
|
// because it can index everything, not only vertices (similar to how the WII works).
|
||||||
// This is, however, more incompatible with standard video cards, so arrays must be converted.
|
// This is, however, more incompatible with standard video cards, so arrays must be converted.
|
||||||
// Must convert to GL/DX format.
|
// Must convert to GL/DX format.
|
||||||
|
|
|
@ -176,7 +176,7 @@ Error ResourceImporterWAV::import(const String &p_source_file, const String &p_s
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Dont need anything else, continue */
|
/* Don't need anything else, continue */
|
||||||
format_found = true;
|
format_found = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -49,7 +49,7 @@ void EditorAtlas::fit(const Vector<Size2i> &p_rects, Vector<Point2i> &r_result,
|
||||||
|
|
||||||
//super simple, almost brute force scanline stacking fitter
|
//super simple, almost brute force scanline stacking fitter
|
||||||
//it's pretty basic for now, but it tries to make sure that the aspect ratio of the
|
//it's pretty basic for now, but it tries to make sure that the aspect ratio of the
|
||||||
//resulting atlas is somehow square. This is necesary because video cards have limits
|
//resulting atlas is somehow square. This is necessary because video cards have limits
|
||||||
//on texture size (usually 2048 or 4096), so the more square a texture, the more chances
|
//on texture size (usually 2048 or 4096), so the more square a texture, the more chances
|
||||||
//it will work in every hardware.
|
//it will work in every hardware.
|
||||||
// for example, it will prioritize a 1024x1024 atlas (works everywhere) instead of a
|
// for example, it will prioritize a 1024x1024 atlas (works everywhere) instead of a
|
||||||
|
|
|
@ -745,8 +745,8 @@ struct _EditorFontData {
|
||||||
|
|
||||||
Vector<uint8_t> bitmap;
|
Vector<uint8_t> bitmap;
|
||||||
int width,height;
|
int width,height;
|
||||||
int ofs_x; //ofset to center, from ABOVE
|
int ofs_x; //offset to center, from ABOVE
|
||||||
int ofs_y; //ofset to begining, from LEFT
|
int ofs_y; //offset to beginning, from LEFT
|
||||||
int valign; //vertical alignment
|
int valign; //vertical alignment
|
||||||
int halign;
|
int halign;
|
||||||
float advance;
|
float advance;
|
||||||
|
|
|
@ -470,7 +470,7 @@ bool ShaderEditorPlugin::handles(Object *p_object) const {
|
||||||
bool handles = true;
|
bool handles = true;
|
||||||
Shader *shader = p_object->cast_to<Shader>();
|
Shader *shader = p_object->cast_to<Shader>();
|
||||||
/*
|
/*
|
||||||
if (!shader || shader->cast_to<ShaderGraph>()) // Dont handle ShaderGraph's
|
if (!shader || shader->cast_to<ShaderGraph>()) // Don't handle ShaderGraph's
|
||||||
handles = false;
|
handles = false;
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
|
@ -2425,7 +2425,7 @@ void ShaderGraphView::_create_node(int p_id) {
|
||||||
colors.push_back("ShadowColor");
|
colors.push_back("ShadowColor");
|
||||||
colors.push_back("Diffuse");
|
colors.push_back("Diffuse");
|
||||||
colors.push_back("Specular");
|
colors.push_back("Specular");
|
||||||
colors.push_back("Emmision");
|
colors.push_back("Emission");
|
||||||
Array reals;
|
Array reals;
|
||||||
reals.push_back("Alpha");
|
reals.push_back("Alpha");
|
||||||
reals.push_back("DiffuseAlpha");
|
reals.push_back("DiffuseAlpha");
|
||||||
|
|
|
@ -710,7 +710,7 @@ void TextureRegionEditor::_edit_region() {
|
||||||
autoslice_cache.erase(F->next());
|
autoslice_cache.erase(F->next());
|
||||||
} else {
|
} else {
|
||||||
queue_erase = true;
|
queue_erase = true;
|
||||||
//Cant delete the first rect in the list.
|
//Can't delete the first rect in the list.
|
||||||
}
|
}
|
||||||
merged = true;
|
merged = true;
|
||||||
}
|
}
|
||||||
|
|
|
@ -1570,7 +1570,7 @@ void SceneTreeDock::_normalize_drop(Node *&to_node, int &to_pos, int p_type) {
|
||||||
//drop at below selected node
|
//drop at below selected node
|
||||||
if (to_node == EditorNode::get_singleton()->get_edited_scene()) {
|
if (to_node == EditorNode::get_singleton()->get_edited_scene()) {
|
||||||
//if at lower sibling of root node
|
//if at lower sibling of root node
|
||||||
to_pos = 0; //just insert at begining of root node
|
to_pos = 0; //just insert at beginning of root node
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -299,7 +299,7 @@ public:
|
||||||
richtext->push_color(Color(0, 1.0, 0.5));
|
richtext->push_color(Color(0, 1.0, 0.5));
|
||||||
richtext->add_text("faeries.\n");
|
richtext->add_text("faeries.\n");
|
||||||
richtext->pop();
|
richtext->pop();
|
||||||
richtext->add_text("In this new episode, we will attemp to ");
|
richtext->add_text("In this new episode, we will attempt to ");
|
||||||
richtext->push_font(richtext->get_font("mono_font", "Fonts"));
|
richtext->push_font(richtext->get_font("mono_font", "Fonts"));
|
||||||
richtext->push_color(Color(0.7, 0.5, 1.0));
|
richtext->push_color(Color(0.7, 0.5, 1.0));
|
||||||
richtext->add_text("deliver something nice");
|
richtext->add_text("deliver something nice");
|
||||||
|
|
|
@ -1573,9 +1573,9 @@ def no_verbose(sys, env):
|
||||||
def detect_visual_c_compiler_version(tools_env):
|
def detect_visual_c_compiler_version(tools_env):
|
||||||
# tools_env is the variable scons uses to call tools that execute tasks, SCons's env['ENV'] that executes tasks...
|
# tools_env is the variable scons uses to call tools that execute tasks, SCons's env['ENV'] that executes tasks...
|
||||||
# (see the SCons documentation for more information on what it does)...
|
# (see the SCons documentation for more information on what it does)...
|
||||||
# in order for this function to be well encapsulated i choose to force it to recieve SCons's TOOLS env (env['ENV']
|
# in order for this function to be well encapsulated i choose to force it to receive SCons's TOOLS env (env['ENV']
|
||||||
# and not scons setup environment (env)... so make sure you call the right environment on it or it will fail to detect
|
# and not scons setup environment (env)... so make sure you call the right environment on it or it will fail to detect
|
||||||
# the propper vc version that will be called
|
# the proper vc version that will be called
|
||||||
|
|
||||||
# These is no flag to give to visual c compilers to set the architecture, ie scons bits argument (32,64,ARM etc)
|
# These is no flag to give to visual c compilers to set the architecture, ie scons bits argument (32,64,ARM etc)
|
||||||
# There are many different cl.exe files that are run, and each one compiles & links to a different architecture
|
# There are many different cl.exe files that are run, and each one compiles & links to a different architecture
|
||||||
|
|
|
@ -491,7 +491,7 @@ godot_variant GDAPI godot_instance_get(godot_instance p_instance, char *p_prop);
|
||||||
#define GODOT_PROPERTY_HINT_RANGE 1 ///< hint_text = "min,max,step,slider; //slider is optional"
|
#define GODOT_PROPERTY_HINT_RANGE 1 ///< hint_text = "min,max,step,slider; //slider is optional"
|
||||||
#define GODOT_PROPERTY_HINT_EXP_RANGE 2 ///< hint_text = "min,max,step", exponential edit
|
#define GODOT_PROPERTY_HINT_EXP_RANGE 2 ///< hint_text = "min,max,step", exponential edit
|
||||||
#define GODOT_PROPERTY_HINT_ENUM 3 ///< hint_text= "val1,val2,val3,etc"
|
#define GODOT_PROPERTY_HINT_ENUM 3 ///< hint_text= "val1,val2,val3,etc"
|
||||||
#define GODOT_PROPERTY_HINT_EXP_EASING 4 /// exponential easing funciton (Math::ease)
|
#define GODOT_PROPERTY_HINT_EXP_EASING 4 /// exponential easing function (Math::ease)
|
||||||
#define GODOT_PROPERTY_HINT_LENGTH 5 ///< hint_text= "length" (as integer)
|
#define GODOT_PROPERTY_HINT_LENGTH 5 ///< hint_text= "length" (as integer)
|
||||||
#define GODOT_PROPERTY_HINT_SPRITE_FRAME 6
|
#define GODOT_PROPERTY_HINT_SPRITE_FRAME 6
|
||||||
#define GODOT_PROPERTY_HINT_KEY_ACCEL 7 ///< hint_text= "length" (as integer)
|
#define GODOT_PROPERTY_HINT_KEY_ACCEL 7 ///< hint_text= "length" (as integer)
|
||||||
|
|
|
@ -253,13 +253,13 @@ RES ResourceFormatDDS::load(const String &p_path, const String &p_original_path,
|
||||||
uint32_t size = pitch * height;
|
uint32_t size = pitch * height;
|
||||||
ERR_FAIL_COND_V(size != width * height * info.block_size, RES());
|
ERR_FAIL_COND_V(size != width * height * info.block_size, RES());
|
||||||
|
|
||||||
uint8_t pallete[256 * 4];
|
uint8_t palette[256 * 4];
|
||||||
f->get_buffer(pallete, 256 * 4);
|
f->get_buffer(palette, 256 * 4);
|
||||||
|
|
||||||
int colsize = 3;
|
int colsize = 3;
|
||||||
for (int i = 0; i < 256; i++) {
|
for (int i = 0; i < 256; i++) {
|
||||||
|
|
||||||
if (pallete[i * 4 + 3] < 255)
|
if (palette[i * 4 + 3] < 255)
|
||||||
colsize = 4;
|
colsize = 4;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -281,11 +281,11 @@ RES ResourceFormatDDS::load(const String &p_path, const String &p_original_path,
|
||||||
|
|
||||||
int dst_ofs = size + i * colsize;
|
int dst_ofs = size + i * colsize;
|
||||||
int src_ofs = i * 4;
|
int src_ofs = i * 4;
|
||||||
wb[dst_ofs + 0] = pallete[src_ofs + 2];
|
wb[dst_ofs + 0] = palette[src_ofs + 2];
|
||||||
wb[dst_ofs + 1] = pallete[src_ofs + 1];
|
wb[dst_ofs + 1] = palette[src_ofs + 1];
|
||||||
wb[dst_ofs + 2] = pallete[src_ofs + 0];
|
wb[dst_ofs + 2] = palette[src_ofs + 0];
|
||||||
if (colsize == 4)
|
if (colsize == 4)
|
||||||
wb[dst_ofs + 3] = pallete[src_ofs + 3];
|
wb[dst_ofs + 3] = palette[src_ofs + 3];
|
||||||
}
|
}
|
||||||
|
|
||||||
wb = PoolVector<uint8_t>::Write();
|
wb = PoolVector<uint8_t>::Write();
|
||||||
|
|
|
@ -1539,7 +1539,7 @@ Error GDCompiler::_parse_function(GDScript *p_script, const GDParser::ClassNode
|
||||||
signature += "::0";
|
signature += "::0";
|
||||||
}
|
}
|
||||||
|
|
||||||
//funciton and class
|
//function and class
|
||||||
|
|
||||||
if (p_class->name) {
|
if (p_class->name) {
|
||||||
signature += "::" + String(p_class->name) + "." + String(func_name);
|
signature += "::" + String(p_class->name) + "." + String(func_name);
|
||||||
|
@ -1660,7 +1660,7 @@ Error GDCompiler::_parse_class(GDScript *p_script, GDScript *p_owner, const GDPa
|
||||||
String sub = p_class->extends_class[i];
|
String sub = p_class->extends_class[i];
|
||||||
if (script->subclasses.has(sub)) {
|
if (script->subclasses.has(sub)) {
|
||||||
|
|
||||||
Ref<Script> subclass = script->subclasses[sub]; //avoid reference from dissapearing
|
Ref<Script> subclass = script->subclasses[sub]; //avoid reference from disappearing
|
||||||
script = subclass;
|
script = subclass;
|
||||||
} else {
|
} else {
|
||||||
|
|
||||||
|
|
|
@ -1070,7 +1070,7 @@ static bool _guess_identifier_type(GDCompletionContext &context, int p_line, con
|
||||||
//return _guess_expression_type(context,context._class->variables[i].expression,context._class->variables[i].line,r_type);
|
//return _guess_expression_type(context,context._class->variables[i].expression,context._class->variables[i].line,r_type);
|
||||||
}
|
}
|
||||||
|
|
||||||
//try to guess from assignment in construtor or _ready
|
//try to guess from assignment in constructor or _ready
|
||||||
if (_guess_identifier_from_assignment_in_function(context, p_line + 1, p_identifier, "_ready", r_type))
|
if (_guess_identifier_from_assignment_in_function(context, p_line + 1, p_identifier, "_ready", r_type))
|
||||||
return true;
|
return true;
|
||||||
if (_guess_identifier_from_assignment_in_function(context, p_line + 1, p_identifier, "_enter_tree", r_type))
|
if (_guess_identifier_from_assignment_in_function(context, p_line + 1, p_identifier, "_enter_tree", r_type))
|
||||||
|
|
|
@ -1021,7 +1021,7 @@ GDParser::Node *GDParser::_parse_expression(Node *p_parent, bool p_static, bool
|
||||||
OperatorNode::Operator op;
|
OperatorNode::Operator op;
|
||||||
bool valid = true;
|
bool valid = true;
|
||||||
|
|
||||||
//assign, if allowed is only alowed on the first operator
|
//assign, if allowed is only allowed on the first operator
|
||||||
#define _VALIDATE_ASSIGN \
|
#define _VALIDATE_ASSIGN \
|
||||||
if (!p_allow_assign) { \
|
if (!p_allow_assign) { \
|
||||||
_set_error("Unexpected assign."); \
|
_set_error("Unexpected assign."); \
|
||||||
|
@ -1253,7 +1253,7 @@ GDParser::Node *GDParser::_parse_expression(Node *p_parent, bool p_static, bool
|
||||||
// this is not invalid and can really appear
|
// this is not invalid and can really appear
|
||||||
// but it becomes invalid anyway because no binary op
|
// but it becomes invalid anyway because no binary op
|
||||||
// can be followed by an unary op in a valid combination,
|
// can be followed by an unary op in a valid combination,
|
||||||
// due to how precedence works, unaries will always dissapear first
|
// due to how precedence works, unaries will always disappear first
|
||||||
|
|
||||||
_set_error("Unexpected two consecutive operators after ternary if.");
|
_set_error("Unexpected two consecutive operators after ternary if.");
|
||||||
return NULL;
|
return NULL;
|
||||||
|
@ -1263,7 +1263,7 @@ GDParser::Node *GDParser::_parse_expression(Node *p_parent, bool p_static, bool
|
||||||
// this is not invalid and can really appear
|
// this is not invalid and can really appear
|
||||||
// but it becomes invalid anyway because no binary op
|
// but it becomes invalid anyway because no binary op
|
||||||
// can be followed by an unary op in a valid combination,
|
// can be followed by an unary op in a valid combination,
|
||||||
// due to how precedence works, unaries will always dissapear first
|
// due to how precedence works, unaries will always disappear first
|
||||||
|
|
||||||
_set_error("Unexpected two consecutive operators after ternary else.");
|
_set_error("Unexpected two consecutive operators after ternary else.");
|
||||||
return NULL;
|
return NULL;
|
||||||
|
@ -1300,7 +1300,7 @@ GDParser::Node *GDParser::_parse_expression(Node *p_parent, bool p_static, bool
|
||||||
// this is not invalid and can really appear
|
// this is not invalid and can really appear
|
||||||
// but it becomes invalid anyway because no binary op
|
// but it becomes invalid anyway because no binary op
|
||||||
// can be followed by an unary op in a valid combination,
|
// can be followed by an unary op in a valid combination,
|
||||||
// due to how precedence works, unaries will always dissapear first
|
// due to how precedence works, unaries will always disappear first
|
||||||
|
|
||||||
_set_error("Unexpected two consecutive operators.");
|
_set_error("Unexpected two consecutive operators.");
|
||||||
return NULL;
|
return NULL;
|
||||||
|
|
|
@ -532,7 +532,7 @@ bool GDScript::_update_exports() {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
//print_line("unchaged is "+get_path());
|
//print_line("unchanged is "+get_path());
|
||||||
}
|
}
|
||||||
|
|
||||||
if (base_cache.is_valid()) {
|
if (base_cache.is_valid()) {
|
||||||
|
@ -1271,7 +1271,7 @@ void GDInstance::call_multilevel_reversed(const StringName &p_method, const Vari
|
||||||
|
|
||||||
void GDInstance::notification(int p_notification) {
|
void GDInstance::notification(int p_notification) {
|
||||||
|
|
||||||
//notification is not virutal, it gets called at ALL levels just like in C.
|
//notification is not virtual, it gets called at ALL levels just like in C.
|
||||||
Variant value = p_notification;
|
Variant value = p_notification;
|
||||||
const Variant *args[1] = { &value };
|
const Variant *args[1] = { &value };
|
||||||
|
|
||||||
|
|
|
@ -180,7 +180,7 @@ void AudioStreamOGGVorbis::set_data(const PoolVector<uint8_t> &p_data) {
|
||||||
//does this work? (it's less mem..)
|
//does this work? (it's less mem..)
|
||||||
//decode_mem_size = ogg_alloc.alloc_buffer_length_in_bytes + info.setup_memory_required + info.temp_memory_required + info.max_frame_size;
|
//decode_mem_size = ogg_alloc.alloc_buffer_length_in_bytes + info.setup_memory_required + info.temp_memory_required + info.max_frame_size;
|
||||||
|
|
||||||
//print_line("succeded "+itos(ogg_alloc.alloc_buffer_length_in_bytes)+" setup "+itos(info.setup_memory_required)+" setup temp "+itos(info.setup_temp_memory_required)+" temp "+itos(info.temp_memory_required)+" maxframe"+itos(info.max_frame_size));
|
//print_line("succeeded "+itos(ogg_alloc.alloc_buffer_length_in_bytes)+" setup "+itos(info.setup_memory_required)+" setup temp "+itos(info.setup_temp_memory_required)+" temp "+itos(info.temp_memory_required)+" maxframe"+itos(info.max_frame_size));
|
||||||
|
|
||||||
length = stb_vorbis_stream_length_in_seconds(ogg_stream);
|
length = stb_vorbis_stream_length_in_seconds(ogg_stream);
|
||||||
stb_vorbis_close(ogg_stream);
|
stb_vorbis_close(ogg_stream);
|
||||||
|
|
|
@ -1489,7 +1489,7 @@ Variant VisualScriptInstance::_call_internal(const StringName &p_method, void *p
|
||||||
VSDEBUG("WORKING MEM: " + itos(node->working_mem_idx));
|
VSDEBUG("WORKING MEM: " + itos(node->working_mem_idx));
|
||||||
|
|
||||||
if (current_node_id == f->node) {
|
if (current_node_id == f->node) {
|
||||||
//if function node, set up function arguments from begining of stack
|
//if function node, set up function arguments from beginning of stack
|
||||||
|
|
||||||
for (int i = 0; i < f->argument_count; i++) {
|
for (int i = 0; i < f->argument_count; i++) {
|
||||||
input_args[i] = &variant_stack[i];
|
input_args[i] = &variant_stack[i];
|
||||||
|
|
|
@ -1180,7 +1180,7 @@ VisualScriptExpression::ENode *VisualScriptExpression::_parse_expression() {
|
||||||
// this is not invalid and can really appear
|
// this is not invalid and can really appear
|
||||||
// but it becomes invalid anyway because no binary op
|
// but it becomes invalid anyway because no binary op
|
||||||
// can be followed by an unary op in a valid combination,
|
// can be followed by an unary op in a valid combination,
|
||||||
// due to how precedence works, unaries will always dissapear first
|
// due to how precedence works, unaries will always disappear first
|
||||||
|
|
||||||
_set_error("Unexpected two consecutive operators.");
|
_set_error("Unexpected two consecutive operators.");
|
||||||
return NULL;
|
return NULL;
|
||||||
|
|
|
@ -20,7 +20,7 @@ package com.google.android.vending.licensing;
|
||||||
* Interface used as part of a {@link Policy} to allow application authors to obfuscate
|
* Interface used as part of a {@link Policy} to allow application authors to obfuscate
|
||||||
* licensing data that will be stored into a SharedPreferences file.
|
* licensing data that will be stored into a SharedPreferences file.
|
||||||
* <p>
|
* <p>
|
||||||
* Any transformation scheme must be reversable. Implementing classes may optionally implement an
|
* Any transformation scheme must be reversible. Implementing classes may optionally implement an
|
||||||
* integrity check to further prevent modification to preference data. Implementing classes
|
* integrity check to further prevent modification to preference data. Implementing classes
|
||||||
* should use device-specific information as a key in the obfuscation algorithm to prevent
|
* should use device-specific information as a key in the obfuscation algorithm to prevent
|
||||||
* obfuscated preferences from being shared among devices.
|
* obfuscated preferences from being shared among devices.
|
||||||
|
|
|
@ -340,7 +340,7 @@ public class Godot extends Activity implements SensorEventListener, IDownloaderC
|
||||||
r = is.read(len);
|
r = is.read(len);
|
||||||
if (r<4) {
|
if (r<4) {
|
||||||
|
|
||||||
Log.d("GODOT", "**ERROR** Wrong cmdline param lenght.\n");
|
Log.d("GODOT", "**ERROR** Wrong cmdline param length.\n");
|
||||||
return new String[0];
|
return new String[0];
|
||||||
}
|
}
|
||||||
int strlen=((int)(len[3]&0xFF)<<24) | ((int)(len[2]&0xFF)<<16) | ((int)(len[1]&0xFF)<<8) | ((int)(len[0]&0xFF));
|
int strlen=((int)(len[3]&0xFF)<<24) | ((int)(len[2]&0xFF)<<16) | ((int)(len[1]&0xFF)<<8) | ((int)(len[0]&0xFF));
|
||||||
|
|
|
@ -469,7 +469,7 @@ public class GodotIO {
|
||||||
}
|
}
|
||||||
|
|
||||||
/////////////////////////
|
/////////////////////////
|
||||||
// MISCELANEOUS OS IO
|
// MISCELLANEOUS OS IO
|
||||||
/////////////////////////
|
/////////////////////////
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -68,9 +68,9 @@ class JavaClass : public Reference {
|
||||||
jmethodID method;
|
jmethodID method;
|
||||||
};
|
};
|
||||||
|
|
||||||
_FORCE_INLINE_ static void _convert_to_variant_type(int p_sig, Variant::Type &r_type, float &likelyhood) {
|
_FORCE_INLINE_ static void _convert_to_variant_type(int p_sig, Variant::Type &r_type, float &likelihood) {
|
||||||
|
|
||||||
likelyhood = 1.0;
|
likelihood = 1.0;
|
||||||
r_type = Variant::NIL;
|
r_type = Variant::NIL;
|
||||||
|
|
||||||
switch (p_sig) {
|
switch (p_sig) {
|
||||||
|
@ -81,37 +81,37 @@ class JavaClass : public Reference {
|
||||||
case ARG_TYPE_BYTE | ARG_NUMBER_CLASS_BIT:
|
case ARG_TYPE_BYTE | ARG_NUMBER_CLASS_BIT:
|
||||||
case ARG_TYPE_BYTE:
|
case ARG_TYPE_BYTE:
|
||||||
r_type = Variant::INT;
|
r_type = Variant::INT;
|
||||||
likelyhood = 0.1;
|
likelihood = 0.1;
|
||||||
break;
|
break;
|
||||||
case ARG_TYPE_CHAR | ARG_NUMBER_CLASS_BIT:
|
case ARG_TYPE_CHAR | ARG_NUMBER_CLASS_BIT:
|
||||||
case ARG_TYPE_CHAR:
|
case ARG_TYPE_CHAR:
|
||||||
r_type = Variant::INT;
|
r_type = Variant::INT;
|
||||||
likelyhood = 0.2;
|
likelihood = 0.2;
|
||||||
break;
|
break;
|
||||||
case ARG_TYPE_SHORT | ARG_NUMBER_CLASS_BIT:
|
case ARG_TYPE_SHORT | ARG_NUMBER_CLASS_BIT:
|
||||||
case ARG_TYPE_SHORT:
|
case ARG_TYPE_SHORT:
|
||||||
r_type = Variant::INT;
|
r_type = Variant::INT;
|
||||||
likelyhood = 0.3;
|
likelihood = 0.3;
|
||||||
break;
|
break;
|
||||||
case ARG_TYPE_INT | ARG_NUMBER_CLASS_BIT:
|
case ARG_TYPE_INT | ARG_NUMBER_CLASS_BIT:
|
||||||
case ARG_TYPE_INT:
|
case ARG_TYPE_INT:
|
||||||
r_type = Variant::INT;
|
r_type = Variant::INT;
|
||||||
likelyhood = 1.0;
|
likelihood = 1.0;
|
||||||
break;
|
break;
|
||||||
case ARG_TYPE_LONG | ARG_NUMBER_CLASS_BIT:
|
case ARG_TYPE_LONG | ARG_NUMBER_CLASS_BIT:
|
||||||
case ARG_TYPE_LONG:
|
case ARG_TYPE_LONG:
|
||||||
r_type = Variant::INT;
|
r_type = Variant::INT;
|
||||||
likelyhood = 0.5;
|
likelihood = 0.5;
|
||||||
break;
|
break;
|
||||||
case ARG_TYPE_FLOAT | ARG_NUMBER_CLASS_BIT:
|
case ARG_TYPE_FLOAT | ARG_NUMBER_CLASS_BIT:
|
||||||
case ARG_TYPE_FLOAT:
|
case ARG_TYPE_FLOAT:
|
||||||
r_type = Variant::REAL;
|
r_type = Variant::REAL;
|
||||||
likelyhood = 1.0;
|
likelihood = 1.0;
|
||||||
break;
|
break;
|
||||||
case ARG_TYPE_DOUBLE | ARG_NUMBER_CLASS_BIT:
|
case ARG_TYPE_DOUBLE | ARG_NUMBER_CLASS_BIT:
|
||||||
case ARG_TYPE_DOUBLE:
|
case ARG_TYPE_DOUBLE:
|
||||||
r_type = Variant::REAL;
|
r_type = Variant::REAL;
|
||||||
likelyhood = 0.5;
|
likelihood = 0.5;
|
||||||
break;
|
break;
|
||||||
case ARG_TYPE_STRING: r_type = Variant::STRING; break;
|
case ARG_TYPE_STRING: r_type = Variant::STRING; break;
|
||||||
case ARG_TYPE_CLASS: r_type = Variant::OBJECT; break;
|
case ARG_TYPE_CLASS: r_type = Variant::OBJECT; break;
|
||||||
|
@ -119,31 +119,31 @@ class JavaClass : public Reference {
|
||||||
case ARG_ARRAY_BIT | ARG_TYPE_BOOLEAN: r_type = Variant::ARRAY; break;
|
case ARG_ARRAY_BIT | ARG_TYPE_BOOLEAN: r_type = Variant::ARRAY; break;
|
||||||
case ARG_ARRAY_BIT | ARG_TYPE_BYTE:
|
case ARG_ARRAY_BIT | ARG_TYPE_BYTE:
|
||||||
r_type = Variant::POOL_BYTE_ARRAY;
|
r_type = Variant::POOL_BYTE_ARRAY;
|
||||||
likelyhood = 1.0;
|
likelihood = 1.0;
|
||||||
break;
|
break;
|
||||||
case ARG_ARRAY_BIT | ARG_TYPE_CHAR:
|
case ARG_ARRAY_BIT | ARG_TYPE_CHAR:
|
||||||
r_type = Variant::POOL_BYTE_ARRAY;
|
r_type = Variant::POOL_BYTE_ARRAY;
|
||||||
likelyhood = 0.5;
|
likelihood = 0.5;
|
||||||
break;
|
break;
|
||||||
case ARG_ARRAY_BIT | ARG_TYPE_SHORT:
|
case ARG_ARRAY_BIT | ARG_TYPE_SHORT:
|
||||||
r_type = Variant::POOL_INT_ARRAY;
|
r_type = Variant::POOL_INT_ARRAY;
|
||||||
likelyhood = 0.3;
|
likelihood = 0.3;
|
||||||
break;
|
break;
|
||||||
case ARG_ARRAY_BIT | ARG_TYPE_INT:
|
case ARG_ARRAY_BIT | ARG_TYPE_INT:
|
||||||
r_type = Variant::POOL_INT_ARRAY;
|
r_type = Variant::POOL_INT_ARRAY;
|
||||||
likelyhood = 1.0;
|
likelihood = 1.0;
|
||||||
break;
|
break;
|
||||||
case ARG_ARRAY_BIT | ARG_TYPE_LONG:
|
case ARG_ARRAY_BIT | ARG_TYPE_LONG:
|
||||||
r_type = Variant::POOL_INT_ARRAY;
|
r_type = Variant::POOL_INT_ARRAY;
|
||||||
likelyhood = 0.5;
|
likelihood = 0.5;
|
||||||
break;
|
break;
|
||||||
case ARG_ARRAY_BIT | ARG_TYPE_FLOAT:
|
case ARG_ARRAY_BIT | ARG_TYPE_FLOAT:
|
||||||
r_type = Variant::POOL_REAL_ARRAY;
|
r_type = Variant::POOL_REAL_ARRAY;
|
||||||
likelyhood = 1.0;
|
likelihood = 1.0;
|
||||||
break;
|
break;
|
||||||
case ARG_ARRAY_BIT | ARG_TYPE_DOUBLE:
|
case ARG_ARRAY_BIT | ARG_TYPE_DOUBLE:
|
||||||
r_type = Variant::POOL_REAL_ARRAY;
|
r_type = Variant::POOL_REAL_ARRAY;
|
||||||
likelyhood = 0.5;
|
likelihood = 0.5;
|
||||||
break;
|
break;
|
||||||
case ARG_ARRAY_BIT | ARG_TYPE_STRING: r_type = Variant::POOL_STRING_ARRAY; break;
|
case ARG_ARRAY_BIT | ARG_TYPE_STRING: r_type = Variant::POOL_STRING_ARRAY; break;
|
||||||
case ARG_ARRAY_BIT | ARG_TYPE_CLASS: r_type = Variant::ARRAY; break;
|
case ARG_ARRAY_BIT | ARG_TYPE_CLASS: r_type = Variant::ARRAY; break;
|
||||||
|
|
|
@ -881,7 +881,7 @@ JNIEXPORT void JNICALL Java_org_godotengine_godot_GodotLib_initialize(JNIEnv *en
|
||||||
|
|
||||||
__android_log_print(ANDROID_LOG_INFO, "godot", "*****SETUP OK");
|
__android_log_print(ANDROID_LOG_INFO, "godot", "*****SETUP OK");
|
||||||
|
|
||||||
//video driver is determined here, because once initialized, it cant be changed
|
//video driver is determined here, because once initialized, it can't be changed
|
||||||
String vd = GlobalConfig::get_singleton()->get("display/driver");
|
String vd = GlobalConfig::get_singleton()->get("display/driver");
|
||||||
|
|
||||||
env->CallVoidMethod(_godot_instance, _on_video_init, (jboolean) true);
|
env->CallVoidMethod(_godot_instance, _on_video_init, (jboolean) true);
|
||||||
|
|
|
@ -289,7 +289,7 @@ void HaikuDirectWindow::HandleKeyboardEvent(BMessage *message) {
|
||||||
event.key.unicode = BUnicodeChar::FromUTF8(&bytes);
|
event.key.unicode = BUnicodeChar::FromUTF8(&bytes);
|
||||||
}
|
}
|
||||||
|
|
||||||
//make it consistent accross platforms.
|
//make it consistent across platforms.
|
||||||
if (event.key.scancode == KEY_BACKTAB) {
|
if (event.key.scancode == KEY_BACKTAB) {
|
||||||
event.key.scancode = KEY_TAB;
|
event.key.scancode = KEY_TAB;
|
||||||
event.key.mod.shift = true;
|
event.key.mod.shift = true;
|
||||||
|
|
|
@ -331,7 +331,7 @@ static void clear_touches() {
|
||||||
glBindFramebufferOES(GL_FRAMEBUFFER_OES, viewFramebuffer);
|
glBindFramebufferOES(GL_FRAMEBUFFER_OES, viewFramebuffer);
|
||||||
glBindRenderbufferOES(GL_RENDERBUFFER_OES, viewRenderbuffer);
|
glBindRenderbufferOES(GL_RENDERBUFFER_OES, viewRenderbuffer);
|
||||||
// This call associates the storage for the current render buffer with the EAGLDrawable (our CAEAGLLayer)
|
// This call associates the storage for the current render buffer with the EAGLDrawable (our CAEAGLLayer)
|
||||||
// allowing us to draw into a buffer that will later be rendered to screen whereever the layer is (which corresponds with our view).
|
// allowing us to draw into a buffer that will later be rendered to screen wherever the layer is (which corresponds with our view).
|
||||||
[context renderbufferStorage:GL_RENDERBUFFER_OES fromDrawable:(id<EAGLDrawable>)self.layer];
|
[context renderbufferStorage:GL_RENDERBUFFER_OES fromDrawable:(id<EAGLDrawable>)self.layer];
|
||||||
glFramebufferRenderbufferOES(GL_FRAMEBUFFER_OES, GL_COLOR_ATTACHMENT0_OES, GL_RENDERBUFFER_OES, viewRenderbuffer);
|
glFramebufferRenderbufferOES(GL_FRAMEBUFFER_OES, GL_COLOR_ATTACHMENT0_OES, GL_RENDERBUFFER_OES, viewRenderbuffer);
|
||||||
|
|
||||||
|
|
|
@ -1867,7 +1867,7 @@ void RasterizerIPhone::_setup_light(LightInstance *p_instance, int p_idx) {
|
||||||
switch (ld->type) {
|
switch (ld->type) {
|
||||||
|
|
||||||
case VS::LIGHT_DIRECTIONAL: {
|
case VS::LIGHT_DIRECTIONAL: {
|
||||||
/* This doesnt have attenuation */
|
/* This doesn't have attenuation */
|
||||||
|
|
||||||
glMatrixMode(GL_MODELVIEW);
|
glMatrixMode(GL_MODELVIEW);
|
||||||
glPushMatrix();
|
glPushMatrix();
|
||||||
|
@ -2088,7 +2088,7 @@ void RasterizerIPhone::_render_list_forward(RenderList *p_render_list) {
|
||||||
uint64_t prev_light_hash = 0;
|
uint64_t prev_light_hash = 0;
|
||||||
const Skeleton *prev_skeleton = NULL;
|
const Skeleton *prev_skeleton = NULL;
|
||||||
const Geometry *prev_geometry = NULL;
|
const Geometry *prev_geometry = NULL;
|
||||||
const ParamOverrideMap *prev_overrides = NULL; // make it diferent than NULL
|
const ParamOverrideMap *prev_overrides = NULL; // make it different than NULL
|
||||||
|
|
||||||
Geometry::Type prev_geometry_type = Geometry::GEOMETRY_INVALID;
|
Geometry::Type prev_geometry_type = Geometry::GEOMETRY_INVALID;
|
||||||
|
|
||||||
|
|
|
@ -169,7 +169,7 @@ Error ContextGL_Win::initialize() {
|
||||||
|
|
||||||
if (wglCreateContextAttribsARB == NULL) //OpenGL 3.0 is not supported
|
if (wglCreateContextAttribsARB == NULL) //OpenGL 3.0 is not supported
|
||||||
{
|
{
|
||||||
MessageBox(NULL, "Cannot get Proc Adress for CreateContextAttribs", "ERROR", MB_OK | MB_ICONEXCLAMATION);
|
MessageBox(NULL, "Cannot get Proc Address for CreateContextAttribs", "ERROR", MB_OK | MB_ICONEXCLAMATION);
|
||||||
wglDeleteContext(hRC);
|
wglDeleteContext(hRC);
|
||||||
return ERR_CANT_CREATE;
|
return ERR_CANT_CREATE;
|
||||||
}
|
}
|
||||||
|
|
|
@ -283,7 +283,7 @@ def configure(env):
|
||||||
+ " will be executed and inform you.")
|
+ " will be executed and inform you.")
|
||||||
sys.exit()
|
sys.exit()
|
||||||
|
|
||||||
# Forcing bits argument because MSVC does not have a flag to set this through SCons... it's different compilers (cl.exe's) called from the propper command prompt
|
# Forcing bits argument because MSVC does not have a flag to set this through SCons... it's different compilers (cl.exe's) called from the proper command prompt
|
||||||
# that decide the architecture that is build for. Scons can only detect the os.getenviron (because vsvarsall.bat sets a lot of stuff for cl.exe to work with)
|
# that decide the architecture that is build for. Scons can only detect the os.getenviron (because vsvarsall.bat sets a lot of stuff for cl.exe to work with)
|
||||||
env["bits"] = "32"
|
env["bits"] = "32"
|
||||||
env["x86_libtheora_opt_vc"] = True
|
env["x86_libtheora_opt_vc"] = True
|
||||||
|
|
|
@ -1019,7 +1019,7 @@ void OS_X11::handle_key_event(XKeyEvent *p_event, bool p_echo) {
|
||||||
// XKeycodeToKeysym to obtain internationalized
|
// XKeycodeToKeysym to obtain internationalized
|
||||||
// input.. WRONG!!
|
// input.. WRONG!!
|
||||||
// you must use XLookupString (???) which not only wastes
|
// you must use XLookupString (???) which not only wastes
|
||||||
// cycles generating an unnecesary string, but also
|
// cycles generating an unnecessary string, but also
|
||||||
// still works in half the cases. (won't handle deadkeys)
|
// still works in half the cases. (won't handle deadkeys)
|
||||||
// For more complex input methods (deadkeys and more advanced)
|
// For more complex input methods (deadkeys and more advanced)
|
||||||
// you have to use XmbLookupString (??).
|
// you have to use XmbLookupString (??).
|
||||||
|
@ -1075,7 +1075,7 @@ void OS_X11::handle_key_event(XKeyEvent *p_event, bool p_echo) {
|
||||||
/* Phase 4, determine if event must be filtered */
|
/* Phase 4, determine if event must be filtered */
|
||||||
|
|
||||||
// This seems to be a side-effect of using XIM.
|
// This seems to be a side-effect of using XIM.
|
||||||
// XEventFilter looks like a core X11 funciton,
|
// XEventFilter looks like a core X11 function,
|
||||||
// but it's actually just used to see if we must
|
// but it's actually just used to see if we must
|
||||||
// ignore a deadkey, or events XIM determines
|
// ignore a deadkey, or events XIM determines
|
||||||
// must not reach the actual gui.
|
// must not reach the actual gui.
|
||||||
|
@ -1157,7 +1157,7 @@ void OS_X11::handle_key_event(XKeyEvent *p_event, bool p_echo) {
|
||||||
event.key.echo = p_echo;
|
event.key.echo = p_echo;
|
||||||
|
|
||||||
if (event.key.scancode == KEY_BACKTAB) {
|
if (event.key.scancode == KEY_BACKTAB) {
|
||||||
//make it consistent accross platforms.
|
//make it consistent across platforms.
|
||||||
event.key.scancode = KEY_TAB;
|
event.key.scancode = KEY_TAB;
|
||||||
event.key.mod.shift = true;
|
event.key.mod.shift = true;
|
||||||
}
|
}
|
||||||
|
|
|
@ -515,7 +515,7 @@ void LineBuilder::strip_add_arc(Vector2 center, float angle_delta, Orientation o
|
||||||
void LineBuilder::new_arc(Vector2 center, Vector2 vbegin, float angle_delta, Color color, Rect2 uv_rect) {
|
void LineBuilder::new_arc(Vector2 center, Vector2 vbegin, float angle_delta, Color color, Rect2 uv_rect) {
|
||||||
|
|
||||||
// Make a standalone arc that doesn't use existing vertices,
|
// Make a standalone arc that doesn't use existing vertices,
|
||||||
// with undistorted UVs from withing a square section
|
// with undistorted UVs from within a square section
|
||||||
|
|
||||||
float radius = vbegin.length();
|
float radius = vbegin.length();
|
||||||
float angle_step = Math_PI / static_cast<float>(round_precision);
|
float angle_step = Math_PI / static_cast<float>(round_precision);
|
||||||
|
|
|
@ -98,7 +98,7 @@ void BoxContainer::_resort() {
|
||||||
elements exist */
|
elements exist */
|
||||||
|
|
||||||
bool has_stretched = false;
|
bool has_stretched = false;
|
||||||
while (stretch_ratio_total > 0) { // first of all, dont even be here if no stretchable objects exist
|
while (stretch_ratio_total > 0) { // first of all, don't even be here if no stretchable objects exist
|
||||||
|
|
||||||
has_stretched = true;
|
has_stretched = true;
|
||||||
bool refit_successful = true; //assume refit-test will go well
|
bool refit_successful = true; //assume refit-test will go well
|
||||||
|
|
|
@ -485,7 +485,7 @@ void Control::_notification(int p_notification) {
|
||||||
} break;
|
} break;
|
||||||
case NOTIFICATION_MOVED_IN_PARENT: {
|
case NOTIFICATION_MOVED_IN_PARENT: {
|
||||||
// some parents need to know the order of the childrens to draw (like TabContainer)
|
// some parents need to know the order of the childrens to draw (like TabContainer)
|
||||||
// update if necesary
|
// update if necessary
|
||||||
if (data.parent)
|
if (data.parent)
|
||||||
data.parent->update();
|
data.parent->update();
|
||||||
update();
|
update();
|
||||||
|
|
|
@ -42,7 +42,7 @@ void WindowDialog::_post_popup() {
|
||||||
|
|
||||||
void WindowDialog::_fix_size() {
|
void WindowDialog::_fix_size() {
|
||||||
|
|
||||||
// Perhaps this should be called when the viewport resizes aswell or windows go out of bounds...
|
// Perhaps this should be called when the viewport resizes as well or windows go out of bounds...
|
||||||
|
|
||||||
// Ensure the whole window is visible.
|
// Ensure the whole window is visible.
|
||||||
Point2i pos = get_global_pos();
|
Point2i pos = get_global_pos();
|
||||||
|
|
|
@ -125,7 +125,7 @@ void RichTextLabel::_process_line(ItemFrame *p_frame, const Vector2 &p_ofs, int
|
||||||
if (cfont.is_null())
|
if (cfont.is_null())
|
||||||
cfont = p_base_font;
|
cfont = p_base_font;
|
||||||
|
|
||||||
//line height should be the font height for the first time, this ensures that an empty line will never have zero height and succesive newlines are displayed
|
//line height should be the font height for the first time, this ensures that an empty line will never have zero height and successive newlines are displayed
|
||||||
int line_height = cfont->get_height();
|
int line_height = cfont->get_height();
|
||||||
|
|
||||||
Variant meta;
|
Variant meta;
|
||||||
|
|
|
@ -705,7 +705,7 @@ void ScrollBar::mouse_motion(const Point2& p_pos, const Point2& p_rel, int b.but
|
||||||
if (value_ofs>(get_max()-get_page()))
|
if (value_ofs>(get_max()-get_page()))
|
||||||
value_ofs=get_max()-get_page();
|
value_ofs=get_max()-get_page();
|
||||||
if (get_val()==value_ofs)
|
if (get_val()==value_ofs)
|
||||||
return; //dont bother if the value is the same
|
return; //don't bother if the value is the same
|
||||||
|
|
||||||
set_val( value_ofs );
|
set_val( value_ofs );
|
||||||
|
|
||||||
|
|
|
@ -2912,7 +2912,7 @@ int Tree::get_column_width(int p_column) const {
|
||||||
if (expand_area < expanding_total)
|
if (expand_area < expanding_total)
|
||||||
return columns[p_column].min_width;
|
return columns[p_column].min_width;
|
||||||
|
|
||||||
ERR_FAIL_COND_V(expanding_columns == 0, -1); // shouldnt happen
|
ERR_FAIL_COND_V(expanding_columns == 0, -1); // shouldn't happen
|
||||||
|
|
||||||
return expand_area * columns[p_column].min_width / expanding_total;
|
return expand_area * columns[p_column].min_width / expanding_total;
|
||||||
}
|
}
|
||||||
|
|
|
@ -136,7 +136,7 @@ RES ResourceFormatLoaderWAV::load(const String &p_path, const String& p_original
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Dont need anything else, continue */
|
/* Don't need anything else, continue */
|
||||||
format_found=true;
|
format_found=true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -573,7 +573,7 @@ bool SceneTree::idle(float p_time) {
|
||||||
}
|
}
|
||||||
|
|
||||||
_flush_ugc();
|
_flush_ugc();
|
||||||
_flush_transform_notifications(); //transforms after world update, to avoid unnecesary enter/exit notifications
|
_flush_transform_notifications(); //transforms after world update, to avoid unnecessary enter/exit notifications
|
||||||
call_group_flags(GROUP_CALL_REALTIME, "_viewports", "update_worlds");
|
call_group_flags(GROUP_CALL_REALTIME, "_viewports", "update_worlds");
|
||||||
|
|
||||||
root_lock--;
|
root_lock--;
|
||||||
|
|
|
@ -289,7 +289,7 @@ void AudioStreamPlaybackSample::mix(AudioFrame *p_buffer, float p_rate_scale, in
|
||||||
offset = loop_end_fp - (loop_begin_fp - offset);
|
offset = loop_end_fp - (loop_begin_fp - offset);
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
/* check for sample not reaching begining */
|
/* check for sample not reaching beginning */
|
||||||
if (offset < 0) {
|
if (offset < 0) {
|
||||||
|
|
||||||
active = false;
|
active = false;
|
||||||
|
|
|
@ -135,7 +135,7 @@ public:
|
||||||
|
|
||||||
float get_baked_length() const;
|
float get_baked_length() const;
|
||||||
Vector2 interpolate_baked(float p_offset, bool p_cubic = false) const;
|
Vector2 interpolate_baked(float p_offset, bool p_cubic = false) const;
|
||||||
PoolVector2Array get_baked_points() const; //useful for going thru
|
PoolVector2Array get_baked_points() const; //useful for going through
|
||||||
|
|
||||||
PoolVector2Array tesselate(int p_max_stages = 5, float p_tolerance = 4) const; //useful for display
|
PoolVector2Array tesselate(int p_max_stages = 5, float p_tolerance = 4) const; //useful for display
|
||||||
|
|
||||||
|
@ -203,8 +203,8 @@ public:
|
||||||
float get_baked_length() const;
|
float get_baked_length() const;
|
||||||
Vector3 interpolate_baked(float p_offset, bool p_cubic = false) const;
|
Vector3 interpolate_baked(float p_offset, bool p_cubic = false) const;
|
||||||
float interpolate_baked_tilt(float p_offset) const;
|
float interpolate_baked_tilt(float p_offset) const;
|
||||||
PoolVector3Array get_baked_points() const; //useful for going thru
|
PoolVector3Array get_baked_points() const; //useful for going through
|
||||||
PoolRealArray get_baked_tilts() const; //useful for going thru
|
PoolRealArray get_baked_tilts() const; //useful for going through
|
||||||
|
|
||||||
PoolVector3Array tesselate(int p_max_stages = 5, float p_tolerance = 4) const; //useful for display
|
PoolVector3Array tesselate(int p_max_stages = 5, float p_tolerance = 4) const; //useful for display
|
||||||
|
|
||||||
|
|
|
@ -8,7 +8,7 @@ import string
|
||||||
|
|
||||||
f = open("theme_data.h", "wb")
|
f = open("theme_data.h", "wb")
|
||||||
|
|
||||||
f.write("// THIS FILE HAS BEEN AUTOGENERATED, DONT EDIT!!\n")
|
f.write("// THIS FILE HAS BEEN AUTOGENERATED, DON'T EDIT!!\n")
|
||||||
|
|
||||||
f.write("\n\n")
|
f.write("\n\n")
|
||||||
|
|
||||||
|
|
|
@ -533,7 +533,7 @@ Error SceneState::_parse_node(Node *p_owner, Node *p_node, int p_parent_idx, Map
|
||||||
|
|
||||||
if (E->get().usage & PROPERTY_USAGE_NO_INSTANCE_STATE || E->get().name == "__meta__") {
|
if (E->get().usage & PROPERTY_USAGE_NO_INSTANCE_STATE || E->get().name == "__meta__") {
|
||||||
//property has requested that no instance state is saved, sorry
|
//property has requested that no instance state is saved, sorry
|
||||||
//also, meta won't be overriden or saved
|
//also, meta won't be overridden or saved
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -54,7 +54,7 @@ private:
|
||||||
|
|
||||||
// hack the name of performance
|
// hack the name of performance
|
||||||
// shaders keep a list of ShaderMaterial -> VisualServer name translations, to make
|
// shaders keep a list of ShaderMaterial -> VisualServer name translations, to make
|
||||||
// convertion fast and save memory.
|
// conversion fast and save memory.
|
||||||
mutable bool params_cache_dirty;
|
mutable bool params_cache_dirty;
|
||||||
mutable Map<StringName, StringName> params_cache; //map a shader param to a material param..
|
mutable Map<StringName, StringName> params_cache; //map a shader param to a material param..
|
||||||
Map<StringName, Ref<Texture> > default_textures;
|
Map<StringName, Ref<Texture> > default_textures;
|
||||||
|
|
|
@ -918,7 +918,7 @@ void AtlasTexture::draw_rect(RID p_canvas_item, const Rect2 &p_rect, bool p_tile
|
||||||
}
|
}
|
||||||
void AtlasTexture::draw_rect_region(RID p_canvas_item, const Rect2 &p_rect, const Rect2 &p_src_rect, const Color &p_modulate, bool p_transpose) const {
|
void AtlasTexture::draw_rect_region(RID p_canvas_item, const Rect2 &p_rect, const Rect2 &p_src_rect, const Color &p_modulate, bool p_transpose) const {
|
||||||
|
|
||||||
//this might not necesarily work well if using a rect, needs to be fixed properly
|
//this might not necessarily work well if using a rect, needs to be fixed properly
|
||||||
Rect2 rc = region;
|
Rect2 rc = region;
|
||||||
|
|
||||||
if (!atlas.is_valid())
|
if (!atlas.is_valid())
|
||||||
|
|
|
@ -57,7 +57,7 @@ void AudioFilterSW::prepare_coefficients(Coeffs *p_coeffs) {
|
||||||
|
|
||||||
double final_cutoff = (cutoff > sr_limit) ? sr_limit : cutoff;
|
double final_cutoff = (cutoff > sr_limit) ? sr_limit : cutoff;
|
||||||
if (final_cutoff < 1) //avoid crapness
|
if (final_cutoff < 1) //avoid crapness
|
||||||
final_cutoff = 1; //dont allow less than this
|
final_cutoff = 1; //don't allow less than this
|
||||||
|
|
||||||
double omega = 2.0 * Math_PI * final_cutoff / sampling_rate;
|
double omega = 2.0 * Math_PI * final_cutoff / sampling_rate;
|
||||||
|
|
||||||
|
|
|
@ -76,7 +76,7 @@ void AudioEffectChorusInstance::_process_chunk(const AudioFrame *p_src_frames, A
|
||||||
uint64_t local_cycles = cycles[vc];
|
uint64_t local_cycles = cycles[vc];
|
||||||
uint64_t increment = llrint(cycles_to_mix / (double)p_frame_count * (double)(1 << AudioEffectChorus::CYCLES_FRAC));
|
uint64_t increment = llrint(cycles_to_mix / (double)p_frame_count * (double)(1 << AudioEffectChorus::CYCLES_FRAC));
|
||||||
|
|
||||||
//check the LFO doesnt read ahead of the write pos
|
//check the LFO doesn't read ahead of the write pos
|
||||||
if ((((int)max_depth_frames) + 10) > delay_frames) { //10 as some threshold to avoid precision stuff
|
if ((((int)max_depth_frames) + 10) > delay_frames) { //10 as some threshold to avoid precision stuff
|
||||||
delay_frames += (int)max_depth_frames - delay_frames;
|
delay_frames += (int)max_depth_frames - delay_frames;
|
||||||
delay_frames += 10; //threshold to avoid precision stuff
|
delay_frames += 10; //threshold to avoid precision stuff
|
||||||
|
|
|
@ -235,7 +235,7 @@ void Reverb::set_extra_spread_base(float p_sec) {
|
||||||
|
|
||||||
void Reverb::configure_buffers() {
|
void Reverb::configure_buffers() {
|
||||||
|
|
||||||
clear_buffers(); //clear if necesary
|
clear_buffers(); //clear if necessary
|
||||||
|
|
||||||
for (int i = 0; i < MAX_COMBS; i++) {
|
for (int i = 0; i < MAX_COMBS; i++) {
|
||||||
|
|
||||||
|
|
|
@ -255,7 +255,7 @@ void AudioServer::_mix_step() {
|
||||||
bus->channels[k].last_mix_with_audio = mix_frames;
|
bus->channels[k].last_mix_with_audio = mix_frames;
|
||||||
} else if (mix_frames - bus->channels[k].last_mix_with_audio > channel_disable_frames) {
|
} else if (mix_frames - bus->channels[k].last_mix_with_audio > channel_disable_frames) {
|
||||||
bus->channels[k].active = false;
|
bus->channels[k].active = false;
|
||||||
continue; //went inactive, dont mix.
|
continue; //went inactive, don't mix.
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -503,7 +503,7 @@ void BodySW::integrate_forces(real_t p_step) {
|
||||||
|
|
||||||
} else {
|
} else {
|
||||||
if (!omit_force_integration && !first_integration) {
|
if (!omit_force_integration && !first_integration) {
|
||||||
//overriden by direct state query
|
//overridden by direct state query
|
||||||
|
|
||||||
Vector3 force = gravity * mass;
|
Vector3 force = gravity * mass;
|
||||||
force += applied_force;
|
force += applied_force;
|
||||||
|
|
|
@ -58,7 +58,7 @@ namespace GjkEpa2 {
|
||||||
|
|
||||||
struct sResults {
|
struct sResults {
|
||||||
enum eStatus {
|
enum eStatus {
|
||||||
Separated, /* Shapes doesnt penetrate */
|
Separated, /* Shapes doesn't penetrate */
|
||||||
Penetrating, /* Shapes are penetrating */
|
Penetrating, /* Shapes are penetrating */
|
||||||
GJK_Failed, /* GJK phase fail, no big issue, shapes are probably just 'touching' */
|
GJK_Failed, /* GJK phase fail, no big issue, shapes are probably just 'touching' */
|
||||||
EPA_Failed /* EPA phase fail, bigger problem, need to save parameters, and debug */
|
EPA_Failed /* EPA phase fail, bigger problem, need to save parameters, and debug */
|
||||||
|
|
|
@ -237,7 +237,7 @@ protected:
|
||||||
Vector3 m_calculatedAxisAngleDiff;
|
Vector3 m_calculatedAxisAngleDiff;
|
||||||
Vector3 m_calculatedAxis[3];
|
Vector3 m_calculatedAxis[3];
|
||||||
|
|
||||||
Vector3 m_AnchorPos; // point betwen pivots of bodies A and B to solve linear axes
|
Vector3 m_AnchorPos; // point between pivots of bodies A and B to solve linear axes
|
||||||
|
|
||||||
bool m_useLinearReferenceFrameA;
|
bool m_useLinearReferenceFrameA;
|
||||||
|
|
||||||
|
|
|
@ -181,7 +181,7 @@ PhysicsDirectSpaceState *PhysicsServerSW::space_get_direct_state(RID p_space) {
|
||||||
ERR_FAIL_COND_V(!space, NULL);
|
ERR_FAIL_COND_V(!space, NULL);
|
||||||
if (!doing_sync || space->is_locked()) {
|
if (!doing_sync || space->is_locked()) {
|
||||||
|
|
||||||
ERR_EXPLAIN("Space state is inaccesible right now, wait for iteration or fixed process notification.");
|
ERR_EXPLAIN("Space state is inaccessible right now, wait for iteration or fixed process notification.");
|
||||||
ERR_FAIL_V(NULL);
|
ERR_FAIL_V(NULL);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -146,7 +146,7 @@ int PhysicsDirectSpaceStateSW::intersect_shape(const RID &p_shape, const Transfo
|
||||||
if (!_match_object_type_query(space->intersection_query_results[i], p_layer_mask, p_object_type_mask))
|
if (!_match_object_type_query(space->intersection_query_results[i], p_layer_mask, p_object_type_mask))
|
||||||
continue;
|
continue;
|
||||||
|
|
||||||
//area cant be picked by ray (default)
|
//area can't be picked by ray (default)
|
||||||
|
|
||||||
if (p_exclude.has(space->intersection_query_results[i]->get_self()))
|
if (p_exclude.has(space->intersection_query_results[i]->get_self()))
|
||||||
continue;
|
continue;
|
||||||
|
@ -225,7 +225,7 @@ bool PhysicsDirectSpaceStateSW::cast_motion(const RID &p_shape, const Transform
|
||||||
//test initial overlap
|
//test initial overlap
|
||||||
#if 0
|
#if 0
|
||||||
if (CollisionSolverSW::solve_static(shape,p_xform,col_obj->get_shape(shape_idx),col_obj_xform,NULL,NULL,&sep_axis)) {
|
if (CollisionSolverSW::solve_static(shape,p_xform,col_obj->get_shape(shape_idx),col_obj_xform,NULL,NULL,&sep_axis)) {
|
||||||
print_line("failed initial cast (collision at begining)");
|
print_line("failed initial cast (collision at beginning)");
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
#else
|
#else
|
||||||
|
|
|
@ -484,7 +484,7 @@ void Body2DSW::integrate_forces(real_t p_step) {
|
||||||
|
|
||||||
} else {
|
} else {
|
||||||
if (!omit_force_integration && !first_integration) {
|
if (!omit_force_integration && !first_integration) {
|
||||||
//overriden by direct state query
|
//overridden by direct state query
|
||||||
|
|
||||||
Vector2 force = gravity * mass;
|
Vector2 force = gravity * mass;
|
||||||
force += applied_force;
|
force += applied_force;
|
||||||
|
|
|
@ -266,7 +266,7 @@ Physics2DDirectSpaceState *Physics2DServerSW::space_get_direct_state(RID p_space
|
||||||
ERR_FAIL_COND_V(!space, NULL);
|
ERR_FAIL_COND_V(!space, NULL);
|
||||||
if ((using_threads && !doing_sync) || space->is_locked()) {
|
if ((using_threads && !doing_sync) || space->is_locked()) {
|
||||||
|
|
||||||
ERR_EXPLAIN("Space state is inaccesible right now, wait for iteration or fixed process notification.");
|
ERR_EXPLAIN("Space state is inaccessible right now, wait for iteration or fixed process notification.");
|
||||||
ERR_FAIL_V(NULL);
|
ERR_FAIL_V(NULL);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -610,7 +610,7 @@ void Rasterizer::_free_fixed_material(const RID& p_material) {
|
||||||
|
|
||||||
void Rasterizer::flush_frame() {
|
void Rasterizer::flush_frame() {
|
||||||
|
|
||||||
//not really necesary to implement
|
//not really necessary to implement
|
||||||
}
|
}
|
||||||
|
|
||||||
Rasterizer::Rasterizer() {
|
Rasterizer::Rasterizer() {
|
||||||
|
|
|
@ -1489,7 +1489,7 @@ public:
|
||||||
virtual void end_shadow_map()=0;
|
virtual void end_shadow_map()=0;
|
||||||
|
|
||||||
virtual void end_frame()=0;
|
virtual void end_frame()=0;
|
||||||
virtual void flush_frame(); //not necesary in most cases
|
virtual void flush_frame(); //not necessary in most cases
|
||||||
|
|
||||||
/* CANVAS API */
|
/* CANVAS API */
|
||||||
|
|
||||||
|
|
|
@ -2820,7 +2820,7 @@ ShaderLanguage::Node *ShaderLanguage::_parse_expression(BlockNode *p_block, cons
|
||||||
// this is not invalid and can really appear
|
// this is not invalid and can really appear
|
||||||
// but it becomes invalid anyway because no binary op
|
// but it becomes invalid anyway because no binary op
|
||||||
// can be followed by an unary op in a valid combination,
|
// can be followed by an unary op in a valid combination,
|
||||||
// due to how precedence works, unaries will always dissapear first
|
// due to how precedence works, unaries will always disappear first
|
||||||
|
|
||||||
_set_error("Parser bug..");
|
_set_error("Parser bug..");
|
||||||
}
|
}
|
||||||
|
@ -3374,7 +3374,7 @@ Error ShaderLanguage::_parse_shader(const Map<StringName, Map<StringName, DataTy
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!is_token_datatype(tk.type)) {
|
if (!is_token_datatype(tk.type)) {
|
||||||
_set_error("Expected funtion, uniform or varying ");
|
_set_error("Expected function, uniform or varying ");
|
||||||
return ERR_PARSE_ERROR;
|
return ERR_PARSE_ERROR;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -3492,7 +3492,7 @@ Error ShaderLanguage::_parse_shader(const Map<StringName, Map<StringName, DataTy
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
//all good let's parse inside the fucntion!
|
//all good let's parse inside the function!
|
||||||
tk = _get_token();
|
tk = _get_token();
|
||||||
if (tk.type != TK_CURLY_BRACKET_OPEN) {
|
if (tk.type != TK_CURLY_BRACKET_OPEN) {
|
||||||
_set_error("Expected '{' to begin function");
|
_set_error("Expected '{' to begin function");
|
||||||
|
|
|
@ -2447,7 +2447,7 @@ void VisualServerScene::_setup_gi_probe(Instance *p_instance) {
|
||||||
for (int y = 0; y < 4; y++) {
|
for (int y = 0; y < 4; y++) {
|
||||||
for (int x = 0; x < 4; x++) {
|
for (int x = 0; x < 4; x++) {
|
||||||
|
|
||||||
//substract minimum
|
//subtract minimum
|
||||||
uint32_t a = uint32_t(alpha_block[x][y]) - min_alpha;
|
uint32_t a = uint32_t(alpha_block[x][y]) - min_alpha;
|
||||||
//convert range to 3 bits
|
//convert range to 3 bits
|
||||||
a = int((a * 7.0 / (max_alpha - min_alpha)) + 0.5);
|
a = int((a * 7.0 / (max_alpha - min_alpha)) + 0.5);
|
||||||
|
@ -2923,7 +2923,7 @@ void VisualServerScene::_bake_gi_probe(Instance *p_gi_probe) {
|
||||||
colors[j].z = (local_data[b.sources[j]].energy[2] / float(probe_data->dynamic.bake_dynamic_range)) / 1024.0;
|
colors[j].z = (local_data[b.sources[j]].energy[2] / float(probe_data->dynamic.bake_dynamic_range)) / 1024.0;
|
||||||
}
|
}
|
||||||
//super quick and dirty compression
|
//super quick and dirty compression
|
||||||
//find 2 most futher apart
|
//find 2 most further apart
|
||||||
float distance = 0;
|
float distance = 0;
|
||||||
Vector3 from, to;
|
Vector3 from, to;
|
||||||
|
|
||||||
|
@ -3001,7 +3001,7 @@ void VisualServerScene::_bake_gi_probe(Instance *p_gi_probe) {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
//by default, 1 is black, otherwise it will be overriden by source
|
//by default, 1 is black, otherwise it will be overridden by source
|
||||||
|
|
||||||
uint32_t index_block[16] = { 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1 };
|
uint32_t index_block[16] = { 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1 };
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue