Skip to content

omarrrefaatt/Image-Mixer-

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 

Repository files navigation

Fourier Transform Image Mixer Documentation

Overview

The Fourier Transform Mixer is a desktop application designed to visualize and manipulate 2D signals (images) using Fourier Transform components. This software emphasizes the significance of the magnitude and phase components and their contributions to the overall signal. The application supports multiple image views, component mixing, and region-based frequency manipulation.

Features

Image Viewers

  1. Open and View Images:

    • Capability to open and display four grayscale images, each in a separate viewport.
    • If a colored image is opened, the program automatically converts it to grayscale.
    • Ensures all opened images are resized to the smallest dimensions among them for consistency.
  2. Fourier Transform (FT) Components:

    • Each image has two displays: one fixed for the original image and another for various FT components.
    • Users can select to view one of the following FT components:
      • FT Magnitude
      • FT Phase
      • FT Real
      • FT Imaginary
  3. Image Browsing:

    • Users can change any of the images by double-clicking on its viewer, invoking a browse function for that specific image.
  4. Brightness and Contrast Adjustment:

    • Users can adjust the brightness and contrast (window/level) of any image or its FT components via mouse dragging.

Components Mixer

  • The output image is generated by performing an inverse Fourier transform (iFFT) on a weighted average of the FT of the four input images.
  • Users can customize the weights for each image's FT components (magnitude and phase, or real and imaginary) using sliders.
  • The interface for adjusting weights is designed to be intuitive and user-friendly.

Regions Mixer

  • Users can select regions of the FT components (inner for low frequencies or outer for high frequencies) to be included in the output.
  • Selection is done by drawing a rectangle on each FT display, with options to highlight the selected region.
  • The region size can be adjusted via sliders or resize handles, and this selection is unified across all four images.

Realtime Mixing

  • The mixing process involves an iFFT operation, which can take some time. A progress bar is displayed to indicate the process's progress.
  • If the user changes the settings and requests a new mix while a previous operation is still running, the program cancels the ongoing operation and starts the new one, ensuring responsiveness and efficiency.

Code Practices

  1. Proper Naming and No Code Repetition:

    • Adhere to coding standards with meaningful variable names and avoid code repetition.
  2. Object-Oriented Programming (OOP) Concepts:

    • Utilize OOP principles to avoid redundant code. Encapsulate image and display functionalities within appropriate classes.
    • Minimize code in the main function, ensuring that most functionalities are encapsulated within classes.
  3. Logging:

    • Implement logging to track user interactions and main steps, aiding in debugging and problem resolution.
    • Use Python's logging library to maintain logs. Ensure that only relevant variables and events are logged for effective debugging.

Conclusion

The Fourier Transform Mixer provides a comprehensive tool for understanding and manipulating the frequency components of 2D signals. By combining robust image viewing capabilities, intuitive mixing interfaces, and real-time processing feedback, the application offers a powerful platform for signal analysis and experimentation.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages