aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/linden/indra/llcommon
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--linden/indra/llcommon/CMakeLists.txt2
-rw-r--r--linden/indra/llcommon/imageids.cpp77
-rw-r--r--linden/indra/llcommon/imageids.h57
-rw-r--r--linden/indra/llcommon/indra_constants.cpp47
-rw-r--r--linden/indra/llcommon/indra_constants.h17
-rw-r--r--linden/indra/llcommon/lldarray.h2
-rw-r--r--linden/indra/llcommon/lldate.cpp2
-rw-r--r--linden/indra/llcommon/lldate.h5
-rw-r--r--linden/indra/llcommon/llerror.h4
-rwxr-xr-xlinden/indra/llcommon/lllslconstants.h3
10 files changed, 168 insertions, 48 deletions
diff --git a/linden/indra/llcommon/CMakeLists.txt b/linden/indra/llcommon/CMakeLists.txt
index ae961a3..7d001ae 100644
--- a/linden/indra/llcommon/CMakeLists.txt
+++ b/linden/indra/llcommon/CMakeLists.txt
@@ -12,6 +12,8 @@ include_directories(
12 ) 12 )
13 13
14set(llcommon_SOURCE_FILES 14set(llcommon_SOURCE_FILES
15 imageids.cpp
16 indra_constants.cpp
15 llapp.cpp 17 llapp.cpp
16 llapr.cpp 18 llapr.cpp
17 llassettype.cpp 19 llassettype.cpp
diff --git a/linden/indra/llcommon/imageids.cpp b/linden/indra/llcommon/imageids.cpp
new file mode 100644
index 0000000..6b4fcd3
--- /dev/null
+++ b/linden/indra/llcommon/imageids.cpp
@@ -0,0 +1,77 @@
1/**
2 * @file imageids.cpp
3 *
4 * $LicenseInfo:firstyear=2001&license=viewergpl$
5 *
6 * Copyright (c) 2001-2010, Linden Research, Inc.
7 *
8 * Second Life Viewer Source Code
9 * The source code in this file ("Source Code") is provided by Linden Lab
10 * to you under the terms of the GNU General Public License, version 2.0
11 * ("GPL"), unless you have obtained a separate licensing agreement
12 * ("Other License"), formally executed by you and Linden Lab. Terms of
13 * the GPL can be found in doc/GPL-license.txt in this distribution, or
14 * online at http://secondlife.com/developers/opensource/gplv2
15 *
16 * There are special exceptions to the terms and conditions of the GPL as
17 * it is applied to this Source Code. View the full text of the exception
18 * in the file doc/FLOSS-exception.txt in this software distribution, or
19 * online at
20 * http://secondlife.com/developers/opensource/flossexception
21 *
22 * By copying, modifying or distributing this software, you acknowledge
23 * that you have read and understood your obligations described above,
24 * and agree to abide by those obligations.
25 *
26 * ALL LINDEN LAB SOURCE CODE IS PROVIDED "AS IS." LINDEN LAB MAKES NO
27 * WARRANTIES, EXPRESS, IMPLIED OR OTHERWISE, REGARDING ITS ACCURACY,
28 * COMPLETENESS OR PERFORMANCE.
29 * $/LicenseInfo$
30 *
31 */
32
33#include "linden_common.h"
34
35#include "imageids.h"
36
37#include "lluuid.h"
38
39//
40// USE OF THIS FILE IS DEPRECATED
41//
42// Please use viewerart.ini and the standard
43// art import path. // indicates if file is only
44 // on dataserver, or also
45 // pre-cached on viewer
46
47// Grass Images
48const LLUUID IMG_SMOKE ("b4ba225c-373f-446d-9f7e-6cb7b5cf9b3d"); // VIEWER
49
50const LLUUID IMG_DEFAULT ("d2114404-dd59-4a4d-8e6c-49359e91bbf0"); // VIEWER
51
52const LLUUID IMG_SUN ("cce0f112-878f-4586-a2e2-a8f104bba271"); // dataserver
53const LLUUID IMG_MOON ("d07f6eed-b96a-47cd-b51d-400ad4a1c428"); // dataserver
54const LLUUID IMG_CLOUD_POOF ("fc4b9f0b-d008-45c6-96a4-01dd947ac621"); // dataserver
55const LLUUID IMG_SHOT ("35f217a3-f618-49cf-bbca-c86d486551a9"); // dataserver
56const LLUUID IMG_SPARK ("d2e75ac1-d0fb-4532-820e-a20034ac814d"); // dataserver
57const LLUUID IMG_FIRE ("aca40aa8-44cf-44ca-a0fa-93e1a2986f82"); // dataserver
58const LLUUID IMG_FACE_SELECT ("a85ac674-cb75-4af6-9499-df7c5aaf7a28"); // face selector
59const LLUUID IMG_DEFAULT_AVATAR ("c228d1cf-4b5d-4ba8-84f4-899a0796aa97"); // dataserver
60const LLUUID IMG_INVISIBLE ("3a367d1c-bef1-6d43-7595-e88c1e3aadb3"); // dataserver
61
62const LLUUID IMG_EXPLOSION ("68edcf47-ccd7-45b8-9f90-1649d7f12806"); // On dataserver
63const LLUUID IMG_EXPLOSION_2 ("21ce046c-83fe-430a-b629-c7660ac78d7c"); // On dataserver
64const LLUUID IMG_EXPLOSION_3 ("fedea30a-1be8-47a6-bc06-337a04a39c4b"); // On dataserver
65const LLUUID IMG_EXPLOSION_4 ("abf0d56b-82e5-47a2-a8ad-74741bb2c29e"); // On dataserver
66const LLUUID IMG_SMOKE_POOF ("1e63e323-5fe0-452e-92f8-b98bd0f764e3"); // On dataserver
67
68const LLUUID IMG_BIG_EXPLOSION_1 ("5e47a0dc-97bf-44e0-8b40-de06718cee9d"); // On dataserver
69const LLUUID IMG_BIG_EXPLOSION_2 ("9c8eca51-53d5-42a7-bb58-cef070395db8"); // On dataserver
70
71const LLUUID IMG_BLOOM1 ("3c59f7fe-9dc8-47f9-8aaf-a9dd1fbc3bef"); // VIEWER
72const LLUUID TERRAIN_DIRT_DETAIL ("0bc58228-74a0-7e83-89bc-5c23464bcec5"); // VIEWER
73const LLUUID TERRAIN_GRASS_DETAIL ("63338ede-0037-c4fd-855b-015d77112fc8"); // VIEWER
74const LLUUID TERRAIN_MOUNTAIN_DETAIL ("303cd381-8560-7579-23f1-f0a880799740"); // VIEWER
75const LLUUID TERRAIN_ROCK_DETAIL ("53a2f406-4895-1d13-d541-d2e3b86bc19c"); // VIEWER
76
77const LLUUID DEFAULT_WATER_NORMAL ("822ded49-9a6c-f61c-cb89-6df54f42cdf4"); // VIEWER
diff --git a/linden/indra/llcommon/imageids.h b/linden/indra/llcommon/imageids.h
index beba0e2..7bae496 100644
--- a/linden/indra/llcommon/imageids.h
+++ b/linden/indra/llcommon/imageids.h
@@ -33,46 +33,43 @@
33#ifndef LL_IMAGEIDS_H 33#ifndef LL_IMAGEIDS_H
34#define LL_IMAGEIDS_H 34#define LL_IMAGEIDS_H
35 35
36#include "lluuid.h"
37
38// 36//
39// USE OF THIS FILE IS DEPRECATED 37// USE OF THIS FILE IS DEPRECATED
40// 38//
41// Please use viewerart.ini and the standard 39// Please use viewerart.ini and the standard
42// art import path. // indicates if file is only 40// art import path.
43 // on dataserver, or also 41
44 // pre-cached on viewer 42class LLUUID;
45 43
46// Grass Images 44extern const LLUUID IMG_SMOKE;
47const LLUUID IMG_SMOKE ("b4ba225c-373f-446d-9f7e-6cb7b5cf9b3d"); // VIEWER
48 45
49const LLUUID IMG_DEFAULT ("d2114404-dd59-4a4d-8e6c-49359e91bbf0"); // VIEWER 46extern const LLUUID IMG_DEFAULT;
50 47
51const LLUUID IMG_SUN ("cce0f112-878f-4586-a2e2-a8f104bba271"); // dataserver 48extern const LLUUID IMG_SUN;
52const LLUUID IMG_MOON ("d07f6eed-b96a-47cd-b51d-400ad4a1c428"); // dataserver 49extern const LLUUID IMG_MOON;
53const LLUUID IMG_CLOUD_POOF ("fc4b9f0b-d008-45c6-96a4-01dd947ac621"); // dataserver 50extern const LLUUID IMG_CLOUD_POOF;
54const LLUUID IMG_SHOT ("35f217a3-f618-49cf-bbca-c86d486551a9"); // dataserver - legacy? 51extern const LLUUID IMG_SHOT;
55const LLUUID IMG_SPARK ("d2e75ac1-d0fb-4532-820e-a20034ac814d"); // dataserver - unused 52extern const LLUUID IMG_SPARK;
56const LLUUID IMG_FIRE ("aca40aa8-44cf-44ca-a0fa-93e1a2986f82"); // dataserver - unused 53extern const LLUUID IMG_FIRE;
57const LLUUID IMG_FACE_SELECT ("a85ac674-cb75-4af6-9499-df7c5aaf7a28"); // face selector 54extern const LLUUID IMG_FACE_SELECT;
58const LLUUID IMG_DEFAULT_AVATAR ("c228d1cf-4b5d-4ba8-84f4-899a0796aa97"); // dataserver 55extern const LLUUID IMG_DEFAULT_AVATAR;
59const LLUUID IMG_INVISIBLE ("3a367d1c-bef1-6d43-7595-e88c1e3aadb3"); // dataserver 56extern const LLUUID IMG_INVISIBLE;
60 57
61const LLUUID IMG_EXPLOSION ("68edcf47-ccd7-45b8-9f90-1649d7f12806"); // On dataserver - unused 58extern const LLUUID IMG_EXPLOSION;
62const LLUUID IMG_EXPLOSION_2 ("21ce046c-83fe-430a-b629-c7660ac78d7c"); // On dataserver - unused 59extern const LLUUID IMG_EXPLOSION_2;
63const LLUUID IMG_EXPLOSION_3 ("fedea30a-1be8-47a6-bc06-337a04a39c4b"); // On dataserver - unused 60extern const LLUUID IMG_EXPLOSION_3;
64const LLUUID IMG_EXPLOSION_4 ("abf0d56b-82e5-47a2-a8ad-74741bb2c29e"); // On dataserver - unused 61extern const LLUUID IMG_EXPLOSION_4;
65const LLUUID IMG_SMOKE_POOF ("1e63e323-5fe0-452e-92f8-b98bd0f764e3"); // On dataserver - legacy? 62extern const LLUUID IMG_SMOKE_POOF;
66 63
67const LLUUID IMG_BIG_EXPLOSION_1 ("5e47a0dc-97bf-44e0-8b40-de06718cee9d"); // On dataserver - unused 64extern const LLUUID IMG_BIG_EXPLOSION_1;
68const LLUUID IMG_BIG_EXPLOSION_2 ("9c8eca51-53d5-42a7-bb58-cef070395db8"); // On dataserver - unused 65extern const LLUUID IMG_BIG_EXPLOSION_2;
69 66
70const LLUUID IMG_BLOOM1 ("3c59f7fe-9dc8-47f9-8aaf-a9dd1fbc3bef"); // VIEWER 67extern const LLUUID IMG_BLOOM1;
71const LLUUID TERRAIN_DIRT_DETAIL ("0bc58228-74a0-7e83-89bc-5c23464bcec5"); // VIEWER 68extern const LLUUID TERRAIN_DIRT_DETAIL;
72const LLUUID TERRAIN_GRASS_DETAIL ("63338ede-0037-c4fd-855b-015d77112fc8"); // VIEWER 69extern const LLUUID TERRAIN_GRASS_DETAIL;
73const LLUUID TERRAIN_MOUNTAIN_DETAIL ("303cd381-8560-7579-23f1-f0a880799740"); // VIEWER 70extern const LLUUID TERRAIN_MOUNTAIN_DETAIL;
74const LLUUID TERRAIN_ROCK_DETAIL ("53a2f406-4895-1d13-d541-d2e3b86bc19c"); // VIEWER 71extern const LLUUID TERRAIN_ROCK_DETAIL;
75 72
76const LLUUID DEFAULT_WATER_NORMAL ("822ded49-9a6c-f61c-cb89-6df54f42cdf4"); // VIEWER 73extern const LLUUID DEFAULT_WATER_NORMAL;
77 74
78#endif 75#endif
diff --git a/linden/indra/llcommon/indra_constants.cpp b/linden/indra/llcommon/indra_constants.cpp
new file mode 100644
index 0000000..64cbb11
--- /dev/null
+++ b/linden/indra/llcommon/indra_constants.cpp
@@ -0,0 +1,47 @@
1/**
2 * @file indra_constants.cpp
3 * @brief some useful short term constants for Indra
4 *
5 * $LicenseInfo:firstyear=2001&license=viewergpl$
6 *
7 * Copyright (c) 2001-2010, Linden Research, Inc.
8 *
9 * Second Life Viewer Source Code
10 * The source code in this file ("Source Code") is provided by Linden Lab
11 * to you under the terms of the GNU General Public License, version 2.0
12 * ("GPL"), unless you have obtained a separate licensing agreement
13 * ("Other License"), formally executed by you and Linden Lab. Terms of
14 * the GPL can be found in doc/GPL-license.txt in this distribution, or
15 * online at http://secondlife.com/developers/opensource/gplv2
16 *
17 * There are special exceptions to the terms and conditions of the GPL as
18 * it is applied to this Source Code. View the full text of the exception
19 * in the file doc/FLOSS-exception.txt in this software distribution, or
20 * online at
21 * http://secondlife.com/developers/opensource/flossexception
22 *
23 * By copying, modifying or distributing this software, you acknowledge
24 * that you have read and understood your obligations described above,
25 * and agree to abide by those obligations.
26 *
27 * ALL LINDEN LAB SOURCE CODE IS PROVIDED "AS IS." LINDEN LAB MAKES NO
28 * WARRANTIES, EXPRESS, IMPLIED OR OTHERWISE, REGARDING ITS ACCURACY,
29 * COMPLETENESS OR PERFORMANCE.
30 * $/LicenseInfo$
31 */
32
33#include "linden_common.h"
34
35#include "indra_constants.h"
36
37#include "lluuid.h"
38
39// "agent id" for things that should be done to ALL agents
40const LLUUID LL_UUID_ALL_AGENTS("44e87126-e794-4ded-05b3-7c42da3d5cdb");
41
42// Governor Linden's agent id.
43const LLUUID ALEXANDRIA_LINDEN_ID("ba2a564a-f0f1-4b82-9c61-b7520bfcd09f");
44const LLUUID GOVERNOR_LINDEN_ID("3d6181b0-6a4b-97ef-18d8-722652995cf1");
45const LLUUID REALESTATE_LINDEN_ID("3d6181b0-6a4b-97ef-18d8-722652995cf1");
46// Maintenance's group id.
47const LLUUID MAINTENANCE_GROUP_ID("dc7b21cd-3c89-fcaa-31c8-25f9ffd224cd");
diff --git a/linden/indra/llcommon/indra_constants.h b/linden/indra/llcommon/indra_constants.h
index 96c0a1f..34d1538 100644
--- a/linden/indra/llcommon/indra_constants.h
+++ b/linden/indra/llcommon/indra_constants.h
@@ -34,7 +34,9 @@
34#define LL_INDRA_CONSTANTS_H 34#define LL_INDRA_CONSTANTS_H
35 35
36#include "stdtypes.h" 36#include "stdtypes.h"
37#include "lluuid.h" 37#include "llpreprocessor.h"
38
39class LLUUID;
38 40
39// At 45 Hz collisions seem stable and objects seem 41// At 45 Hz collisions seem stable and objects seem
40// to settle down at a reasonable rate. 42// to settle down at a reasonable rate.
@@ -261,14 +263,15 @@ const U8 GOD_LIKE = 1;
261const U8 GOD_NOT = 0; 263const U8 GOD_NOT = 0;
262 264
263// "agent id" for things that should be done to ALL agents 265// "agent id" for things that should be done to ALL agents
264const LLUUID LL_UUID_ALL_AGENTS("44e87126-e794-4ded-05b3-7c42da3d5cdb"); 266extern const LLUUID LL_UUID_ALL_AGENTS;
267
268// inventory library owner
269extern const LLUUID ALEXANDRIA_LINDEN_ID;
265 270
266// Governor Linden's agent id. 271extern const LLUUID GOVERNOR_LINDEN_ID;
267const LLUUID ALEXANDRIA_LINDEN_ID("ba2a564a-f0f1-4b82-9c61-b7520bfcd09f"); 272extern const LLUUID REALESTATE_LINDEN_ID;
268const LLUUID GOVERNOR_LINDEN_ID("3d6181b0-6a4b-97ef-18d8-722652995cf1");
269const LLUUID REALESTATE_LINDEN_ID("3d6181b0-6a4b-97ef-18d8-722652995cf1");
270// Maintenance's group id. 273// Maintenance's group id.
271const LLUUID MAINTENANCE_GROUP_ID("dc7b21cd-3c89-fcaa-31c8-25f9ffd224cd"); 274extern const LLUUID MAINTENANCE_GROUP_ID;
272 275
273// Flags for kick message 276// Flags for kick message
274const U32 KICK_FLAGS_DEFAULT = 0x0; 277const U32 KICK_FLAGS_DEFAULT = 0x0;
diff --git a/linden/indra/llcommon/lldarray.h b/linden/indra/llcommon/lldarray.h
index 0e56a11..aee1363 100644
--- a/linden/indra/llcommon/lldarray.h
+++ b/linden/indra/llcommon/lldarray.h
@@ -57,7 +57,7 @@ public:
57 57
58 LLDynamicArray(S32 size=0) : std::vector<Type>(size) { if (size < BlockSize) std::vector<Type>::reserve(BlockSize); } 58 LLDynamicArray(S32 size=0) : std::vector<Type>(size) { if (size < BlockSize) std::vector<Type>::reserve(BlockSize); }
59 59
60 void reset() { std::vector<Type>::resize(0); } 60 void reset() { std::vector<Type>::clear(); }
61 61
62 // ACCESSORS 62 // ACCESSORS
63 const Type& get(S32 index) const { return std::vector<Type>::operator[](index); } 63 const Type& get(S32 index) const { return std::vector<Type>::operator[](index); }
diff --git a/linden/indra/llcommon/lldate.cpp b/linden/indra/llcommon/lldate.cpp
index 41a3af3..be29448 100644
--- a/linden/indra/llcommon/lldate.cpp
+++ b/linden/indra/llcommon/lldate.cpp
@@ -113,6 +113,8 @@ void LLDate::toHTTPDateStream(std::ostream& s) const
113#else 113#else
114 s.setf(ios::right); 114 s.setf(ios::right);
115#endif 115#endif
116 static char const* const weekdays[] = {"Sunday", "Monday", "Tuesday", "Wednesday", "Thursday", "Friday", "Saturday"};
117 static char const* const months[] = {"Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec"};
116 std::string day = weekdays[exp_time.tm_wday]; 118 std::string day = weekdays[exp_time.tm_wday];
117 std::string month = months[exp_time.tm_mon]; 119 std::string month = months[exp_time.tm_mon];
118 120
diff --git a/linden/indra/llcommon/lldate.h b/linden/indra/llcommon/lldate.h
index 7cc9c8a..5e1a491 100644
--- a/linden/indra/llcommon/lldate.h
+++ b/linden/indra/llcommon/lldate.h
@@ -158,9 +158,4 @@ std::ostream& operator<<(std::ostream& s, const LLDate& date);
158// Helper function to stream in a date 158// Helper function to stream in a date
159std::istream& operator>>(std::istream& s, LLDate& date); 159std::istream& operator>>(std::istream& s, LLDate& date);
160 160
161
162const static std::string weekdays[] = {"Sunday", "Monday", "Tuesday", "Wednesday", "Thursday", "Friday", "Saturday"};
163
164const static std::string months[] = {"Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec"};
165
166#endif // LL_LLDATE_H 161#endif // LL_LLDATE_H
diff --git a/linden/indra/llcommon/llerror.h b/linden/indra/llcommon/llerror.h
index 6794be4..37e922d 100644
--- a/linden/indra/llcommon/llerror.h
+++ b/linden/indra/llcommon/llerror.h
@@ -239,7 +239,7 @@ typedef LLError::NoClassInfo _LL_CLASS_TO_LOG;
239*/ 239*/
240 240
241#define lllog(level, broadTag, narrowTag, once) \ 241#define lllog(level, broadTag, narrowTag, once) \
242 { \ 242 do { \
243 static LLError::CallSite _site( \ 243 static LLError::CallSite _site( \
244 level, __FILE__, __LINE__, typeid(_LL_CLASS_TO_LOG), __FUNCTION__, broadTag, narrowTag, once);\ 244 level, __FILE__, __LINE__, typeid(_LL_CLASS_TO_LOG), __FUNCTION__, broadTag, narrowTag, once);\
245 if (_site.shouldLog()) \ 245 if (_site.shouldLog()) \
@@ -252,7 +252,7 @@ typedef LLError::NoClassInfo _LL_CLASS_TO_LOG;
252 LLError::End(); \ 252 LLError::End(); \
253 LLError::Log::flush(_out, _site); \ 253 LLError::Log::flush(_out, _site); \
254 } \ 254 } \
255 } 255 } while(0)
256 256
257// DEPRECATED: Use the new macros that allow tags and *look* like macros. 257// DEPRECATED: Use the new macros that allow tags and *look* like macros.
258#define lldebugs lllog(LLError::LEVEL_DEBUG, NULL, NULL, false) 258#define lldebugs lllog(LLError::LEVEL_DEBUG, NULL, NULL, false)
diff --git a/linden/indra/llcommon/lllslconstants.h b/linden/indra/llcommon/lllslconstants.h
index 222b85d..25a15e4 100755
--- a/linden/indra/llcommon/lllslconstants.h
+++ b/linden/indra/llcommon/lllslconstants.h
@@ -189,9 +189,6 @@ const S32 OBJECT_OWNER = 6;
189const S32 OBJECT_GROUP = 7; 189const S32 OBJECT_GROUP = 7;
190const S32 OBJECT_CREATOR = 8; 190const S32 OBJECT_CREATOR = 8;
191 191
192// llTextBox() magic token string - yes this is a hack. sue me.
193const std::string TEXTBOX_MAGIC_TOKEN = "!!llTextBox!!";
194
195// changed() event flags 192// changed() event flags
196const U32 CHANGED_NONE = 0x0; 193const U32 CHANGED_NONE = 0x0;
197const U32 CHANGED_INVENTORY = 0x1; 194const U32 CHANGED_INVENTORY = 0x1;