summaryrefslogtreecommitdiff
path: root/core
diff options
context:
space:
mode:
authordumitru.stama <dumitru.stama@gmail.com>2017-06-16 17:28:58 -0700
committerdumitru.stama <dumitru.stama@gmail.com>2017-06-16 17:29:05 -0700
commit7787700aca695d9de6355d8133c62da285199e20 (patch)
tree5d081f9de81ce643b02e622a4ace1d276f75151f /core
parent8a03a29233d5ef4cf5be3aeebd76cb77c82bc983 (diff)
Fixed a bug in get_pixel not being const
Diffstat (limited to 'core')
-rw-r--r--core/image.cpp2
-rw-r--r--core/image.h2
2 files changed, 2 insertions, 2 deletions
diff --git a/core/image.cpp b/core/image.cpp
index 380b307020..426b13bccc 100644
--- a/core/image.cpp
+++ b/core/image.cpp
@@ -1712,7 +1712,7 @@ void Image::unlock() {
write_lock = PoolVector<uint8_t>::Write();
}
-Color Image::get_pixel(int p_x, int p_y) {
+Color Image::get_pixel(int p_x, int p_y) const {
uint8_t *ptr = write_lock.ptr();
#ifdef DEBUG_ENABLED
diff --git a/core/image.h b/core/image.h
index 790c5de9f6..bc536dcc88 100644
--- a/core/image.h
+++ b/core/image.h
@@ -304,7 +304,7 @@ public:
DetectChannels get_detected_channels();
- Color get_pixel(int p_x, int p_y);
+ Color get_pixel(int p_x, int p_y) const;
void put_pixel(int p_x, int p_y, const Color &p_color);
void copy_internals_from(const Ref<Image> &p_image) {