Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
Dec 11, 2018, 6:33:26 PM (6 years ago)
Author:
merholzl
Message:

Shader merge

Location:
code/branches/Merge_HS18
Files:
3 edited
1 copied

Legend:

Unmodified
Added
Removed
  • code/branches/Merge_HS18

  • code/branches/Merge_HS18/data/levels/tutorial.oxw

    r9348 r12183  
    5555    <?lua end ?>
    5656
    57     <GlobalShader compositor="Bloom" visible=false>
     57    <GlobalShader compositor="Bloom" visible=true>
    5858      <events>
    5959        <visibility>
    60           <DistanceTrigger position="0,0,0" distance=30 target="Spectator" switch=true />
     60          <DistanceTrigger position="0,0,0" distance=300 target="Spectator" switch=false />
    6161        </visibility>
    6262      </events>
  • code/branches/Merge_HS18/src/libraries/tools/Mesh.cc

    r11783 r12183  
    3535#include <OgreSubEntity.h>
    3636#include <OgreSceneManager.h>
     37#include <OgreHardwareVertexBuffer.h>
    3738
    3839#include "util/Convert.h"
     
    6465            this->scenemanager_->destroyEntity(this->entity_);
    6566
     67
    6668        if (GameMode::showsGraphics())
    6769        {
     
    7072                this->entity_ = this->scenemanager_->createEntity("Mesh" + multi_cast<std::string>(Mesh::meshCounter_s++), meshsource);
    7173                this->entity_->setCastShadows(this->bCastShadows_);
    72             }
    73             catch (...)
     74
     75
     76                unsigned short src, dest;
     77                try
     78                {
     79                    if (!this->entity_->getMesh()->suggestTangentVectorBuildParams(Ogre::VertexElementSemantic::VES_TANGENT, src, dest))
     80                    {
     81                        orxout() << "Generate Tanget for \"" << meshsource << '"' << endl;
     82                        this->entity_->getMesh()->buildTangentVectors(Ogre::VertexElementSemantic::VES_TANGENT, src, dest);
     83                        // this version cleans mirrored and rotated UVs but requires quality models
     84                        // mesh->buildTangentVectors(VES_TANGENT, src, dest, true, true);
     85                    }
     86                } catch (...)
     87                {
     88                    orxout(internal_warning) << "Couldn't generat tangets for \"" << meshsource << '"' << endl;
     89                }
     90
     91            } catch (...)
    7492            {
    7593                orxout(internal_error) << "Couldn't load mesh \"" << meshsource << '"' << endl;
     
    107125                this->entity_->getSubEntity(index)->setMaterialName(name);
    108126        }
    109         else 
     127        else
    110128            orxout() << "ERROR at Index " << index << endl;
    111129    }
Note: See TracChangeset for help on using the changeset viewer.