tPreviewSize(preferredSize.width, preferredSize.height) ĪdjustVideoSurface(screenWidth, screenHeight,preferredSize.width, preferredSize.height, surfaceView) Īnd this the the adaptPrefferedVideoSize method : public void adaptPrefferedVideoSize(Camera.Parameters params) else if (!preferredSize. Start->Run->regedit Open: My Computer->HKEYCURRENTCONFIG->System->CurrentControlSet->Control->VIDEO-> (expand all until you see 'Monitor') Locate: Name Type Data DefaultSetting.XResolution REGDWORD 0x00000400 (1024) DefaultSetting. At the top of the screen in the tool bar select: 'Communication' In the drop down menu select: 'Configure' About half way down the 'Configure PC5250' window there is 'Size'. PreferredSize = params.getPreferredPreviewSizeForVideo() When init params of the camera do this code : Camera.Parameters params = mCamera.getParameters() This is my method to fit video with screen : So my question is,how to capture a video that will fit perfectly to width and height of every screen using MediaRecorder? videoPreview = (VideoView)findViewById(R.id.videoPreview) Īlthough I set the video size and camera parameters,but the video capture still not as big as the device screen.I using Pixel XL emulator,the width is fit the screen,but the height is only half of the screen. Once done recording,I pass the video captured to another activity,and set into a VideoView,the VideoView layout already set to MATCH_PARENT for width and height already. You can download it free here and follow the steps below to screen record as smaller size. You can always record certain window whether it moves or being covered. To record the screen you just need to click on the small. Download Record It to create your marvellous video Record Screen or Specified Window at One Tap Capture your videos at full screen or any size. With Recordit Free you can record the computer screen for a maximum of 5 minutes, which I feel is more than enough for a normal user. I also set the camera parameter in surfaceCreated() as well: mCamera = Camera.open() Record It comes with powerful screen recording, easy to record for everyone. GetWindowManager().getDefaultDisplay().getMetrics(displayMetrics) Screen recorder with facecam: Turn on the front camera to narrow the distance between you and the audience and make the video more popular -Video direction: including three directions. Capture Record your desktop, system sound and/or mic 3. I tried to set video size when prepare recorder: DisplayMetrics displayMetrics = new DisplayMetrics() Select Select the entire screen or a specific area 2. I record video using MediaRecorder in a SurfaceView,once done recording,I pass to another activity to preview the video.I want the video capture is fit perfectly to device screen
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |