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

Feature/premultiply demultiply move #2640

Merged

Conversation

flippmoke
Copy link
Member

Some tests are failing currently for this, but wanted to go ahead and create the pull request so that @artemp and @springmeyer could start to review as there are a lot of changes.

Ref #2633

…he code. The image_data object is now responsible for keeping track of its own premultiplied_alpha status. Created a new utility method in image_util to preform premultiplication.

Added visitor pattern to several different methods as well to prepare for image_data_any including compositing.

Ref #2633
…premultiplication of data prior to compositing. There still seem to be some errors in the resulting images, but I am not quite sure what they are yet.
@flippmoke
Copy link
Member Author

I pushed a few more updates to this, however, still have some failing tests. I have left in some debug code in image_compositing.cpp that throws exceptions if the src or dst variables are not premultiplied, but as per @springmeyer 's request, I will have them removed prior to finishing this pull request.

@springmeyer
Copy link
Member

This is excellent work. Nice choice on throwing in the composite function for now. I actually even put in an abort to make it easy to get a backtrace of where non-premultiplied pixels were comping from. Will push a few fixes in a moment. All tests are passing for me now after 364fb49.

springmeyer pushed a commit that referenced this pull request Jan 15, 2015
@springmeyer springmeyer merged commit 7d2db67 into release/image_data_any Jan 15, 2015
@springmeyer springmeyer deleted the feature/premultiply_demultiply_move branch January 15, 2015 05:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants