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
30
31
32
33
34
35
36
37
38
39
40
41
42
43
#ifndef _SCENE_NODE_RENDER_STATE_H_
#define _SCENE_NODE_RENDER_STATE_H_

#include "Platform/Headers/PlatformDefines.h"

namespace Divide {

struct RenderStagePass;
enum class RenderStage : U32;

class SceneNodeRenderState {
   public:
    SceneNodeRenderState();
    ~SceneNodeRenderState();

    inline void useDefaultMaterial(bool state) { _noDefaultMaterial = !state; }
    inline bool useDefaultMaterial() const { return !_noDefaultMaterial; }
    inline void setDrawState(bool state) { _drawState = state; }
    inline bool getDrawState() const { return _drawState; }

    bool getDrawState(const RenderStagePass& currentStagePass) const;

    void addToDrawExclusionMask(const RenderStagePass& currentStagePass);
    void removeFromDrawExclusionMask(const RenderStagePass& currentStagePass);

    void addToDrawExclusionMask(RenderStage currentStage);
    void removeFromDrawExclusionMask(RenderStage currentStage);

    size_t getDepthStateBlock();
    size_t getShadowStateBlock();

   protected:
    bool _drawState;
    bool _noDefaultMaterial;
    vectorImpl<U32> _exclusionMask;

    size_t _depthStateBlockHash;
    size_t _shadowStateBlockHash;
};

};  // namespace Divide

#endif

Commits for Divide-Framework/trunk/Source Code/Graphs/Headers/SceneNodeRenderState.h

Diff revisions: vs.
Revision Author Commited Message
852 Diff Diff IonutCava picture IonutCava Tue 07 Feb, 2017 17:17:27 +0000

[IonutCava]
- Separate Pass Type from Render Stage:
— Render Stage: Display, Shadow, Reflection, Refraction, etc
— Pass Type: Depth pass, Colour Pass, etc
- ToDo: Bug fixes for issues introduced with this change

773 Diff Diff IonutCava picture IonutCava Tue 04 Oct, 2016 15:53:18 +0000

[IonutCava]
- Split GenericDrawCommand gathering system into Init/Update to facilitate future threading support
- Fix drawCount() == 0 case in submitRenderCommand
- Make _cameraPool (more) threadsafe

766 Diff Diff IonutCava picture IonutCava Mon 22 Aug, 2016 15:54:49 +0000

[IonutCava]
- Descriptor/State cleanup part 2/3: SceneState/SceneRenderState cleanup

703 Diff Diff IonutCava picture IonutCava Wed 11 May, 2016 15:44:57 +0000

[IonutCava]
- Finish XML-based control bindings:
— Allow per bind input params (key id, mouse button index, joystick control data, etc)
— Allow mouse binding (with up to 7 buttons)
— Allow up to 4 joysticks (for now) with 120+ button, POV, Axis, Slider and Vector binding support for each
- Change all hashes in code from U32 to size_t for compatibility with STL/Boost

557 Diff Diff IonutCava picture IonutCava Tue 10 Nov, 2015 12:00:20 +0000

[IonutCava]
- Gather all rendering calls from glVertexArray and glGenericVertexData into a single function in glResources: submitRenderCommand.
— This allows both classes to interpret GenericDrawCommands in the same way
- Use unsigned ints for all hasehs instead of size_t to avoid negative number hashes (useful for debugging)

505 Diff Diff IonutCava picture IonutCava Tue 25 Aug, 2015 22:15:49 +0000

[IonutCava]
- Finish the draw command caching System
- Cleanup AnimationComponent class

458 Diff Diff IonutCava picture IonutCava Tue 02 Jun, 2015 16:26:18 +0000

[Ionut]
- More Linux port work

436 Diff Diff IonutCava picture IonutCava Thu 14 May, 2015 16:09:08 +0000

[Ionut]
- Initial cleanup of RenderStateBlock and RenderStateBlockDescriptor classes
- lineWith is now part of the render state and as such, must be explicitly set in the state hash
— This affects all IMPrimitives, especially those rendered via drawBox3D and drawLines

408 Diff Diff IonutCava picture IonutCava Thu 23 Apr, 2015 15:44:51 +0000

[Ionut]
- Fixed shadow map rendering using the new batching system (W.I.P.)
- Modified the Skeleton/Wireframe/BoundingBox/Geometry toggle system in SceneRenderState

379 IonutCava picture IonutCava Thu 19 Mar, 2015 17:13:02 +0000

[Ionut]
- More batching work:
— Implemented a RenderQueue where all draw commands are gathered but only sent to the GPU on a “flush” command. (currently, one flush per render bin pass)
— RenderQueue holds RenderPackage (former NodeRenderData) and tries to batch the draw commands into the previous package if ShaderBuffer and TextureData between the 2 packages is compatible (currently disabled as some ShaderBuffer rendering glitches appear with animated data)
— RenderingComponent looses the “render” member as rendering commands are queued and postDraw calls are delegated to the renderbin pass