Ignore:
Timestamp:
Mar 7, 2009, 1:38:45 PM (16 years ago)
Author:
vrinside
Message:

fixed the location of particles

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/packages/vizservers/nanovis/NvParticleRenderer.cpp

    r1111 r1298  
    2828
    2929NvParticleRenderer::NvParticleRenderer(int w, int h, CGcontext context)
    30     : scale(1, 1, 1), _activate(false)
     30    : scale(1, 1, 1), _activate(false), origin(0, 0, 0)
    3131{
    3232    psys_width = w;
     
    261261    glPushMatrix();
    262262
     263    glTranslatef(origin.x, origin.y, origin.z);
    263264    glScaled(scale.x, scale.y, scale.z);
    264265
     
    275276}
    276277
    277 void NvParticleRenderer::setVectorField(unsigned int texID, float scaleX, float scaleY, float scaleZ, float max)
    278 {
     278void NvParticleRenderer::setVectorField(unsigned int texID, const Vector3& ori, float scaleX, float scaleY, float scaleZ, float max)
     279{
     280    origin = ori;
    279281    scale.set(scaleX, scaleY, scaleZ);
    280282    _advectionShader->setScale(scale);
Note: See TracChangeset for help on using the changeset viewer.