Viewing paste FBSCALETOHELP1
made on Wed, 13 Nov 2013 23:21:23 -0500
Sane-itized version, click to copy:
&FBSCALETO.HELP me=%tFBSCALETO(SOURCE,DEST,SX1,SY1,SX2,SY2,DX1,DY1,DX2,DY2,%r%t%t\[blend-mode\],\[transparency char\],\[transparency color\],\[blend-param\]);%r%rFBSCALETO is a powerful function for copying, scaling and blending the content of frame buffers.  A single-character copied froma source can be repeated throughout an entire framebuffer, or in a rectangular region.   Scaling and resampling occurs at theindividual character level. This function copies and scales the source region to the destination region.  Source and destinationmay be the same, or may be different framebuffers.  You can also optionally specify a blend mode, which can be one of several valuesoutlined in the help topic BLENDS.  Read the BLEND TUTORIAL for examples of blends.%r%rSee also: FRAME BUFFER, BLEND TUTORIAL, BLEND MODES%r%r----%r%rBLEND MODES%r%rCharacters always overwrite the target framebuffer, unless otherwise specified in the function requesting the mode.A blend mode can sometimes be paired with a blend parameter, and is a ratio (fractional) value between 0 and 1%r%rWhen [color(254,0,blend mode)] parameters are requested, provide a single digit numerical value corresponding to this table:%r%rValue%t%tName%r-----%t%t----%r  0%t%tOverwrite (default A=B)%tCharacters and colors will overwrite from source to target%r1%t%tAdditive (A B)%tcolors will be additive%r2%t%tSubtract (A-B)%tcolors will be subtractive%r3%t%tSubtract (B-A)%tcolors will be subtractive%r4%t%tDifference |A-B|%tcolors will be subtractive and then absolute value applied%r5%t%tDifference |B-A|%tcolors will be subtractive and then absolute value applied%r6%t%tMultiply A*B%tcolor values will be multiplied together, this is a tinting operation%r7%t%tAverage%tthe average of the source and destination colors will be computed%r8%t%tCrossfade%tA weighted average will be applied based on the normalized (0.0-1.0) value in blend parameter%r9%t%tMinimum%tthe minimum color channel value between source and dest will be chosen%r10%t%tMaximum%tthe maximum color channel value between source and dest will be chosen%r11%t%tAmplify%tThe destination color will be amplified by the source color%r12%t%tAND%tThe binary operation AND will occur between the 255-integer version of the color RGB%r13%t%tOR%tThe binary operation OR will occur between the 255-integer version of the color RGB%r14%t%tXOR%tThe binary operation XOR will occur between the 255-integer version of the color RGB%r15%t%tInvert%tThe inversion of the source color will be written to the destination buffer%r%r-----%rBLEND TUTORIAL%r%rBlend examples:%r[fbcreate(INK,11,9)][fbwrite(INK,0,0,[showpicture(TEST4)])][fbcreate(PAPER,79,20)][fbscaleto(INK,PAPER,0,0,10,8,1,1,21,17,0)][fbwrite(PAPER,4,0,Scaled 2X, Blend 0)][fbdestroy(INK)][fbdump(PAPER,%#)][fbdestroy(PAPER)]

Enter a target attribute, object reference and the mushcode.


%tFBSCALETO(SOURCE,DEST,SX1,SY1,SX2,SY2,DX1,DY1,DX2,DY2,%r%t%t\[blend-mode\],\[transparency char\],\[transparency color\],\[blend-param\]);%r
%r
FBSCALETO is a powerful function for copying, scaling and blending the content of frame buffers.  A single-character copied from
a source can be repeated throughout an entire framebuffer, or in a rectangular region.   Scaling and resampling occurs at the
individual character level. This function copies and scales the source region to the destination region.  Source and destination
may be the same, or may be different framebuffers.  You can also optionally specify a blend mode, which can be one of several values
outlined in the help topic BLENDS.  Read the BLEND TUTORIAL for examples of blends.%r
%r
See also: FRAME BUFFER, BLEND TUTORIAL, BLEND MODES%r
%r
----%r
%r
BLEND MODES%r
%r
Characters always overwrite the target framebuffer, unless otherwise specified in the function requesting the mode.
A blend mode can sometimes be paired with a blend parameter, and is a ratio (fractional) value between 0 and 1%r%r
When [color(254,0,blend mode)] parameters are requested, provide a single digit numerical value corresponding to this table:%r
%r
Value%t%tName%r
-----%t%t----%r  
0%t%tOverwrite (default A=B)%tCharacters and colors will overwrite from source to target%r
1%t%tAdditive (A B)%tcolors will be additive%r
2%t%tSubtract (A-B)%tcolors will be subtractive%r
3%t%tSubtract (B-A)%tcolors will be subtractive%r
4%t%tDifference |A-B|%tcolors will be subtractive and then absolute value applied%r
5%t%tDifference |B-A|%tcolors will be subtractive and then absolute value applied%r
6%t%tMultiply A*B%tcolor values will be multiplied together, this is a tinting operation%r
7%t%tAverage%tthe average of the source and destination colors will be computed%r
8%t%tCrossfade%tA weighted average will be applied based on the normalized (0.0-1.0) value in blend parameter%r
9%t%tMinimum%tthe minimum color channel value between source and dest will be chosen%r
10%t%tMaximum%tthe maximum color channel value between source and dest will be chosen%r
11%t%tAmplify%tThe destination color will be amplified by the source color%r
12%t%tAND%tThe binary operation AND will occur between the 255-integer version of the color RGB%r
13%t%tOR%tThe binary operation OR will occur between the 255-integer version of the color RGB%r
14%t%tXOR%tThe binary operation XOR will occur between the 255-integer version of the color RGB%r
15%t%tInvert%tThe inversion of the source color will be written to the destination buffer%r
%r
-----%r
BLEND TUTORIAL%r
%r
Blend examples:%r
[fbcreate(INK,11,9)][fbwrite(INK,0,0,[showpicture(TEST4)])]
[fbcreate(PAPER,79,20)]
[fbscaleto(INK,PAPER,0,0,10,8,1,1,21,17,0)][fbwrite(PAPER,4,0,Scaled 2X, Blend 0)]
[fbdestroy(INK)]
[fbdump(PAPER,%#)]
[fbdestroy(PAPER)]

save as: imprettify (attempt to format for readibility):
Found this useful? Try MUSHcode Repeater
written by orcs.biz