This commit is contained in:
Tanasart 2024-03-19 15:49:29 +07:00
parent 8c7fa1712f
commit 258a8bef27
58 changed files with 358 additions and 359 deletions

View file

@ -516,7 +516,7 @@
{"name":"s_node_vfx_osc","order":14,"path":"sprites/s_node_vfx_osc/s_node_vfx_osc.yy",},
{"name":"sh_chromatic_aberration","order":17,"path":"shaders/sh_chromatic_aberration/sh_chromatic_aberration.yy",},
{"name":"fd_rectangle_create_view","order":3,"path":"scripts/fd_rectangle_create_view/fd_rectangle_create_view.yy",},
{"name":"node_fluid_vortex","order":8,"path":"scripts/node_fluid_vortex/node_fluid_vortex.yy",},
{"name":"node_smoke_vortex","order":8,"path":"scripts/node_smoke_vortex/node_smoke_vortex.yy",},
{"name":"node_pb_draw_angle","order":7,"path":"scripts/node_pb_draw_angle/node_pb_draw_angle.yy",},
{"name":"s_node_3d_set_material","order":20,"path":"sprites/s_node_3d_set_material/s_node_3d_set_material.yy",},
{"name":"s_node_replace_palette","order":53,"path":"sprites/s_node_replace_palette/s_node_replace_palette.yy",},
@ -730,7 +730,7 @@
{"name":"node_VFX_renderer","order":2,"path":"scripts/node_VFX_renderer/node_VFX_renderer.yy",},
{"name":"s_node_pb_fx_stack","order":2,"path":"sprites/s_node_pb_fx_stack/s_node_pb_fx_stack.yy",},
{"name":"fd_draw_sprite_to_collision_mask_surface","order":1,"path":"scripts/fd_draw_sprite_to_collision_mask_surface/fd_draw_sprite_to_collision_mask_surface.yy",},
{"name":"node_fluid_render","order":2,"path":"scripts/node_fluid_render/node_fluid_render.yy",},
{"name":"node_smoke_render","order":2,"path":"scripts/node_smoke_render/node_smoke_render.yy",},
{"name":"s_node_invert","order":24,"path":"sprites/s_node_invert/s_node_invert.yy",},
{"name":"sh_color_picker_side_hue","order":2,"path":"shaders/sh_color_picker_side_hue/sh_color_picker_side_hue.yy",},
{"name":"draw_text_delimiter","order":12,"path":"scripts/draw_text_delimiter/draw_text_delimiter.yy",},
@ -849,7 +849,7 @@
{"name":"draw_connect_elbow_diag","order":2,"path":"scripts/draw_connect_elbow_diag/draw_connect_elbow_diag.yy",},
{"name":"s_node_mk_flag","order":5,"path":"sprites/s_node_mk_flag/s_node_mk_flag.yy",},
{"name":"node_pin","order":2,"path":"scripts/node_pin/node_pin.yy",},
{"name":"_node_fluid_nodes","order":7,"path":"scripts/_node_fluid_nodes/_node_fluid_nodes.yy",},
{"name":"_node_smoke","order":7,"path":"scripts/_node_smoke/_node_smoke.yy",},
{"name":"sh_skew","order":6,"path":"shaders/sh_skew/sh_skew.yy",},
{"name":"libxprocess","order":2,"path":"extensions/libxprocess/libxprocess.yy",},
{"name":"fd_rectangle_get_pressure_height","order":16,"path":"scripts/fd_rectangle_get_pressure_height/fd_rectangle_get_pressure_height.yy",},
@ -961,7 +961,7 @@
{"name":"node_average","order":5,"path":"scripts/node_average/node_average.yy",},
{"name":"sh_diffuse_flow","order":1,"path":"shaders/sh_diffuse_flow/sh_diffuse_flow.yy",},
{"name":"node_mesh_transform","order":2,"path":"scripts/node_mesh_transform/node_mesh_transform.yy",},
{"name":"node_fluid_turbulence","order":10,"path":"scripts/node_fluid_turbulence/node_fluid_turbulence.yy",},
{"name":"node_smoke_turbulence","order":10,"path":"scripts/node_smoke_turbulence/node_smoke_turbulence.yy",},
{"name":"sh_sdf","order":1,"path":"shaders/sh_sdf/sh_sdf.yy",},
{"name":"slider","order":15,"path":"scripts/slider/slider.yy",},
{"name":"biterator","order":1,"path":"scripts/biterator/biterator.yy",},
@ -982,7 +982,7 @@
{"name":"node_wiggler","order":2,"path":"scripts/node_wiggler/node_wiggler.yy",},
{"name":"__matrix4","order":6,"path":"scripts/__matrix4/__matrix4.yy",},
{"name":"fd_GUIDE","order":5,"path":"scripts/fd_GUIDE/fd_GUIDE.yy",},
{"name":"node_fluid_update","order":3,"path":"scripts/node_fluid_update/node_fluid_update.yy",},
{"name":"node_smoke_update","order":3,"path":"scripts/node_smoke_update/node_smoke_update.yy",},
{"name":"s_node_grid_noise","order":5,"path":"sprites/s_node_grid_noise/s_node_grid_noise.yy",},
{"name":"fd_rectangle_set_velocity_size","order":16,"path":"scripts/fd_rectangle_set_velocity_size/fd_rectangle_set_velocity_size.yy",},
{"name":"node_image_gif","order":5,"path":"scripts/node_image_gif/node_image_gif.yy",},
@ -1088,7 +1088,7 @@
{"name":"d3d_icosphere","order":4,"path":"scripts/d3d_icosphere/d3d_icosphere.yy",},
{"name":"s_node_edge_detect","order":19,"path":"sprites/s_node_edge_detect/s_node_edge_detect.yy",},
{"name":"FirebaseFirestoreUserFunctions","order":2,"path":"scripts/FirebaseFirestoreUserFunctions/FirebaseFirestoreUserFunctions.yy",},
{"name":"node_fluid_add_collider","order":6,"path":"scripts/node_fluid_add_collider/node_fluid_add_collider.yy",},
{"name":"node_smoke_add_collider","order":6,"path":"scripts/node_smoke_add_collider/node_smoke_add_collider.yy",},
{"name":"node_atlas_get","order":1,"path":"scripts/node_atlas_get/node_atlas_get.yy",},
{"name":"fontScrollBox","order":14,"path":"scripts/fontScrollBox/fontScrollBox.yy",},
{"name":"node_grid_hex","order":2,"path":"scripts/node_grid_hex/node_grid_hex.yy",},
@ -1149,7 +1149,7 @@
{"name":"append_function","order":1,"path":"scripts/append_function/append_function.yy",},
{"name":"node_3dsurf","order":4,"path":"scripts/node_3dsurf/node_3dsurf.yy",},
{"name":"fd_rectangle_reset_target","order":17,"path":"scripts/fd_rectangle_reset_target/fd_rectangle_reset_target.yy",},
{"name":"node_fluid_group_inline","order":12,"path":"scripts/node_fluid_group_inline/node_fluid_group_inline.yy",},
{"name":"node_smoke_group_inline","order":12,"path":"scripts/node_smoke_group_inline/node_smoke_group_inline.yy",},
{"name":"node_rate_remap","order":3,"path":"scripts/node_rate_remap/node_rate_remap.yy",},
{"name":"s_node_dynasurf","order":3,"path":"sprites/s_node_dynasurf/s_node_dynasurf.yy",},
{"name":"obj_reader","order":2,"path":"scripts/obj_reader/obj_reader.yy",},
@ -1200,7 +1200,7 @@
{"name":"sh_d3d_normal_blur","order":25,"path":"shaders/sh_d3d_normal_blur/sh_d3d_normal_blur.yy",},
{"name":"FirebaseREST_firestore_value_json","order":17,"path":"scripts/FirebaseREST_firestore_value_json/FirebaseREST_firestore_value_json.yy",},
{"name":"d3d_vertex","order":10,"path":"scripts/d3d_vertex/d3d_vertex.yy",},
{"name":"node_fluid_render_output","order":11,"path":"scripts/node_fluid_render_output/node_fluid_render_output.yy",},
{"name":"node_smoke_render_output","order":11,"path":"scripts/node_smoke_render_output/node_smoke_render_output.yy",},
{"name":"s_node_vfx_output","order":11,"path":"sprites/s_node_vfx_output/s_node_vfx_output.yy",},
{"name":"sh_greyscale","order":13,"path":"shaders/sh_greyscale/sh_greyscale.yy",},
{"name":"s_node_pb_box_mirror","order":21,"path":"sprites/s_node_pb_box_mirror/s_node_pb_box_mirror.yy",},
@ -1237,7 +1237,7 @@
{"name":"sh_bloom_pass","order":2,"path":"shaders/sh_bloom_pass/sh_bloom_pass.yy",},
{"name":"fd_rectangle_draw_view","order":4,"path":"scripts/fd_rectangle_draw_view/fd_rectangle_draw_view.yy",},
{"name":"fd_rectangle_set_material_type","order":9,"path":"scripts/fd_rectangle_set_material_type/fd_rectangle_set_material_type.yy",},
{"name":"node_fluid_domain_queue","order":9,"path":"scripts/node_fluid_domain_queue/node_fluid_domain_queue.yy",},
{"name":"node_smoke_domain_queue","order":9,"path":"scripts/node_smoke_domain_queue/node_smoke_domain_queue.yy",},
{"name":"node_spherize","order":6,"path":"scripts/node_spherize/node_spherize.yy",},
{"name":"node_sequence_anim","order":3,"path":"scripts/node_sequence_anim/node_sequence_anim.yy",},
{"name":"sh_blend_replace","order":50,"path":"shaders/sh_blend_replace/sh_blend_replace.yy",},
@ -1328,7 +1328,7 @@
{"name":"surfaceBox","order":22,"path":"scripts/surfaceBox/surfaceBox.yy",},
{"name":"s_node_array_composite","order":17,"path":"sprites/s_node_array_composite/s_node_array_composite.yy",},
{"name":"node_gradient_palette","order":11,"path":"scripts/node_gradient_palette/node_gradient_palette.yy",},
{"name":"node_fluid_domain","order":1,"path":"scripts/node_fluid_domain/node_fluid_domain.yy",},
{"name":"node_smoke_domain","order":1,"path":"scripts/node_smoke_domain/node_smoke_domain.yy",},
{"name":"Obj_FirebaseFirestore_Collection_Query_LessEqualThan","order":6,"path":"objects/Obj_FirebaseFirestore_Collection_Query_LessEqualThan/Obj_FirebaseFirestore_Collection_Query_LessEqualThan.yy",},
{"name":"s_node_repeat","order":23,"path":"sprites/s_node_repeat/s_node_repeat.yy",},
{"name":"s_node_array_length","order":5,"path":"sprites/s_node_array_length/s_node_array_length.yy",},
@ -1545,7 +1545,7 @@
{"name":"sh_cell_noise_random","order":3,"path":"shaders/sh_cell_noise_random/sh_cell_noise_random.yy",},
{"name":"node_iterator_input","order":1,"path":"scripts/node_iterator_input/node_iterator_input.yy",},
{"name":"s_node_atlas","order":5,"path":"sprites/s_node_atlas/s_node_atlas.yy",},
{"name":"node_fluid_add","order":4,"path":"scripts/node_fluid_add/node_fluid_add.yy",},
{"name":"node_smoke_add","order":4,"path":"scripts/node_smoke_add/node_smoke_add.yy",},
{"name":"sh_d3d_geometry","order":23,"path":"shaders/sh_d3d_geometry/sh_d3d_geometry.yy",},
{"name":"__panel_linear_setting","order":8,"path":"scripts/__panel_linear_setting/__panel_linear_setting.yy",},
{"name":"BBMOD_Quaternion","order":3,"path":"scripts/BBMOD_Quaternion/BBMOD_Quaternion.yy",},
@ -1716,7 +1716,7 @@
{"name":"Obj_FirebaseFirestore_Document_Update","order":7,"path":"objects/Obj_FirebaseFirestore_Document_Update/Obj_FirebaseFirestore_Document_Update.yy",},
{"name":"node_transform_single","order":1,"path":"scripts/node_transform_single/node_transform_single.yy",},
{"name":"node_string_length","order":7,"path":"scripts/node_string_length/node_string_length.yy",},
{"name":"node_fluid_apply_velocity","order":5,"path":"scripts/node_fluid_apply_velocity/node_fluid_apply_velocity.yy",},
{"name":"node_smoke_apply_velocity","order":5,"path":"scripts/node_smoke_apply_velocity/node_smoke_apply_velocity.yy",},
{"name":"s_node_path_transform","order":5,"path":"sprites/s_node_path_transform/s_node_path_transform.yy",},
{"name":"s_node_path_blend","order":1,"path":"sprites/s_node_path_blend/s_node_path_blend.yy",},
{"name":"s_biterator_tab_active","order":12,"path":"sprites/s_biterator_tab_active/s_biterator_tab_active.yy",},

View file

@ -739,7 +739,7 @@
{"id":{"name":"s_node_vfx_osc","path":"sprites/s_node_vfx_osc/s_node_vfx_osc.yy",},},
{"id":{"name":"sh_chromatic_aberration","path":"shaders/sh_chromatic_aberration/sh_chromatic_aberration.yy",},},
{"id":{"name":"fd_rectangle_create_view","path":"scripts/fd_rectangle_create_view/fd_rectangle_create_view.yy",},},
{"id":{"name":"node_fluid_vortex","path":"scripts/node_fluid_vortex/node_fluid_vortex.yy",},},
{"id":{"name":"node_smoke_vortex","path":"scripts/node_smoke_vortex/node_smoke_vortex.yy",},},
{"id":{"name":"node_pb_draw_angle","path":"scripts/node_pb_draw_angle/node_pb_draw_angle.yy",},},
{"id":{"name":"s_node_3d_set_material","path":"sprites/s_node_3d_set_material/s_node_3d_set_material.yy",},},
{"id":{"name":"s_node_replace_palette","path":"sprites/s_node_replace_palette/s_node_replace_palette.yy",},},
@ -979,7 +979,7 @@
{"id":{"name":"node_VFX_renderer","path":"scripts/node_VFX_renderer/node_VFX_renderer.yy",},},
{"id":{"name":"s_node_pb_fx_stack","path":"sprites/s_node_pb_fx_stack/s_node_pb_fx_stack.yy",},},
{"id":{"name":"fd_draw_sprite_to_collision_mask_surface","path":"scripts/fd_draw_sprite_to_collision_mask_surface/fd_draw_sprite_to_collision_mask_surface.yy",},},
{"id":{"name":"node_fluid_render","path":"scripts/node_fluid_render/node_fluid_render.yy",},},
{"id":{"name":"node_smoke_render","path":"scripts/node_smoke_render/node_smoke_render.yy",},},
{"id":{"name":"s_node_invert","path":"sprites/s_node_invert/s_node_invert.yy",},},
{"id":{"name":"sh_color_picker_side_hue","path":"shaders/sh_color_picker_side_hue/sh_color_picker_side_hue.yy",},},
{"id":{"name":"draw_text_delimiter","path":"scripts/draw_text_delimiter/draw_text_delimiter.yy",},},
@ -1118,7 +1118,7 @@
{"id":{"name":"draw_connect_elbow_diag","path":"scripts/draw_connect_elbow_diag/draw_connect_elbow_diag.yy",},},
{"id":{"name":"s_node_mk_flag","path":"sprites/s_node_mk_flag/s_node_mk_flag.yy",},},
{"id":{"name":"node_pin","path":"scripts/node_pin/node_pin.yy",},},
{"id":{"name":"_node_fluid_nodes","path":"scripts/_node_fluid_nodes/_node_fluid_nodes.yy",},},
{"id":{"name":"_node_smoke","path":"scripts/_node_smoke/_node_smoke.yy",},},
{"id":{"name":"sh_noise","path":"shaders/sh_noise/sh_noise.yy",},},
{"id":{"name":"sh_skew","path":"shaders/sh_skew/sh_skew.yy",},},
{"id":{"name":"libxprocess","path":"extensions/libxprocess/libxprocess.yy",},},
@ -1183,7 +1183,7 @@
{"id":{"name":"node_byte_file_write","path":"scripts/node_byte_file_write/node_byte_file_write.yy",},},
{"id":{"name":"node_iterator_length","path":"scripts/node_iterator_length/node_iterator_length.yy",},},
{"id":{"name":"node_VFX_attract","path":"scripts/node_VFX_attract/node_VFX_attract.yy",},},
{"id":{"name":"node_fluid_repulse","path":"scripts/node_fluid_repulse/node_fluid_repulse.yy",},},
{"id":{"name":"node_smoke_repulse","path":"scripts/node_smoke_repulse/node_smoke_repulse.yy",},},
{"id":{"name":"sh_d3d_ssao_blur","path":"shaders/sh_d3d_ssao_blur/sh_d3d_ssao_blur.yy",},},
{"id":{"name":"function_register","path":"scripts/function_register/function_register.yy",},},
{"id":{"name":"panel_addon","path":"scripts/panel_addon/panel_addon.yy",},},
@ -1244,7 +1244,7 @@
{"id":{"name":"node_average","path":"scripts/node_average/node_average.yy",},},
{"id":{"name":"sh_diffuse_flow","path":"shaders/sh_diffuse_flow/sh_diffuse_flow.yy",},},
{"id":{"name":"node_mesh_transform","path":"scripts/node_mesh_transform/node_mesh_transform.yy",},},
{"id":{"name":"node_fluid_turbulence","path":"scripts/node_fluid_turbulence/node_fluid_turbulence.yy",},},
{"id":{"name":"node_smoke_turbulence","path":"scripts/node_smoke_turbulence/node_smoke_turbulence.yy",},},
{"id":{"name":"sh_sdf","path":"shaders/sh_sdf/sh_sdf.yy",},},
{"id":{"name":"slider","path":"scripts/slider/slider.yy",},},
{"id":{"name":"biterator","path":"scripts/biterator/biterator.yy",},},
@ -1266,7 +1266,7 @@
{"id":{"name":"node_wiggler","path":"scripts/node_wiggler/node_wiggler.yy",},},
{"id":{"name":"__matrix4","path":"scripts/__matrix4/__matrix4.yy",},},
{"id":{"name":"fd_GUIDE","path":"scripts/fd_GUIDE/fd_GUIDE.yy",},},
{"id":{"name":"node_fluid_update","path":"scripts/node_fluid_update/node_fluid_update.yy",},},
{"id":{"name":"node_smoke_update","path":"scripts/node_smoke_update/node_smoke_update.yy",},},
{"id":{"name":"s_node_checker","path":"sprites/s_node_checker/s_node_checker.yy",},},
{"id":{"name":"s_node_grid_noise","path":"sprites/s_node_grid_noise/s_node_grid_noise.yy",},},
{"id":{"name":"Room_FirebaseFirestore","path":"rooms/Room_FirebaseFirestore/Room_FirebaseFirestore.yy",},},
@ -1391,7 +1391,7 @@
{"id":{"name":"d3d_icosphere","path":"scripts/d3d_icosphere/d3d_icosphere.yy",},},
{"id":{"name":"s_node_edge_detect","path":"sprites/s_node_edge_detect/s_node_edge_detect.yy",},},
{"id":{"name":"FirebaseFirestoreUserFunctions","path":"scripts/FirebaseFirestoreUserFunctions/FirebaseFirestoreUserFunctions.yy",},},
{"id":{"name":"node_fluid_add_collider","path":"scripts/node_fluid_add_collider/node_fluid_add_collider.yy",},},
{"id":{"name":"node_smoke_add_collider","path":"scripts/node_smoke_add_collider/node_smoke_add_collider.yy",},},
{"id":{"name":"node_atlas_get","path":"scripts/node_atlas_get/node_atlas_get.yy",},},
{"id":{"name":"fontScrollBox","path":"scripts/fontScrollBox/fontScrollBox.yy",},},
{"id":{"name":"node_grid_hex","path":"scripts/node_grid_hex/node_grid_hex.yy",},},
@ -1457,7 +1457,7 @@
{"id":{"name":"append_function","path":"scripts/append_function/append_function.yy",},},
{"id":{"name":"node_3dsurf","path":"scripts/node_3dsurf/node_3dsurf.yy",},},
{"id":{"name":"fd_rectangle_reset_target","path":"scripts/fd_rectangle_reset_target/fd_rectangle_reset_target.yy",},},
{"id":{"name":"node_fluid_group_inline","path":"scripts/node_fluid_group_inline/node_fluid_group_inline.yy",},},
{"id":{"name":"node_smoke_group_inline","path":"scripts/node_smoke_group_inline/node_smoke_group_inline.yy",},},
{"id":{"name":"node_rate_remap","path":"scripts/node_rate_remap/node_rate_remap.yy",},},
{"id":{"name":"s_node_dynasurf","path":"sprites/s_node_dynasurf/s_node_dynasurf.yy",},},
{"id":{"name":"obj_reader","path":"scripts/obj_reader/obj_reader.yy",},},
@ -1514,7 +1514,7 @@
{"id":{"name":"sh_d3d_normal_blur","path":"shaders/sh_d3d_normal_blur/sh_d3d_normal_blur.yy",},},
{"id":{"name":"FirebaseREST_firestore_value_json","path":"scripts/FirebaseREST_firestore_value_json/FirebaseREST_firestore_value_json.yy",},},
{"id":{"name":"d3d_vertex","path":"scripts/d3d_vertex/d3d_vertex.yy",},},
{"id":{"name":"node_fluid_render_output","path":"scripts/node_fluid_render_output/node_fluid_render_output.yy",},},
{"id":{"name":"node_smoke_render_output","path":"scripts/node_smoke_render_output/node_smoke_render_output.yy",},},
{"id":{"name":"s_node_vfx_output","path":"sprites/s_node_vfx_output/s_node_vfx_output.yy",},},
{"id":{"name":"sh_greyscale","path":"shaders/sh_greyscale/sh_greyscale.yy",},},
{"id":{"name":"s_node_pb_box_mirror","path":"sprites/s_node_pb_box_mirror/s_node_pb_box_mirror.yy",},},
@ -1555,7 +1555,7 @@
{"id":{"name":"fd_rectangle_draw_view","path":"scripts/fd_rectangle_draw_view/fd_rectangle_draw_view.yy",},},
{"id":{"name":"fd_rectangle_set_material_type","path":"scripts/fd_rectangle_set_material_type/fd_rectangle_set_material_type.yy",},},
{"id":{"name":"node_seperate_shape","path":"scripts/node_seperate_shape/node_seperate_shape.yy",},},
{"id":{"name":"node_fluid_domain_queue","path":"scripts/node_fluid_domain_queue/node_fluid_domain_queue.yy",},},
{"id":{"name":"node_smoke_domain_queue","path":"scripts/node_smoke_domain_queue/node_smoke_domain_queue.yy",},},
{"id":{"name":"node_spherize","path":"scripts/node_spherize/node_spherize.yy",},},
{"id":{"name":"node_sequence_anim","path":"scripts/node_sequence_anim/node_sequence_anim.yy",},},
{"id":{"name":"sh_blend_replace","path":"shaders/sh_blend_replace/sh_blend_replace.yy",},},
@ -1657,7 +1657,7 @@
{"id":{"name":"surfaceBox","path":"scripts/surfaceBox/surfaceBox.yy",},},
{"id":{"name":"s_node_array_composite","path":"sprites/s_node_array_composite/s_node_array_composite.yy",},},
{"id":{"name":"node_gradient_palette","path":"scripts/node_gradient_palette/node_gradient_palette.yy",},},
{"id":{"name":"node_fluid_domain","path":"scripts/node_fluid_domain/node_fluid_domain.yy",},},
{"id":{"name":"node_smoke_domain","path":"scripts/node_smoke_domain/node_smoke_domain.yy",},},
{"id":{"name":"Obj_FirebaseFirestore_Collection_Query_LessEqualThan","path":"objects/Obj_FirebaseFirestore_Collection_Query_LessEqualThan/Obj_FirebaseFirestore_Collection_Query_LessEqualThan.yy",},},
{"id":{"name":"s_node_repeat","path":"sprites/s_node_repeat/s_node_repeat.yy",},},
{"id":{"name":"s_node_array_length","path":"sprites/s_node_array_length/s_node_array_length.yy",},},
@ -1680,7 +1680,7 @@
{"id":{"name":"d3d_surface_extrude","path":"scripts/d3d_surface_extrude/d3d_surface_extrude.yy",},},
{"id":{"name":"sh_mk_tile18_edge_b","path":"shaders/sh_mk_tile18_edge_b/sh_mk_tile18_edge_b.yy",},},
{"id":{"name":"node_mesh_to_path","path":"scripts/node_mesh_to_path/node_mesh_to_path.yy",},},
{"id":{"name":"node_fluid_group","path":"scripts/node_fluid_group/node_fluid_group.yy",},},
{"id":{"name":"node_smoke_group","path":"scripts/node_smoke_group/node_smoke_group.yy",},},
{"id":{"name":"sh_kuwahara_ani","path":"shaders/sh_kuwahara_ani/sh_kuwahara_ani.yy",},},
{"id":{"name":"sh_convolution","path":"shaders/sh_convolution/sh_convolution.yy",},},
{"id":{"name":"FirebaseREST_HTTP_Failed_Firestore","path":"scripts/FirebaseREST_HTTP_Failed_Firestore/FirebaseREST_HTTP_Failed_Firestore.yy",},},
@ -1905,7 +1905,7 @@
{"id":{"name":"sh_cell_noise_random","path":"shaders/sh_cell_noise_random/sh_cell_noise_random.yy",},},
{"id":{"name":"node_iterator_input","path":"scripts/node_iterator_input/node_iterator_input.yy",},},
{"id":{"name":"s_node_atlas","path":"sprites/s_node_atlas/s_node_atlas.yy",},},
{"id":{"name":"node_fluid_add","path":"scripts/node_fluid_add/node_fluid_add.yy",},},
{"id":{"name":"node_smoke_add","path":"scripts/node_smoke_add/node_smoke_add.yy",},},
{"id":{"name":"sh_d3d_geometry","path":"shaders/sh_d3d_geometry/sh_d3d_geometry.yy",},},
{"id":{"name":"__panel_linear_setting","path":"scripts/__panel_linear_setting/__panel_linear_setting.yy",},},
{"id":{"name":"BBMOD_Quaternion","path":"scripts/BBMOD_Quaternion/BBMOD_Quaternion.yy",},},
@ -2105,7 +2105,7 @@
{"id":{"name":"Obj_FirebaseFirestore_Document_Update","path":"objects/Obj_FirebaseFirestore_Document_Update/Obj_FirebaseFirestore_Document_Update.yy",},},
{"id":{"name":"node_transform_single","path":"scripts/node_transform_single/node_transform_single.yy",},},
{"id":{"name":"node_string_length","path":"scripts/node_string_length/node_string_length.yy",},},
{"id":{"name":"node_fluid_apply_velocity","path":"scripts/node_fluid_apply_velocity/node_fluid_apply_velocity.yy",},},
{"id":{"name":"node_smoke_apply_velocity","path":"scripts/node_smoke_apply_velocity/node_smoke_apply_velocity.yy",},},
{"id":{"name":"s_node_path_transform","path":"sprites/s_node_path_transform/s_node_path_transform.yy",},},
{"id":{"name":"s_node_sdf","path":"sprites/s_node_sdf/s_node_sdf.yy",},},
{"id":{"name":"s_node_path_blend","path":"sprites/s_node_path_blend/s_node_path_blend.yy",},},

Binary file not shown.

Before

Width:  |  Height:  |  Size: 80 KiB

After

Width:  |  Height:  |  Size: 80 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 80 KiB

After

Width:  |  Height:  |  Size: 80 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 58 KiB

After

Width:  |  Height:  |  Size: 58 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 58 KiB

After

Width:  |  Height:  |  Size: 58 KiB

View file

@ -1,4 +1,4 @@
function Node_Fluid(_x, _y, _group = noone) : Node(_x, _y, _group) constructor {
function Node_Smoke(_x, _y, _group = noone) : Node(_x, _y, _group) constructor {
color = COLORS.node_blend_smoke;
icon = THEME.smoke_sim;
update_on_frame = true;

View file

@ -1,7 +1,7 @@
{
"resourceType": "GMScript",
"resourceVersion": "1.0",
"name": "node_fluid_add",
"name": "_node_smoke",
"isCompatibility": false,
"isDnD": false,
"parent": {

View file

@ -38,6 +38,14 @@ function Node_Combine_HSV(_x, _y, _group = noone) : Node_Processor(_x, _y, _grou
var _v = _arr? array_safe_get(_data[5], 2) : _data[2];
var _a = _arr? array_safe_get(_data[5], 3) : _data[3];
var _baseS = is_surface(_h)? _h : (is_surface(_s)? _s : _v);
if(!is_surface(_baseS)) return _outSurf;
var _ww = surface_get_width_safe(_baseS);
var _hh = surface_get_height_safe(_baseS);
_outSurf = surface_verify(_outSurf, _ww, _hh);
surface_set_shader(_outSurf, sh_combine_hsv);
shader_set_surface("samH", _h);
shader_set_surface("samS", _s);
@ -49,7 +57,7 @@ function Node_Combine_HSV(_x, _y, _group = noone) : Node_Processor(_x, _y, _grou
shader_set_i("useV", is_surface(_v));
shader_set_i("useA", is_surface(_a));
draw_sprite_stretched(s_fx_pixel, 0, 0, 0, surface_get_width_safe(_outSurf), surface_get_width_safe(_outSurf));
draw_sprite_stretched(s_fx_pixel, 0, 0, 0, _ww, _hh);
surface_reset_shader();
return _outSurf;

View file

@ -55,12 +55,13 @@ function Node_Combine_RGB(_x, _y, _group = noone) : Node_Processor(_x, _y, _grou
var _b = _arr? array_safe_get(_data[8], 2) : _data[2];
var _a = _arr? array_safe_get(_data[8], 3) : _data[3];
var _baseS = _r;
if(!is_surface(_baseS)) _baseS = _g;
if(!is_surface(_baseS)) _baseS = _b;
var _baseS = is_surface(_r)? _r : (is_surface(_g)? _g : _b);
if(!is_surface(_baseS)) return _outSurf;
_outSurf = surface_verify(_outSurf, surface_get_width_safe(_baseS), surface_get_height_safe(_baseS));
var _ww = surface_get_width_safe(_baseS);
var _hh = surface_get_height_safe(_baseS);
_outSurf = surface_verify(_outSurf, _ww, _hh);
surface_set_shader(_outSurf, sh_combine_rgb);
@ -77,7 +78,8 @@ function Node_Combine_RGB(_x, _y, _group = noone) : Node_Processor(_x, _y, _grou
shader_set_i("mode", !_data[4]);
shader_set_f_map("base", _data[5], _data[6], inputs[| 5]);
draw_sprite_stretched(s_fx_pixel, 0, 0, 0, surface_get_width_safe(_outSurf), surface_get_height_safe(_outSurf));
draw_sprite_stretched(s_fx_pixel, 0, 0, 0, _ww, _hh);
surface_reset_shader();
return _outSurf;

View file

@ -6,14 +6,14 @@ function Node_Diffuse(_x, _y, _group = noone) : Node(_x, _y, _group) constructor
inputs[| 1] = nodeValue("Dissipation", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 0.05)
.setDisplay(VALUE_DISPLAY.slider, { range: [ -0.2, 0.2, 0.001] });
inputs[| 2] = nodeValue("Scale", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 4)
inputs[| 2] = nodeValue("Scale", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 1);
inputs[| 3] = nodeValue("Randomness", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 100)
inputs[| 3] = nodeValue("Randomness", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 1);
inputs[| 4] = nodeValue("Flow rate", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 0.1)
.setDisplay(VALUE_DISPLAY.slider, { range: [ 0, 0.2, 0.001] });
inputs[| 4] = nodeValue("Flow rate", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 0.5)
.setDisplay(VALUE_DISPLAY.slider, { range: [ 0, 1, 0.01] });
inputs[| 5] = nodeValue("Thershold", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, [ 0.5, 0.7 ])
inputs[| 5] = nodeValue("Threshold", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, [ 0.5, 0.7 ])
.setDisplay(VALUE_DISPLAY.slider_range);
inputs[| 6] = nodeValue("Seed", self, JUNCTION_CONNECT.input, VALUE_TYPE.integer, seed_random())
@ -34,17 +34,7 @@ function Node_Diffuse(_x, _y, _group = noone) : Node(_x, _y, _group) constructor
["Rendering", false], 5,
]
temp_surface = [ surface_create(1, 1), surface_create(1, 1), surface_create(1, 1) ];
bufferStore.velocity = buffer_create(1, buffer_grow, 4);
static drawOverlay = function(hover, active, _x, _y, _s, _mx, _my, _snx, _sny) { #region
var _surf = getInputData(0);
var _sw = surface_get_width_safe(_surf);
var _sh = surface_get_height_safe(_surf);
if(!surface_valid(temp_surface[2], _sw, _sh)) return;
} #endregion
temp_surface = [ surface_create(1, 1), surface_create(1, 1) ];
static update = function() {
var _surf = getInputData(0);
@ -56,15 +46,17 @@ function Node_Diffuse(_x, _y, _group = noone) : Node(_x, _y, _group) constructor
var _seed = getInputData(6);
var _fstr = getInputData(8);
var _detl = getInputData(9);
if(!is_surface(_surf)) return;
var _sw = surface_get_width_safe(_surf);
var _sh = surface_get_height_safe(_surf);
var _outSurf = outputs[| 0].getValue();
_outSurf = surface_verify(_outSurf, _sw, _sh);
temp_surface[0] = surface_verify(temp_surface[0], _sw, _sh);
temp_surface[1] = surface_verify(temp_surface[1], _sw, _sh);
_outSurf = surface_verify(_outSurf, _sw, _sh);
for( var i = 0, n = array_length(temp_surface); i < n; i++ )
temp_surface[i] = surface_verify(temp_surface[i], _sw, _sh);
surface_set_shader(temp_surface[0], sh_diffuse_dissipate);
shader_set_f("dimension", _sw, _sh);
@ -73,32 +65,13 @@ function Node_Diffuse(_x, _y, _group = noone) : Node(_x, _y, _group) constructor
draw_surface_safe(_surf);
surface_reset_shader();
#region velocity
temp_surface[2] = surface_from_buffer(bufferStore.velocity);
if(!surface_valid(temp_surface[2], _sw, _sh, surface_rgba16float)) {
surface_free(temp_surface[2]);
temp_surface[2] = surface_create(_sw, _sh, surface_rgba16float);
surface_clear(temp_surface[2]);
bufferStore.velocity = buffer_from_surface(temp_surface[2]);
}
surface_set_shader(temp_surface[2], sh_vector_diverge,, BLEND.add);
draw_sprite_stretched(s_fx_pixel, 0, 0, 0, _sw, _sh);
surface_reset_shader();
#endregion
surface_set_shader(temp_surface[1], sh_diffuse_flow);
shader_set_f("dimension", _sw, _sh);
shader_set_f("scale", _scal);
shader_set_i("detail", _detl);
shader_set_i("iteration", _detl);
shader_set_f("flowRate", _flow);
shader_set_f("seed", _seed + CURRENT_FRAME / _rand);
shader_set_i("useExternal", is_surface(temp_surface[2]));
shader_set_f("externalStrength", _fstr);
shader_set_surface("externalForce", temp_surface[2]);
shader_set_f("seed", _seed + CURRENT_FRAME * _rand / 100);
shader_set_f("externalForce", _fstr);
draw_surface_safe(temp_surface[0]);
surface_reset_shader();

View file

@ -15,7 +15,7 @@ function Node_Flood_Fill(_x, _y, _group = noone) : Node_Processor(_x, _y, _group
inputs[| 4] = nodeValue("Position", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, [ 1, 1 ])
.setDisplay(VALUE_DISPLAY.vector);
inputs[| 5] = nodeValue("Colors", self, JUNCTION_CONNECT.input, VALUE_TYPE.color, cola(c_black) )
inputs[| 5] = nodeValue("Colors", self, JUNCTION_CONNECT.input, VALUE_TYPE.color, cola(c_black) );
inputs[| 6] = nodeValue("Threshold", self, JUNCTION_CONNECT.input, VALUE_TYPE.float, 0.1)
.setDisplay(VALUE_DISPLAY.slider);

View file

@ -1,11 +0,0 @@
{
"resourceType": "GMScript",
"resourceVersion": "1.0",
"name": "node_fluid_domain_queue",
"isCompatibility": false,
"isDnD": false,
"parent": {
"name": "smokeSim",
"path": "folders/nodes/data/simulation/smokeSim.yy",
},
}

View file

@ -1,11 +0,0 @@
{
"resourceType": "GMScript",
"resourceVersion": "1.0",
"name": "node_fluid_group_inline",
"isCompatibility": false,
"isDnD": false,
"parent": {
"name": "smokeSim",
"path": "folders/nodes/data/simulation/smokeSim.yy",
},
}

View file

@ -1,11 +0,0 @@
{
"resourceType": "GMScript",
"resourceVersion": "1.0",
"name": "node_fluid_render",
"isCompatibility": false,
"isDnD": false,
"parent": {
"name": "smokeSim",
"path": "folders/nodes/data/simulation/smokeSim.yy",
},
}

View file

@ -1,11 +0,0 @@
{
"resourceType": "GMScript",
"resourceVersion": "1.0",
"name": "node_fluid_render_output",
"isCompatibility": false,
"isDnD": false,
"parent": {
"name": "smokeSim",
"path": "folders/nodes/data/simulation/smokeSim.yy",
},
}

View file

@ -1,11 +0,0 @@
{
"resourceType": "GMScript",
"resourceVersion": "1.0",
"name": "node_fluid_repulse",
"isCompatibility": false,
"isDnD": false,
"parent": {
"name": "smokeSim",
"path": "folders/nodes/data/simulation/smokeSim.yy",
},
}

View file

@ -1,11 +0,0 @@
{
"resourceType": "GMScript",
"resourceVersion": "1.0",
"name": "node_fluid_turbulence",
"isCompatibility": false,
"isDnD": false,
"parent": {
"name": "smokeSim",
"path": "folders/nodes/data/simulation/smokeSim.yy",
},
}

View file

@ -1,11 +0,0 @@
{
"resourceType": "GMScript",
"resourceVersion": "1.0",
"name": "node_fluid_update",
"isCompatibility": false,
"isDnD": false,
"parent": {
"name": "smokeSim",
"path": "folders/nodes/data/simulation/smokeSim.yy",
},
}

View file

@ -1,11 +0,0 @@
{
"resourceType": "GMScript",
"resourceVersion": "1.0",
"name": "node_fluid_vortex",
"isCompatibility": false,
"isDnD": false,
"parent": {
"name": "smokeSim",
"path": "folders/nodes/data/simulation/smokeSim.yy",
},
}

View file

@ -3,6 +3,8 @@ function Node_HSV_Channel(_x, _y, _group = noone) : Node_Processor(_x, _y, _grou
inputs[| 0] = nodeValue("Surface in", self, JUNCTION_CONNECT.input, VALUE_TYPE.surface, noone);
inputs[| 1] = nodeValue("Output Array", self, JUNCTION_CONNECT.input, VALUE_TYPE.boolean, false);
outputs[| 0] = nodeValue("Hue", self, JUNCTION_CONNECT.output, VALUE_TYPE.surface, noone);
outputs[| 1] = nodeValue("Saturation", self, JUNCTION_CONNECT.output, VALUE_TYPE.surface, noone);
outputs[| 2] = nodeValue("Value", self, JUNCTION_CONNECT.output, VALUE_TYPE.surface, noone);
@ -10,20 +12,58 @@ function Node_HSV_Channel(_x, _y, _group = noone) : Node_Processor(_x, _y, _grou
attribute_surface_depth();
static processData = function(_outSurf, _data, output_index) { #region
surface_set_target(_outSurf);
static step = function() { #region
var _arr = getInputData(1);
outputs[| 0].name = _arr? "HSV" : "Hue";
outputs[| 0].setArrayDepth(_arr);
outputs[| 1].setVisible(!_arr, !_arr);
outputs[| 2].setVisible(!_arr, !_arr);
outputs[| 3].setVisible(!_arr, !_arr);
} #endregion
static setShader = function(index) {
DRAW_CLEAR
BLEND_OVERRIDE;
switch(output_index) {
case 0 : shader_set(sh_channel_H); break;
case 1 : shader_set(sh_channel_S); break;
case 2 : shader_set(sh_channel_V); break;
case 3 : shader_set(sh_channel_A); break;
BLEND_OVERRIDE
switch(index) {
case 0 : shader_set(sh_channel_H); break;
case 1 : shader_set(sh_channel_S); break;
case 2 : shader_set(sh_channel_V); break;
case 3 : shader_set(sh_channel_A); break;
}
}
static resetShader = function() {
shader_reset();
BLEND_NORMAL
}
static processData = function(_outSurf, _data, output_index) { #region
var _arr = _data[1];
if(_arr && output_index) return _outSurf;
if(_arr) {
for( var i = 0; i < 4; i++ ) {
var _surf = array_safe_get(_outSurf, i);
_surf = surface_verify(_surf, _ww, _hh);
_outSurf[i] = _surf;
surface_set_target(_surf);
setShader(i);
draw_surface_safe(_data[0]);
resetShader();
surface_reset_target();
}
draw_surface_safe(_data[0], 0, 0);
shader_reset();
BLEND_NORMAL;
surface_reset_target();
} else {
surface_set_target(_outSurf);
setShader(output_index);
draw_surface_safe(_data[0]);
resetShader();
surface_reset_target();
}
return _outSurf;
} #endregion

View file

@ -412,25 +412,25 @@ function __initNodes() {
#endregion
var smokeSim = ds_list_create(); #region
addNodeCatagory("SmokeSim", smokeSim, ["Node_Fluid_Group", "Node_Fluid_Group_Inline"]);
addNodeCatagory("SmokeSim", smokeSim, ["Node_Smoke_Group", "Node_Smoke_Group_Inline"]);
ds_list_add(smokeSim, "Group");
addNodeObject(smokeSim, "Input", s_node_group_input, "Node_Group_Input", [1, Node_Group_Input]).hideRecent().hideGlobal();
addNodeObject(smokeSim, "Output", s_node_group_output, "Node_Group_Output", [1, Node_Group_Output]).hideRecent().hideGlobal();
addNodeObject(smokeSim, "Render Domain", s_node_smokeSim_render_output, "Node_Fluid_Render_Output", [1, Node_Fluid_Render_Output]).hideRecent().setVersion(11540).hideGlobal();
addNodeObject(smokeSim, "Render Domain", s_node_smokeSim_render_output, "Node_Smoke_Render_Output", [1, Node_Smoke_Render_Output]).hideRecent().setVersion(11540).hideGlobal();
ds_list_add(smokeSim, "Domain");
addNodeObject(smokeSim, "Domain", s_node_smokeSim_domain, "Node_Fluid_Domain", [1, Node_Fluid_Domain]).hideRecent().setVersion(1120);
addNodeObject(smokeSim, "Update Domain", s_node_smokeSim_update, "Node_Fluid_Update", [1, Node_Fluid_Update],, "Run smoke by one step.").hideRecent().setVersion(1120);
addNodeObject(smokeSim, "Render Domain", s_node_smokeSim_render, "Node_Fluid_Render", [1, Node_Fluid_Render],, "Render smoke to surface. This node also have update function build in.").hideRecent().setVersion(1120);
addNodeObject(smokeSim, "Queue Domain", s_node_smokeSim_domain_queue, "Node_Fluid_Domain_Queue", [1, Node_Fluid_Domain_Queue],, "Sync multiple domains to be render at the same time.").hideRecent().setVersion(1120);
addNodeObject(smokeSim, "Domain", s_node_smokeSim_domain, "Node_Smoke_Domain", [1, Node_Smoke_Domain]).hideRecent().setVersion(1120);
addNodeObject(smokeSim, "Update Domain", s_node_smokeSim_update, "Node_Smoke_Update", [1, Node_Smoke_Update],, "Run smoke by one step.").hideRecent().setVersion(1120);
addNodeObject(smokeSim, "Render Domain", s_node_smokeSim_render, "Node_Smoke_Render", [1, Node_Smoke_Render],, "Render smoke to surface. This node also have update function build in.").hideRecent().setVersion(1120);
addNodeObject(smokeSim, "Queue Domain", s_node_smokeSim_domain_queue, "Node_Smoke_Domain_Queue", [1, Node_Smoke_Domain_Queue],, "Sync multiple domains to be render at the same time.").hideRecent().setVersion(1120);
ds_list_add(smokeSim, "Smoke");
addNodeObject(smokeSim, "Add Emitter", s_node_smokeSim_emitter, "Node_Fluid_Add", [1, Node_Fluid_Add],, "Add smoke emitter.").hideRecent().setVersion(1120);
addNodeObject(smokeSim, "Apply Velocity", s_node_smokeSim_apply_velocity, "Node_Fluid_Apply_Velocity", [1, Node_Fluid_Apply_Velocity],, "Apply velocity to smoke.").hideRecent().setVersion(1120);
addNodeObject(smokeSim, "Add Collider", s_node_smokeSim_add_collider, "Node_Fluid_Add_Collider", [1, Node_Fluid_Add_Collider],, "Add solid object that smoke can collides to.").hideRecent().setVersion(1120);
addNodeObject(smokeSim, "Vortex", s_node_smokeSim_vortex, "Node_Fluid_Vortex", [1, Node_Fluid_Vortex],, "Apply rotational force around a point.").hideRecent().setVersion(1120);
addNodeObject(smokeSim, "Repulse", s_node_smokeSim_repulse, "Node_Fluid_Repulse", [1, Node_Fluid_Repulse],, "Spread smoke away from a point.").hideRecent().setVersion(1120);
addNodeObject(smokeSim, "Turbulence", s_node_smokeSim_turbulence, "Node_Fluid_Turbulence", [1, Node_Fluid_Turbulence],, "Apply random velocity map to the smoke.").hideRecent().setVersion(1120);
addNodeObject(smokeSim, "Add Emitter", s_node_smokeSim_emitter, "Node_Smoke_Add", [1, Node_Smoke_Add],, "Add smoke emitter.").hideRecent().setVersion(1120);
addNodeObject(smokeSim, "Apply Velocity", s_node_smokeSim_apply_velocity, "Node_Smoke_Apply_Velocity", [1, Node_Smoke_Apply_Velocity],, "Apply velocity to smoke.").hideRecent().setVersion(1120);
addNodeObject(smokeSim, "Add Collider", s_node_smokeSim_add_collider, "Node_Smoke_Add_Collider", [1, Node_Smoke_Add_Collider],, "Add solid object that smoke can collides to.").hideRecent().setVersion(1120);
addNodeObject(smokeSim, "Vortex", s_node_smokeSim_vortex, "Node_Smoke_Vortex", [1, Node_Smoke_Vortex],, "Apply rotational force around a point.").hideRecent().setVersion(1120);
addNodeObject(smokeSim, "Repulse", s_node_smokeSim_repulse, "Node_Smoke_Repulse", [1, Node_Smoke_Repulse],, "Spread smoke away from a point.").hideRecent().setVersion(1120);
addNodeObject(smokeSim, "Turbulence", s_node_smokeSim_turbulence, "Node_Smoke_Turbulence", [1, Node_Smoke_Turbulence],, "Apply random velocity map to the smoke.").hideRecent().setVersion(1120);
#endregion
var flipSim = ds_list_create(); #region
@ -718,7 +718,7 @@ function __initNodes() {
addNodeObject(generator, "VFX", s_node_vfx, "Node_VFX_Group_Inline", [1, Node_VFX_Group_Inline],, "Create VFX group, which generate particles that can be manipulated using different force nodes.");
addNodeObject(generator, "RigidSim", s_node_rigidSim, "Node_Rigid_Group_Inline", [1, Node_Rigid_Group_Inline],, "Create group for rigidbody simulation.").setVersion(1110);
addNodeObject(generator, "FLIP Fluid", s_node_fluidSim_group, "Node_FLIP_Group_Inline", [1, Node_FLIP_Group_Inline],, "Create group for fluid simulation.").setVersion(11620);
addNodeObject(generator, "SmokeSim", s_node_smokeSim_group, "Node_Fluid_Group_Inline", [1, Node_Fluid_Group_Inline],, "Create group for smoke simulation.").setVersion(1120);
addNodeObject(generator, "SmokeSim", s_node_smokeSim_group, "Node_Smoke_Group_Inline", [1, Node_Smoke_Group_Inline],, "Create group for smoke simulation.").setVersion(1120);
addNodeObject(generator, "StrandSim", s_node_strandSim, "Node_Strand_Group_Inline", [1, Node_Strand_Group_Inline], ["hair"], "Create group for hair simulation.").setVersion(1140);
addNodeObject(generator, "Diffuse", s_node_diffuse, "Node_Diffuse", [1, Node_Diffuse],, "Simulate diffusion like simulation.").setVersion(11640);
addNodeObject(generator, "Reaction Diffusion", s_node_reaction_diffusion, "Node_RD", [1, Node_RD],, "Simulate reaction diffusion effect.").setVersion(11630);
@ -1119,7 +1119,7 @@ function __initNodes() {
addNodeObject(hid, "Onion Skin", s_node_cache, "Node_Onion_Skin", [1, Node_Onion_Skin]).setVersion(1147).hideRecent();
addNodeObject(hid, "RigidSim", s_node_rigidSim, "Node_Rigid_Group", [1, Node_Rigid_Group],, "Create group for rigidbody simulation.").setVersion(1110).hideRecent();
addNodeObject(hid, "RigidSim Global", s_node_rigidSim_global, "Node_Rigid_Global", [1, Node_Rigid_Global]).setVersion(1110).hideRecent();
addNodeObject(hid, "SmokeSim", s_node_smokeSim_group, "Node_Fluid_Group", [1, Node_Fluid_Group],, "Create group for fluid simulation.").setVersion(1120).hideRecent();
addNodeObject(hid, "SmokeSim", s_node_smokeSim_group, "Node_Smoke_Group", [1, Node_Smoke_Group],, "Create group for fluid simulation.").setVersion(1120).hideRecent();
addNodeObject(hid, "StrandSim", s_node_strandSim, "Node_Strand_Group", [1, Node_Strand_Group], ["Hair"], "Create group for hair simulation.").setVersion(1140).hideRecent();
addNodeObject(hid, "Feedback", s_node_feedback, "Node_Feedback_Inline", [1, Node_Feedback_Inline]).hideRecent();
addNodeObject(hid, "Loop", s_node_loop, "Node_Iterate_Inline", [1, Node_Iterate_Inline]).hideRecent();

View file

@ -4,10 +4,12 @@ function Node_RGB_Channel(_x, _y, _group = noone) : Node_Processor(_x, _y, _grou
inputs[| 0] = nodeValue("Surface In", self, JUNCTION_CONNECT.input, VALUE_TYPE.surface, noone);
inputs[| 1] = nodeValue("Output Type", self, JUNCTION_CONNECT.input, VALUE_TYPE.integer, 0)
.setDisplay(VALUE_DISPLAY.enum_scroll, ["Channel value", "Greyscale"]);
.setDisplay(VALUE_DISPLAY.enum_scroll, [ "Channel value", "Greyscale" ]);
inputs[| 2] = nodeValue("Keep Alpha", self, JUNCTION_CONNECT.input, VALUE_TYPE.boolean, false);
inputs[| 3] = nodeValue("Output Array", self, JUNCTION_CONNECT.input, VALUE_TYPE.boolean, false);
outputs[| 0] = nodeValue("Red", self, JUNCTION_CONNECT.output, VALUE_TYPE.surface, noone);
outputs[| 1] = nodeValue("Green", self, JUNCTION_CONNECT.output, VALUE_TYPE.surface, noone);
outputs[| 2] = nodeValue("Blue", self, JUNCTION_CONNECT.output, VALUE_TYPE.surface, noone);
@ -15,25 +17,66 @@ function Node_RGB_Channel(_x, _y, _group = noone) : Node_Processor(_x, _y, _grou
attribute_surface_depth();
static step = function() { #region
var _arr = getInputData(3);
outputs[| 0].name = _arr? "RGBA" : "Red";
outputs[| 0].setArrayDepth(_arr);
outputs[| 1].setVisible(!_arr, !_arr);
outputs[| 2].setVisible(!_arr, !_arr);
outputs[| 3].setVisible(!_arr, !_arr);
} #endregion
static setShader = function(index, grey, _alp) {
DRAW_CLEAR
BLEND_OVERRIDE
switch(index) {
case 0 : shader_set(grey? sh_channel_R_grey : sh_channel_R); break;
case 1 : shader_set(grey? sh_channel_G_grey : sh_channel_G); break;
case 2 : shader_set(grey? sh_channel_B_grey : sh_channel_B); break;
case 3 : shader_set(grey? sh_channel_A_grey : sh_channel_A); break;
}
shader_set_i("keepAlpha", _alp);
}
static resetShader = function() {
shader_reset();
BLEND_NORMAL
}
static processData = function(_outSurf, _data, output_index) { #region
var _out = _data[1];
var _alp = _data[2];
var _arr = _data[3];
surface_set_target(_outSurf);
DRAW_CLEAR
BLEND_OVERRIDE;
switch(output_index) {
case 0 : shader_set(_out? sh_channel_R_grey : sh_channel_R); break;
case 1 : shader_set(_out? sh_channel_G_grey : sh_channel_G); break;
case 2 : shader_set(_out? sh_channel_B_grey : sh_channel_B); break;
case 3 : shader_set(_out? sh_channel_A_grey : sh_channel_A); break;
if(_arr && output_index) return _outSurf;
var _ww = surface_get_width_safe(_data[0]);
var _hh = surface_get_height_safe(_data[0]);
if(_arr) {
for( var i = 0; i < 4; i++ ) {
var _surf = array_safe_get(_outSurf, i);
_surf = surface_verify(_surf, _ww, _hh);
_outSurf[i] = _surf;
surface_set_target(_surf);
setShader(i, _out, _alp);
draw_surface_safe(_data[0]);
resetShader();
surface_reset_target();
}
shader_set_i("keepAlpha", _alp);
draw_surface_safe(_data[0], 0, 0);
shader_reset();
BLEND_NORMAL;
surface_reset_target();
} else {
surface_set_target(_outSurf);
setShader(output_index, _out, _alp);
draw_surface_safe(_data[0]);
resetShader();
surface_reset_target();
}
return _outSurf;
} #endregion

View file

@ -1,4 +1,4 @@
function Node_Fluid_Add(_x, _y, _group = noone) : Node_Fluid(_x, _y, _group) constructor {
function Node_Smoke_Add(_x, _y, _group = noone) : Node_Smoke(_x, _y, _group) constructor {
name = "Add Emitter";
color = COLORS.node_blend_smoke;
icon = THEME.smoke_sim;

View file

@ -1,7 +1,7 @@
{
"resourceType": "GMScript",
"resourceVersion": "1.0",
"name": "node_fluid_group",
"name": "node_smoke_add",
"isCompatibility": false,
"isDnD": false,
"parent": {

View file

@ -1,4 +1,4 @@
function Node_Fluid_Add_Collider(_x, _y, _group = noone) : Node_Fluid(_x, _y, _group) constructor {
function Node_Smoke_Add_Collider(_x, _y, _group = noone) : Node_Smoke(_x, _y, _group) constructor {
name = "Add Collider";
color = COLORS.node_blend_smoke;
icon = THEME.smoke_sim;

View file

@ -1,7 +1,7 @@
{
"resourceType": "GMScript",
"resourceVersion": "1.0",
"name": "node_fluid_add_collider",
"name": "node_smoke_add_collider",
"isCompatibility": false,
"isDnD": false,
"parent": {

View file

@ -1,4 +1,4 @@
function Node_Fluid_Apply_Velocity(_x, _y, _group = noone) : Node_Fluid(_x, _y, _group) constructor {
function Node_Smoke_Apply_Velocity(_x, _y, _group = noone) : Node_Smoke(_x, _y, _group) constructor {
name = "Apply Velocity";
w = 96;
min_h = 96;

View file

@ -1,7 +1,7 @@
{
"resourceType": "GMScript",
"resourceVersion": "1.0",
"name": "node_fluid_apply_velocity",
"name": "node_smoke_apply_velocity",
"isCompatibility": false,
"isDnD": false,
"parent": {

View file

@ -1,4 +1,4 @@
function Node_Fluid_Domain(_x, _y, _group = noone) : Node_Fluid(_x, _y, _group) constructor {
function Node_Smoke_Domain(_x, _y, _group = noone) : Node_Smoke(_x, _y, _group) constructor {
name = "Domain";
color = COLORS.node_blend_smoke;
icon = THEME.smoke_sim;

View file

@ -1,7 +1,7 @@
{
"resourceType": "GMScript",
"resourceVersion": "1.0",
"name": "_node_fluid_nodes",
"name": "node_smoke_domain",
"isCompatibility": false,
"isDnD": false,
"parent": {

View file

@ -1,4 +1,4 @@
function Node_Fluid_Domain_Queue(_x, _y, _group = noone) : Node_Fluid(_x, _y, _group) constructor {
function Node_Smoke_Domain_Queue(_x, _y, _group = noone) : Node_Smoke(_x, _y, _group) constructor {
name = "Queue Domain";
w = 96;

View file

@ -0,0 +1,11 @@
{
"resourceType": "GMScript",
"resourceVersion": "1.0",
"name": "node_smoke_domain_queue",
"isCompatibility": false,
"isDnD": false,
"parent": {
"name": "smokeSim",
"path": "folders/nodes/data/simulation/smokeSim.yy",
},
}

View file

@ -1,6 +1,6 @@
#macro FLUID_DOMAIN_CHECK if(!instance_exists(_dom) && is_instanceof(group, Node_Fluid_Group)) _dom = group.domain; if(_dom == noone || !instance_exists(_dom)) return;
#macro FLUID_DOMAIN_CHECK if(!instance_exists(_dom) && is_instanceof(group, Node_Smoke_Group)) _dom = group.domain; if(_dom == noone || !instance_exists(_dom)) return;
function Node_Fluid_Group(_x, _y, _group = noone) : Node_Collection(_x, _y, _group) constructor {
function Node_Smoke_Group(_x, _y, _group = noone) : Node_Collection(_x, _y, _group) constructor {
name = "SmokeSim";
color = COLORS.node_blend_smoke;
icon = THEME.smoke_sim;
@ -59,7 +59,7 @@ function Node_Fluid_Group(_x, _y, _group = noone) : Node_Collection(_x, _y, _gro
domain = fd_rectangle_create(PROJECT.attributes.surface_dimension[0], PROJECT.attributes.surface_dimension[1]);
if(!LOADING && !APPENDING && !CLONING) {
var _render = nodeBuild("Node_Fluid_Render_Output", 128, -32, self);
var _render = nodeBuild("Node_Smoke_Render_Output", 128, -32, self);
}
static update = function() {

View file

@ -1,7 +1,7 @@
{
"resourceType": "GMScript",
"resourceVersion": "1.0",
"name": "node_fluid_domain",
"name": "node_smoke_group",
"isCompatibility": false,
"isDnD": false,
"parent": {

View file

@ -1,4 +1,4 @@
function Node_Fluid_Group_Inline(_x, _y, _group = noone) : Node_Collection_Inline(_x, _y, _group) constructor {
function Node_Smoke_Group_Inline(_x, _y, _group = noone) : Node_Collection_Inline(_x, _y, _group) constructor {
name = "SmokeSim";
color = COLORS.node_blend_smoke;
icon = THEME.smoke_sim;
@ -6,8 +6,8 @@ function Node_Fluid_Group_Inline(_x, _y, _group = noone) : Node_Collection_Inlin
is_simulation = true;
if(!LOADING && !APPENDING && !CLONING) {
var _domain = nodeBuild("Node_Fluid_Domain", x, y);
var _render = nodeBuild("Node_Fluid_Render", x + 320, y);
var _domain = nodeBuild("Node_Smoke_Domain", x, y);
var _render = nodeBuild("Node_Smoke_Render", x + 320, y);
_render.inputs[| 0].setFrom(_domain.outputs[| 0]);

View file

@ -0,0 +1,11 @@
{
"resourceType": "GMScript",
"resourceVersion": "1.0",
"name": "node_smoke_group_inline",
"isCompatibility": false,
"isDnD": false,
"parent": {
"name": "smokeSim",
"path": "folders/nodes/data/simulation/smokeSim.yy",
},
}

View file

@ -1,4 +1,4 @@
function Node_Fluid_Render(_x, _y, _group = noone) : Node_Fluid(_x, _y, _group) constructor {
function Node_Smoke_Render(_x, _y, _group = noone) : Node_Smoke(_x, _y, _group) constructor {
name = "Render Domain";
color = COLORS.node_blend_smoke;
icon = THEME.smoke_sim;

View file

@ -0,0 +1,11 @@
{
"resourceType": "GMScript",
"resourceVersion": "1.0",
"name": "node_smoke_render",
"isCompatibility": false,
"isDnD": false,
"parent": {
"name": "smokeSim",
"path": "folders/nodes/data/simulation/smokeSim.yy",
},
}

View file

@ -1,4 +1,4 @@
function Node_Fluid_Render_Output(_x, _y, _group = noone) : Node_Group_Output(_x, _y, _group) constructor {
function Node_Smoke_Render_Output(_x, _y, _group = noone) : Node_Group_Output(_x, _y, _group) constructor {
name = "Render Domain";
color = COLORS.node_blend_smoke;
icon = THEME.smoke_sim;

View file

@ -0,0 +1,11 @@
{
"resourceType": "GMScript",
"resourceVersion": "1.0",
"name": "node_smoke_render_output",
"isCompatibility": false,
"isDnD": false,
"parent": {
"name": "smokeSim",
"path": "folders/nodes/data/simulation/smokeSim.yy",
},
}

View file

@ -1,4 +1,4 @@
function Node_Fluid_Repulse(_x, _y, _group = noone) : Node_Fluid(_x, _y, _group) constructor {
function Node_Smoke_Repulse(_x, _y, _group = noone) : Node_Smoke(_x, _y, _group) constructor {
name = "Repulse";
w = 96;
min_h = 96;

View file

@ -0,0 +1,11 @@
{
"resourceType": "GMScript",
"resourceVersion": "1.0",
"name": "node_smoke_repulse",
"isCompatibility": false,
"isDnD": false,
"parent": {
"name": "smokeSim",
"path": "folders/nodes/data/simulation/smokeSim.yy",
},
}

View file

@ -1,4 +1,4 @@
function Node_Fluid_Turbulence(_x, _y, _group = noone) : Node_Fluid(_x, _y, _group) constructor {
function Node_Smoke_Turbulence(_x, _y, _group = noone) : Node_Smoke(_x, _y, _group) constructor {
name = "Turbulence";
w = 96;
min_h = 96;

View file

@ -0,0 +1,11 @@
{
"resourceType": "GMScript",
"resourceVersion": "1.0",
"name": "node_smoke_turbulence",
"isCompatibility": false,
"isDnD": false,
"parent": {
"name": "smokeSim",
"path": "folders/nodes/data/simulation/smokeSim.yy",
},
}

View file

@ -1,4 +1,4 @@
function Node_Fluid_Update(_x, _y, _group = noone) : Node_Fluid(_x, _y, _group) constructor {
function Node_Smoke_Update(_x, _y, _group = noone) : Node_Smoke(_x, _y, _group) constructor {
name = "Update Fluid";
color = COLORS.node_blend_smoke;
icon = THEME.smoke_sim;

View file

@ -0,0 +1,11 @@
{
"resourceType": "GMScript",
"resourceVersion": "1.0",
"name": "node_smoke_update",
"isCompatibility": false,
"isDnD": false,
"parent": {
"name": "smokeSim",
"path": "folders/nodes/data/simulation/smokeSim.yy",
},
}

View file

@ -1,4 +1,4 @@
function Node_Fluid_Vortex(_x, _y, _group = noone) : Node_Fluid(_x, _y, _group) constructor {
function Node_Smoke_Vortex(_x, _y, _group = noone) : Node_Smoke(_x, _y, _group) constructor {
name = "Vortex";
w = 96;
min_h = 96;

View file

@ -0,0 +1,11 @@
{
"resourceType": "GMScript",
"resourceVersion": "1.0",
"name": "node_smoke_vortex",
"isCompatibility": false,
"isDnD": false,
"parent": {
"name": "smokeSim",
"path": "folders/nodes/data/simulation/smokeSim.yy",
},
}

View file

@ -552,8 +552,10 @@ function NodeValue(_name, _node, _connect, _type, _value, _tooltip = "") constru
else if(_connect == JUNCTION_CONNECT.output) node.outputMap[? internalName] = self;
}
tooltip = _tooltip;
editWidget = noone;
tooltip = _tooltip;
editWidget = noone;
editWidgetRaw = noone;
mapWidget = noone;
active_tooltip = "";
tags = VALUE_TAG.none;
@ -1287,6 +1289,8 @@ function NodeValue(_name, _node, _connect, _type, _value, _tooltip = "") constru
break; #endregion
}
editWidgetRaw = editWidget;
for( var i = 0, n = ds_list_size(animator.values); i < n; i++ ) {
animator.values[| i].ease_in_type = key_inter;
animator.values[| i].ease_out_type = key_inter;
@ -1300,8 +1304,6 @@ function NodeValue(_name, _node, _connect, _type, _value, _tooltip = "") constru
attributes.mapped = false;
attributes.map_index = index;
editWidgetRaw = editWidget;
mapButton = button(function() {
attributes.mapped = !attributes.mapped;
var val = getValue();
@ -2615,7 +2617,8 @@ function NodeValue(_name, _node, _connect, _type, _value, _tooltip = "") constru
} #endregion
static attributeApply = function() { #region
if(struct_has(attributes, "mapped")) mappableStep();
if(struct_has(attributes, "mapped") && attributes.mapped)
mappableStep();
} #endregion
static connect = function(log = false) { #region

View file

@ -249,7 +249,7 @@
function surface_from_buffer(buff) { #region
static header_length = 24;
if(!buffer_exists(buff)) return noone;
if(buffer_get_size(buff) < header_length) return noone;

View file

@ -6,9 +6,9 @@ uniform sampler2D samS;
uniform sampler2D samV;
uniform sampler2D samA;
uniform int useR;
uniform int useG;
uniform int useB;
uniform int useH;
uniform int useS;
uniform int useV;
uniform int useA;
vec3 hsv2rgb(vec3 c) {

View file

@ -20,5 +20,5 @@ void main() {
vec4 f8 = texture2D( gm_BaseTexture, v_vTexcoord + vec2( tx.x, tx.y) );
vec4 clr = (f0 + f1 + f2 + f3 + f4 + f5 + f6 + f7 + f8) / 9.;
gl_FragColor = vec4(clr.rgb * dissipation, clr.a);
gl_FragColor = vec4(clr.rgb * dissipation, 1.);
}

View file

@ -4,131 +4,70 @@ varying vec4 v_vColour;
uniform vec2 dimension;
uniform float seed;
uniform float scale;
uniform int detail;
uniform int iteration;
uniform float flowRate;
uniform int useExternal;
uniform float externalStrength;
uniform sampler2D externalForce;
uniform float externalForce;
float random (in vec2 st) { return fract(sin(dot(st.xy + vec2(21.456, 46.856), vec2(12.989, 78.233))) * 43758.545); }
float grey (vec4 col) { return (col.r + col.g + col.b) / 3.; }
///////////////////// PERLIN START /////////////////////
vec3 mod289(vec3 x) { return x - floor(x * (1.0 / 289.0)) * 289.0; }
vec4 mod289(vec4 x) { return x - floor(x * (1.0 / 289.0)) * 289.0; }
vec4 permute(vec4 x) { return mod289(((x * 34.0) + 10.0) * x); }
vec4 taylorInvSqrt(vec4 r) { return 1.79284291400159 - 0.85373472095314 * r; }
float random (in vec2 st) { return smoothstep(0., 1., abs(fract(sin(dot(st.xy + vec2(21.456, 46.856), vec2(12.989, 78.233))) * (43758.545 + seed)) * 2. - 1.)); }
vec2 random2 (in vec2 st) { float a = random(st) * 6.28319; return vec2(cos(a), sin(a)); }
float snoise(vec3 vec) { #region
vec3 v = vec * 4.;
float noise (in vec2 st) {
vec2 cellMin = floor(st);
vec2 cellMax = floor(st) + vec2(1., 1.);
const vec2 C = vec2(1.0 / 6.0, 1.0 / 3.0);
const vec4 D = vec4(0.0, 0.5, 1.0, 2.0);
vec2 f = fract(st);
vec2 u = f * f * (3.0 - 2.0 * f);
vec2 _a = vec2(cellMin.x, cellMin.y);
vec2 _b = vec2(cellMax.x, cellMin.y);
vec2 _c = vec2(cellMin.x, cellMax.y);
vec2 _d = vec2(cellMax.x, cellMax.y);
vec2 ai = f - vec2(0., 0.);
vec2 bi = f - vec2(1., 0.);
vec2 ci = f - vec2(0., 1.);
vec2 di = f - vec2(1., 1.);
vec2 a2 = random2(_a);
vec2 b2 = random2(_b);
vec2 c2 = random2(_c);
vec2 d2 = random2(_d);
float l1 = mix(dot(ai, a2), dot(bi, b2), u.x);
float l2 = mix(dot(ci, c2), dot(di, d2), u.x);
return mix(l1, l2, u.y) + 0.5;
}
// First corner
vec3 i = floor(v + dot(v, C.yyy));
vec3 x0 = v - i + dot(i, C.xxx);
// Other corners
vec3 g = step(x0.yzx, x0.xyz);
vec3 l = 1.0 - g;
vec3 i1 = min( g.xyz, l.zxy );
vec3 i2 = max( g.xyz, l.zxy );
float perlin ( vec2 st ) {
float amp = pow(2., float(iteration) - 1.) / (pow(2., float(iteration)) - 1.);
float n = 0.;
vec2 pos = st;
// x0 = x0 - 0.0 + 0.0 * C.xxx;
// x1 = x0 - i1 + 1.0 * C.xxx;
// x2 = x0 - i2 + 2.0 * C.xxx;
// x3 = x0 - 1.0 + 3.0 * C.xxx;
vec3 x1 = x0 - i1 + C.xxx;
vec3 x2 = x0 - i2 + C.yyy; // 2.0*C.x = 1/3 = C.y
vec3 x3 = x0 - D.yyy; // -1.0+3.0*C.x = -0.5 = -D.y
// Permutations
i = mod289(i);
vec4 p = permute( permute( permute(
i.z + vec4(0.0, i1.z, i2.z, 1.0 ))
+ i.y + vec4(0.0, i1.y, i2.y, 1.0 ))
+ i.x + vec4(0.0, i1.x, i2.x, 1.0 ));
// Gradients: 7x7 points over a square, mapped onto an octahedron.
// The ring size 17*17 = 289 is close to a multiple of 49 (49*6 = 294)
float n_ = 0.142857142857; // 1.0/7.0
vec3 ns = n_ * D.wyz - D.xzx;
vec4 j = p - 49.0 * floor(p * ns.z * ns.z); // mod(p,7*7)
vec4 x_ = floor(j * ns.z);
vec4 y_ = floor(j - 7.0 * x_ ); // mod(j,N)
vec4 x = x_ * ns.x + ns.yyyy;
vec4 y = y_ * ns.x + ns.yyyy;
vec4 h = 1.0 - abs(x) - abs(y);
vec4 b0 = vec4( x.xy, y.xy );
vec4 b1 = vec4( x.zw, y.zw );
//vec4 s0 = vec4(lessThan(b0,0.0))*2.0 - 1.0;
//vec4 s1 = vec4(lessThan(b1,0.0))*2.0 - 1.0;
vec4 s0 = floor(b0) * 2.0 + 1.0;
vec4 s1 = floor(b1) * 2.0 + 1.0;
vec4 sh = -step(h, vec4(0.0));
vec4 a0 = b0.xzyw + s0.xzyw * sh.xxyy ;
vec4 a1 = b1.xzyw + s1.xzyw * sh.zzww ;
vec3 p0 = vec3(a0.xy, h.x);
vec3 p1 = vec3(a0.zw, h.y);
vec3 p2 = vec3(a1.xy, h.z);
vec3 p3 = vec3(a1.zw, h.w);
//Normalise gradients
vec4 norm = taylorInvSqrt(vec4(dot(p0, p0), dot(p1, p1), dot(p2, p2), dot(p3, p3)));
p0 *= norm.x;
p1 *= norm.y;
p2 *= norm.z;
p3 *= norm.w;
// Mix final noise value
vec4 m = max(0.5 - vec4(dot(x0, x0), dot(x1, x1), dot(x2, x2), dot(x3, x3)), 0.0);
m = m * m;
float n = 105.0 * dot( m * m, vec4( dot(p0, x0), dot(p1, x1), dot(p2, x2), dot(p3, x3) ) );
n = mix(0.0, 0.5 + 0.5 * n, smoothstep(0.0, 0.003, vec.z));
return n;
} #endregion
float simplex(in vec2 st, in int itr) { #region
vec2 p = st * 2.0 - 1.0;
vec3 xyz = vec3(p, seed);
float amp = pow(2., float(itr) - 1.) / (pow(2., float(itr)) - 1.);
float n = 0.;
for(int i = 0; i < 32; i++) {
if(i >= itr) break;
n += snoise(xyz) * amp;
for(int i = 0; i < iteration; i++) {
n += noise(pos) * amp;
amp *= .5;
xyz *= 2.;
pos *= 2.;
}
return n;
} #endregion
}
///////////////////// PERLIN END /////////////////////
void main() {
vec2 tx = 1. / dimension;
float x0 = simplex((v_vTexcoord + vec2(-tx.x, 0.)) / scale, detail);
float x1 = simplex((v_vTexcoord + vec2( tx.x, 0.)) / scale, detail);
float y0 = simplex((v_vTexcoord + vec2(0., -tx.y)) / scale, detail);
float y1 = simplex((v_vTexcoord + vec2(0., tx.y)) / scale, detail);
float x0 = perlin((v_vTexcoord + vec2(-tx.x, 0.)) * scale);
float x1 = perlin((v_vTexcoord + vec2( tx.x, 0.)) * scale);
float y0 = perlin((v_vTexcoord + vec2(0., -tx.y)) * scale);
float y1 = perlin((v_vTexcoord + vec2(0., tx.y)) * scale);
vec2 flow = vec2(x1 - x0, y1 - y0);
if(useExternal == 1) {
vec4 _forc = texture2D( externalForce, v_vTexcoord );
flow -= _forc.xy * externalStrength;
}
vec2 flow = vec2(x1 - x0, y1 - y0) + externalForce * (v_vTexcoord - 0.5);
gl_FragColor = texture2D( gm_BaseTexture, v_vTexcoord - flow * flowRate );
}

View file

@ -206,14 +206,14 @@ void main() { #region
if(shiftAxis == 0) {
shf /= sca.x;
float cellY = floor(_pos.y * sca.y);
float cellY = floor(_pos.y * sca.y);
float shiftX = mod(cellY, 2.) * shf;
_pos.x += shiftX;
} else {
shf /= sca.y;
float cellX = floor(_pos.x * sca.x);
float cellX = floor(_pos.x * sca.x);
float shiftY = mod(cellX, 2.) * shf;
_pos.y += shiftY;

View file

@ -4,7 +4,6 @@ varying vec4 v_vColour;
uniform vec2 u_resolution;
uniform vec2 position;
uniform float scale;
uniform float bright;
uniform int iteration;
///////////////////// PERLIN START /////////////////////
@ -20,15 +19,15 @@ float noise (in vec2 st) {
vec2 f = fract(st);
vec2 u = f * f * (3.0 - 2.0 * f);
float lerp1 = mix(dot(f + vec2(0.0, 0.0), random2(i + vec2(0.0, 0.0))), dot(f + vec2(1.0, 0.0), random2(i + vec2(1.0, 0.0))), u.x);
float lerp2 = mix(dot(f + vec2(0.0, 1.0), random2(i + vec2(0.0, 1.0))), dot(f + vec2(1.0, 1.0), random2(i + vec2(1.0, 1.0))), u.x);
float lerp1 = mix(dot(f - vec2(0.0, 0.0), random2(i + vec2(0.0, 0.0))), dot(f - vec2(1.0, 0.0), random2(i + vec2(1.0, 0.0))), u.x);
float lerp2 = mix(dot(f - vec2(0.0, 1.0), random2(i + vec2(0.0, 1.0))), dot(f - vec2(1.0, 1.0), random2(i + vec2(1.0, 1.0))), u.x);
return mix(lerp1, lerp2, u.y);
}
float perlin ( vec2 pos, int iteration ) {
float amp = pow(2., float(iteration) - 1.) / (pow(2., float(iteration)) - 1.);
float n = 0.;
float amp = pow(2., float(iteration) - 1.) / (pow(2., float(iteration)) - 1.);
float n = 0.;
for(int i = 0; i < iteration; i++) {
n += noise(pos) * amp;

View file

@ -50,19 +50,11 @@ float noise (in vec2 st, in vec2 scale) { #region
vec2 ci = f - vec2(0., 1.);
vec2 di = f - vec2(1., 1.);
//float a = random(_a);
//float b = random(_b);
//float c = random(_c);
//float d = random(_d);
vec2 a2 = random2(_a);
vec2 b2 = random2(_b);
vec2 c2 = random2(_c);
vec2 d2 = random2(_d);
//float l1 = mix(a, b, u.x);
//float l2 = mix(c, d, u.x);
float l1 = mix(dot(ai, a2), dot(bi, b2), u.x);
float l2 = mix(dot(ci, c2), dot(di, d2), u.x);
@ -72,7 +64,7 @@ float noise (in vec2 st, in vec2 scale) { #region
float perlin(in vec2 st) { #region
float amp = pow(2., float(iteration) - 1.) / (pow(2., float(iteration)) - 1.);
float n = 0.;
vec2 pos = st;
vec2 pos = st;
vec2 sc = sca;
for(int i = 0; i < iteration; i++) {