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
Make os::SurfaceFormat an enum class #4414
Make os::SurfaceFormat an enum class #4414
Conversation
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.
clang-tidy made some suggestions
@@ -36,7 +36,7 @@ uint32_t convert_color_to_surface(color_t color, const Palette* palette, const I | |||
} | |||
|
|||
template<> | |||
uint32_t convert_color_to_surface<RgbTraits, os::kRgbaSurfaceFormat>(color_t c, const Palette* palette, const ImageSpec& spec, const os::SurfaceFormatData* fd) { | |||
uint32_t convert_color_to_surface<RgbTraits, os::SurfaceFormat::kRgbaSurfaceFormat>(color_t c, const Palette* palette, const ImageSpec& spec, const os::SurfaceFormatData* fd) { |
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: parameter 'palette' is unused [misc-unused-parameters]
uint32_t convert_color_to_surface<RgbTraits, os::SurfaceFormat::kRgbaSurfaceFormat>(color_t c, const Palette* palette, const ImageSpec& spec, const os::SurfaceFormatData* fd) {
^
this fix will not be applied because it overlaps with another fix
@@ -36,7 +36,7 @@ | |||
} | |||
|
|||
template<> | |||
uint32_t convert_color_to_surface<RgbTraits, os::kRgbaSurfaceFormat>(color_t c, const Palette* palette, const ImageSpec& spec, const os::SurfaceFormatData* fd) { | |||
uint32_t convert_color_to_surface<RgbTraits, os::SurfaceFormat::kRgbaSurfaceFormat>(color_t c, const Palette* palette, const ImageSpec& spec, const os::SurfaceFormatData* fd) { |
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: parameter 'spec' is unused [misc-unused-parameters]
uint32_t convert_color_to_surface<RgbTraits, os::SurfaceFormat::kRgbaSurfaceFormat>(color_t c, const Palette* palette, const ImageSpec& spec, const os::SurfaceFormatData* fd) {
^
this fix will not be applied because it overlaps with another fix
@@ -45,7 +45,7 @@ | |||
} | |||
|
|||
template<> | |||
uint32_t convert_color_to_surface<GrayscaleTraits, os::kRgbaSurfaceFormat>(color_t c, const Palette* palette, const ImageSpec& spec, const os::SurfaceFormatData* fd) { | |||
uint32_t convert_color_to_surface<GrayscaleTraits, os::SurfaceFormat::kRgbaSurfaceFormat>(color_t c, const Palette* palette, const ImageSpec& spec, const os::SurfaceFormatData* fd) { |
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: parameter 'palette' is unused [misc-unused-parameters]
uint32_t convert_color_to_surface<GrayscaleTraits, os::SurfaceFormat::kRgbaSurfaceFormat>(color_t c, const Palette* palette, const ImageSpec& spec, const os::SurfaceFormatData* fd) {
^
this fix will not be applied because it overlaps with another fix
@@ -45,7 +45,7 @@ | |||
} | |||
|
|||
template<> | |||
uint32_t convert_color_to_surface<GrayscaleTraits, os::kRgbaSurfaceFormat>(color_t c, const Palette* palette, const ImageSpec& spec, const os::SurfaceFormatData* fd) { | |||
uint32_t convert_color_to_surface<GrayscaleTraits, os::SurfaceFormat::kRgbaSurfaceFormat>(color_t c, const Palette* palette, const ImageSpec& spec, const os::SurfaceFormatData* fd) { |
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: parameter 'spec' is unused [misc-unused-parameters]
uint32_t convert_color_to_surface<GrayscaleTraits, os::SurfaceFormat::kRgbaSurfaceFormat>(color_t c, const Palette* palette, const ImageSpec& spec, const os::SurfaceFormatData* fd) {
^
this fix will not be applied because it overlaps with another fix
@@ -54,7 +54,7 @@ | |||
} | |||
|
|||
template<> | |||
uint32_t convert_color_to_surface<IndexedTraits, os::kRgbaSurfaceFormat>(color_t c0, const Palette* palette, const ImageSpec& spec, const os::SurfaceFormatData* fd) { | |||
uint32_t convert_color_to_surface<IndexedTraits, os::SurfaceFormat::kRgbaSurfaceFormat>(color_t c0, const Palette* palette, const ImageSpec& spec, const os::SurfaceFormatData* fd) { |
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: function template specialization 'app::(anonymous namespace)::convert_color_to_surface<doc::IndexedTraits, os::kRgbaSurfaceFormat>' has a primary template declaration with different parameter names [readability-inconsistent-declaration-parameter-name]
uint32_t convert_color_to_surface<IndexedTraits, os::SurfaceFormat::kRgbaSurfaceFormat>(color_t c0, const Palette* palette, const ImageSpec& spec, const os::SurfaceFormatData* fd) {
^
Additional context
src/app/util/conversion_to_surface.cpp:32: the primary template declaration seen here
uint32_t convert_color_to_surface(color_t color, const Palette* palette, const ImageSpec& spec, const os::SurfaceFormatData* fd) {
^
src/app/util/conversion_to_surface.cpp:56: differing parameters are named here: ('c0'), in primary template declaration: ('color')
uint32_t convert_color_to_surface<IndexedTraits, os::SurfaceFormat::kRgbaSurfaceFormat>(color_t c0, const Palette* palette, const ImageSpec& spec, const os::SurfaceFormatData* fd) {
^
@@ -64,7 +64,7 @@ | |||
} | |||
|
|||
template<> | |||
uint32_t convert_color_to_surface<BitmapTraits, os::kRgbaSurfaceFormat>(color_t c0, const Palette* palette, const ImageSpec& spec, const os::SurfaceFormatData* fd) { | |||
uint32_t convert_color_to_surface<BitmapTraits, os::SurfaceFormat::kRgbaSurfaceFormat>(color_t c0, const Palette* palette, const ImageSpec& spec, const os::SurfaceFormatData* fd) { |
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: function template specialization 'app::(anonymous namespace)::convert_color_to_surface<doc::BitmapTraits, os::kRgbaSurfaceFormat>' has a primary template declaration with different parameter names [readability-inconsistent-declaration-parameter-name]
uint32_t convert_color_to_surface<BitmapTraits, os::SurfaceFormat::kRgbaSurfaceFormat>(color_t c0, const Palette* palette, const ImageSpec& spec, const os::SurfaceFormatData* fd) {
^
Additional context
src/app/util/conversion_to_surface.cpp:32: the primary template declaration seen here
uint32_t convert_color_to_surface(color_t color, const Palette* palette, const ImageSpec& spec, const os::SurfaceFormatData* fd) {
^
src/app/util/conversion_to_surface.cpp:66: differing parameters are named here: ('c0'), in primary template declaration: ('color')
uint32_t convert_color_to_surface<BitmapTraits, os::SurfaceFormat::kRgbaSurfaceFormat>(color_t c0, const Palette* palette, const ImageSpec& spec, const os::SurfaceFormatData* fd) {
^
@@ -64,7 +64,7 @@ | |||
} | |||
|
|||
template<> | |||
uint32_t convert_color_to_surface<BitmapTraits, os::kRgbaSurfaceFormat>(color_t c0, const Palette* palette, const ImageSpec& spec, const os::SurfaceFormatData* fd) { | |||
uint32_t convert_color_to_surface<BitmapTraits, os::SurfaceFormat::kRgbaSurfaceFormat>(color_t c0, const Palette* palette, const ImageSpec& spec, const os::SurfaceFormatData* fd) { |
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: parameter 'spec' is unused [misc-unused-parameters]
uint32_t convert_color_to_surface<BitmapTraits, os::SurfaceFormat::kRgbaSurfaceFormat>(color_t c0, const Palette* palette, const ImageSpec& spec, const os::SurfaceFormatData* fd) {
^
this fix will not be applied because it overlaps with another fix
Adding a link to the PR (instead to the commit) just to find it faster: aseprite/laf#83 |
Closing this PR as aseprite/laf#83 was updated to avoid this refactor. |
These changes should be merged once the following commit is merged: aseprite/laf@6406feb