This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package io.github.sceneview.node | |
import androidx.annotation.IntRange | |
import com.google.android.filament.* | |
import io.github.sceneview.Entity | |
import io.github.sceneview.components.HasRenderableComponent | |
import io.github.sceneview.managers.NodeManager | |
import io.github.sceneview.mesh.Geometry | |
import io.github.sceneview.mesh.geometry |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package io.github.sceneview.mesh | |
import com.google.android.filament.Engine | |
import io.github.sceneview.math.Direction | |
import io.github.sceneview.math.Position | |
import io.github.sceneview.math.Size | |
/** | |
* Creates a [Geometry] in the shape of a cube with the give specifications. | |
* |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package io.github.sceneview.mesh | |
import com.google.android.filament.* | |
import dev.romainguy.kotlin.math.Float2 | |
import dev.romainguy.kotlin.math.max | |
import dev.romainguy.kotlin.math.min | |
import io.github.sceneview.components.EntityInstance | |
import io.github.sceneview.math.Direction | |
import io.github.sceneview.math.Position | |
import io.github.sceneview.math.normalToTangent |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package io.github.sceneview | |
import android.annotation.SuppressLint | |
import android.content.Context | |
import android.content.res.AssetManager | |
import android.graphics.PixelFormat | |
import android.graphics.drawable.ColorDrawable | |
import android.media.MediaRecorder | |
import android.os.Handler | |
import android.os.Looper |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package io.github.sceneview.components | |
import com.google.android.filament.EntityInstance | |
import com.google.android.filament.LightManager | |
import dev.romainguy.kotlin.math.Quaternion | |
import io.github.sceneview.light.* | |
import io.github.sceneview.math.Direction | |
import io.github.sceneview.math.Position | |
import io.github.sceneview.utils.Color | |
import io.github.sceneview.utils.toColor |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package io.github.sceneview.components | |
import android.animation.ObjectAnimator | |
import com.google.android.filament.* | |
import com.google.ar.sceneform.rendering.* | |
import dev.romainguy.kotlin.math.* | |
import io.github.sceneview.* | |
import io.github.sceneview.animation.TransformAnimator | |
import io.github.sceneview.gesture.* | |
import io.github.sceneview.math.* |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
fun startVideoRecord(fragment: MainFragment) { | |
verifyPermission(activity = fragment.activity, | |
permissions = listOf( | |
Manifest.permission.RECORD_AUDIO | |
), | |
fallBack = { | |
fragment.isRecording = false | |
}, | |
success = { | |
fragment.isRecording = true |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class WebView @JvmOverloads constructor( | |
context: Context, | |
attrs: AttributeSet? = null, | |
defStyleAttr: Int = 0, | |
defStyleRes: Int = 0 | |
) : WebView(context, attrs, defStyleAttr, defStyleRes) { | |
init { | |
this.isScrollContainer = false | |
this.isNestedScrollingEnabled = false |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
view.doOnDestroy { | |
removeListener(view) | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
view.doOnResume { | |
startWelcomeAnimation(view) | |
} | |
view.doOnPause { | |
stopWelcomeAnimation(view) | |
} |