G'MIC - GREYC's Magic for Image Computing: A Full-Featured Open-Source Framework for Image Processing
Banner Institutions GREYC CNRS ENSICAEN UNICAEN

A Full-Featured Open-Source Framework for Image Processing



Latest stable version: 4.0.4 (2026/08/19)

Reference
Table of Contents  ▸  List of Commands  ▸  Reptorian's Commands  ▸  rep_rotate_by_torus_top◀  ycocg2rgb    |    rep_pixel_push  ▶

rep_rotate_by_torus_top

Arguments:

  • 0<=_torus_circu_min_dimension_percent_1(%)<=100,0<=_torus_circu_min_dimension_percent_2(%)<=100,_distort_ang,_mode_1={ 0=softmode | 1=midmode | 2=hardmode | 3=hardmode_alt | 4=distroymode | 5=invdistroymode | 6=quadextrudemode | 7=hexextrudemode },_mode_2={ 0=softmode | 1=midmode | 2=hardmode | 3=hardmode_alt | 4=distroymode | 5=invdistroymode | 6=quadextrudemode | 7=hexextrudemode },0<=_mode_percent_comb(%)<=100,_offx(%),_offy(%),_off_dup={ 0=no_duplicate_dist | 1=duplicate_dist },_bgremove={ 0=keep_background | 1=remove_background },_cent_isolat_torus_mode={ 0=do_not_center | 1=center },_interpolation={ 0=nearest | 1=linear },_boundary={ 0=none | 1=neumann | 2=periodic | 3=mirror }

Description:

Inspired by the Donut Distortion plugin made by MadJik for Paint.NET, this version of donut distortion adds new features such as more modes, mode blending, isolated torus mode.

(equivalent to shortcut command rep_rbtt).


_torus_circu_min_dimension_percent_1 refers to the primary circumference of circle relative to the minimum image dimension.
_torus_circu_min_dimension_percent_2 refers to the secondary circumference of circle relative to the minimum image dimension.
_distort_ang refers to the maximum angle of distortion.
_mode_1 refers to the first mode of donut distortion.
_mode_1 refers to the second mode of donut distortion.
_mode_percent_comb refers to the weighed average of combination of modes. This only works if and only if _mode_1 and _mode_2 are specified!
_offx refers to the offset of donut distortion relative to the center in -1,1 x-coordinates. 100% means the center will be located in 1.
_offy refers to the offset of donut distortion relative to the center in -1,1 y-coordinates. 100% means the center will be located in 1.
_off_dup option defines whether distortion will wrap around when it reach out of bound.
_bgremove defines whether the background is removed.
_cent_isolat_torus_mode is a special mode used to aid into creating torus from image. This only works if _bgremove is active.
_interpolation defines the smoothness of the image.
_boundary defines how out-of-range values are wrapped as.

Default values:

_torus_circu_min_dimension_percent_1=1,_torus_circu_min_dimension_percent_2=.5,_distort_ang=45,_mode_1=0,_mode_2=,_mode_percent_comb=50%,_offx=0%,_offy=0%,_off_dup=1,_bgremove=0,_cent_isolat_torus_mode=0,_interpolation=1,_boundary=2

G'MIC - GREYC's Magic for Image Computing: A Full-Featured Open-Source Framework for Image Processing

G'MIC is an open-source software distributed under the CeCILL free software licenses (LGPL-like and/or
GPL-compatible). Copyrights (C) Since July 2008, David Tschumperlé - GREYC UMR CNRS 6072, Image Team.