About Store Forum Documentation Contact



Post Reply 
something like this appeared..
Author Message
b1s Offline
Member

Post: #1
something like this appeared..
when i updated the engine.
something like this came up as i tried to update my project.
9.0\vc\include\esenthelengine\Misc/Data.h(112) : error C2070: 'const wchar_t *(DetailLevels::ResolutionElement &)': illegal sizeof operand
12-22-2009 02:35 AM
Find all posts by this user Quote this message in a reply
Esenthel Offline
Administrator

Post: #2
RE: something like this appeared..
please paste your code where you are receiving the error

and what is the DetailLevels::ResolutionElement ?
12-22-2009 02:57 AM
Find all posts by this user Quote this message in a reply
Esenthel Offline
Administrator

Post: #3
RE: something like this appeared..
it looks like you're trying to give an invalid parameter into DataDesc
12-22-2009 02:58 AM
Find all posts by this user Quote this message in a reply
b1s Offline
Member

Post: #4
RE: something like this appeared..
header

Code:
class DetailLevels
{
public:
    struct ResolutionElement // for easy parsing of arrays
    {
       VecI2 resolution;
    };

    static ResolutionElement resolutions[];
    static const int RESOLUTIONCOUNT;

    static CChar8* levels[];
    static const int LEVELCOUNT;

    static const CChar* ResolutionElementParser(ResolutionElement &elm) // function which transforms ComboBoxElm into a string
    {
       static Str str;
       return str = S + elm.resolution.x + " x " + elm.resolution.y;
    }

    static void setDetailLevel(int level);
};
cpp
Code:
DetailLevels::ResolutionElement DetailLevels::resolutions[] =
{
    {VecI2( 800, 600)},
    {VecI2(1024, 768)},
    {VecI2(1280, 720)},
    {VecI2(1280, 768)},
    {VecI2(1280, 960)},
    {VecI2(1280,1024)},
    {VecI2(1600, 900)},
    {VecI2(1600,1024)},
    {VecI2(1680, 1050)},
    {VecI2(1920,1080)},
};
const int DetailLevels::RESOLUTIONCOUNT = ELMS(resolutions);

CChar8* DetailLevels::levels[] =
{
    "Low",
    "Medium",
    "High"
};
const int DetailLevels::LEVELCOUNT = ELMS(levels);


void DetailLevels::setDetailLevel(int level)
{
    switch (level) {
        default:
        {
            // Default settings
            ViewportFull.fov = DegToRad(65); // TODO: Calculate this dynamically?
            D.shdMapSize(512); // shader map size
            D.hpRt(true); // ??
            D.ambPower(0.3); // ambient light


i have no clue whats happening. i would like to say just that..
in every update im having extreme difficulties to fix my project accordingly.
name changes and update notes seem a bit vague and search system in this forum does not work very well.
(This post was last modified: 12-22-2009 11:23 AM by b1s.)
12-22-2009 09:41 AM
Find all posts by this user Quote this message in a reply
Esenthel Offline
Administrator

Post: #5
RE: something like this appeared..
you haven't posted the code which makes the errors, but I can see that maybe this is causing the problems

Code:
static const CChar* ResolutionElementParser(ResolutionElement &elm) // function which transforms ComboBoxElm into a string
    {
       static Str str;
       return str = S + elm.resolution.x + " x " + elm.resolution.y;
    }
this should be changed to
Code:
static Str Reso...
{
    return S + elm.resolution.x + " x " + elm.resolution.y;
}

name changed are a necesity in order to make the engine better
if you receive a compile error after update, then you need to make sure that highlighted code lines use the same parameters as required (check the headers od used functions)
I haven't noticed problems with forum search system, if you have an example of incorectly working search system please let me know
12-22-2009 05:16 PM
Find all posts by this user Quote this message in a reply
Post Reply