Skip to content
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

Implement operator= in ImageContainerByITKImage #1336

Merged

Conversation

phcerdan
Copy link
Member

@phcerdan phcerdan commented Jul 17, 2018

  • [NA] Unit-test of your feature with Catch.
  • [NA] Doxygen documentation of the code completed (classes, methods, types, members...)
  • [NA] Documentation module page added or updated.
  • New entry in the ChangeLog.md added.
  • No warning raised in Debug cmake mode (otherwise, Travis C.I. will fail).
  • All continuous integration tests pass (Travis & appveyor)

@dcoeurjo dcoeurjo added the Image label Jul 18, 2018
@dcoeurjo dcoeurjo added this to the 1.0 milestone Jul 18, 2018
@phcerdan phcerdan force-pushed the add_operator_equal_ITKImageContainer branch from 035744a to 9153b55 Compare July 18, 2018 13:09
phcerdan added a commit to phcerdan/SGEXT that referenced this pull request Jul 18, 2018
Provide an optional argument taking the distance map generated in
the script create_distance_map.
It would be required when --select=dmax

It requires a DGtal version with: DGtal-team/DGtal#1336 merged.
@phcerdan
Copy link
Member Author

Let me know if I can improve anything here. I think not having implemented it was just because nobody used it before. The base class defines the assignment operator, and all the other subclasses of ImageContainers have the operator implemented.

if (this != &other)
{
myITKImagePointer = other.myITKImagePointer;
myDomain = other.myDomain;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should updateDomain be called here instead of copying domain, like in the copy constructor ?

@phcerdan phcerdan force-pushed the add_operator_equal_ITKImageContainer branch from 9153b55 to 2b71dc2 Compare July 20, 2018 19:08
@phcerdan
Copy link
Member Author

Thanks @rolanddenis for the review, fixed, using updateDomain() as in the copy constructor.

@rolanddenis
Copy link
Member

Seems good, merging 😉 Thanks !

@rolanddenis rolanddenis merged commit a395742 into DGtal-team:master Jul 20, 2018
phcerdan added a commit to phcerdan/SGEXT that referenced this pull request Jan 26, 2021
Provide an optional argument taking the distance map generated in
the script create_distance_map.
It would be required when --select=dmax

It requires a DGtal version with: DGtal-team/DGtal#1336 merged.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants