![]() |
|
|||||||
| Screensaver/Visualization Developement Create beautiful presets for XBMC's exclusive Vortex 3D Visualizer |
![]() |
|
|
Thread Tools | Search this Thread | Display Modes |
|
|
#1 |
|
Python Expert
|
Intro
Vortex Presets uses a scripting library known as AngelScript. The Scripting language follows the same/similar syntax to C/C++. Here is a list of things that might be useful to know. I might post this on the Wiki Later on. Just thought this forums looking bare. Hopefully some more infomation can be given later like examples, samples, explanations on how stuff actually works. For now this list is here just so you know. Supported Data Types
List of Global Defined Constants const int PRIM_POINTLIST = 1; const int PRIM_LINELIST = 2; const int PRIM_LINELOOP = 3; const int PRIM_LINESTRIP = 4; const int PRIM_TRIANGLELIST = 5; const int PRIM_TRIANGLESTRIP = 6; const int PRIM_TRIANGLEFAN = 7; const int PRIM_QUADLIST = 8; const int PRIM_QUADSTRIP = 9; const int TEXTURE_FRAMEBUFFER = 1; const int TEXTURE_NEXTPRESET = 2; const int TEXTURE_CURRPRESET = 3; const int TEXTURE_ALBUMART = 4; const int NULL = 0; const int BLEND_OFF = 0; const int BLEND_ADD = 1; const int BLEND_MOD = 2; const int BLEND_MAX = 3; const int FILLMODE_SOLID = 0; const int FILLMODE_WIREFRAME = 1; Global Vortex Variables
Operators and Math + Addition (5+3 will give 8) - Subtraction (5-3 will give 2) * Multiplcation (2*4 will give 8) = Equality (left side will be made same as right side) += (same as left = left + right -= (same as left = left - right) Cos(x) Cosine of x in radians Sin(x) Sine of x in radians Rand() Chooses a random float from 0 to 1. [Not sure how many decial places] Rand()*10 Chooses a random float from 0 to 10 [Still not sure how many decimal places] Pow(a,x) a to the power of x (I think )Fabs(a) makes float a an absolute value Vortex Functions I got no idea exactly how these works i just found them in the inlucded presets. a,b,c,d,e,[f] for showing variables in the function argument,
__________________
** Team blackbolt member and Team XBMC Tester** XBMC 4 ever Always read the XBMC online-manual, FAQ and search the forum before posting. Do not e-mail XBMC-Team members directly asking for support. Read/follow the forum rules. For troubleshooting and bug reporting please make sure you read this first.
|
|
|
|
|
|
#2 |
|
Team-XBMC Developer
Join Date: Jan 2004
Location: England
Posts: 55
![]() |
Math Functions
float Rand() - returns a random number between 0 and 1 float Sin(float x) - returns the sine of x (x in radians) float Cos(float x) - - returns the cosine of x (x in radians) float Mag(float x, float y) - returns the magnitude of x and y ( same as sqrt(x*x + y*y) ) float Clamp(float x, float min, float max) - returns x after clamping it to the min and max values float Fabs(float x ) - returns the absolute value of x int Abs(int x) - returns the absolute value of x float Atan2(float x, float y) - returns the arctangent of x and y float Pow(float x, float y) - returns x raised to the power y float Sqrt(float x) - returns the square root of x
__________________
Always read the XBMC online-manual, FAQ and search the forum before posting. Do not e-mail XBMC-Team members directly asking for support. Read/follow the forum rules. For troubleshooting and bug reporting please make sure you read this first.
|
|
|
|
|
|
#3 |
|
Member
Join Date: Sep 2004
Location: Germany
Posts: 61
![]() |
Some additions:
General: the coordinatesystem is left-handed: x,y in screenplane z into the screen. Primitives: if you use PRIM_QUADLIST, the vertices have to be ordered clockwise, otherwise the texture on top is mirrored. 1----2 | | 4----3 |
|
|
|
![]() |
| Bookmarks |
| Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
| Thread Tools | Search this Thread |
| Display Modes | |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Video-overlay for Python scripting? | BennY- | Plugin/Script (Python) Development | 12 | 2007-01-19 20:21 |
| Request for more options for Python Scripting - new puthon-engine features | vSaAmTp | Plugin/Script (Python) Development | 2 | 2006-10-05 15:11 |
| Scripting and slideshow | Spoetzl | Plugin/Script (Python) Help and Support | 2 | 2006-07-19 20:18 |
| Crash proof scripting | Phunck | Plugin/Script (Python) Development | 1 | 2005-04-28 16:08 |
| Scripting question about a few things | Billy | Plugin/Script (Python) Development | 9 | 2004-10-29 03:22 |