void
Player::set_video_container_size (dcp::Size s)
{
- Change (ChangeType::PENDING, PlayerProperty::VIDEO_CONTAINER_SIZE, false);
+ ChangeSignaller<Player, int> cc(this, PlayerProperty::VIDEO_CONTAINER_SIZE);
if (s == _video_container_size) {
- Change(ChangeType::CANCELLED, PlayerProperty::VIDEO_CONTAINER_SIZE, false);
+ cc.abort();
return;
}
_black_image = make_shared<Image>(AV_PIX_FMT_RGB24, _video_container_size, Image::Alignment::PADDED);
_black_image->make_black ();
}
-
- Change (ChangeType::DONE, PlayerProperty::VIDEO_CONTAINER_SIZE, false);
}
void
Player::set_dcp_decode_reduction (optional<int> reduction)
{
- Change (ChangeType::PENDING, PlayerProperty::DCP_DECODE_REDUCTION, false);
+ ChangeSignaller<Player, int> cc(this, PlayerProperty::DCP_DECODE_REDUCTION);
if (reduction == _dcp_decode_reduction.load()) {
- Change(ChangeType::CANCELLED, PlayerProperty::DCP_DECODE_REDUCTION, false);
+ cc.abort();
return;
}
_dcp_decode_reduction = reduction;
setup_pieces();
-
- Change (ChangeType::DONE, PlayerProperty::DCP_DECODE_REDUCTION, false);
}
Atmos (data.data, dcp_time, data.metadata);
}
+
+void
+Player::signal_change(ChangeType type, int property)
+{
+ Change(type, property, false);
+}
+
boost::optional<dcpomatic::DCPTime> content_time_to_dcp (std::shared_ptr<const Content> content, dcpomatic::ContentTime t) const;
boost::optional<dcpomatic::ContentTime> dcp_to_content_time (std::shared_ptr<const Content> content, dcpomatic::DCPTime t) const;
+ void signal_change(ChangeType type, int property);
+
/** First parameter is PENDING, DONE or CANCELLED.
* Second parameter is the property.
* Third parameter is true if these signals are currently likely to be frequent.