Changeset 396 for experimental/distortionNG
- Timestamp:
- Jul 4, 2012, 11:02:56 PM (12 years ago)
- Location:
- experimental/distortionNG
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
experimental/distortionNG/DistortionManipulator.cpp
r393 r396 517 517 void DistortionManipulator::updateDistortionSetup() 518 518 { 519 //updateDistortionViewProjectionMatrix();519 updateDistortionViewProjectionMatrix(); 520 520 updateDistortionMesh(); 521 521 _distortionSet->clearDirtyStatus(); … … 548 548 printf("Camera Direction: %.2lf, %.2lf, %.2lf\n",Focus.x()-Eye.x(),Focus.y()-Eye.y(),Focus.z()-Eye.z()); 549 549 printf("Vertical after: %.2lf, %.2lf, %.2lf\n",Vertical.x()-Eye.x(),Vertical.y()-Eye.y(),Vertical.z()-Eye.z()); 550 551 double fovy, aspectRatio, zNear, zFar; 552 _viewer->getCamera()->getProjectionMatrixAsPerspective(fovy, aspectRatio, zNear, zFar); 553 OSG_ALWAYS<<"aspect ratio: "<<aspectRatio<<std::endl; 554 //double newAspectRatio = double(_screenPixWidth) / double(_screenPixHeight); 555 //double aspectRatioChange = newAspectRatio / aspectRatio; 556 //if (aspectRatioChange != 1.0) 557 //{ 558 // _viewer->getCamera()->getProjectionMatrix() *= osg::Matrix::scale(1.0/aspectRatioChange,1.0,1.0); 559 //} 560 561 550 562 } 551 563 else -
experimental/distortionNG/shaderIntensityMap.frag
r395 r396 6 6 void main(void) 7 7 { 8 //vec4 blendColor = texture2DRect(intensityMapTexture, gl_FragCoord);9 vec4 blendColor = texture2DRect(intensityMapTexture, texCoord);8 vec4 blendColor = texture2DRect(intensityMapTexture, gl_FragCoord); 9 //vec4 blendColor = texture2DRect(intensityMapTexture, texCoord); 10 10 11 11 gl_FragColor = blendColor * texture2DRect( sceneTexture, texCoord) ;
Note: See TracChangeset
for help on using the changeset viewer.