ComfyUI  >  Nodes  >  FizzNodes >  SinWave 📅🅕🅝

ComfyUI Node: SinWave 📅🅕🅝

Class Name

SinWave

Category
FizzNodes 📅🅕🅝/WaveNodes
Author
FizzleDorf (Account age: 1989 days)
Extension
FizzNodes
Latest Updated
6/27/2024
Github Stars
0.3K

How to Install FizzNodes

Install this extension via the ComfyUI Manager by searching for  FizzNodes
  • 1. Click the Manager button in the main menu
  • 2. Select Custom Nodes Manager button
  • 3. Enter FizzNodes in the search bar
After installation, click the  Restart button to restart ComfyUI. Then, manually refresh your browser to clear the cache and access the updated list of nodes.

Visit ComfyUI Online for ready-to-use ComfyUI environment

  • Free trial available
  • High-speed GPU machines
  • 200+ preloaded models/nodes
  • Freedom to upload custom models/nodes
  • 50+ ready-to-run workflows
  • 100% private workspace with up to 200GB storage
  • Dedicated Support

Run ComfyUI Online

SinWave 📅🅕🅝 Description

Generate smooth sine wave patterns for artistic and animation effects with adjustable frequency, height, and position.

SinWave 📅🅕🅝:

The SinWave node is designed to generate a sine wave pattern based on the provided parameters. This node is particularly useful for creating smooth, oscillating values that can be applied in various artistic and animation contexts. By adjusting the phase, amplitude, and translations, you can control the wave's frequency, height, and position, making it a versatile tool for generating dynamic and rhythmic effects. The SinWave node calculates the sine of the current frame, allowing for continuous and seamless wave generation over time.

SinWave 📅🅕🅝 Input Parameters:

phase

The phase parameter controls the period of the sine wave, which is the length of one complete cycle. A higher phase value results in a longer cycle, while a lower phase value shortens the cycle. This parameter accepts floating-point values with a minimum of 0.0, a maximum of 9999.0, and a default value of 1.0.

amplitude

The amplitude parameter determines the height of the sine wave. A higher amplitude value increases the wave's peak and trough, making the oscillations more pronounced. This parameter accepts floating-point values with a minimum of 0.0, a maximum of 9999.0, and a default value of 0.5.

x_translation

The x_translation parameter shifts the sine wave horizontally. This translation allows you to move the wave along the x-axis, effectively changing the starting point of the wave. This parameter accepts floating-point values with a minimum of 0.0, a maximum of 9999.0, and a default value of 0.0.

y_translation

The y_translation parameter shifts the sine wave vertically. This translation moves the entire wave up or down along the y-axis, adjusting the baseline of the wave. This parameter accepts floating-point values with a minimum of 0.0, a maximum of 9999.0, and a default value of 0.5.

current_frame

The current_frame parameter represents the current point in time or frame number for which the sine wave value is being calculated. This parameter is essential for generating the wave over time and accepts integer values with a minimum of 0.0, a maximum of 9999.0, and a default value of 1.0.

SinWave 📅🅕🅝 Output Parameters:

FLOAT

The FLOAT output is the calculated value of the sine wave at the given current_frame. This value is a floating-point number that represents the y-coordinate of the sine wave at the specified frame, taking into account the phase, amplitude, and translations.

INT

The INT output is the integer representation of the calculated sine wave value. This value is derived by converting the FLOAT output to an integer, which can be useful for applications that require discrete values.

SinWave 📅🅕🅝 Usage Tips:

  • To create a smooth and continuous wave, ensure that the current_frame parameter is incremented consistently over time.
  • Adjust the amplitude to control the intensity of the wave's oscillations, making it more or less pronounced as needed.
  • Use the x_translation and y_translation parameters to position the wave precisely within your desired coordinate space.
  • Experiment with different phase values to achieve various wave frequencies, from rapid oscillations to slow, undulating movements.

SinWave 📅🅕🅝 Common Errors and Solutions:

ValueError: math domain error

  • Explanation: This error occurs when the input values result in an invalid mathematical operation, such as taking the sine of an out-of-range value.
  • Solution: Ensure that all input parameters are within their specified ranges and that the phase value is not zero.

TypeError: unsupported operand type(s)

  • Explanation: This error happens when the input parameters are of incorrect types, such as passing a string instead of a float or integer.
  • Solution: Verify that all input parameters are of the correct types as specified in the documentation.

OverflowError: numerical result out of range

  • Explanation: This error occurs when the calculated sine wave value exceeds the representable range of floating-point numbers.
  • Solution: Check the amplitude and phase values to ensure they are within reasonable limits to prevent excessively large results.

SinWave 📅🅕🅝 Related Nodes

Go back to the extension to check out more related nodes.
FizzNodes
RunComfy

© Copyright 2024 RunComfy. All Rights Reserved.

RunComfy is the premier ComfyUI platform, offering ComfyUI online environment and services, along with ComfyUI workflows featuring stunning visuals.