User Tools

Site Tools


hyperfun:lib_attrset

Applying a set of attributes and union operation

Set Attributes

hfa_setattributes.jpg
Definition: if(fв%_0) then s=c

Call: hfA_SetAttributes(f,s,c);

Parameters:
f - real values
s - Output Array
c - array of attributes

Output : array s

Test file: hfA_SetAttributes.hf

Set Colors

hfa_setcolor.jpg

Definition: if(fв%_0) then s[1]=r;s[2]=g;s[3]=b;

Call: hfA_SetColor(f,s,r,g,b);

Parameters:
f - real values
s - Output Array
r,g,b - rgb color values

Output : s array

Test file: hfA_SetColor.hf

Union

hfa_union.jpg

Definition : R_uni(f1,f2)

Call: hfA_Union(f1,f2,s,c1,c2,type);

Parameters:
f1,f2 - function values
s - Output Array
c1 - array of attributes of f1
c2 - array of attributes of f2
type - Predefined Unions (for the intersection set) :

  • 0 : Attributes of f1
  • 1 : Attributes of f2
  • 2 : Sum of c1 and c2
  • 3: Min of the components s [i] = min(c1[i],c2[i]);
  • 4: Max of the components s[i] = max(c1[i],c2[i]);

Output : Return the value R_uni(f1,f2). Fill the s array

Test file: hfA_Union.hf

hyperfun/lib_attrset.txt · Last modified: 2023/12/19 03:07 by 127.0.0.1