Looking for functions to FX some texts...

BlitzPlus Forums/BlitzPlus Programming/Looking for functions to FX some texts...

OverDozing(Posted 2007) [#1]
Hello,

I am looking for some functions to transform a text into a jpg logo just like photoshop would do…
The processing time isn’t a problem, the main concern is the quality looking.
How much you would charge me?
Here what I am looking for:

Text2Image(string$)

BlendingStroke(img, rgb, size) ;see photoshop blending options

BlendingGradient(img, rgb1, rgb2) ;gradient the text image

BlendingShadow(img, size)

MergeImgs(img1, img2) ;as merging logo into a bg image


The function’s parameters can be modified, all I want is: Text -> FXs -> Final result.
Thank you.


OverDozing(Posted 2007) [#2]
here an example:



CS_TBL(Posted 2007) [#3]
Those are not small functions you're asking. How much have you tried to do yourself?


OverDozing(Posted 2007) [#4]
Well, the thing is I don't have much time and I don't feel comfortable with 'ReadPixelFast' and such...
I thought it would be better to let someone else code it.

However, I start looking into it since it seems nobody is interested by my offer.

BlendingStroke(img, rgb, size) is bothering me, I can't develop a descent idea to do it.

Any help is welcome… :)


CS_TBL(Posted 2007) [#5]
Do you like nutshells? :P

Scan pixels left-right, right-left, up-down, down-up, and compare their value with the previous value you read. ABS() the difference, draw the difference to a new layer. The result is the border of such a character.

Another option would be to draw an oval with a given size at those spots where the difference is >0 .. that would somewhat resemble your stroke.


OverDozing(Posted 2007) [#6]
I hate 2d graphics manipulation!!! do I ?

I have to say 'Read/WritePixelFast' is quite interresting, yeah I rarely used it before.

I understand the ideas, I will try, thank you. :)


OverDozing(Posted 2007) [#7]
'Another option would be to draw an oval with a given size at those spots where the difference is >0 .. that would somewhat resemble your stroke.'

The oval technical work very good for mine application and no 'Read/WritePixelFast' headheck :)

Thanks




Pongo(Posted 2007) [#8]
I have a library of blend modes that I have almost ready to go. I have almost posted it in the code archives a few times, but really want to clean it up first.

Basically it will allow you to blend any 2 images using additive,multiply,overlay,hardlight, or simple masking. There may be a few others in there, but I can't recall at the moment. You can also tint either image to change the effect.

I will try to clean things up and get this posted, as it sounds like you could use it? You might have to be a bit patient though, I have limited time to work on stuff.


OverDozing(Posted 2007) [#9]
Hey Pongo, it does sound interresting! :)


Pongo(Posted 2007) [#10]
Just looked over the code, and it's pretty close to release. I will try to post it tomorrow with some examples for use.


Pongo(Posted 2007) [#11]
http://www.blitzbasic.com/codearcs/codearcs.php?code=2127

B3d code, but it's not using any 3d so (I think) it should be fine or require just a small bit of modification.


OverDozing(Posted 2007) [#12]
Hey Pongo
It s cool stuff, I had no tint fx yet so I will definitely include it in my code, the overlay is great too! Excellent stuff!

I spotted a little mistake:

Change this:
For y = 0 To ImageWidth(img1) -1
For x = 0 To ImageHeight(img1) -1
to:
For x = 0 To ImageWidth(img1) -1
For y = 0 To ImageHeight(img1) -1

I tested it on b3d and b+, it works! :)

Thank you :)


Pongo(Posted 2007) [#13]
oops,... will have to change that! I've been working with square images, so it never came up.

Glad you can use it, I'm sure there are areas that could be made cleaner/faster. Math is not my strong area so this drove me nuts figuring out some of this.


OverDozing(Posted 2007) [#14]
ooooh it s fast enough really, it s just perfect for my application! :)
Processing time isn't a problem.


Pongo(Posted 2007) [#15]
Just updated the code to fix that issue. Thanks for pointing it out.

Yea,... It's been fast enough for me, and it will never be a "real-time" effect anyways. I just know that someone will be able to look at it and see that things could be optimized further.

I was so close last night and spent over an hour trying to track down why the overlay mask mode wasn't working. Finally came down to a single undeclared local. Agggh.