Subversion Repository Public Repository

Divide-Framework

This repository has no backups
This repository's network speed is throttled to 100KB/sec

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
#include "Headers/ParticleVelocityGenerator.h"

namespace Divide {

void ParticleVelocityGenerator::generate(vectorImpl<std::future<void>>& packagedTasks, 
                                         const U64 deltaTime,
                                         ParticleData& p,
                                         U32 startIndex,
                                         U32 endIndex) {
    vec3<F32> min = _sourceOrientation * _minStartVel.xyz();
    vec3<F32> max = _sourceOrientation * _maxStartVel.xyz();
    
    typedef decltype(std::begin(p._velocity)) iter_t;
    for_each_interval<iter_t>(std::begin(p._velocity) + startIndex,
                              std::begin(p._velocity) + endIndex,
                              ParticleData::g_threadPartitionSize,
                              [&](iter_t from, iter_t to)
    {
        packagedTasks.push_back(
            std::async(std::launch::async | std::launch::deferred,
                       [from, to, min, max]() {
                           std::for_each(from, to, [&](iter_t::value_type& velocity)
                           {
                               velocity.set(Random(min, max));
                           });
                      }));
    });
}
};

Commits for Divide-Framework/trunk/Source Code/Dynamics/Entities/Particles/ConcreteGenerators/ParticleVelocityGenerator.cpp

Diff revisions: vs.
Revision Author Commited Message
631 Diff Diff IonutCava picture IonutCava Sun 24 Jan, 2016 20:28:21 +0000

[IonutCava]
- Fix and optimize particle rendering system
- Temporarily disable Z_PRE_PASS system for testing
- Improve thread pool destruction system a bit
- Fix texture loading when used as fb attachment
- Forward+ renderer now takes the entire light buffer (no need to split up by light type)
- Start work on occlusion culling fixes:
— ToDo: Take into account batching system
— Fix gl_DrawIDARB usage

568 Diff Diff IonutCava picture IonutCava Mon 16 Nov, 2015 16:32:35 +0000

[IonutCava]
- Apply SGN transforms to particle emitters
- Fix some GLSL casts

542 Diff Diff IonutCava picture IonutCava Thu 29 Oct, 2015 23:44:59 +0000

[IonutCava]
- Improved multi-threaded culling
- Increased nodeBuffer size to avoid different render stages to override each-other’s data and wait for locks
- Added a indirect command buffer per render stage

541 Diff Diff IonutCava picture IonutCava Thu 29 Oct, 2015 17:03:27 +0000

[IonutCava]
- Initial work on multi-threading the main loop (experimental. unstable):
— Multi-threaded frustum culling
— Multi-threaded particle update system

530 Diff Diff IonutCava picture IonutCava Tue 20 Oct, 2015 15:58:24 +0000

[IonutCava]
- Particle system improvements
- glLockManager improvements

521 Diff Diff IonutCava picture IonutCava Tue 06 Oct, 2015 16:12:58 +0000

[IonutCava]
- Performance improvements:
— Upload an entire animation’s bone data instead of the current frame’s data and bind the appropriate frame’s transform range.
-— Sacrifices VRAM but reduces the number of RAM->VRAM uploads for animated characters
— Some refactoring in the particle code (emitter, generators, updaters, etc)
- Bugfix:
— Default texture wrap mode to REPEAT instead of CLAMP as ASSIMP seems to be failing at reading texture wrap modes and REPEAT is a safer bet.

433 Diff Diff IonutCava picture IonutCava Wed 13 May, 2015 15:57:17 +0000

[Ionut]
- Some code cleanup (global functions now start with a capital case)
- Some fixed timestep adjustments
- Input logging (key presses & mouse button presses with location at event time)

422 Diff Diff IonutCava picture IonutCava Tue 05 May, 2015 20:33:47 +0000

[Ionut]
- Bug fixes for the previous commit
- Replace most static_cast<U32/I32> with to_int / to_uint

358 Diff Diff IonutCava picture IonutCava Sun 01 Mar, 2015 22:44:38 +0000

[Ionut]
- Fixed some OpenGL initialization issues and function calls (no proper support for DSA yet)
- Cleanup up the Sound and Physics Wrappers
- Some readability improvements here and there

353 IonutCava picture IonutCava Tue 17 Feb, 2015 17:08:27 +0000

[Ionut]
- Compatibility updates for Boost 1.57 (some warnings still exist for now)
- Fixed some non-conforming code
- Added ALL OF THE MISSING FILES FROM THE LAST 15 commits ...........