From what I can tell the RenderComponent (and it's subclasses) only purpose is to create the corresponding SceneNode. After this it appears to never be used again. Wouldn't it be better to destroy it after its done or combine it's purpose with another component so that it is still used?
RenderComponent Purpose?
This site uses cookies. By continuing to browse this site, you are agreeing to our Cookie Policy.
-
-
Personally I don't think so as the components are meant to represent a single aspect of the actor, as well the rendercomponent can have several options like 'cast shadows'PC - Custom Built
CPU: 3rd Gen. Intel i7 3770 3.4Ghz
GPU: ATI Radeon HD 7959 3GB
RAM: 16GB
Laptop - Alienware M17x
CPU: 3rd Gen. Intel i7 - Ivy Bridge
GPU: NVIDIA GeForce GTX 660M - 2GB GDDR5
RAM: 8GB Dual Channel DDR3 @ 1600mhz -
Ok, so in a move advanced engine the render component could be used to set special effects and visual options for the actor which could then be set to the corresponding node through events, is this correct?
-
Yes exactly, but I think more importantly it represents an aspect of the actor, I personally feel like anything that represents a part of an actor should be put in a component.PC - Custom Built
CPU: 3rd Gen. Intel i7 3770 3.4Ghz
GPU: ATI Radeon HD 7959 3GB
RAM: 16GB
Laptop - Alienware M17x
CPU: 3rd Gen. Intel i7 - Ivy Bridge
GPU: NVIDIA GeForce GTX 660M - 2GB GDDR5
RAM: 8GB Dual Channel DDR3 @ 1600mhz -
All of these things are correct.
In a real engine, the render component would have a lot more functionality. Its main purpose is to act as the interface into the rendering system for that object. For example, you might have a function that makes the object invisible, or applies a new shader.
-Rez -
Or perhaps to define which camera the actor should be attached to! I say that because it can be very useful to have a separate camera for UI.Mr.Mike
Author, Programmer, Brewer, Patriot
-
Share
- Facebook 0
- Twitter 0
- Google Plus 0
- Reddit 0
-
Users Online 2
2 Guests