-
Notifications
You must be signed in to change notification settings - Fork 180
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[play] Separate Encoding and Type in Player application. #1836
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
/* ========================= eCAL LICENSE ================================= | ||
* | ||
* Copyright (C) 2016 - 2019 Continental Corporation | ||
* Copyright (C) 2016 - 2024 Continental Corporation | ||
* | ||
* Licensed under the Apache License, Version 2.0 (the "License"); | ||
* you may not use this file except in compliance with the License. | ||
|
@@ -40,12 +40,13 @@ ChannelTreeItem::ChannelTreeItem(const QString& source_name) | |
, duration_(0) | ||
{} | ||
|
||
ChannelTreeItem::ChannelTreeItem(const QString& source_name, const QString& channel_type, size_t total_channel_size, | ||
ChannelTreeItem::ChannelTreeItem(const QString& source_name, const QString& channel_encoding, const QString& channel_type, size_t total_channel_size, | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. warning: no header providing "size_t" is directly included [misc-include-cleaner] app/play/play_gui/src/widgets/models/channel_tree_item.cpp:18: - #include <math.h>
+ #include <cstddef>
+ #include <math.h> |
||
double min_channel_timestamp, double max_channel_timestamp, long long expected_frames, long long existing_frames, double duration) | ||
: QAbstractTreeItem() | ||
, enabled_(true) | ||
, source_name_(source_name) | ||
, target_name_(source_name) | ||
, channel_encoding_(channel_encoding) | ||
, channel_type_(channel_type) | ||
, total_channel_size_(total_channel_size) | ||
, min_channel_timestamp_(min_channel_timestamp) | ||
|
@@ -76,6 +77,8 @@ QVariant ChannelTreeItem::data(Columns column, Qt::ItemDataRole role) const | |
return source_name_; | ||
case ChannelTreeItem::Columns::TARGET_CHANNEL_NAME: | ||
return target_name_; | ||
case ChannelTreeItem::Columns::CHANNEL_ENCODING: | ||
return channel_encoding_; | ||
case ChannelTreeItem::Columns::CHANNEL_TYPE: | ||
return channel_type_; | ||
case ChannelTreeItem::Columns::TOTAL_CHANNEL_SIZE: | ||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
/* ========================= eCAL LICENSE ================================= | ||
* | ||
* Copyright (C) 2016 - 2019 Continental Corporation | ||
* Copyright (C) 2016 - 2024 Continental Corporation | ||
* | ||
* Licensed under the Apache License, Version 2.0 (the "License"); | ||
* you may not use this file except in compliance with the License. | ||
|
@@ -32,6 +32,7 @@ class ChannelTreeItem : public QAbstractTreeItem | |
SOURCE_CHANNEL_NAME, | ||
TARGET_CHANNEL_NAME, | ||
|
||
CHANNEL_ENCODING, | ||
CHANNEL_TYPE, | ||
TOTAL_CHANNEL_SIZE, | ||
|
||
|
@@ -47,7 +48,7 @@ class ChannelTreeItem : public QAbstractTreeItem | |
}; | ||
|
||
ChannelTreeItem(const QString& source_name); | ||
ChannelTreeItem(const QString& source_name, const QString& channel_type, size_t total_channel_size, | ||
ChannelTreeItem(const QString& source_name, const QString& channel_encoding, const QString& channel_type, size_t total_channel_size, | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. warning: no header providing "size_t" is directly included [misc-include-cleaner] app/play/play_gui/src/widgets/models/channel_tree_item.h:22: + #include <cstddef> |
||
double min_channel_timestamp, double max_channel_timestamp, long long expected_frames, long long existing_frames, double duration); | ||
|
||
~ChannelTreeItem(); | ||
|
@@ -76,6 +77,7 @@ class ChannelTreeItem : public QAbstractTreeItem | |
|
||
QString source_name_; | ||
QString target_name_; | ||
QString channel_encoding_; | ||
QString channel_type_; | ||
|
||
size_t total_channel_size_; | ||
|
Original file line number | Diff line number | Diff line change | ||||
---|---|---|---|---|---|---|
@@ -1,6 +1,6 @@ | ||||||
/* ========================= eCAL LICENSE ================================= | ||||||
* | ||||||
* Copyright (C) 2016 - 2019 Continental Corporation | ||||||
* Copyright (C) 2016 - 2024 Continental Corporation | ||||||
* | ||||||
* Licensed under the Apache License, Version 2.0 (the "License"); | ||||||
* you may not use this file except in compliance with the License. | ||||||
|
@@ -237,9 +237,10 @@ void ChannelTreeModel::reload() | |||||
double minTimestamp = QEcalPlay::instance()->minTimestampOfChannel(name); | ||||||
double maxTimestamp = QEcalPlay::instance()->maxTimestampOfChannel(name); | ||||||
std::string channel_type = QEcalPlay::instance()->channelType(name); | ||||||
std::string channel_encoding = QEcalPlay::instance()->channelEncoding(name); | ||||||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. warning: variable 'channel_encoding' of type 'std::string' (aka 'basic_string') can be declared 'const' [misc-const-correctness]
Suggested change
|
||||||
size_t total_channel_size = QEcalPlay::instance()->channelCumulativeEstimatedSize(name); | ||||||
|
||||||
ChannelTreeItem* channel_item = new ChannelTreeItem(name.c_str(), channel_type.c_str(), total_channel_size, | ||||||
ChannelTreeItem* channel_item = new ChannelTreeItem(name.c_str(), channel_encoding.c_str(), channel_type.c_str(), total_channel_size, | ||||||
minTimestamp, maxTimestamp, expected_frames, existing_frames, duration); | ||||||
new_channel_list.push_back(channel_item); | ||||||
} | ||||||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
warning: variable 'measurement_lock' of type 'std::shared_lockstd::shared_timed_mutex' can be declared 'const' [misc-const-correctness]