veryjerry3 avatar

More Work on randomized image creation

veryjerry3

Published: 15 Apr 2022 › Updated: 15 Apr 2022More Work on randomized image creation

More Work on randomized image creation

So last week I worked on creating randomized images and layering them on top of each other. This week I'm going in a slightly different direction. The first thing I did differently was the background. While the background color is still randomized, it is limited by my college colors. Each color is given a variable and the color used is chosen by the function random.choice. I started trying to choose the background by choosing a random integer and adding it after the letter c to get a random variable name, but this way is so much easier. With the chosen color, a 1000 by 1000 image is created.

image.png

After that image is created a logo is chosen. These logos are various logos of my college that are on my computer and they are chosen the same way as above. Then the program checks each logo to see which is the chosen logo and then scales that logo and pastes it onto the background then saves it to a new file. The reason it has to check which logo it is is that each logo is a different size so they have to be scaled by a certain amount and placed onto the background with a different offset.

image.png

I problem I have with the logos are that the background of the logos aren't showing transparency even though I chose transparent pngs which means the way I'm doing it doesn't support them. I probably would have to find a way to fix that before any more work on it can be done.

Leave More Work on randomized image creation to:

Written by

Read more #gradnium posts


Best Posts From veryjerry3

We have not curated any of veryjerry3's posts yet. But you can encourage our curation team to review posts by visiting them regularly and by referring other readers. Because we give priority to frequently read content.

More Posts From veryjerry3