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 request: brightness and contrast sliders for layers #186

Closed
mhl opened this issue Dec 10, 2011 · 7 comments
Closed

feature request: brightness and contrast sliders for layers #186

mhl opened this issue Dec 10, 2011 · 7 comments

Comments

@mhl
Copy link
Contributor

mhl commented Dec 10, 2011

Pavel suggested that it would be great to be able to adjust the brightness and contrast of layers as well as their transparency.

@unidesigner
Copy link
Contributor

webgl would support it all: http://evanw.github.com/glfx.js/docs/

@unidesigner
Copy link
Contributor

@tomka
Copy link
Contributor

tomka commented Mar 22, 2014

Comment from @SRez in issue #606 regarding the support of contrast sliders:

Second, I have a request. Is it possible to have a ‘contrast slider’ – this is very important for us. There is already a ‘brightness slider’, which is a blessing.

Reply from me in issue #606:

For the contrast slider: This is certainly something we want to have, too. I once created infrastructure for having such sliders which let the back-end manipulate the images. This is, however, not practical, as you can easily kill the server with many image manipulating requests. Instead, I will look into letting the front-end (browser) do that. The whole topic is covered in issue #186.

Reply from @SRez in #606:

With respect to ‘contrast slider’, a front-end solution would be fine – I would be happy with any type of control over contrast.
The reason a contrast slider would be of great aid in tracing is that often times one gets folds on a section as dark lines; and while the fold might appear dark (product of image acquisition and exposure settings), there is actually information there. By changing the contrast, one could, more often than not, see the information beneath the fold. It is also a useful tool for deciphering synaptic densities.

@aschampion aschampion mentioned this issue Mar 6, 2015
10 tasks
@SRez
Copy link

SRez commented Mar 26, 2015

Hi,
Could you tell me how this filter is implemented? Does it appear as a slider like the 'opacity slider' or as a interactive button..? We upgraded to the latest instance, but I can not see where this is implemented.
Many thanks,
Best,
Reza

@aschampion
Copy link
Contributor

To use the brightness/contrast sliders (and other filters), you will need to enable the tiles to be rendered with WebGL. You can enable this from the settings widget (gear icon in the toolbar) by clicking the "Prefer WebGL Layers" checkbox. After doing this you will need to refresh the page.

However, for this to work the server hosting your image stack must be appropriately configured. Specifically, it must set a cross-origin resource sharing policy, and that policy must include the origin which hosts your CATMAID instance. You can find information on how to do that for many types of server at this site, but for nginx it is usually as simple as adding add_header Access-Control-Allow-Origin *; to the location block for your image tiles. Of course if you don't want to allow use of the images from any domain you may want to replace the wildcard * with a regex which matches specific domains you plan to use.

To tell that the WebGL tile layer is working, when you open the layers and filter control by clicking the toggle in the bottom left of the stack view, you should see controls for blend mode and filters in addition to the opacity slider:

screenshot from 2015-03-26 10 23 03

Select "Brightness, Contrast, & Saturation" from the filters drop down, click "Add", and the appropriate sliders will appear:

screenshot from 2015-03-26 10 23 33

@SRez
Copy link

SRez commented Mar 26, 2015

Thank you so much for this information Andrew. I shall definitely try this; from your screen shot it looks exactly what I was wishing for. Super.
best,
Reza

@sdadoun
Copy link

sdadoun commented May 13, 2015

Thank you Andrew. I just suceed to install a new instance of Catmaid and those new features seem to work perfectly.
Best,
Simon

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

6 participants