Commit Graph

62 Commits

Author SHA1 Message Date
Gareth Martin
7690c4efe8 Fix landscape layer import being averaged with existing data
[CL 2526766 by Gareth Martin in Main branch]
2015-04-27 06:51:49 -04:00
Mike Fricker
114458bf0f Clang warning fixes: Fixed missing 'override' specifiers
- Also removed some unreferenced functions that adding 'override' revealed

PR #1002 -- Thank you, Omar007!

[CL 2498415 by Mike Fricker in Main branch]
2015-04-01 07:20:55 -04:00
PaulEremeeff
3d878d5a79 PR #996: Fixing PVS-Studio warnings (Contributed by PaulEremeeff)
I have reviewed each change carefully, but it is a large change and I could have missed something! Here is a summary of the types of changes in this CL:
 * Made nullptr checks consistent (the plurality of the changes are of this type)
 * Completed switch statements (IE, switch did not explicitly handle default case, but had unhandled enum entries - this is the second most popular type of fix)
 * Removed unused variables
 * Removed redundant initializations
 * WidgetNavigationCustomization.cpp was fixed by the owner
 * integers converted to floats where result was stored in a float
 * Removed redundent null checks (e.g. before delete statements)
 * Renamed variables to prevent non-obvious shadowing
 * Fixed use of bitwise & when checking for equality to an enum entry (which is often 0)
 * Fixes for some copy paste errors (e.g. FoliageEdMode.cpp)

[CL 2498053 by Dan Oconnor in Main branch]
2015-03-31 20:12:31 -04:00
Zak Middleton
50daf8b396 #ue4 - Perf: Convert some uses of GetActorRotation() to GetActorQuat() where possible. Use FQuatRotationMatrix rather than FRotationMatrix where possible.
- FQuatRotationMatrix(GetActorQuat()) is ~4x faster than FRotationMatrix(GetActorRotation()), due to latter form's FQuat->FRotator conversion and different matrix construction using Sin/Cos.

[CL 2497964 by Zak Middleton in Main branch]
2015-03-31 18:56:31 -04:00
Dmitriy Dyomin
62de645e06 Fixed landscape tool crash when target landscape sub-level is hidden
UE-12433

[CL 2493427 by Dmitriy Dyomin in Main branch]
2015-03-27 05:11:05 -04:00
Dmitriy Dyomin
13a176c258 Fix: UE-12111 [CrashReport] Crash after undoing/deleting landscape
[CL 2488944 by Dmitriy Dyomin in Main branch]
2015-03-24 01:43:34 -04:00
Dan Oconnor
84da45973f PR #936: Fixes for PVS-Studio warnings from Paul Eremeeff
These are mostly fixes to redundant comparisons and initialization code, but there's also a fix for serious looking scope issue in FontCache.cpp

[CL 2483865 by Dan Oconnor in Main branch]
2015-03-18 20:36:02 -04:00
Richard TalbotWatkin
1d7768ff2b Added 3 new orthographic viewport modes.
#jira UE-1143 - LIVE: Include option to view Orthographic views from both angles Front Back Left Right Top Bottom
#reviewedby Matt.Kuhlenschmidt

[CL 2480276 by Richard TalbotWatkin in Main branch]
2015-03-16 12:50:15 -04:00
Dmitriy Dyomin
fcd4e0bb55 Fixed landscape tools to work with cross-level foliage
Fixed landscape retopologize tool that was losing foliage links

[CL 2469877 by Dmitriy Dyomin in Main branch]
2015-03-05 03:28:09 -05:00
Ori Cohen
fd1b14704b Refactor overlap/sweep/raycast so that they explicitly use channel object type or profile.
Old functionality still works, but deprecated. Note that for the object type the object params have been moved to the same argument position as ByChannel and byProfile

[CL 2460970 by Ori Cohen in Main branch]
2015-02-25 16:38:53 -05:00
Dmitriy Dyomin
b2c0251808 Seamless foliage painting/editing ( using shared foliage settings )
UE-8464
#codereview Jack.Porter

[CL 2435030 by Dmitriy Dyomin in Main branch]
2015-02-06 03:30:39 -05:00
Mikolaj Sieluzycki
fa01cacb6c Trim down the amount of UObject constructors.
#codereview Robert.Manuszewski

[CL 2429641 by Mikolaj Sieluzycki in Main branch]
2015-02-03 05:40:57 -05:00
Gareth Martin
505b7af648 Fix Landscape copy/paste gizmo bounds being calculated incorrectly. This was causing it to randomly disappear.
Fix Landscape copy/paste gizmo not being selected automatically when entering the copy/paste tool, or importing data into the gizmo, or switching to the gizmo brush, or opening the landscape editor when the copy/paste tool or the gizmo brush was the active tool/brush. This was causing it to unexpectedly not be movable/rotatable/resizable in those situations.
Fix Landscape copy/paste gizmo not being selectable with a single click. Coupled with the previous bug, this was causing a lot of confusion!
A bit of cleanup of the gizmo code:
- the landscape edmode is no-longer responsible for rendering a (0% opacity) box around the gizmo to make it selectable, instead the gizmo itself is now selectable.
- the gizmo frustrum transform is now calculated significantly more sanely!

[CL 2412231 by Gareth Martin in Main branch]
2015-01-20 10:47:28 -05:00
Gil Gribb
c357d02f8e UE4 - fix crash on raw importing
#codereview jack.porter

[CL 2411360 by Gil Gribb in Main branch]
2015-01-19 16:22:53 -05:00
Ori Cohen
9e51521dbe Move foliage into its own module
[CL 2405964 by Ori Cohen in Main branch]
2015-01-14 10:26:59 -05:00
Steve Robb
0756ef15b9 Delegate comparisons deprecated, lots of other associated code deprecated, and lots of warning fixups:
* Multicast delegate Add* calls now return FDelegateHandles, and Remove* calls are now all deprecated, except for a new Remove function which takes a FDelegateHandle.
* New FConsoleManager::RegisterConsoleVariableSink_Handle and UnregisterConsoleVariableSink_Handle functions which work in terms of FConsoleVariableSinkHandle.
* Timer calls which don't take FTimerHandles are deprecated.
* FTicker::AddTicker now returns an FDelegateHandle and is removed by an overloaded Remove function.
* DEFINE_ONLINE_DELEGATE* macros now define _Handle variants of the Add/Remove functions which return/take handles.
* Various other handle-based registration changes.
* Some unity build fixes.
* Some simplification of delegate code.
* Fixes for lots of existing code to use handle-based registration and unregistration.

#codereview robert.manuszewski

[CL 2400883 by Steve Robb in Main branch]
2015-01-08 09:29:27 -05:00
Gareth Martin
f303ca52fb Fix crash with landscape ramp tool (and maybe others) when undoing the creation of the landscape
[CL 2399928 by Gareth Martin in Main branch]
2015-01-07 12:00:19 -05:00
Jack Porter
61c3fe910b Back out revision 218 from //depot/UE4/Engine/Source/Editor/LandscapeEditor/Private/LandscapeEdMode.cpp
[CL 2393618 by Jack Porter in Main branch]
2014-12-19 05:07:40 -05:00
Jack Porter
e78822ef45 Fix for crash entering landscape edit mode
[CL 2393603 by Jack Porter in Main branch]
2014-12-19 04:47:35 -05:00
Gareth Martin
d9e53f7b12 Optimized landscape editing significantly by removing the TMap of brush points and replacing it with a 2D array of data (FLandscapeBrushData class)
Most code accessing brush/landscape data by calculating indexes (e.g. Data + (Y-Y1)*XSize + (X-X1)) replaced with scanline[X] style for speed
LandscapeInfo->SelectedRegion is now only queried if it contains anything, to avoid hashing the key unneccessarily (the hash function was showing on profiles :( )
Smoothing tool's SmoothFilterKernel*Scale* replaced by the more intuitive Size
Component brush fixed to be properly centered on the cursor at odd sizes and work correctly with the add component tool when cursor is over the landscape (but part of the brush is off the landscape) and size is >1
Copy tool fixed to copy the selected area and not a circle when using ctrl+c
Also a few style cleanups. for (auto it = xyz.CreateIterator...) replaced with ranged for, enums replaced with enum classes, 0.f -> 0.0f, NULL->nullptr, etc.

[CL 2392355 by Gareth Martin in Main branch]
2014-12-18 06:52:06 -05:00
Gareth Martin
bc7c3ff112 Fix "error: '&&' within '||' [-Werror,-Wlogical-op-parentheses]"
[CL 2383943 by Gareth Martin in Main branch]
2014-12-10 13:53:55 -05:00
Gareth Martin
fc43907d10 Add user setting for using Ctrl key in landscape editor
[CL 2383400 by Gareth Martin in Main branch]
2014-12-10 09:33:39 -05:00
Gareth Martin
5343bde5d6 Fix "CurrentTool && CurrentTool" in landscape editor code
[CL 2383389 by Gareth Martin in Main branch]
2014-12-10 09:29:05 -05:00
Ben Marsh
149375b14b Update copyright notices to 2015.
[CL 2379638 by Ben Marsh in Main branch]
2014-12-07 19:09:38 -05:00
Michael Noland
8fadce6378 Engine: Replace some color literals with FColor / FColorList entries
[CL 2378046 by Michael Noland in Main branch]
2014-12-05 15:03:26 -05:00