Programming C, C++, Java, PHP, Ruby, Turing, VB
Computer Science Canada 
Programming C, C++, Java, PHP, Ruby, Turing, VB  

Username:   Password: 
 RegisterRegister   
 Gradient Module
Index -> Programming, Turing -> Turing Submissions
Goto page Previous  1, 2
View previous topic Printable versionDownload TopicRate TopicSubscribe to this topicPrivate MessagesRefresh page View next topic
Author Message
Mackie




PostPosted: Sun Jan 27, 2008 12:58 am   Post subject: RE:Gradient Module

EDIT:

Alright basic transparency is now working perfectly, but I think I'm going to over do it. Thanks for you help everyone! I couldn't have done it without you.
Sponsor
Sponsor
Sponsor
sponsor
StealthArcher




PostPosted: Sun Jan 27, 2008 3:50 pm   Post subject: Re: Gradient Module

My classmates are going to gape when they see this, too bad I didn't make it myself.
Mackie




PostPosted: Sun Jan 27, 2008 11:19 pm   Post subject: Re: Gradient Module

StealthArcher @ Sun Jan 27, 2008 3:50 pm wrote:
My classmates are going to gape when they see this, too bad I didn't make it myself.

Let me know what they think of it. Any Ideas they have for features or any bugs you find.

I always enjoy input, good or bad. (Preferably good Razz)
Mackie




PostPosted: Sun Feb 10, 2008 2:16 am   Post subject: Re: Gradient Module

New Release!

It took longer than I thought to get to this point. I forgot to work on this actually. So, there is a new syntax for:

Gradient.Oval (xPosition, yPosition, xRadius, yRadius, outerColor, innerColor : int, Ratio : real)

That's right! I've added multi-radii in to the Oval. There is still a glitch but, it's getting there. For an example check the first post of the thread.



Gradient_ModuleV03.zip
 Description:
v0.3

Download
 Filename:  Gradient_ModuleV03.zip
 Filesize:  7.36 KB
 Downloaded:  199 Time(s)

StealthArcher




PostPosted: Sun Feb 10, 2008 10:46 am   Post subject: RE:Gradient Module

Now to move on to multiple colors in one gradient! Very Happy So did my ratio formula help any?
Mackie




PostPosted: Sun Feb 10, 2008 12:26 pm   Post subject: RE:Gradient Module

Defiantly, although ericfourfour's formating, and De-cluttering suggestions helped me figure it out a lot more.
StealthArcher




PostPosted: Sun Feb 10, 2008 6:16 pm   Post subject: RE:Gradient Module

I never seem to help much here. EvRYBUDY IS TU GUD!
(not directed at mackie)
Mackie




PostPosted: Sun Feb 10, 2008 6:18 pm   Post subject: RE:Gradient Module

Haha, no you helped don't worry.
Sponsor
Sponsor
Sponsor
sponsor
Sean




PostPosted: Thu Feb 14, 2008 6:13 pm   Post subject: Re: Gradient Module

I've discovered some few glitches within the program, and have pointed it out to Mackie.

When drawing his Gradient.MapleLeaf with a large size, you have a slight problem. Say you chose his example, a leaf would appear with the same colours, although a green circle would appear in the middle, same with the star.

I've been looking for a way to clear that, but haven't found a way on my own, nor has Mackie to my knowledge. Any feedback or suggestions?

Also, a reverse Gradient Module would be good. Might try it by doing the opposite of what Mackie did. Could be fun.
StealthArcher




PostPosted: Thu Feb 14, 2008 11:36 pm   Post subject: Re: Gradient Module

The grren interior in the center is actually another maple leaf, drawn with the same color generation problems his alpha used to have, I fixed it using a basic cheap solution, but I'll make it better another time when I'm not tired.


GM V 0.3.1.zip
 Description:
Changes:
-ML color glitch fixed.

Download
 Filename:  GM V 0.3.1.zip
 Filesize:  7.69 KB
 Downloaded:  99 Time(s)

Mackie




PostPosted: Fri Feb 15, 2008 12:40 am   Post subject: RE:Gradient Module

The problem is in your fix is the smaller it is the more of the correct color gets cut out, and the problem still exists, with extremely large shapes. The problem seems to be for what ever reason, the for loop goes a bit to far. This causes the size to go negative, and for the maple leaf to become negative with, both color and size. Also, if you do plan on working on this problem (I will be). Then you should know that the Star is the exact same as the maple leaf.

Thanks StealthArcher.
HeavenAgain




PostPosted: Fri Feb 15, 2008 1:06 am   Post subject: RE:Gradient Module

when i see the "very large" and "negative", it gave me the conclusion of
Quote:
In current implementations of Turing, the range of integers is from -2147483647 to 2147483647. In other words, the maximum size of integer is 2**31 - 1. See maxint. This range exists because integers are stored in 4 bytes. The remaining negative value, -2147483648 records uninitialization.
but i dont think you actually went crazy and typed something like 999999999999 (12 digits) did you?..... and another thing, could it be the color's problem? since RGB each have value of 256, so 256^3 is 16777216 (7 digits) it might give funky result? (er after looking up the RGB thing, i noticed its real... so it might not be 256 colors each, but just some thought to where your problem might be)
StealthArcher




PostPosted: Fri Feb 15, 2008 11:45 am   Post subject: Re: Gradient Module

Alright, here we go, I'm in prog class atm, and fixed it better.


GM V0.3.2.zip
 Description:
Fix-ed

Download
 Filename:  GM V0.3.2.zip
 Filesize:  8 KB
 Downloaded:  147 Time(s)

Display posts from previous:   
   Index -> Programming, Turing -> Turing Submissions
View previous topic Tell A FriendPrintable versionDownload TopicRate TopicSubscribe to this topicPrivate MessagesRefresh page View next topic

Page 2 of 2  [ 28 Posts ]
Goto page Previous  1, 2
Jump to:   


Style:  
Search: