Commit Graph

5735 Commits

Author SHA1 Message Date
Latif Khalifa
4d3c80e273 Merge branch 'master' of git://github.com/AlericInglewood/SingularityViewer 2014-04-04 20:08:19 +02:00
Aleric Inglewood
a332a7fc35 Compile fix for motions backport. 2014-04-04 17:33:45 +02:00
Aleric Inglewood
2fb945a489 Fix floating point round off error bug that caused mAnimTime to be decreased in value.
Conflicts:
	indra/llcharacter/llmotioncontroller.cpp
2014-04-04 15:22:18 +02:00
Aleric Inglewood
4d2517d163 Freeze also synchronized avatars when editing an attachment.
On the removal of permYouOwner():

Calling permYouOwner() to determine if an attachment is yours is
not correct: grid gods (and that includes BEFORE requesting admin
status) are marked as owner of everything in their sim.

The reason for that is that otherwise,
  <Melanie_T> if they only had it when actually godding u, the viewer
  would have to have an option to either show the proper menus (it
  doesn't) or allow the sim to refresh the object flags without full
  object updates (it hasn't).
  <Melanie_T> gods often have to act fast, for instance with griefers.
  Having transition to god mode take as long as a full rez just isn't an
  option, apart from the sim load caused by resending all objects.
  <Melanie_T> Then i tried resending only the object that was selected
  but there the arriving object update would close the pie menu.
  So you right-click a prim and the pie menu would close again.

The result has always been that if you are on your own sim, in opensim,
and select an attachment on another avatar, then YOU would freeze, not
the selected avatar. This patch fixes that "opensim related" bug as
well.
2014-04-04 15:19:50 +02:00
Aleric Inglewood
b4848f308f Compile fix for Release 2014-04-04 15:19:39 +02:00
Aleric Inglewood
1c8876cead Synchronize looping animations that start at the same moment. 2014-04-04 15:19:28 +02:00
Aleric Inglewood
1bcb6ad20d Version 2 of AISyncClient et al.
A tool to synchronize objects:
Objects derived from AISyncClient can signal that they are
'ready' or 'not ready' for up to 32 events (using a bitmask)
at a time. Clients that are created at roughly the same time
as other clients, and which return the same 'key' (a virtual
function returning an AISyncKey object) will be grouped together
and receive events (by means of virtual functions being called)
to notify them of all clients being ready or not for one of the
events (the least significant bit)). The other events can be polled.

This new version does away with all the templates and explicitly
remembers what events each client is ready for instead of just
updating a counter of the number of clients. This was necessary
because a client is removed then the server needs to know if it
was ready or not when it has to be able to update those counters.
This time I chose to just run over all stored clients and AND
and OR the per-client-ready-masks because 1) that information
is available now and 2) the lists will normally contain only
one or two clients, so it's fast enough.
The new version also allows for real key comparison (and derived
keys) instead of just using "hash" value that is compared.
2014-04-04 15:19:18 +02:00
Aleric Inglewood
66aaa9cf80 Add LLMotionController* LLMotion::mMotionController
This is needed for synchronization: motions will have to start
(with a specific start time offset) from a point in the code where
only the motion object is available.

I added/used LLMotionController& in a previous commit, this was
now changed into a pointer. There is (obviously) not much reason
for that, but also no disadvantage: the diff relative to LLs code
doesn't get larger since the references where already added, too.

Conflicts:
	indra/llcharacter/llkeyframemotion.cpp
	indra/llcharacter/llkeyframemotion.h
2014-04-04 15:19:02 +02:00
Aleric Inglewood
61d365e957 Removed this again... 2014-04-04 15:15:36 +02:00
Aleric Inglewood
006b319c3a Add AISyncClient<> (and AISyncServer).
A tool to synchronize objects:
Objects derived from AISyncClient can signal that they are
'ready' or 'not ready' for up to 4 events (using a bitmask)
at a time. Clients that signal to be ready for anything
at roughly the same time as other clients, and which return
the same 'hash' (a virtual function returning a 64bit value)
will be grouped together and receive events (by means of
virtual functions being called) to notify them of all clients
being ready or not for one of the events (syncevent1).
The other three events can be polled.

The memory usage is low (one pointer per client that points
to its AISyncServer object), servers are released to a cache
after about 100 ms (unless there is actual need for synchronization),
so there aren't much of those either.

The CPU usage is extremely low: all events are handled in
parallel in a 32 bit value (6 bits per event to count the
number of registered clients and the number of ready clients
for each event, and the remaining 8 bits to count the
number of reference pointers (which should only be a constant
higher, so that is overkill). To signal to a server that
a client has become ready or not is mostly a function call,
which then takes 1 clock cycle or so before returning.
Registration of a client is slightly more expensive as it
requires a pointer to be added to the end of a std::list.
This tool could easily be used as part of the graphics engine
(not that I intend to do that :p).
2014-04-04 15:15:26 +02:00
Aleric Inglewood
e38ec797fd Fix lookat and pointat shared experience.
There was a bug that when people turned off sending viewer effects,
they'd also turn off sending LookAt, while there is a seperate
checkbox to turn THAT off, while still seeing their own avatar
happily look around, breaking shared experience (most notably, most
people will be complete oblivious of the fact that they look like
zombies to others and that their friends do not see the same thing
on their screen).

This patch fixes this: both parties now see the same thing. Lookat
and PointAt are only turned off by their respective checkboxes,
and no longer silently influenced by turning off other viewer
effects.
2014-04-04 15:15:15 +02:00
Aleric Inglewood
94b42e7a9b Speed up of particular inefficient part related to motions.
For these standard motions, the viewer likes to very frequently
flood-call startMotion/stopMotion sometimes, which at the very
least needs a LLUUID lookup in a std::map. In particular, this
is done for two of them for every avatar in the sim every frame.
This code makes it possible to test if that makes sense by
merely doing a bit test.

Conflicts:
	indra/llcharacter/llkeyframemotion.h
2014-04-04 15:14:54 +02:00
Aleric Inglewood
61097dac72 Auto clean up motion cache.
Conflicts:
	indra/llcharacter/llkeyframemotion.cpp
	indra/llcharacter/llkeyframemotion.h
	indra/newview/llfloaterbvhpreview.cpp
2014-04-04 15:10:52 +02:00
Aleric Inglewood
116fe01dee Add AIDebugInstanceCounter
Prints number of instances upon construction and destruction.
Usage:

class LLSomething : public AIDebugInstanceCounter<LLSomething>
...
2014-04-04 14:57:55 +02:00
Aleric Inglewood
ba2bf9f366 Get rid of unused and irrepairable code. 2014-04-04 14:57:41 +02:00
Aleric Inglewood
a5b68f2da2 Changes to llkeyframemotionparam.cpp as result of audit.
These changes were the result of my Motion leak audit.
However, there is a serious problem with LLKeyframeMotionParam
in that it stores plain pointers to objects that can and will be deleted
by other objects. Its the classicial LL example of coding
non-Object-Oriented badly maintainable and instable code.

I cannot make sure this won't go wrong for the simple fact
that LLKeyframeMotionParam is not used at ALL in our code.
Hence, the next commit will rather delete this file.
This commit is merely to have a record of this finding.
2014-04-04 14:57:31 +02:00
Inusaito Sayori
97edb0f954 [Floater Flexibility] Part three: Create the flexible toolbar and create the temporary settings for button visibility
Look in debug settings for settings that start with ToolbarVisible
This will have an official interface by part four.
2014-04-03 14:36:20 -04:00
Inusaito Sayori
a3531b931b Feature Request: Ding for groups and conference chats. 2014-04-03 01:27:27 -04:00
Aleric Inglewood
0438f070f7 Merge remote-tracking branch 'singu/master' 2014-04-01 01:28:55 +02:00
Inusaito Sayori
f53e36c430 Fix not being able to buy land because of inversed RLVa logic. 2014-03-31 13:12:33 -04:00
Inusaito Sayori
8889e2de64 Fix icon packaging on mac. 2014-03-31 12:22:12 -04:00
Shyotl
dfb465a11b Merge branch 'master' of https://github.com/singularity-viewer/SingularityViewer.git 2014-03-29 02:13:26 -05:00
Shyotl
9ed2dc755c Always set materials mask if deferred for materials/alpha pools. Fixes potential crash in LLDrawPoolAlpha::renderAlpha 2014-03-28 17:14:57 -05:00
Latif Khalifa
e70342b356 Removed duplicate check introduced in the last change 2014-03-28 16:42:27 +01:00
Latif Khalifa
ba0fd794d7 Compile fix 2014-03-28 16:20:38 +01:00
Latif Khalifa
dbd7de628f Fix compilation with gcc 2014-03-28 08:50:02 +01:00
Shyotl
d6fdaa93a4 Added adaptive vsync support (selectable in preferences->graphics->hardware, provided the driver supports it). Also hide 16x fsaa on amd hardware, as it is not supported on said hardware (unsure about intel). 2014-03-28 02:34:03 -05:00
Latif Khalifa
80076833d1 Fix compilation with gcc 2014-03-28 08:30:22 +01:00
Latif Khalifa
dc9d3fbf96 Fix build with SDL prior to 1.3.0 2014-03-28 08:29:30 +01:00
Latif Khalifa
e12548ab8c Merge branch 'master' of git://github.com/Shyotl/SingularityViewer 2014-03-28 08:45:40 +01:00
Shyotl
894261862d Tweaks to stencil handling to allow masking out of sky (or geometry).
Reset stencil clear value to 0 after done clearing.
2014-03-27 22:31:47 -05:00
Shyotl
07a261a259 A little bit of cleanup. 2014-03-27 22:04:30 -05:00
Shyotl
34a7bf4dbb Comment out unused shader. 2014-03-27 21:30:23 -05:00
Shyotl
5988f6cf88 Updated rigged mesh face batch/pool handling.
Fixed issue with fullbright and glow occlusion.
RenderTransparentWater toggling should work more gracefully.
Fixed some bugs in general drawpool classification for faces. Bump pool was superceding more than it should have.
2014-03-27 21:27:40 -05:00
Inusaito Sayori
039be1f8e9 Fix Issue 1413: Local Texture Default Texture Update Settings, Also fix the side issue of the More section not having visible ui at first.
Also I got fed up with the bad code and leaks so I did some refactoring of floaterlocalassetbrowse.*, but just a bit.
2014-03-27 21:33:21 -04:00
Inusaito Sayori
70e92a1cea More helpful fixes and touchups from Cinder 2014-03-27 20:10:06 -04:00
Inusaito Sayori
2af2e37dcd Right clicking folder with only gestures (no worn items) should still offer remove from outfit if any gesture in that folder is active.
Also follow linked folders when wearing folders, this will make linked folders a lot more useful!
Also fixes a warning and some spacing issues
2014-03-27 20:02:12 -04:00
Inusaito Sayori
a6559b1e51 [Floater Flexibility] Part two: Move floater dictionary into menu commands and use a common function to ShowFloaters between LLToolBar and menus. 2014-03-27 00:31:32 -04:00
Inusaito Sayori
361b8852df Fix Issue 1419: Moving a link to an inventory folder moves the pointed folder and not the link 2014-03-25 19:56:41 -04:00
Inusaito Sayori
ff201ce3f9 Fix Issue 1448: Hard crash when emptying the mute list. 2014-03-25 19:51:49 -04:00
Inusaito Sayori
de2ce83a8d Touchups to namesystem update 2014-03-25 19:39:02 -04:00
Inusaito Sayori
f37d83abe1 [Floater Flexibility] Part one: Refactor all floaters to work with the dictionary in one way or another. 2014-03-25 00:23:56 -04:00
Inusaito Sayori
ee610ceb3f The Name System update!
Adds name list specific name settings, Removes boolean for having lists of speakers with legacy names in favor of having a more flexible setting for them
Have a look at the combo boxes on Adv. Chat->Chat UI to customize these new settings.

There is now a fourth option for name display: LegaCy Name (D is play Name)
2014-03-24 17:52:13 -04:00
Inusaito Sayori
5affacab70 Fixes, mainly for Clang/Mac, from Cinder. 2014-03-24 16:56:10 -04:00
Latif Khalifa
924011f36e Merge branch 'master' of git://github.com/Lirusaito/SingularityViewer 2014-03-23 14:24:47 +01:00
Inusaito Sayori
70b5a6f05b Prevent Issue 1445, reassess enablement of asset browser buttons when selection may have changed 2014-03-23 06:03:20 -04:00
Inusaito Sayori
05c7270dcf Merge changes for STORM-2008
"Remove from outfit" should deactivate gestures in a folder as well as take off items
Credit to Lance Corrimal
2014-03-20 03:53:11 -04:00
Inusaito Sayori
a75e34d1c2 Feature Request: Allow "wear_folder" SLapps 2014-03-20 03:34:17 -04:00
Inusaito Sayori
f7139ac20e Fix Issue 1406: Create Landmark shows name twice, not description 2014-03-18 19:45:18 -04:00
Inusaito Sayori
e43d718e0f Sappadilli's fix for the mini button 2014-03-18 19:18:57 -04:00