Could you share me an example of this decoder? I donβt know any which can fetch the parts of an image from a URL. This also canβt use editable images
just a GET on the url gives you the png data, you pass it to this decoder and itβll give you all you need to get the individual pixels
What is wally? I am unaware of it. Is it like a file manager or something?
Something like that; Wally is a package manager for Roblox. Itβs made by UpliftGames (the people who made Adopt Me)
ffrostfall made a good post about it (iβm not good at explaining)
These odd deformaties occur when rotating the sprite (or more technically: multiplying its X size by -1)
Not quite sure why that happens. Issue probably lies within DrawTexturedTriangleXY somewhere, also scale wasnβt intended to be used as negative values. A solution for now is to probably just use two separate sprites for flipping your image
I was considering that! Iβm just sad that the Tri draw call has even more artifacts than I thought. :,(
I dont even know why, i assume my math somewhere is slightly off, but if someone can figure out the issue that would be amazing
βββββββββββββββββββββββββββββββββββ
is there still a possibility that the pixel fix could be looked into soon? Iβd love to get back to it
Now we can literally re-create Doom also in roblox studio
Btw very nice work
I look into it again possibly today or tomorrow and see if i can do a fix
I dont seem to be having this issue. Can you send the sprite you used to test this?
Just make sure to remove the background colors
I tested the top row one and it seems to work perfectly fine at scales 1, 2 and 3. I am having no distortion issues with the scale.
Are you using the latest version of CanvasDraw?
Here was my test spritesheet I made:
64x16
Hi, this is what it looks like for me, even after using a different version
This is what it looks like fullscaled, it still has those tiny extras pixels
Can you send me a repo? Iβll take a look
Sure! Add me on Discord.
my username is aunarky
we living ββββββββββββββββββββββ
Module Update - v4.8.0.b
Hey all. This update introduces a couple of new things. The biggest and most important change is that the canvas method DrawImageRect has been reworked and has changed slightly.
Canvas:DrawImageRect() changes:
-
This method no longer uses textured triangles to render a rect. This means that there are no jagged texturing distortions at decimal scales or uneven texture scales.
-
Added FlipX and FlipY boolean parameters for a native way to flip a sprite/image within an image rect region
-
Removed the angle parameter due to much more simplistic and faster rendering method. This parameter also didnβt really serve much use paired up with this method.
-
The rendering speed of this method has been increased by about 15%. There is also no more overdrawing issues.
-
Alpha blending is now supported!
Parameter changes can be visualised here:
Canvas:DrawImageRect(
ImageData, -- Our image/texture
Point, -- The origin point
ReftOffset, -- Rect offset in pixels
RectSize, -- Rect size in pixels
Scale, -- Scale percentage
FlipX, -- Flips the rect horizontally
FlipY, -- Flips the rect vertically
AlphaBlending -- Enables true transparency blending
)
New canvas method; Canvas:ViewportToCanvasPoint()
This new client sided method can come in handy when working with screen or viewport points as this method transforms them to canvas pixel points.
This method behaves very similarly to Canvas:GetMousePoint()
, but instead takes Vector2 position parameter and returns a Vector2 canvas point, regardless if it is within or outside of the canvas.
local ScreenPos = Vector2.new(1920, 1080) -- Bottom right corner of a standard 1080p screen
local CanvasPoint = Canvas:ViewportToCanvasPoint(ScreenPos)
print(CanvasPoint)
CanvasDraw4.8.0.b.rbxm (65.0 KB)