summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorCarl Hetherington <cth@carlh.net>2019-12-19 14:29:18 +0100
committerCarl Hetherington <cth@carlh.net>2020-01-12 22:28:59 +0100
commit2645b6ae99397e46fa25f694ef8c194e4ea1fd21 (patch)
treef58279d20be8fb8d6ae35ebcf932e18d041de995 /src
parenta972af6dcbdb0b8a1c5386d34a0cea2c12738a67 (diff)
Rename ::same -> ::definitely_equal.
Diffstat (limited to 'src')
-rw-r--r--src/lib/dcp_video.cc4
-rw-r--r--src/lib/dcp_video.h2
-rw-r--r--src/lib/ffmpeg_image_proxy.cc2
-rw-r--r--src/lib/ffmpeg_image_proxy.h2
-rw-r--r--src/lib/image_proxy.h2
-rw-r--r--src/lib/j2k_encoder.cc2
-rw-r--r--src/lib/j2k_image_proxy.cc2
-rw-r--r--src/lib/j2k_image_proxy.h2
-rw-r--r--src/lib/player_video.cc6
-rw-r--r--src/lib/player_video.h2
-rw-r--r--src/lib/position_image.cc2
-rw-r--r--src/lib/position_image.h2
-rw-r--r--src/lib/raw_image_proxy.cc2
-rw-r--r--src/lib/raw_image_proxy.h2
14 files changed, 17 insertions, 17 deletions
diff --git a/src/lib/dcp_video.cc b/src/lib/dcp_video.cc
index 6f32b6686..f98df5dbd 100644
--- a/src/lib/dcp_video.cc
+++ b/src/lib/dcp_video.cc
@@ -208,7 +208,7 @@ DCPVideo::eyes () const
* (apart from the frame index), false if it is probably not.
*/
bool
-DCPVideo::same (shared_ptr<const DCPVideo> other) const
+DCPVideo::definitely_equal (shared_ptr<const DCPVideo> other) const
{
if (_frames_per_second != other->_frames_per_second ||
_j2k_bandwidth != other->_j2k_bandwidth ||
@@ -216,5 +216,5 @@ DCPVideo::same (shared_ptr<const DCPVideo> other) const
return false;
}
- return _frame->same (other->_frame);
+ return _frame->definitely_equal (other->_frame);
}
diff --git a/src/lib/dcp_video.h b/src/lib/dcp_video.h
index 81ddc4470..17e7104dc 100644
--- a/src/lib/dcp_video.h
+++ b/src/lib/dcp_video.h
@@ -54,7 +54,7 @@ public:
Eyes eyes () const;
- bool same (boost::shared_ptr<const DCPVideo> other) const;
+ bool definitely_equal (boost::shared_ptr<const DCPVideo> other) const;
static boost::shared_ptr<dcp::OpenJPEGImage> convert_to_xyz (boost::shared_ptr<const PlayerVideo> frame, dcp::NoteHandler note);
diff --git a/src/lib/ffmpeg_image_proxy.cc b/src/lib/ffmpeg_image_proxy.cc
index 9c91d1d87..0c5f6dc0d 100644
--- a/src/lib/ffmpeg_image_proxy.cc
+++ b/src/lib/ffmpeg_image_proxy.cc
@@ -209,7 +209,7 @@ FFmpegImageProxy::send_binary (shared_ptr<Socket> socket) const
}
bool
-FFmpegImageProxy::same (shared_ptr<const ImageProxy> other) const
+FFmpegImageProxy::definitely_equal (shared_ptr<const ImageProxy> other) const
{
shared_ptr<const FFmpegImageProxy> mp = dynamic_pointer_cast<const FFmpegImageProxy> (other);
if (!mp) {
diff --git a/src/lib/ffmpeg_image_proxy.h b/src/lib/ffmpeg_image_proxy.h
index 5f9b3b131..87862a8b1 100644
--- a/src/lib/ffmpeg_image_proxy.h
+++ b/src/lib/ffmpeg_image_proxy.h
@@ -36,7 +36,7 @@ public:
void add_metadata (xmlpp::Node *) const;
void send_binary (boost::shared_ptr<Socket>) const;
- bool same (boost::shared_ptr<const ImageProxy> other) const;
+ bool definitely_equal (boost::shared_ptr<const ImageProxy> other) const;
size_t memory_used () const;
int avio_read (uint8_t* buffer, int const amount);
diff --git a/src/lib/image_proxy.h b/src/lib/image_proxy.h
index b6fe87732..82d1a9a3a 100644
--- a/src/lib/image_proxy.h
+++ b/src/lib/image_proxy.h
@@ -74,7 +74,7 @@ public:
virtual void add_metadata (xmlpp::Node *) const = 0;
virtual void send_binary (boost::shared_ptr<Socket>) const = 0;
/** @return true if our image is definitely the same as another, false if it is probably not */
- virtual bool same (boost::shared_ptr<const ImageProxy>) const = 0;
+ virtual bool definitely_equal (boost::shared_ptr<const ImageProxy>) const = 0;
/** Do any useful work that would speed up a subsequent call to ::image().
* This method may be called in a different thread to image().
* @return log2 of any scaling down that will be applied to the image.
diff --git a/src/lib/j2k_encoder.cc b/src/lib/j2k_encoder.cc
index 5c3fd477e..ae31e2b17 100644
--- a/src/lib/j2k_encoder.cc
+++ b/src/lib/j2k_encoder.cc
@@ -217,7 +217,7 @@ J2KEncoder::encode (shared_ptr<PlayerVideo> pv, DCPTime time)
LOG_DEBUG_ENCODE("Frame @ %1 J2K", to_string(time));
/* This frame already has J2K data, so just write it */
_writer->write (pv->j2k(), position, pv->eyes ());
- } else if (_last_player_video[pv->eyes()] && _writer->can_repeat(position) && pv->same (_last_player_video[pv->eyes()])) {
+ } else if (_last_player_video[pv->eyes()] && _writer->can_repeat(position) && pv->definitely_equal(_last_player_video[pv->eyes()])) {
LOG_DEBUG_ENCODE("Frame @ %1 REPEAT", to_string(time));
_writer->repeat (position, pv->eyes ());
} else {
diff --git a/src/lib/j2k_image_proxy.cc b/src/lib/j2k_image_proxy.cc
index 31fda2510..14c2f69fe 100644
--- a/src/lib/j2k_image_proxy.cc
+++ b/src/lib/j2k_image_proxy.cc
@@ -196,7 +196,7 @@ J2KImageProxy::send_binary (shared_ptr<Socket> socket) const
}
bool
-J2KImageProxy::same (shared_ptr<const ImageProxy> other) const
+J2KImageProxy::definitely_equal (shared_ptr<const ImageProxy> other) const
{
shared_ptr<const J2KImageProxy> jp = dynamic_pointer_cast<const J2KImageProxy> (other);
if (!jp) {
diff --git a/src/lib/j2k_image_proxy.h b/src/lib/j2k_image_proxy.h
index 510c0ff25..c56bdc025 100644
--- a/src/lib/j2k_image_proxy.h
+++ b/src/lib/j2k_image_proxy.h
@@ -57,7 +57,7 @@ public:
void add_metadata (xmlpp::Node *) const;
void send_binary (boost::shared_ptr<Socket>) const;
/** @return true if our image is definitely the same as another, false if it is probably not */
- bool same (boost::shared_ptr<const ImageProxy>) const;
+ bool definitely_equal (boost::shared_ptr<const ImageProxy>) const;
int prepare (boost::optional<dcp::Size> = boost::optional<dcp::Size>()) const;
dcp::Data j2k () const {
diff --git a/src/lib/player_video.cc b/src/lib/player_video.cc
index 75479136f..8284c79ab 100644
--- a/src/lib/player_video.cc
+++ b/src/lib/player_video.cc
@@ -245,7 +245,7 @@ PlayerVideo::inter_position () const
/** @return true if this PlayerVideo is definitely the same as another, false if it is probably not */
bool
-PlayerVideo::same (shared_ptr<const PlayerVideo> other) const
+PlayerVideo::definitely_equal (shared_ptr<const PlayerVideo> other) const
{
if (_crop != other->_crop ||
_fade != other->_fade ||
@@ -263,14 +263,14 @@ PlayerVideo::same (shared_ptr<const PlayerVideo> other) const
return false;
}
- if (_text && other->_text && !_text->same (other->_text.get ())) {
+ if (_text && other->_text && !_text->definitely_equal(other->_text.get())) {
/* They both have texts but they are different */
return false;
}
/* Now neither has subtitles */
- return _in->same (other->_in);
+ return _in->definitely_equal (other->_in);
}
AVPixelFormat
diff --git a/src/lib/player_video.h b/src/lib/player_video.h
index 3cd559409..5e579a705 100644
--- a/src/lib/player_video.h
+++ b/src/lib/player_video.h
@@ -99,7 +99,7 @@ public:
return _inter_size;
}
- bool same (boost::shared_ptr<const PlayerVideo> other) const;
+ bool definitely_equal (boost::shared_ptr<const PlayerVideo> other) const;
size_t memory_used () const;
diff --git a/src/lib/position_image.cc b/src/lib/position_image.cc
index c342e1866..fa65a14e5 100644
--- a/src/lib/position_image.cc
+++ b/src/lib/position_image.cc
@@ -25,7 +25,7 @@
using std::cout;
bool
-PositionImage::same (PositionImage const & other) const
+PositionImage::definitely_equal (PositionImage const & other) const
{
if ((!image && other.image) || (image && !other.image) || position != other.position) {
return false;
diff --git a/src/lib/position_image.h b/src/lib/position_image.h
index 3e6d833e7..4ab90d39f 100644
--- a/src/lib/position_image.h
+++ b/src/lib/position_image.h
@@ -39,7 +39,7 @@ public:
boost::shared_ptr<Image> image;
Position<int> position;
- bool same (PositionImage const & other) const;
+ bool definitely_equal (PositionImage const & other) const;
};
#endif
diff --git a/src/lib/raw_image_proxy.cc b/src/lib/raw_image_proxy.cc
index 21201faa6..ed6f1f289 100644
--- a/src/lib/raw_image_proxy.cc
+++ b/src/lib/raw_image_proxy.cc
@@ -76,7 +76,7 @@ RawImageProxy::send_binary (shared_ptr<Socket> socket) const
}
bool
-RawImageProxy::same (shared_ptr<const ImageProxy> other) const
+RawImageProxy::definitely_equal (shared_ptr<const ImageProxy> other) const
{
shared_ptr<const RawImageProxy> rp = dynamic_pointer_cast<const RawImageProxy> (other);
if (!rp) {
diff --git a/src/lib/raw_image_proxy.h b/src/lib/raw_image_proxy.h
index dcd107a9e..769520187 100644
--- a/src/lib/raw_image_proxy.h
+++ b/src/lib/raw_image_proxy.h
@@ -35,7 +35,7 @@ public:
void add_metadata (xmlpp::Node *) const;
void send_binary (boost::shared_ptr<Socket>) const;
- bool same (boost::shared_ptr<const ImageProxy>) const;
+ bool definitely_equal (boost::shared_ptr<const ImageProxy>) const;
size_t memory_used () const;
private: