How can I set a End Frame of blender movie clip editor to match the end time of the video (without trying to search the End Frame of video)? Currently when I'm importing the video, the End Frame is set to 250 instead of ~600 which my video is currently having.
Your problem - from a VSE point of view:
You want your End Frame Range to be set to your newly imported Footages length.
While still hovering over the VSE view press PageUp.
Hover your mouse over your timeline and press E to match your End Frame with your Current frame. (Blenders Hotkeys are context sensitive)
Make sure, the function Use Preview Range is unchecked if you want your Scene Frame Range to be set accordingly for your final Render.
Further explanation regarding your situation:
You want to achieve this in the MCE directly. Which is possible via some Python code. But for a quick manual workaround just import your MCE Clip into a VSE via Add (Shift+A) - Clip - <Movie Clip Name> as it will produce the result you want in the MCE as well. The Frame Range used is the current Scene ones which is applied to both the VSE and the MCE. You could delete your VSE Strip of the MCE clip afterwards if you don't want it to be rendered out.
$\begingroup$ This has been not working any more by default in the earlier 2.80 versions, but just now the devs reintroduced these hotkeys. :-) $\endgroup$– SamothNov 6, 2019 at 22:31
Go to View > Range then select Set Frame Range To Strips and it's done.
$\begingroup$ In latest version seems to be PageUP to get to the end of the strip then View>Range>Set End Frame $\endgroup$ Sep 26, 2020 at 3:17
$\begingroup$ For 3.1: In Editor + Tracking + Clip use
Set Scene Frames. This adjust Start/End for the animation range. $\endgroup$– minsMay 1, 2022 at 20:32
When your MCE is open, you could just use this line of Python to achieve your goal:
bpy.context.scene.frame_end = [area for area in bpy.data.screens.get(bpy.context.screen.name).areas.values() if area.type == 'CLIP_EDITOR'].spaces.clip.frame_duration
This basically just sets your End Frame to the Length of your Video Clip that is currently loaded into your MCE. It does so by getting the current active Screen, searching for the Area which is the MCE and uses this only one left from the list of all visible areas and from within it takes the selected/active clip and uses its length.
Paste it into a Python Console View, hit Enter et voilà.
And I already described how to execute such a piece of code via hotkey.
Scene.frame_end(the "End: 250" box) to your current playhead position (
Scene.frame_current). It works fine for me (but only with recent versions of Blender like 2.76/2.77a, this behaviour has been added not too long ago). $\endgroup$