JANG-Just-Another-NFT-Generator
JANG-Just-Another-NFT-Generator copied to clipboard
Genarete image based on posibility
how to generate image based on possiblity example: 3 background 3 avatar
must be generate 6 image and all layer has been used
You can use Math.random() to generate a random number between 0 and 1 and then assign the possibilities of what you are trying to do. Note that this will change the outcome each time it is run
Hi, I tried to add another layer with an assigned possibility. It is working, but this new layer overwrites the existing image, instead of overlapping. I could not figure out. Is there some kind of a "pixel mask" applied to your example images? I just drew a horizontal line in Paint and saved it as a 512x512 picture.
Are you using transparent PNG images to overlap. If there is a white background to the image it will cover the previous layer
On Thu, Mar 7, 2024, 11:39 PM vasez @.***> wrote:
Hi, I tried to add another layer with an assigned possibility. It is working, but this new layer overwrites the existing image, instead of overlapping. I could not figure out. Is there some kind of a "pixel mask" applied to your example images? I just drew a horizontal line in paint and saved it as a 512x512 picture.
— Reply to this email directly, view it on GitHub https://github.com/jamesbachini/JANG-Just-Another-NFT-Generator/issues/4#issuecomment-1984785827, or unsubscribe https://github.com/notifications/unsubscribe-auth/AE6GVY57UN7H3U7CS7ERG3LYXD3EDAVCNFSM6AAAAAAUIIQIBGVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMYTSOBUG44DKOBSG4 . You are receiving this because you commented.Message ID: @.*** com>
Thanks! I switched to PNG format, and applied a transparent background layer with GIMP, and it works :)