Google 致力于为黑人社区推动种族平等。查看具体举措

TakeVideo

class TakeVideo : ActivityResultContract<Uri!, Bitmap!>
kotlin.Any
   ↳ androidx.activity.result.contract.ActivityResultContract<android.net.Uri, android.graphics.Bitmap>
   ↳ androidx.activity.result.contract.ActivityResultContracts.TakeVideo

An ActivityResultContract to take a picture saving it into the provided content-Uri.

Returns a thumbnail.

This can be extended to override createIntent if you wish to pass additional extras to the Intent created by super.createIntent().

Summary

Public constructors

An ActivityResultContract to take a picture saving it into the provided content-Uri.

Public methods
open Intent
createIntent(@NonNull context: Context, @NonNull input: Uri)

ActivityResultContract.SynchronousResult<Bitmap!>?
getSynchronousResult(@NonNull context: Context, @NonNull input: Uri)

Bitmap?
parseResult(resultCode: Int, @Nullable intent: Intent?)

Public constructors

<init>

TakeVideo()

An ActivityResultContract to take a picture saving it into the provided content-Uri.

Returns a thumbnail.

This can be extended to override createIntent if you wish to pass additional extras to the Intent created by super.createIntent().

Public methods

createIntent

@CallSuper @NonNull open fun createIntent(
    @NonNull context: Context,
    @NonNull input: Uri
): Intent

getSynchronousResult

@Nullable fun getSynchronousResult(
    @NonNull context: Context,
    @NonNull input: Uri
): ActivityResultContract.SynchronousResult<Bitmap!>?

parseResult

@Nullable fun parseResult(
    resultCode: Int,
    @Nullable intent: Intent?
): Bitmap?