Jump to content

A computer program drawing a photo

Recommended Posts

With continuance of processors doubling in speed and Terabyte petabytes hard drives soon coming to the market, it will not be long before someone will be able to achieve such as task.

 

Surprisingly writing the code to “draw” a photo is so simple, it is unreal, less than 50 lines.

 

<geek mode>

 

Starting with a blank canvas in black, you increment the value in point(0,0) on the screen counting from 0 to 16777215 (0xFFFFFF).

 

When you hit, 16777215, you reset it to zero and increment the value in the next pixel along and if that happens to be also 16777215 you reset that and increment the next pixel along. It is a recursive procedure.

 

Basically you are setting every pixel on screen in a logical order in every permutations possible until all pixels go through from black to white.

 

</geek mode>

 

This will take many, many years, probably beyond my life time to process with today’s computers, but one day with the advancement of nantotechnology we may get there sooner.

 

For those that haven’t cottoned on by now this program has drawn every image since time itself began even countless garbage.

 

That means it will have produced an image from the day you are born to the day you die in every possible angle and every possible range. In places you have never visited with people who you’ve never met along side you. There will be one of you with three or more eyes. Your imagination is unlimited. Aliens, creatures, ideas, objects, dreams, that man have never seen will have been produced.

 

The down side of this program means naked people will have been produced of all ages. Also, who owns the copyright to these photos / images / icons / in some cases a page of written work? What will happen to the artists?

 

You heard it here first… now back to reality!

Share this post


Link to post
Share on other sites

there's a prize for the person who works out how long that would take.

 

is it something like (assuming 255 colours used - v basic pics): (255^16777215^16777215 operations)/operations per second.

 

That surely is longer than the universe is going to exist.

Share this post


Link to post
Share on other sites
is it something like (assuming 255 colours used - v basic pics): (255^16777215^16777215 operations)/operations per second.

 

The dimension of the image needs to be included into your equation.

 

There are tricks you can do like counting up in step of 16 and fine tune it when something looks interesting.

 

For a 32x32 icon using the incremential 16 step trick it would be: (16777215 / 16) ^ (32 x 32)

 

Feel free to correct me if I am wrong.

Share this post


Link to post
Share on other sites

Interesting, but I think giving a monkey a typewriter and waiting for it to come up with a Shakespeare play would be quicker!

Share this post


Link to post
Share on other sites
With continuance of processors doubling in speed and Terabyte hard drives soon coming to the market

 

Processors haven't "doubled in speed" for ages - multiple cores are now today's thing. And terabyte drives have been out for quite a while. Just don't buy a Seagate!

Share this post


Link to post
Share on other sites
Just don't buy a Seagate!

 

Why not? I swear by Seagate (only make that I haven't ever had a problem with)

Share this post


Link to post
Share on other sites

well to be honest, why are people putting a firmware update for 1TB drives on 500GB drives... its thier own fault tbfh.

Share this post


Link to post
Share on other sites
Processors haven't "doubled in speed" for ages - multiple cores are now today's thing. And terabyte drives have been out for quite a while. Just don't buy a Seagate!

 

Sorry, I meant petabytes.

Share this post


Link to post
Share on other sites
With continuance of processors doubling in speed and Terabyte hard drives soon coming to the market, it will not be long before someone will be able to achieve such as task.

 

Surprisingly writing the code to “draw” a photo is so simple, it is unreal, less than 50 lines.

 

<geek mode>

 

Starting with a blank canvas in black, you increment the value in point(0,0) on the screen counting from 0 to 16777215 (0xFFFFFF).

 

When you hit, 16777215, you reset it to zero and increment the value in the next pixel along and if that happens to be also 16777215 you reset that and increment the next pixel along. It is a recursive procedure.

 

Basically you are setting every pixel on screen in a logical order in every permutations possible until all pixels go through from black to white.

 

</geek mode>

 

This will take many, many years, probably beyond my life time to process with today’s computers, but one day with the advancement of nantotechnology we may get there sooner.

 

For those that haven’t cottoned on by now this program has drawn every image since time itself began even countless garbage.

 

That means it will have produced an image from the day you are born to the day you die in every possible angle and every possible range. In places you have never visited with people who you’ve never met along side you. There will be one of you with three or more eyes. Your imagination is unlimited. Aliens, creatures, ideas, objects, dreams, that man have never seen will have been produced.

 

The down side of this program means naked people will have been produced of all ages. Also, who owns the copyright to these photos / images / icons / in some cases a page of written work? What will happen to the artists?

 

You heard it here first… now back to reality!

 

generating the images is easy - it's finding them that takes eternity.

Share this post


Link to post
Share on other sites

Or how about this idea for the ultimate in lossless compression - you just need to provide hashes for your desired file; perhaps both MD5 and SHA1 plus the filesize, to minimise the risk of collisions. Then write a program that "just" constructs every single possible file of the same size, changing 1 bit at a time, until you have a file with matching hashes! The universe may have imploded back in on itself by the time it's finished, but you'll never have to worry about download caps again ;)

Share this post


Link to post
Share on other sites
well to be honest, why are people putting a firmware update for 1TB drives on 500GB drives... its thier own fault tbfh.

 

Maybe you should read the comments, a couple of people made the same mistake as you.

 

http://seagate.custkb.com/seagate/crm/selfservice/search.jsp?DocId=207931

 

The 500GB models with firmware SD15 was recommended for update to SD1A.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.