Sphere Vector Visualizer in 3D (SVV3D) is a tool for visualizing spheres and vectors in a 3D environment.
Clone this repository:
git clone [email protected]:PabloPalaciosAlonso/SphereVectorVisualizer3D.git
Navigate to the cloned directory:
cd SphereVectorVisualizer3D
Then use the following commands to install SVV3D:
python setup.py sdist
pip install dist/SVV3D-1.0.tar.gz
To use SVV3D, simply pass a filename to the program:
SVV3D <filename>
To use a different window size, add the -WindowSize option followed by the desired width and height to the command line:
SVV3D <filename> -WindowSize width height
Remember, 'filename', 'width', 'height', and 'opacity' are placeholders and should be replaced with your actual file name, desired dimensions, and desired opacity level respectively.
- Use the
W
,A
,S
, andD
keys to move the camera. - Use
Shift
andCtrl
to move the camera up and down, respectively. - Use the
1
,2
, and3
keys to rotate the animation clockwise along the X, Y, and Z axes, respectively. - Use the
4
,5
, and6
keys to rotate the animation anticlockwise along the X, Y, and Z axes, respectively. - Use the
+
and-
keys to increase and decrease the speed of the camera movement, respectively.
- Use the
Space
key to advance to the next frame. - Use the
R
key to return to the previous frame. - Use the
B
key to jump to the first frame. - Use the
T
key to jump to the last frame. - Use the
M
key to play the animation at 60 FPS.
- Use the
C
key to take a screenshot of the animation.
Each sphere is defined by a line in the following format:
rx ry rz color radius
rx
,ry
,rz
: Coordinates of the center of the spherecolor
: (optional) Color code of the sphereradius
: (optional) Radius of the sphere
Each arrow is defined by a line in the following format:
rx ry rz vx vy vz color width
rx
,ry
,rz
: Position of the base of the arrowvx
,vy
,vz
: Direction vector of the arrowcolor
: (optional) Color code of the arrowwidth
: (optional) Width of the arrow
There are 65 different colors that can be used, the first 14 colors are:
0
: White1
: Red2
: Orange3
: Yellow4
: Lime-green5
: Green6
: Green-blue7
: Turquoise8
: Teal9
: Blue10
: Purple11
: Magenta12
: Fuchsia13
: Grey
The next colors follow the same sequence, starting from red, but in lighter shades, see image.
-Sphere opacity
: The opacity of the spheres can be changed by adding a line "# SPHERE OPACITY X", where X is a real number between 0.0 and 1.0. Here, 0.0 indicates a transparent sphere, and 1.0 indicates an opaque sphere. By default, the opacity is 1.0.
The end of a frame is indicated with a #
symbol.