Re: Displaying pixel-perfect images without blur when zooming

2014-08-28 Thread Nico Krebs | www.mensch-und-maschine.de
Thank you both! i added a vote to the feature request. Could you provide a short sample, how snapshot(..) can help me zooming without antialiasing? Nico Jim Graham mailto:james.gra...@oracle.com 28. August 2014 01:33 We have no plans at all for implementing pixel preview as a setting on

Re: Displaying pixel-perfect images without blur when zooming

2014-08-28 Thread Jim Graham
Hi Nico, snapshot can set a resolution in stone, but it doesn't - in and of itself - help with zooming that fixed resolution representation without antialiasing. To get an aliased zoom of an image see the code that Felipe already posted in this thread. To be clear, to get an aliased,

Re: Displaying pixel-perfect images without blur when zooming

2014-08-28 Thread Nico Krebs | www.mensch-und-maschine.de
Thank you Jim, Edu and Felipe for that quick solution :) I will implement this solution and post a short report to this thread - and to SO. Nico Jim Graham mailto:james.gra...@oracle.com 28. August 2014 23:14 Hi Nico, snapshot can set a resolution in stone, but it doesn't - in and of

Re: Displaying pixel-perfect images without blur when zooming

2014-08-27 Thread Nico Krebs | www.mensch-und-maschine.de
Hi Edu, short story: i built a very simple image file format: a zip file, containing a meta.xml file and several png images. the xml defines the position of each png in the image. this way i have a very basic layered image file. I built the first version with Swing in JDK 7 but switched to

Re: Displaying pixel-perfect images without blur when zooming

2014-08-27 Thread Nico Krebs | www.mensch-und-maschine.de
i just found this StackOverflow-post: https://stackoverflow.com/questions/16089304/javafx-imageview-without-any-smoothing the author also thinks that this is a bug. the proposed solutions seems to be a hack and to be slow(guessing). imagine an image with around 1000 layers (which already

Re: Displaying pixel-perfect images without blur when zooming

2014-08-27 Thread Nico Krebs | www.mensch-und-maschine.de
fyi: i just checked if the scrollpane is smoothing the images, but it`s not. removing the scrollpane keeps images smoothed. Edu García mailto:arcn...@gmail.com 26. August 2014 23:13 I'm curious. Why setSmooth doesn't work? Also, do I really need to create an image in memory just to render

Re: Displaying pixel-perfect images without blur when zooming

2014-08-27 Thread Jim Graham
On 8/27/14 1:04 AM, Nico Krebs | www.mensch-und-maschine.de wrote: Question 1: I don't know why setSmooth(false) doesnt work. Perhaps am i using it the wrong way? I set it for each ImageView object i got in my list. the scrollpane can`t be unsmoothed because of the lack of the setSmooth()

Re: Displaying pixel-perfect images without blur when zooming

2014-08-27 Thread Edu García
Thank you Nico and Jim. Also Jim, that issue only talks about ImageView IIRC. Are you going to implement something similar for shapes? I know it's not the same, but I wanted to show pixelated shapes as well (think about zooming in past 100% in Illustrator with pixel preview enabled). I don't keep

Re: Displaying pixel-perfect images without blur when zooming

2014-08-27 Thread Jim Graham
We have no plans at all for implementing pixel preview as a setting on Shapes. You can do that with snapshot if you want. The Shape.setSmooth() setting (currently stubbed out) is meant to control antialiasing, not rendering resolution. There should be similar bugs for Shape.setSmooth() and

Displaying pixel-perfect images without blur when zooming

2014-08-26 Thread Nico Krebs | www.mensch-und-maschine.de
Hi there, i want to display multiple images (layers) inside a scene and want to be able to zoom without having blurry images as you can see in the images in the attachment (on the left you can see very big scaled pixels as i need it and on the right is the blurry JavaFX-Result on which i cannot

Re: Displaying pixel-perfect images without blur when zooming

2014-08-26 Thread Felipe Heidrich
Hi Nico, Is this what you looking for: Image image - the image to scale up int width = (int)image.getWidth(); int height = (int)image.getHeight(); int z = (int)getZoom(); // 2, 4, 8, 16 (I only tested for powers of two) IntBuffer src = IntBuffer.allocate(width

Re: Displaying pixel-perfect images without blur when zooming

2014-08-26 Thread Nico Krebs | www.mensch-und-maschine.de
Thanx for that quick response! It is the right direction, but doing this for one image is not enough. when having multiple images, the distances between them must be scaled, too. I will extend your example to scale all nodes and their positions, too. I try it tomorrow and post the result here.

Re: Displaying pixel-perfect images without blur when zooming

2014-08-26 Thread Edu García
I'm curious. Why setSmooth doesn't work? Also, do I really need to create an image in memory just to render something showing the pixels? On Aug 27, 2014 3:32 AM, Nico Krebs | www.mensch-und-maschine.de nicokrebs@googlemail.com wrote: Thanx for that quick response! It is the right

Re: Displaying pixel-perfect images without blur when zooming

2014-08-26 Thread Felipe Heidrich
I'm curious. Why setSmooth doesn't work? I tried setSmooth but it doesn’t work. See the doc: Indicates whether to use a better quality filtering algorithm or a faster”. I expected this be a set for the interpolation algorithm (bilinear, bicubic, nearest neighbor, etc). My case I didn’t

Re: Displaying pixel-perfect images without blur when zooming

2014-08-26 Thread Jim Graham
We simply haven't implemented this yet: https://javafx-jira.kenai.com/browse/RT-28629 ...jim On 8/26/14 3:29 PM, Felipe Heidrich wrote: I'm curious. Why setSmooth doesn't work? I tried setSmooth but it doesn’t work. See the doc: Indicates whether to use a better