How to Make JavaFX Image Pixel-Perfect

Stack Overflow
How to Make JavaFX Image Pixel-Perfect
I am making an 8-bit game like Minecraft with Perspective Camera and SubScene and such, get this result from new Box() {{ setMaterial(new PhongMaterial() {{ setDiffuseMap(new Image(&quo...
8 Replies
JavaBot
JavaBot13mo ago
This post has been reserved for your question.
Hey @The Typhothanian! Please use /close or the Close Post button above when your problem is solved. Please remember to follow the help guidelines. This post will be automatically closed after 300 minutes of inactivity.
TIP: Narrow down your issue to simple and precise questions to maximize the chance that others will reply in here.
The Typhothanian
The TyphothanianOP13mo ago
i already posted it on stack overflow, it's all explained there pls
Unknown User
Unknown User13mo ago
Message Not Public
Sign In & Join Server To View
JavaBot
JavaBot12mo ago
💤 Post marked as dormant
This post has been inactive for over 300 minutes, thus, it has been archived. If your question was not answered yet, feel free to re-open this post or create a new one. In case your post is not getting any attention, you can try to use /help ping. Warning: abusing this will result in moderative actions taken against you.
The Typhothanian
The TyphothanianOP12mo ago
I messed around a bit, and I tried this:
new Box(16, 16, 16) {{
setMaterial(new PhongMaterial() {{
Image img = new Image("img.png");
setDiffuseMap(img);
setSelfIlluminationMap(img);
}});
setCache(true);
}}
new Box(16, 16, 16) {{
setMaterial(new PhongMaterial() {{
Image img = new Image("img.png");
setDiffuseMap(img);
setSelfIlluminationMap(img);
}});
setCache(true);
}}
(sorry for the indentation) And that gets a semi-okay result (pic) The front face is too bright, and the other faces are exactly what I want. I've tried changing the specular power and colors and such, but too low and the blurryness comes back, too high and it's too reflective. (pic 2 is what it looks like without self illumination map)
No description
No description
The Typhothanian
The TyphothanianOP12mo ago
also the image is just something I had lying around and I didnt want to make another texture
The Typhothanian
The TyphothanianOP12mo ago
with transparency:
No description
JavaBot
JavaBot12mo ago
💤 Post marked as dormant
This post has been inactive for over 300 minutes, thus, it has been archived. If your question was not answered yet, feel free to re-open this post or create a new one. In case your post is not getting any attention, you can try to use /help ping. Warning: abusing this will result in moderative actions taken against you.
Want results from more Discord servers?
Add your server