Some adjustments
This commit is contained in:
parent
159e9ca843
commit
4994a23a8a
1 changed files with 6 additions and 8 deletions
|
@ -74,17 +74,15 @@ int main()
|
|||
// initialize renderer: aperture = lens thickness, secondaryRayCount = how many rays per pixel are created
|
||||
float focalLength = length(camera.getPosition() - planePosition + Vector3d(0, 0, 2.6f));
|
||||
DOFRenderer renderer(0.02, 100, focalLength);
|
||||
float imageScalar = 2;
|
||||
float imageScalar = 1;
|
||||
Texture image = renderer.renderImage(scene, camera, 1920 * imageScalar, 1080 * imageScalar);
|
||||
|
||||
// Use post-processing Bloom effect
|
||||
Bloom bloomEffect = Bloom(image.getImage());
|
||||
Texture imageWithBloom = image;
|
||||
imageWithBloom.setTexture(bloomEffect.bloom(0.55f, 5, 10.0f, 0.06f));
|
||||
|
||||
// save images
|
||||
image.save("result.png");
|
||||
imageWithBloom.save("resultWithBloom.png");
|
||||
|
||||
// Use post-processing Bloom effect
|
||||
Bloom bloomEffect = Bloom(image.getImage(), 0.88f, image);
|
||||
image.setTexture(bloomEffect.bloom(50, 20.0f, 0.5f));
|
||||
image.save("resultWithBloom.png");
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue