Rotate PF function?

Started by cyphyr, October 11, 2010, 05:05:37 AM

Previous topic - Next topic

cyphyr

I'm sure I saw a thread about this but I cant find it. It was using a fairly simple (5 nodes?) function network to rotate a Power Fractle about its y axis. I've seen a number of threads looking for the same or similar thing but the usual answer is "hmm, you couldn't do that without functions". Can anybody remember this thread and point me to it?
:)
Cheers
Richard
www.richardfraservfx.com
https://www.facebook.com/RichardFraserVFX/
/|\

Ryzen 9 5950X OC@4Ghz, 64Gb (TG4 benchmark 4:13)

FrankB

I don't know how to rotate a PF, I don't think it's possible (happy to stand corrected) , but I know how to rotate a perlin 3D noise. Copy and paste the below into TG2, and play with the rotate vector node.

Cheers,
Frank

<terragen_clip>
    <constant_scalar
        name = "Constant scalar 02"
        gui_use_node_pos = "1"
        gui_node_pos = "-1160 300 0"
        gui_group = ""
        enable = "1"
        input_node = ""
        gui_use_preview_patch_size = "0"
        gui_preview_patch_size = "1000 1000"
        scalar = "22"
        >
    </constant_scalar>
    <constant_scalar
        name = "Constant scalar 01"
        gui_use_node_pos = "1"
        gui_node_pos = "-1300 260 0"
        gui_group = ""
        enable = "1"
        input_node = ""
        gui_use_preview_patch_size = "0"
        gui_preview_patch_size = "1000 1000"
        scalar = "300"
        >
    </constant_scalar>
    <rotate_y_vector
        name = "Rotate y vector 01"
        gui_use_node_pos = "1"
        gui_node_pos = "-1360 320 0"
        gui_group = ""
        enable = "1"
        input_node = "Get position in texture 01"
        gui_use_preview_patch_size = "0"
        gui_preview_patch_size = "1000 1000"
        angle_about_y = "173.25"
        >
    </rotate_y_vector>
    <perlin_3D_scalar
        name = "Perlin 3D scalar 01"
        gui_use_node_pos = "1"
        gui_node_pos = "-1340 200 0"
        gui_group = ""
        enable = "1"
        input_node = "Rotate y vector 01"
        gui_use_preview_patch_size = "0"
        gui_preview_patch_size = "1000 1000"
        scale = "Constant scalar 01"
        seed = "Constant scalar 02"
        >
    </perlin_3D_scalar>
    <get_position_in_texture
        name = "Get position in texture 01"
        gui_use_node_pos = "1"
        gui_node_pos = "-1380 360 0"
        gui_group = ""
        enable = "1"
        input_node = ""
        gui_use_preview_patch_size = "0"
        gui_preview_patch_size = "1000 1000"
        >
    </get_position_in_texture>
</terragen_clip>

cyphyr

Most excellent, this will do the job VERY nicely :)
Thankyou
Richard
www.richardfraservfx.com
https://www.facebook.com/RichardFraserVFX/
/|\

Ryzen 9 5950X OC@4Ghz, 64Gb (TG4 benchmark 4:13)

FrankB


inkydigit

thanks Frank...always good to learn something new!

dandelO

You can rotate almost any shader by plugging it into the shader array node, including a fractal. Set the shader array to create only one instance of the input shader and use the rotation control to rotate the input shader around Y.

cyphyr

#6
This is what I needed the rotation function for.
Works a treat. I couldn't get your method to work Dandleo on a planetary scale.
Cheers guys
Richard
Ps works animated too  :)
www.richardfraservfx.com
https://www.facebook.com/RichardFraserVFX/
/|\

Ryzen 9 5950X OC@4Ghz, 64Gb (TG4 benchmark 4:13)