From 36e09ee4564806125abcc82188ba58c06c7c7d1e Mon Sep 17 00:00:00 2001 From: Stephen Gold Date: Tue, 16 Jan 2018 18:05:34 -0800 Subject: [PATCH] comment corrections in jme3-vr: mostly spelling and grammar --- .../main/java/com/jme3/app/VRAppState.java | 10 +++++----- .../main/java/com/jme3/app/VRApplication.java | 8 ++++---- .../main/java/com/jme3/app/VREnvironment.java | 2 +- .../com/jme3/input/vr/oculus/OculusVR.java | 2 +- .../input/vr/oculus/OculusViewManager.java | 6 +++--- .../input/vr/openvr/OpenVRViewManager.java | 4 ++-- .../jme3/input/vr/osvr/OSVRViewManager.java | 4 ++-- .../jme3/shadow/AbstractShadowFilterVR.java | 6 +++--- .../jme3/shadow/AbstractShadowRendererVR.java | 4 ++-- .../DirectionalLightShadowFilterVR.java | 18 ++++++++--------- .../DirectionalLightShadowRendererVR.java | 20 +++++++++---------- .../VRDirectionalLightShadowRenderer.java | 6 +++--- .../com/jme3/system/lwjgl/LwjglWindowVR.java | 6 +++--- 13 files changed, 48 insertions(+), 48 deletions(-) diff --git a/jme3-vr/src/main/java/com/jme3/app/VRAppState.java b/jme3-vr/src/main/java/com/jme3/app/VRAppState.java index df329a505..7035e4c98 100644 --- a/jme3-vr/src/main/java/com/jme3/app/VRAppState.java +++ b/jme3-vr/src/main/java/com/jme3/app/VRAppState.java @@ -1,7 +1,7 @@ package com.jme3.app; /* - * Copyright (c) 2009-2012 jMonkeyEngine + * Copyright (c) 2009-2018 jMonkeyEngine * All rights reserved. * * Redistribution and use in source and binary forms, with or without @@ -117,7 +117,7 @@ public class VRAppState extends AbstractAppState { } /** - * Create a new VR app state with given settings. The app state relies on the the given {@link VREnvironment VR environment}. + * Create a new VR app state with given settings. The app state relies on the given {@link VREnvironment VR environment}. * @param settings the settings to use. * @param environment the {@link VREnvironment VR environment} that this app state is using. */ @@ -146,9 +146,9 @@ public class VRAppState extends AbstractAppState { } /** - * Set the frustrum values for the application. - * @param near the frustrum near value. - * @param far the frustrum far value. + * Set the frustum values for the application. + * @param near the frustum near value. + * @param far the frustum far value. */ public void setFrustrumNearFar(float near, float far) { fNear = near; diff --git a/jme3-vr/src/main/java/com/jme3/app/VRApplication.java b/jme3-vr/src/main/java/com/jme3/app/VRApplication.java index 2ad8ee134..0ea29d645 100644 --- a/jme3-vr/src/main/java/com/jme3/app/VRApplication.java +++ b/jme3-vr/src/main/java/com/jme3/app/VRApplication.java @@ -332,9 +332,9 @@ public abstract class VRApplication implements Application, SystemListener { } /** - * Set the frustrum values for the application. - * @param near the frustrum near value. - * @param far the frustrum far value. + * Set the frustum values for the application. + * @param near the frustum near value. + * @param far the frustum far value. */ public void setFrustrumNearFar(float near, float far) { fNear = near; @@ -1006,7 +1006,7 @@ public abstract class VRApplication implements Application, SystemListener { } /** - * Set the scene observer. The VR headset will be linked to it. If no observer is set, the VR headset is linked to the the application {@link #getCamera() camera}. + * Set the scene observer. The VR headset will be linked to it. If no observer is set, the VR headset is linked to the application {@link #getCamera() camera}. * @param observer the scene observer. */ public void setObserver(Spatial observer) { diff --git a/jme3-vr/src/main/java/com/jme3/app/VREnvironment.java b/jme3-vr/src/main/java/com/jme3/app/VREnvironment.java index 400d5396c..aaf5249ca 100644 --- a/jme3-vr/src/main/java/com/jme3/app/VREnvironment.java +++ b/jme3-vr/src/main/java/com/jme3/app/VREnvironment.java @@ -219,7 +219,7 @@ public class VREnvironment { } /** - * Set the scene observer. The VR headset will be linked to it. If no observer is set, the VR headset is linked to the the application {@link #getCamera() camera}. + * Set the scene observer. The VR headset will be linked to it. If no observer is set, the VR headset is linked to the application {@link #getCamera() camera}. * @param observer the scene observer. */ public void setObserver(Spatial observer) { diff --git a/jme3-vr/src/main/java/com/jme3/input/vr/oculus/OculusVR.java b/jme3-vr/src/main/java/com/jme3/input/vr/oculus/OculusVR.java index 7dcc36b9f..cde41e6c4 100644 --- a/jme3-vr/src/main/java/com/jme3/input/vr/oculus/OculusVR.java +++ b/jme3-vr/src/main/java/com/jme3/input/vr/oculus/OculusVR.java @@ -237,7 +237,7 @@ public class OculusVR implements VRAPI { hmdRelativeEyePositions[eye] = new Vector3f(); // Find the eye render information - we use this in the - // view manager for giving LibOVR it's timewarp information. + // view manager for giving LibOVR its timewarp information. eyeRenderDesc[eye] = OVREyeRenderDesc.malloc(); ovr_GetRenderDesc(session, eye, fovPorts[eye], eyeRenderDesc[eye]); diff --git a/jme3-vr/src/main/java/com/jme3/input/vr/oculus/OculusViewManager.java b/jme3-vr/src/main/java/com/jme3/input/vr/oculus/OculusViewManager.java index ac97ab3ef..517d8d265 100644 --- a/jme3-vr/src/main/java/com/jme3/input/vr/oculus/OculusViewManager.java +++ b/jme3-vr/src/main/java/com/jme3/input/vr/oculus/OculusViewManager.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2009-2017 jMonkeyEngine + * Copyright (c) 2009-2018 jMonkeyEngine * All rights reserved. * * Redistribution and use in source and binary forms, with or without @@ -233,12 +233,12 @@ public class OculusViewManager extends AbstractVRViewManager { private void setupCamerasAndViews() { // TODO: Use LobOVR IPD etc if (environment != null) { - // get desired frustrum from original camera + // get desired frustum from original camera Camera origCam = environment.getCamera(); float fFar = origCam.getFrustumFar(); float fNear = origCam.getFrustumNear(); - // restore frustrum on distortion scene cam, if needed + // restore frustum on distortion scene cam, if needed if (environment.isInstanceRendering()) { leftCamera = origCam; } else { diff --git a/jme3-vr/src/main/java/com/jme3/input/vr/openvr/OpenVRViewManager.java b/jme3-vr/src/main/java/com/jme3/input/vr/openvr/OpenVRViewManager.java index b2880c3a7..f4bdc920b 100644 --- a/jme3-vr/src/main/java/com/jme3/input/vr/openvr/OpenVRViewManager.java +++ b/jme3-vr/src/main/java/com/jme3/input/vr/openvr/OpenVRViewManager.java @@ -497,12 +497,12 @@ public class OpenVRViewManager extends AbstractVRViewManager { private void setupCamerasAndViews() { if (environment != null){ - // get desired frustrum from original camera + // get desired frustum from original camera Camera origCam = environment.getCamera(); float fFar = origCam.getFrustumFar(); float fNear = origCam.getFrustumNear(); - // restore frustrum on distortion scene cam, if needed + // restore frustum on distortion scene cam, if needed if( environment.isInstanceRendering() ) { leftCamera = origCam; } else if( environment.compositorAllowed() == false ) { diff --git a/jme3-vr/src/main/java/com/jme3/input/vr/osvr/OSVRViewManager.java b/jme3-vr/src/main/java/com/jme3/input/vr/osvr/OSVRViewManager.java index 077a19f12..e3f1df53a 100644 --- a/jme3-vr/src/main/java/com/jme3/input/vr/osvr/OSVRViewManager.java +++ b/jme3-vr/src/main/java/com/jme3/input/vr/osvr/OSVRViewManager.java @@ -607,7 +607,7 @@ public class OSVRViewManager extends AbstractVRViewManager{ if (environment != null){ if (environment.getApplication() != null){ - // get desired frustrum from original camera + // get desired frustum from original camera Camera origCam = environment.getCamera(); float fFar = origCam.getFrustumFar(); float fNear = origCam.getFrustumNear(); @@ -617,7 +617,7 @@ public class OSVRViewManager extends AbstractVRViewManager{ ((OSVR)environment.getVRHardware()).getEyeInfo(); } - // restore frustrum on distortion scene cam, if needed + // restore frustum on distortion scene cam, if needed if( environment.isInstanceRendering() ) { leftCamera = origCam; } else if( environment.compositorAllowed() == false ) { diff --git a/jme3-vr/src/main/java/com/jme3/shadow/AbstractShadowFilterVR.java b/jme3-vr/src/main/java/com/jme3/shadow/AbstractShadowFilterVR.java index 3b090e95d..9c6d355c9 100644 --- a/jme3-vr/src/main/java/com/jme3/shadow/AbstractShadowFilterVR.java +++ b/jme3-vr/src/main/java/com/jme3/shadow/AbstractShadowFilterVR.java @@ -1,7 +1,7 @@ package com.jme3.shadow; /* - * Copyright (c) 2009-2012 jMonkeyEngine + * Copyright (c) 2009-2018 jMonkeyEngine * All rights reserved. * * Redistribution and use in source and binary forms, with or without @@ -186,7 +186,7 @@ public abstract class AbstractShadowFilterVR } /** - * returns the shdaow intensity + * returns the shadow intensity * * @see #setShadowIntensity(float shadowIntensity) * @return shadowIntensity @@ -309,7 +309,7 @@ public abstract class AbstractShadowFilterVR /** - * Get the the edge filtering mode. + * Get the edge filtering mode. * @return the edge filtering mode. */ public EdgeFilteringMode getEdgeFilteringMode() { diff --git a/jme3-vr/src/main/java/com/jme3/shadow/AbstractShadowRendererVR.java b/jme3-vr/src/main/java/com/jme3/shadow/AbstractShadowRendererVR.java index ade7f5e4f..296855e5a 100644 --- a/jme3-vr/src/main/java/com/jme3/shadow/AbstractShadowRendererVR.java +++ b/jme3-vr/src/main/java/com/jme3/shadow/AbstractShadowRendererVR.java @@ -1,7 +1,7 @@ package com.jme3.shadow; /* - * Copyright (c) 2009-2012 jMonkeyEngine + * Copyright (c) 2009-2018 jMonkeyEngine * All rights reserved. * * Redistribution and use in source and binary forms, with or without @@ -487,7 +487,7 @@ public abstract class AbstractShadowRendererVR implements SceneProcessor, Savabl getReceivers(lightReceivers); if (lightReceivers.size() != 0) { - //setting params to recieving geometry list + //setting params to receiving geometry list setMatParams(lightReceivers); Camera cam = viewPort.getCamera(); diff --git a/jme3-vr/src/main/java/com/jme3/shadow/DirectionalLightShadowFilterVR.java b/jme3-vr/src/main/java/com/jme3/shadow/DirectionalLightShadowFilterVR.java index 41dc9eaba..5cc149ea3 100644 --- a/jme3-vr/src/main/java/com/jme3/shadow/DirectionalLightShadowFilterVR.java +++ b/jme3-vr/src/main/java/com/jme3/shadow/DirectionalLightShadowFilterVR.java @@ -1,7 +1,7 @@ package com.jme3.shadow; /* - * Copyright (c) 2009-2012 jMonkeyEngine + * Copyright (c) 2009-2018 jMonkeyEngine * All rights reserved. * * Redistribution and use in source and binary forms, with or without @@ -43,10 +43,10 @@ import java.io.IOException; /** * * This Filter does basically the same as a DirectionalLightShadowRenderer - * except it renders the post shadow pass as a fulscreen quad pass instead of a + * except it renders the post shadow pass as a fullscreen quad pass instead of a * geometry pass. It's mostly faster than PssmShadowRenderer as long as you have - * more than a about ten shadow recieving objects. The expense is the draw back - * that the shadow Recieve mode set on spatial is ignored. So basically all and + * more than a about ten shadow receiving objects. The expense is the draw back + * that the shadow Receive mode set on spatial is ignored. So basically all and * only objects that render depth in the scene receive shadows. See this post * for more details * http://jmonkeyengine.org/groups/general-2/forum/topic/silly-question-about-shadow-rendering/#post-191599 @@ -106,7 +106,7 @@ public class DirectionalLightShadowFilterVR extends AbstractShadowFilterVRtrue) - * This prevents shadows' edges to flicker when the camera moves + * Enables the stabilization of the shadow's edges. (default is true) + * This prevents shadow edges from flickering when the camera moves. * However it can lead to some shadow quality loss in some particular scenes. * @param stabilize true if the stabilization has to be enabled and false otherwise. * @see #isEnabledStabilization() diff --git a/jme3-vr/src/main/java/com/jme3/shadow/DirectionalLightShadowRendererVR.java b/jme3-vr/src/main/java/com/jme3/shadow/DirectionalLightShadowRendererVR.java index ac74bf5bb..4c87a39d7 100644 --- a/jme3-vr/src/main/java/com/jme3/shadow/DirectionalLightShadowRendererVR.java +++ b/jme3-vr/src/main/java/com/jme3/shadow/DirectionalLightShadowRendererVR.java @@ -1,7 +1,7 @@ package com.jme3.shadow; /* - * Copyright (c) 2009-2012 jMonkeyEngine + * Copyright (c) 2009-2018 jMonkeyEngine * All rights reserved. * * Redistribution and use in source and binary forms, with or without @@ -53,11 +53,11 @@ import com.jme3.shadow.ShadowUtil; import java.io.IOException; /** - * DirectionalLightShadowRenderer renderer use Parrallel Split Shadow Mapping + * DirectionalLightShadowRenderer renderer use Parallel Split Shadow Mapping * technique (pssm)
It splits the view frustum in several parts and compute * a shadow map for each one.
splits are distributed so that the closer they * are from the camera, the smaller they are to maximize the resolution used of - * the shadow map.
This result in a better quality shadow than standard + * the shadow map.
This results in a better quality shadow than standard * shadow mapping.
for more informations on this read this http://http.developer.nvidia.com/GPUGems3/gpugems3_ch10.html
*

@@ -77,7 +77,7 @@ public class DirectionalLightShadowRendererVR extends AbstractShadowRendererVR { private boolean stabilize = true; /** - * Used for serialzation use + * Used for serialization use * DirectionalLightShadowRenderer#DirectionalLightShadowRenderer(AssetManager * assetManager, int shadowMapSize, int nbSplits) */ @@ -182,7 +182,7 @@ public class DirectionalLightShadowRendererVR extends AbstractShadowRendererVR { // update frustum points based on current camera and split ShadowUtil.updateFrustumPoints(viewPort.getCamera(), splitsArray[shadowMapIndex], splitsArray[shadowMapIndex + 1], 1.0f, points); - //Updating shadow cam with curent split frustra + //Updating shadow cam with current split frusta if (lightReceivers.size()==0) { for (Spatial scene : viewPort.getScenes()) { ShadowUtil.getGeometriesInCamFrustum(scene, viewPort.getCamera(), RenderQueue.ShadowMode.Receive, lightReceivers); @@ -231,7 +231,7 @@ public class DirectionalLightShadowRendererVR extends AbstractShadowRendererVR { } /** - * returns the labda parameter see #setLambda(float lambda) + * returns the lambda parameter see #setLambda(float lambda) * * @return lambda */ @@ -241,10 +241,10 @@ public class DirectionalLightShadowRendererVR extends AbstractShadowRendererVR { /** * Adjust the repartition of the different shadow maps in the shadow extend - * usualy goes from 0.0 to 1.0 + * usually goes from 0.0 to 1.0 * a low value give a more linear repartition resulting in a constant quality in the shadow over the extends, but near shadows could look very jagged * a high value give a more logarithmic repartition resulting in a high quality for near shadows, but the quality quickly decrease over the extend. - * the default value is set to 0.65f (theoric optimal value). + * the default value is set to 0.65f (theoretic optimal value). * @param lambda the lambda value. */ public void setLambda(float lambda) { @@ -260,8 +260,8 @@ public class DirectionalLightShadowRendererVR extends AbstractShadowRendererVR { } /** - * Enables the stabilization of the shadows's edges. (default is true) - * This prevents shadows' edges to flicker when the camera moves + * Enables the stabilization of the shadow's edges. (default is true) + * This prevents shadow edges from flickering when the camera moves. * However it can lead to some shadow quality loss in some particular scenes. * @param stabilize true if stabilization has to be enabled and false otherwise. */ diff --git a/jme3-vr/src/main/java/com/jme3/shadow/VRDirectionalLightShadowRenderer.java b/jme3-vr/src/main/java/com/jme3/shadow/VRDirectionalLightShadowRenderer.java index d73d6d08a..759fdc42b 100644 --- a/jme3-vr/src/main/java/com/jme3/shadow/VRDirectionalLightShadowRenderer.java +++ b/jme3-vr/src/main/java/com/jme3/shadow/VRDirectionalLightShadowRenderer.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2009-2012 jMonkeyEngine + * Copyright (c) 2009-2018 jMonkeyEngine * All rights reserved. * * Redistribution and use in source and binary forms, with or without @@ -35,11 +35,11 @@ import com.jme3.asset.AssetManager; import com.jme3.shadow.DirectionalLightShadowRenderer; /** - * DirectionalLightShadowRenderer renderer use Parrallel Split Shadow Mapping + * DirectionalLightShadowRenderer renderer use Parallel Split Shadow Mapping * technique (pssm)
It splits the view frustum in several parts and compute * a shadow map for each one.
splits are distributed so that the closer they * are from the camera, the smaller they are to maximize the resolution used of - * the shadow map.
This result in a better quality shadow than standard + * the shadow map.
This results in a better quality shadow than standard * shadow mapping.
for more informations on this read this http://http.developer.nvidia.com/GPUGems3/gpugems3_ch10.html
*

diff --git a/jme3-vr/src/main/java/com/jme3/system/lwjgl/LwjglWindowVR.java b/jme3-vr/src/main/java/com/jme3/system/lwjgl/LwjglWindowVR.java index 95a1f8420..4bcad1876 100644 --- a/jme3-vr/src/main/java/com/jme3/system/lwjgl/LwjglWindowVR.java +++ b/jme3-vr/src/main/java/com/jme3/system/lwjgl/LwjglWindowVR.java @@ -1,7 +1,7 @@ package com.jme3.system.lwjgl; /* - * Copyright (c) 2009-2012 jMonkeyEngine + * Copyright (c) 2009-2018 jMonkeyEngine * All rights reserved. * * Redistribution and use in source and binary forms, with or without @@ -101,7 +101,7 @@ public abstract class LwjglWindowVR extends LwjglContextVR implements Runnable { } /** - * Set the title if its a windowed display + * Set the title if it's a windowed display * * @param title the title to set */ @@ -112,7 +112,7 @@ public abstract class LwjglWindowVR extends LwjglContextVR implements Runnable { } /** - * Restart if its a windowed or full-screen display. + * Restart if it's a windowed or full-screen display. */ public void restart() { if (created.get()) {