Logo by AGUS - Contribute your own Logo!

END OF AN ERA, FRACTALFORUMS.COM IS CONTINUED ON FRACTALFORUMS.ORG

it was a great time but no longer maintainable by c.Kleinhuis contact him for any data retrieval,
thanks and see you perhaps in 10 years again

this forum will stay online for reference
News: Did you know ? you can use LaTex inside Postings on fractalforums.com!
 
*
Welcome, Guest. Please login or register. April 25, 2024, 09:03:32 PM


Login with username, password and session length


The All New FractalForums is now in Public Beta Testing! Visit FractalForums.org and check it out!


Pages: 1 [2] 3   Go Down
  Print  
Share this topic on DiggShare this topic on FacebookShare this topic on GoogleShare this topic on RedditShare this topic on StumbleUponShare this topic on Twitter
Author Topic: "New" fractal type; Mandalay (in KIFS/ non KIFS versions)  (Read 10510 times)
0 Members and 1 Guest are viewing this topic.
DarkBeam
Global Moderator
Fractal Senior
******
Posts: 2512


Fragments of the fractal -like the tip of it


« Reply #15 on: March 08, 2015, 08:41:16 PM »

Rotated  smiley I called this "Transformation"

<Quoted Image Removed>

 A Beer Cup A Beer Cup A Beer Cup ty!!!!!
Logged

No sweat, guardian of wisdom!
Crist-JRoger
Fractal Fertilizer
*****
Posts: 389



WWW
« Reply #16 on: March 08, 2015, 08:46:54 PM »

 cheesy it's a coffee i think?
Logged

knighty
Fractal Iambus
***
Posts: 819


« Reply #17 on: March 08, 2015, 09:53:47 PM »

cheesy it's a coffee i think?
Yes! it is.  wink
Very nice render BTW.

@DarkBeam:
Yes there are cuts! but I like it this way.
This is the original shader. I just added controls for fg, g and juliaC:
Code:
#info Mandalay Distance Estimator.
#define providesInit
#include "DE-Raytracer.frag"
#include "MathUtils.frag"
#group Mandalay

// Number of fractal iterations.
uniform int Iterations;  slider[0,17,30]
uniform int ColorIterations;  slider[0,3,30]

uniform float MinRad2;  slider[0,0.25,2.0]

// Scale parameter. A perfect Menger is 3.0
uniform float Scale;  slider[-3.0,3.0,5.0]
vec4 scale = vec4(Scale, Scale, Scale, abs(Scale)) / MinRad2;

uniform float fo; slider[0.,0.5,2.]
uniform float g; slider[0.,0.9,2.]
// precomputed constants

uniform vec3 RotVector; slider[(0,0,0),(1,1,1),(1,1,1)]

// Scale parameter. A perfect Menger is 3.0
uniform float RotAngle; slider[0.00,0,180]

uniform bool Julia; checkbox[false]
uniform vec3 JuliaC; slider[(-2,-2,-2),(0,0,0),(2,2,2)]

mat3 rot;

void init() {
rot = rotationMatrix3(normalize(RotVector), RotAngle);
}

float absScalem1 = abs(Scale - 1.0);
float AbsScaleRaisedTo1mIters = pow(abs(Scale), float(1-Iterations));


// Compute the distance from `pos` to the Mandelbox.
float DE(vec3 pos) {
vec4 p = vec4(pos,1), p0 = p;  // p.w is the distance estimate
       if(Julia) p0.xyz = JuliaC;

for (int i=0; i<Iterations; i++) {
p.xyz*=rot;
float nx = abs(p.x);
float ny = abs(p.y);
float nz = abs(p.z);

float fx = -2.*fo+nx;
float fy = -2.*fo+ny;
float fz = -2.*fo+nz;
float xf = (fo-abs(-fo+nx));
float yf = (fo-abs(-fo+ny));
float zf = (fo-abs(-fo+nz));
float gx = g+nx;
float gy = g+ny;
float gz = g+nz;

  if (fx > 0 && fx>ny&& fx>nz) {
    if (fx>gy&& fx>gz) {
     // square edge:
     xf += g;
     // orthogonal axis must stay ortho:
     yf = (fo-abs(g-fo+ny));
     zf = (fo-abs(g-fo+nz));
    } else {
     // top:
     xf = -max(ny,nz);
     // orthogonal axis must stay ortho:
     yf = (fo-abs(-3.*fo+max(nx,nz)));
     zf = (fo-abs(-3.*fo+max(ny,nx)));
    }
  }
  else if (fy > 0 && fy>nx&& fy>nz) {
    if (fy>gx&& fy>gz) {
     // square edge:
     yf += g;
    // orthogonal axis must stay ortho:
     xf = (fo-abs(g-fo+nx));
     zf = (fo-abs(g-fo+nz));
    } else {
     // top:
     yf = -max(nx,nz);
     // orthogonal axis must stay ortho:
     xf = (fo-abs(-3.*fo+max(ny,nz)));
     zf = (fo-abs(-3.*fo+max(ny,nx)));
    }
  }
  else if (fz > 0 && fz>nx&& fz>ny) {
    if (fz>gx&& fz>gy) {
     // square edge:
     zf += g;
     // orthogonal axis must stay ortho:
     xf = (fo-abs(g-fo+nx));
     zf = (fo-abs(g-fo+nz));
    } else {
     // top:
     zf = -max(ny,nx);
     // orthogonal axis must stay ortho:
     xf = (fo-abs(-3.*fo+max(ny,nz)));
     yf = (fo-abs(-3.*fo+max(nx,nz)));
    }
  }
             p.x = xf; p.y =yf; p.z = zf;
float r2 = dot(p.xyz, p.xyz);
if (i<ColorIterations) orbitTrap = min(orbitTrap, abs(vec4(p.xyz,r2)));
p *= clamp(max(MinRad2/r2, MinRad2), 0.0, 1.0);  // dp3,div,max.sat,mul
p = p*scale + p0;
             if ( r2>1000.0) break;

}
return ((length(p.xyz) - absScalem1) / p.w - AbsScaleRaisedTo1mIters);
}

This is a slight modification to make it more symmetric. There still are discontinuities:
Code:
#info Mandalay Distance Estimator.
#define providesInit
#include "DE-Raytracer.frag"
#include "MathUtils.frag"
#group Mandalay

// Number of fractal iterations.
uniform int Iterations;  slider[0,17,30]
uniform int ColorIterations;  slider[0,3,30]

uniform float MinRad2;  slider[0,0.25,2.0]

// Scale parameter. A perfect Menger is 3.0
uniform float Scale;  slider[-3.0,3.0,5.0]
vec4 scale = vec4(Scale, Scale, Scale, abs(Scale)) / MinRad2;

uniform float fo; slider[0.,0.5,2.]
uniform float g; slider[0.,0.9,2.]
// precomputed constants

uniform vec3 RotVector; slider[(0,0,0),(1,1,1),(1,1,1)]

// Scale parameter. A perfect Menger is 3.0
uniform float RotAngle; slider[0.00,0,180]

uniform bool Julia; checkbox[false]
uniform vec3 JuliaC; slider[(-2,-2,-2),(0,0,0),(2,2,2)]

mat3 rot;

void init() {
rot = rotationMatrix3(normalize(RotVector), RotAngle);
}

float absScalem1 = abs(Scale - 1.0);
float AbsScaleRaisedTo1mIters = pow(abs(Scale), float(1-Iterations));


// Compute the distance from `pos` to the Mandelbox.
float DE(vec3 pos) {
vec4 p = vec4(pos,1), p0 = p;  // p.w is the distance estimate
       if(Julia) p0.xyz = JuliaC;

for (int i=0; i<Iterations; i++) {
p.xyz*=rot;
vec3 n = abs(p);
if(n.y>n.x) n.xy=n.yx;
      if(n.z>n.y) n.yz=n.zy;
      if(n.y>n.x) n.xy=n.yx;
float fx = -2.*fo+n.x;
float fy = -2.*fo+n.y;
float fz = -2.*fo+n.z;
float xf = (fo-abs(-fo+n.x));
float yf = (fo-abs(-fo+n.y));
float zf = (fo-abs(-fo+n.z));
float gx = g+n.x;
float gy = g+n.y;
float gz = g+n.z;

  if (fx > 0 && fx>n.y && fx>n.z) {
    if (fx>gy&& fx>gz) {
     // square edge:
     xf += g;
     // orthogonal axis must stay ortho:
     yf = (fo-abs(g-fo+n.y));
     zf = (fo-abs(g-fo+n.z));
    } else {
     // top:
     xf = -max(n.y,n.z);
     // orthogonal axis must stay ortho:
     yf = (fo-abs(-3.*fo+max(n.x,n.z)));
     zf = (fo-abs(-3.*fo+max(n.y,n.x)));
    }
  }
             p.x = xf; p.y =yf; p.z = zf;
float r2 = dot(p.xyz, p.xyz);
if (i<ColorIterations) orbitTrap = min(orbitTrap, abs(vec4(p.xyz,r2)));
p *= clamp(max(MinRad2/r2, MinRad2), 0.0, 1.0);  // dp3,div,max.sat,mul
p = p*scale + p0;
             if ( r2>1000.0) break;

}
return ((length(p.xyz) - absScalem1) / p.w - AbsScaleRaisedTo1mIters);
}

I couldn't get anything interesting with "my" folding version.
Logged
DarkBeam
Global Moderator
Fractal Senior
******
Posts: 2512


Fragments of the fractal -like the tip of it


« Reply #18 on: March 08, 2015, 10:35:44 PM »

Oh no...
There must be a method to fix the cuts sad
Will check tomorrow.
The 2d version looked great but did not saved! sad
Logged

No sweat, guardian of wisdom!
Sabine
Fractal Fertilizer
*****
Posts: 373



WWW
« Reply #19 on: March 08, 2015, 11:01:50 PM »


Some rotating too... Not as smart though wink
Logged

sabine62.deviantart.com
Sabine
Fractal Fertilizer
*****
Posts: 373



WWW
« Reply #20 on: March 08, 2015, 11:17:46 PM »



@DarkBeam
Not much, but hey wink Done with Knighty's modification
« Last Edit: March 08, 2015, 11:46:44 PM by sabine62 » Logged

sabine62.deviantart.com
Crist-JRoger
Fractal Fertilizer
*****
Posts: 389



WWW
« Reply #21 on: March 08, 2015, 11:27:39 PM »

This is the original shader. I just added controls for fg, g and juliaC:
...
I couldn't get anything interesting with "my" folding version.
When rotate this, it looks like garbage dump  cheesy So there is and correct geometry too.
And this is a new script for Fragmentarium in a long time... thank you and DarkBeam )

upd.:
This is from first script:

« Last Edit: March 09, 2015, 06:45:19 AM by Crist-JRoger » Logged

DarkBeam
Global Moderator
Fractal Senior
******
Posts: 2512


Fragments of the fractal -like the tip of it


« Reply #22 on: March 09, 2015, 01:26:28 PM »

This solution is 90% perfect! Still cuts but almost never noticeable. cheesy Ty Knighty!

Code:
float DE(vec3 pos) {
vec4 p = vec4(pos,1), p0 = p;  // p.w is the distance estimate
       if(Julia) p0.xyz = JuliaC;

for (int i=0; i<Iterations; i++) {
p.xyz*=rot;
vec3 n = abs(p);
if(n.y>n.x) n.xy=n.yx;
      if(n.z>n.y) n.yz=n.zy;
      if(n.y>n.x) n.xy=n.yx;
float fx = -2.*fo+n.x;
float fy = -2.*fo+n.y;
float fz = -2.*fo+n.z;
float xf = (fo-abs(-fo+n.x));
float yf = (fo-abs(-fo+n.y));
float zf = (fo-abs(-fo+n.z));
float gx = g+n.x;
float gy = g+n.y;
float gz = g+n.z;

  if (fx > 0 && fx>n.y && fx>n.z) {
    if (fx>gy&& fx>gz) {
     // square edge:
     xf += g;
     // orthogonal axis must stay ortho:
     yf = (fo-abs(-g-fo+n.y));
     zf = (fo-abs(-g-fo+n.z));
    } else {
     // top:
     xf = -n.y;
     // orthogonal axis must stay ortho:
     yf = (fo-abs(-3.*fo+n.x));
     zf = fo-(abs(-fo+n.z));
    }
  }
Logged

No sweat, guardian of wisdom!
knighty
Fractal Iambus
***
Posts: 819


« Reply #23 on: March 09, 2015, 03:16:47 PM »

That transformation is fantastic!
Finally got someting that is hopefully without discontinuities thought one have to lower fudge factor.
Enjoy:
Code:
#info Non-Mandalay Distance Estimator.
#define providesInit
#include "DE-Raytracer.frag"
#include "MathUtils.frag"
#group Non_Mandalay

// Number of iterations.
uniform int Iterations;  slider[0,10,20]

// Scale parameter. A perfect Menger is 3.0
uniform float Scale; slider[-4.0,-2,4.00]

uniform vec3 RotVector; slider[(0,0,0),(1,0,0),(1,1,1)]

// Scale parameter. A perfect Menger is 3.0
uniform float RotAngle; slider[0.00,00,360]

uniform vec3 fo; slider[(0.,0,0),(0.5,0.5,0.5),(2.,2.,2.)]
uniform vec3 g; slider[(0.,0,0),(0.1,0.1,0.1),(2.,2.,2.)]
uniform bool Serial; checkbox[false]
//Mandelbox's radial fold
uniform float MinRad2;  slider[0,0.25,2.0]
// Julia
uniform bool Julia; checkbox[false]
uniform vec3 JuliaC; slider[(-2,-2,-2),(1,1,1),(2,2,2)]

mat3 rot;
float sr;
void init() {
rot = rotationMatrix3(normalize(RotVector), RotAngle);
sr = 30.;
}
//DarkBeam's "fold"... reinterpreted... it's more than a fold, much more! Just awesome!
float DBFold(vec3 p, float fo, float g){
if(p.z>p.y) p.yz=p.zy;
float vx=p.x-2.*fo;
float vy=p.y-4.*fo;
  float v=abs(max(vx,vy)+fo)-fo;
float v1=max(vx-g,p.y);
v=min(v,v1);
v1=max(vx+g,2.*fo-p.y);
return min(v,v1);
}
//the coordinates are pushed/pulled in parallel
vec3 DBFoldParallel(vec3 p, vec3 fo, vec3 g){
vec3 p1=p;
p.x=DBFold(p1,fo.x,g.x);
p.y=DBFold(p1.yzx,fo.y,g.y);
p.z=DBFold(p1.zxy,fo.z,g.z);
return p;
}
//serial version
vec3 DBFoldSerial(vec3 p, vec3 fo, vec3 g){
p.x=DBFold(p,fo.x,g.x);
p.y=DBFold(p.yzx,fo.y,g.y);
p.z=DBFold(p.zxy,fo.z,g.z);
return p;
}
float DE(vec3 p)
{
vec4 JC=Julia? vec4(JuliaC,0.) : vec4(p,1.);
float r2=dot(p,p);
float dd = 1.;
for(int i = 0; i<Iterations && r2<10000.; i++){
p=abs(p);

if(Serial) p=DBFoldSerial(p,fo,g);
else p=DBFoldParallel(p,fo,g);

r2=dot(p,p);
//orbitTrap = min(orbitTrap, abs(vec4(p.x,p.y,p.z,r2)));
float  t = clamp(1./r2, 1., 1./MinRad2);
p*=t; dd*=t;

p=p*Scale+JC.xyz; dd=dd*abs(Scale)+JC.w;
p=rot*p;
r2=dot(p,p);
orbitTrap = min(orbitTrap, abs(vec4(p.x,p.y,p.z,r2)));
}
#if 1
return (sqrt(r2)-sr)/dd;//bounding volume is a sphere
#else
p=abs(p); return (max(p.x,max(p.y,p.z))-sr)/dd;//bounding volume is a cube
#endif
}


#preset Default
FOV = 0.56284
Eye = -1.25806,4.3182,1.28612
Target = 0.63661,-4.73449,-1.95634
Up = -0.967592,-0.236269,0.0891205
EquiRectangular = false
FocalPlane = 1
Aperture = 0
Gamma = 1
ToneMapping = 1
Exposure = 1
Brightness = 1
Contrast = 1
Saturation = 1
GaussianWeight = 1
AntiAliasScale = 2
Detail = -3
DetailAO = -1.10789
FudgeFactor = 0.51331
MaxRaySteps = 244
Dither = 0.5
NormalBackStep = 1
AO = 0,0,0,0.89655
Specular = 0.08679
SpecularExp = 16
SpecularMax = 10
SpotLight = 1,1,1,1
SpotLightDir = -0.36066,-0.60656
CamLight = 1,1,1,0.69828
CamLightMin = 0.81301
Glow = 1,1,1,0.17808
GlowMax = 20
Fog = 0
HardShadow = 1
ShadowSoft = 20
Reflection = 0
DebugSun = false
BaseColor = 0.623529,0.623529,0.623529
OrbitStrength = 0.37743
X = 0.5,0.6,0.6,-0.22968
Y = 1,0.6,0,0.44876
Z = 0.8,0.78,1,0.15902
R = 0.4,0.7,1,-0.14184
BackgroundColor = 0.596078,0.6,0.513725
GradientBackground = 0.3
CycleColors = false
Cycles = 7.03846
EnableFloor = false
FloorNormal = 0,0,0
FloorHeight = 0
FloorColor = 1,1,1
Iterations = 12
Scale = -1.79592
RotVector = 1,1,1
RotAngle = 0
MinRad2 = 0.2695
Julia = true
JuliaC = 1.43644,0.04812,-0.9416
fo = 0.3131,0.23642,0.44728
g = 0.14512,0.10726,0.42272
Serial = false
#endpreset


#preset squares
FOV = 0.56284
Eye = -1.96287,4.04877,3.77569
Target = 0.9938,-2.37872,-3.00664
Up = -0.926068,-0.374525,-0.0461524
EquiRectangular = false
FocalPlane = 1
Aperture = 0
Gamma = 1
ToneMapping = 1
Exposure = 1
Brightness = 1
Contrast = 1
Saturation = 1
GaussianWeight = 1
AntiAliasScale = 2
Detail = -3
DetailAO = -1.10789
FudgeFactor = 0.51331
MaxRaySteps = 244
Dither = 0.5
NormalBackStep = 1
AO = 0,0,0,0.89655
Specular = 0.08679
SpecularExp = 16
SpecularMax = 10
SpotLight = 1,1,1,1
SpotLightDir = -0.36066,-0.60656
CamLight = 1,1,1,0.69828
CamLightMin = 0.81301
Glow = 1,1,1,0.17808
GlowMax = 20
Fog = 0
HardShadow = 1
ShadowSoft = 20
Reflection = 0
DebugSun = false
BaseColor = 0.623529,0.623529,0.623529
OrbitStrength = 0.37743
X = 0.5,0.6,0.6,-0.22968
Y = 1,0.6,0,0.44876
Z = 0.8,0.78,1,0.15902
R = 0.4,0.7,1,-0.14184
BackgroundColor = 0.596078,0.6,0.513725
GradientBackground = 0.3
CycleColors = false
Cycles = 7.03846
EnableFloor = false
FloorNormal = 0,0,0
FloorHeight = 0
FloorColor = 1,1,1
Iterations = 12
Scale = -2
RotVector = 1,1,1
RotAngle = 0
MinRad2 = 0.2695
Julia = true
JuliaC = 0.84536,0.29552,-0.84536
fo = 0.08946,0.40894,0.42172
g = 0,0.35332,0.37854
Serial = false
#endpreset

#preset Serial
FOV = 0.56284
Eye = -0.740185,1.57305,2.96597
Target = 1.52048,-2.3518,-5.72538
Up = -0.947187,-0.292735,-0.130931
EquiRectangular = false
FocalPlane = 1
Aperture = 0
Gamma = 1
ToneMapping = 1
Exposure = 1
Brightness = 1
Contrast = 1
Saturation = 1
GaussianWeight = 1
AntiAliasScale = 2
Detail = -3
DetailAO = -1.10789
FudgeFactor = 0.51331
MaxRaySteps = 244
Dither = 0.5
NormalBackStep = 1
AO = 0,0,0,0.89655
Specular = 0.08679
SpecularExp = 16
SpecularMax = 10
SpotLight = 1,1,1,1
SpotLightDir = -0.36066,-0.60656
CamLight = 1,1,1,0.69828
CamLightMin = 0.81301
Glow = 1,1,1,0.17808
GlowMax = 20
Fog = 0
HardShadow = 1
ShadowSoft = 20
Reflection = 0
DebugSun = false
BaseColor = 0.847059,0.847059,0.847059
OrbitStrength = 0.31907
X = 0.5,0.6,0.6,0.32156
Y = 1,0.6,0,0.65372
Z = 0.8,0.78,1,0.68904
R = 0.4,0.7,1,-0.39008
BackgroundColor = 0.596078,0.6,0.513725
GradientBackground = 0.3
CycleColors = false
Cycles = 7.03846
EnableFloor = false
FloorNormal = 0,0,0
FloorHeight = 0
FloorColor = 1,1,1
Iterations = 12
Scale = -2
RotVector = 1,1,1
RotAngle = 0
MinRad2 = 0.2695
Julia = true
JuliaC = 0.50172,0.85912,-1.189
fo = 0.45368,0.40894,0.42172
g = 0,0.35332,0.37854
Serial = true
#endpreset


#preset anotherOne
FOV = 0.56284
Eye = 1.56502,-1.86838,6.47704
Target = -0.57575,0.414304,-2.81064
Up = -0.820632,0.489478,0.294914
EquiRectangular = false
FocalPlane = 1
Aperture = 0
Gamma = 1
ToneMapping = 1
Exposure = 1
Brightness = 1
Contrast = 1
Saturation = 1
GaussianWeight = 1
AntiAliasScale = 2
Detail = -3
DetailAO = -1.10789
FudgeFactor = 0.61977
MaxRaySteps = 244
Dither = 0.5
NormalBackStep = 1
AO = 0,0,0,0.89655
Specular = 0.08679
SpecularExp = 16
SpecularMax = 10
SpotLight = 1,1,1,1
SpotLightDir = -0.36066,-0.60656
CamLight = 1,1,1,0.69828
CamLightMin = 0.81301
Glow = 1,1,1,0.17808
GlowMax = 20
Fog = 0
HardShadow = 1
ShadowSoft = 20
Reflection = 0
DebugSun = false
BaseColor = 0.847059,0.847059,0.847059
OrbitStrength = 0.31907
X = 0.5,0.6,0.6,0.32156
Y = 1,0.6,0,0.65372
Z = 0.8,0.78,1,0.68904
R = 0.4,0.7,1,-0.39008
BackgroundColor = 0.596078,0.6,0.513725
GradientBackground = 0.3
CycleColors = false
Cycles = 7.03846
EnableFloor = false
FloorNormal = 0,0,0
FloorHeight = 0
FloorColor = 1,1,1
Iterations = 12
Scale = -2
RotVector = 1,1,1
RotAngle = 0
MinRad2 = 0.2695
Julia = true
JuliaC = -2,1.4914,-0.87284
fo = 0.65814,0.19808,0.34504
g = 0.39116,0.57414,0.32808
Serial = false
#endpreset

#preset anotherOneOne
FOV = 0.56284
Eye = 2.16929,5.4393,0.457666
Target = -1.47387,-3.61201,-0.467417
Up = 0.14205,-0.160743,0.976721
EquiRectangular = false
FocalPlane = 1
Aperture = 0
Gamma = 1
ToneMapping = 1
Exposure = 1
Brightness = 1
Contrast = 1
Saturation = 1
GaussianWeight = 1
AntiAliasScale = 2
Detail = -3
DetailAO = -1.10789
FudgeFactor = 0.51331
MaxRaySteps = 244
Dither = 0.5
NormalBackStep = 1
AO = 0,0,0,0.89655
Specular = 0.08679
SpecularExp = 16
SpecularMax = 10
SpotLight = 1,1,1,1
SpotLightDir = -0.36066,-0.60656
CamLight = 1,1,1,0.69828
CamLightMin = 0.81301
Glow = 1,1,1,0.17808
GlowMax = 20
Fog = 0
HardShadow = 1
ShadowSoft = 20
Reflection = 0
DebugSun = false
BaseColor = 0.623529,0.623529,0.623529
OrbitStrength = 0.37743
X = 0.5,0.6,0.6,-0.22968
Y = 1,0.6,0,0.44876
Z = 0.8,0.78,1,0.15902
R = 0.4,0.7,1,-0.14184
BackgroundColor = 0.596078,0.6,0.513725
GradientBackground = 0.3
CycleColors = false
Cycles = 7.03846
EnableFloor = false
FloorNormal = 0,0,0
FloorHeight = 0
FloorColor = 1,1,1
Iterations = 12
Scale = -2
RotVector = 1,1,1
RotAngle = 0
MinRad2 = 0.25
Julia = true
JuliaC = 1,-1,1
fo = 0.754,0.28116,0
g = 0.80758,0.0694,0.4164
Serial = true
#endpreset
« Last Edit: March 12, 2015, 08:17:51 PM by knighty » Logged
DarkBeam
Global Moderator
Fractal Senior
******
Posts: 2512


Fragments of the fractal -like the tip of it


« Reply #24 on: March 09, 2015, 04:45:01 PM »

Hehe Knighty cheesy In reality, leave me alone,  embarrass The problem was that we must simply ignore z in the rectangle twiddling, like this;

Code:
float DE(vec3 pos) {
vec4 p = vec4(pos,1), p0 = p;  // p.w is the distance estimate
       if(Julia) p0.xyz = JuliaC;

for (int i=0; i<Iterations; i++) {
p.xyz*=rot;
vec3 n = abs(p);
if(n.y>n.x) n.xy=n.yx;
       if(n.z>n.y) n.yz=n.zy;
       if(n.y>n.x) n.xy=n.yx;
float fx = -2.*fo+n.x;
float fy = -2.*fo+n.y;
float fz = -2.*fo+n.z;
float xf = (fo-abs(-fo+n.x));
float yf = (fo-abs(-fo+n.y));
// float zf = (fo-abs(-fo+n.z)); // NOT necessary!
float zf = n.z; // leave z alone! ;) Or not? It's ok!
float gx = g+n.x;
float gy = g+n.y;
float gz = g+n.z;

  if (fx > 0 && fx>n.y && fx>n.z) {
    if (fx>gy&& fx>gz) {
     // square edge:
     xf += g;
     // orthogonal axis must stay ortho:
     yf = (fo-abs(g-fo+n.y)); // aaaaaaahhh!!! g-fo not -g-fo!!!
     // zf = (fo-abs(-g-fo+n.z)); //NOT touch tsk tsk
    } else {
     // top:
     xf = -n.y;
     // orthogonal axis must stay ortho:
     yf = (fo-abs(-3.*fo+n.x));
     // zf = fo-(abs(-fo+n.z)); //NOT touch tsk tsk
    }
  }

The rest was due to some... errors fiery ... around! wink Now it's perfectly working wink

« Last Edit: March 09, 2015, 05:10:00 PM by DarkBeam » Logged

No sweat, guardian of wisdom!
cKleinhuis
Administrator
Fractal Senior
*******
Posts: 7044


formerly known as 'Trifox'


WWW
« Reply #25 on: March 09, 2015, 04:55:36 PM »

When rotate this, it looks like garbage dump  cheesy So there is and correct geometry too.
And this is a new script for Fragmentarium in a long time... thank you and DarkBeam )

upd.:
This is from first script:

<Quoted Image Removed>

hey cris, this looks just fantastic, i am not aware of you alls latest changes to the rendering scripts, how can i reproduce this ?
...for making an animated version of it cheesy
Logged

---

divide and conquer - iterate and rule - chaos is No random!
DarkBeam
Global Moderator
Fractal Senior
******
Posts: 2512


Fragments of the fractal -like the tip of it


« Reply #26 on: March 09, 2015, 05:14:01 PM »

Omg!!! Knighty your version is even better! shocked alien
Logged

No sweat, guardian of wisdom!
DarkBeam
Global Moderator
Fractal Senior
******
Posts: 2512


Fragments of the fractal -like the tip of it


« Reply #27 on: March 09, 2015, 08:57:42 PM »

Image of the "old" Kifs...

Logged

No sweat, guardian of wisdom!
youhn
Fractal Molossus
**
Posts: 696


Shapes only exists in our heads.


« Reply #28 on: March 09, 2015, 10:49:14 PM »

 Repeating Zooming Self-Silimilar Thumb Up, by Craig
Logged
Crist-JRoger
Fractal Fertilizer
*****
Posts: 389



WWW
« Reply #29 on: March 10, 2015, 04:36:48 AM »

hey cris, this looks just fantastic, i am not aware of you alls latest changes to the rendering scripts, how can i reproduce this ?
...for making an animated version of it cheesy
script from first post, raytracer last modified, need to enable clouds
#define USE_IQ_CLOUDS
This is environment and geometry preset
Code:
#preset Default
FOV = 0.7
Eye = 1.97922,1.4423,-1.09709
Target = -3.09327,-5.43927,-5.88962
FocalPlane = 0.70006
Aperture = 0.01
InFocusAWidth = 1
ApertureNbrSides = 7 NotLocked
ApertureRot = 0
ApStarShaped = false
Gamma = 0.625
ToneMapping = 5
Exposure = 0.98937
Brightness = 1
Contrast = 1
Saturation = 1
GaussianWeight = 1
AntiAliasScale = 2
Bloom = true
BloomIntensity = 1.20588
BloomPow = 4.7059
BloomTaps = 20
Detail = -3.9
DetailAO = -0.37233
FudgeFactor = 1
MaxRaySteps = 736
MaxDistance = 100
Dither = 0.83636
NormalBackStep = 1
AO = 0,0,0,1.11
AoCorrect = 1
Specular = 1.20408
SpecularExp = 286.765
CamLight = 0.701961,0.921569,1,1.6
CamLightMin = 1
Glow = 1,1,1,0
GlowMax = 20
Reflection = 0.27451,0.270588,0.384314
ReflectionsNumber = 0
SpotGlow = true
SpotLight = 1,0.768627,0.501961,1.5517
LightPos = -0.5618,2.3596,3.2584
LightSize = 0.29897
LightFallOff = 0
LightGlowRad = 1.0135
LightGlowExp = 0.73335
HardShadow = 0.98718
ShadowSoft = 0
BaseColor = 1,1,1
OrbitStrength = 0.80822
X = 0.5,0.6,0.6,0.7
Y = 1,0.6,0,0.4
Z = 0.8,0.78,1,0.5
R = 0.4,0.7,1,0.12
BackgroundColor = 0.341176,0.329412,0.423529
GradientBackground = 0
CycleColors = true
Cycles = 2.1
EnableFloor = true
FloorNormal = 0,0,1
FloorHeight = -2.15
FloorColor = 0.223529,0.27451,0.2
HF_Fallof = 2.26342
HF_Const = 0
HF_Intensity = 0.14286
HF_Dir = 0.04854,-0.04854,1
HF_Offset = -0.926
HF_Color = 0.662745,0.8,1,0.64614
HF_Scatter = 5.443
HF_Anisotropy = 0.494118,0.635294,0.662745
HF_FogIter = 16
HF_CastShadow = false
CloudScale = 0.38878
CloudFlatness = 0
CloudTops = 0.03
CloudBase = -8.0542
CloudDensity = 1
CloudRoughness = 0.97516
CloudContrast = 0.625
CloudColor = 0.556863,0.603922,0.690196
SunLightColor = 0.698039,0.556863,0.384314
Iterations = 10
ColorIterations = 6
MinRad2 = 0.12244
Scale = 2.38184
RotVector = 0,0,0.5
RotAngle = 180
Up = -0.210789,-0.44171,0.857353
#endpreset
Logged

Pages: 1 [2] 3   Go Down
  Print  
 
Jump to:  

Related Topics
Subject Started by Replies Views Last post
Special "offset" and "rotate" options from Fractallab possible in M3d-formula? Mandelbulb 3d « 1 2 » SaMMy 18 30948 Last post April 05, 2011, 12:20:52 PM
by DarkBeam
KIFS and the "fold and cut problem" IFS - Iterated Function Systems knighty 5 6110 Last post May 22, 2011, 02:40:25 PM
by knighty
I had a vague idea that "fractal" was related to "pretty pictures" Meet & Greet Repomancer 5 8606 Last post October 10, 2012, 02:04:23 AM
by David Makin
proclamation: "twitch" hybrid type (new) Theories & Research cKleinhuis 6 573 Last post September 02, 2015, 11:49:49 PM
by cKleinhuis
"cannot combine with previous 'type-name' declaration specifier" Bug Reporting vitke 2 2231 Last post January 30, 2016, 05:16:01 PM
by vitke

Powered by MySQL Powered by PHP Powered by SMF 1.1.21 | SMF © 2015, Simple Machines

Valid XHTML 1.0! Valid CSS! Dilber MC Theme by HarzeM
Page created in 0.154 seconds with 25 queries. (Pretty URLs adds 0.011s, 2q)